Dela via


RequirementValidator Class

Determines whether the required context and services are available for the specified type.

Namespace:  Microsoft.Windows.Design
Assembly:  Microsoft.Windows.Design.Extensibility (in Microsoft.Windows.Design.Extensibility.dll)

Syntax

'Declaration
Public NotInheritable Class RequirementValidator
'Usage
Dim instance As RequirementValidator
public sealed class RequirementValidator
public ref class RequirementValidator sealed
public final class RequirementValidator

Remarks

Use the RequirementValidator class to defer creation of objects that do not have their requirements in place. An object may specify a requirement to a service or context item by adding a RequiresServiceAttribute or RequiresContextItemAttribute on its class. Areas of the designer that automatically create objects check these attributes to make sure the object can be used in the designer context.

You can define other types of requirements by deriving from RequirementAttribute and implementing the abstract MeetsRequirement method.

Inheritance Hierarchy

System.Object
  Microsoft.Windows.Design.RequirementValidator

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

See Also

Reference

RequirementValidator Members

Microsoft.Windows.Design Namespace

RequiresServiceAttribute

RequiresContextItemAttribute

UsesItemPolicyAttribute

PrimarySelectionPolicy

FeatureProvider

Other Resources

Feature Providers and Feature Connectors

Understanding WPF Designer Extensibility