SPWebApplication.QueryFeatures method (SPFeatureScope, Boolean)
Retrieves all features in the current Web application that are scoped to Site or Web and have a specific needsUpgrade state.
Assembly: Microsoft.SharePoint (in Microsoft.SharePoint.dll)
public SPFeatureQueryResultCollection QueryFeatures( SPFeatureScope scope, bool needsUpgrade )
- Type: Microsoft.SharePoint.SPFeatureScope
The scope of the features to be retrieved. The supported scopes are limited to Site and Web.
- Type: System.Boolean
true indicates that only the features that require upgrade are included; otherwise, false indicates that features that do not require upgrade are also included.
Return valueType: Microsoft.SharePoint.SPFeatureQueryResultCollection
Returns an SPFeatureQueryResultCollection object that represents all features of a given scope and of the specified status.