Share via


PackageUtilities.IsCapabilityMatch Method

Definition

Checks whether a given project matches the requirements prescribed in an AppliesTo expression.

Overloads

IsCapabilityMatch(String, String)

Checks whether a given set of project capabilities fulfills the requirements prescribed in an AppliesTo expression.

IsCapabilityMatch(IVsHierarchy, String)

Checks whether a given project matches the requirements prescribed in an AppliesTo expression.

IsCapabilityMatch(IVsBooleanSymbolPresenceChecker, String)

Checks whether a given project matches the requirements prescribed in an AppliesTo expression.

Remarks

For more information about project capabilities, see VsProjectCapabilityExpressionMatcher.

IsCapabilityMatch(String, String)

Checks whether a given set of project capabilities fulfills the requirements prescribed in an AppliesTo expression.

public:
 static bool IsCapabilityMatch(Platform::String ^ capabilities, Platform::String ^ capabilityAppliesToExpression);

Parameters

capabilities
String

A space-delimited list of project capabilities, same format as __VSHPROPID5.VSHPROPID_ProjectCapabilities -- null and empty is allowed and results in an empty set of project capabilities during evaluation.

capabilityAppliesToExpression
String

The capability expression, such as "(VisualC | CSharp) + (MSTest | NUnit)". The '|' is the OR operator. The '&' and '+' characters are both AND operators. The '!' character is the NOT operator. Parentheses force evaluation precedence order. A null or empty expression is evaluated as a match.

Returns

true if the project contains a matching set of project capabilities; false otherwise.

Applies to

IsCapabilityMatch(IVsHierarchy, String)

Checks whether a given project matches the requirements prescribed in an AppliesTo expression.

public:
[System::Runtime::CompilerServices::Extension]
 static bool IsCapabilityMatch(Microsoft::VisualStudio::Shell::Interop::IVsHierarchy ^ project, Platform::String ^ capabilityAppliesToExpression);

Parameters

project
IVsHierarchy

The project to test compatibility.

capabilityAppliesToExpression
String

The capability expression, such as "(VisualC | CSharp) + (MSTest | NUnit)". The '|' is the OR operator. The '&' and '+' characters are both AND operators. The '!' character is the NOT operator. Parentheses force evaluation precedence order. A null or empty expression is evaluated as a match.

Returns

true if the project contains a matching set of project capabilities; false otherwise.

Applies to

IsCapabilityMatch(IVsBooleanSymbolPresenceChecker, String)

Checks whether a given project matches the requirements prescribed in an AppliesTo expression.

public:
 static bool IsCapabilityMatch(Microsoft::VisualStudio::Shell::Interop::IVsBooleanSymbolPresenceChecker ^ capabilityPresenceChecker, Platform::String ^ capabilityAppliesToExpression);

Parameters

capabilityPresenceChecker
IVsBooleanSymbolPresenceChecker

The project capability presence checker to use when evaluating the expression.

capabilityAppliesToExpression
String

The capability expression, such as "(VisualC | CSharp) + (MSTest | NUnit)". The '|' is the OR operator. The '&' and '+' characters are both AND operators. The '!' character is the NOT operator. Parentheses force evaluation precedence order. A null or empty expression is evaluated as a match.

Returns

true if the project contains a matching set of project capabilities; false otherwise.

Applies to