November Happy Hour will be moved to Thursday December 5th.

Class PropertyDefinitionTypePlugInAttribute

Automatically register a property type on startup

Inheritance
System.Object
PropertyDefinitionTypePlugInAttribute
Namespace: EPiServer.PlugIn
Assembly: EPiServer.dll
Version: 12.0.3
Syntax
public class PropertyDefinitionTypePlugInAttribute : PlugInAttribute
Examples

This property type will automatically be registered with EPiServer

    [PropertyDefinitionTypePlugIn]
public class PropertySpecialLink : PropertyString
{
// ...
// ...
// ...
}

Constructors

PropertyDefinitionTypePlugInAttribute()

Initializes a new instance of the PropertyDefinitionTypePlugInAttribute class.

Declaration
public PropertyDefinitionTypePlugInAttribute()

Properties

GUID

Gets or sets the unique id for the corresponding PropertyDefinitionType.

Declaration
public string GUID { get; set; }
Property Value
Type Description
System.String

The unique id of the PropertyDefinitionType. Default value is null.

Remarks

Use GetGUID() to check if a value has been assigned.

Methods

GetGUID()

Returns the nullable Guid for the corresponding property GUID.

Declaration
public Nullable<Guid> GetGUID()
Returns
Type Description
System.Nullable<System.Guid>
Remarks

If the usage of the attribute has not set the GUID property this will not have any value.

Match(Object)

Returns a value indicating whether this instance equals a specified object.

Declaration
public override bool Match(object o)
Parameters
Type Name Description
System.Object o

The object to match.

Returns
Type Description
System.Boolean

True if the object matches this instance.

Examples

Used internally to selectively load plugins.

Start()

Auto-start method that is called upon application startup.

Declaration
public static void Start()
Remarks

The PlugInLocator will call the static Start method on classes derived from PlugInAttribute on application startup. The action performed by this attribute is to register this property type.

Extension Methods