Class PropertyDataInterceptor<TPropertyData>

Used to handle how values should be retrevied and written to a PropertyData type.

Inheritance
System.Object
PropertyDataInterceptor<TPropertyData>
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: EPiServer.DataAbstraction.RuntimeModel
Assembly: EPiServer.dll
Version: 8.11.0
Syntax
public class PropertyDataInterceptor<TPropertyData> : IPropertyDataInterceptor where TPropertyData : PropertyData
Type Parameters
Name Description
TPropertyData

Constructors

PropertyDataInterceptor()

Declaration
public PropertyDataInterceptor()

Methods

Use<TModelValue>(Func<TPropertyData, Object>, Action<TPropertyData, Object>)

Specifies which get and set accessors that should be used when accessing a PropertyData type.

Declaration
public PropertyDataInterceptor<TPropertyData> Use<TModelValue>(Func<TPropertyData, object> getAccessor, Action<TPropertyData, object> setAccessor)
Parameters
Type Name Description
System.Func<TPropertyData, System.Object> getAccessor

The get accessor.

System.Action<TPropertyData, System.Object> setAccessor

The set accessor.

Returns
Type Description
PropertyDataInterceptor<TPropertyData>

This instance.

Type Parameters
Name Description
TModelValue

The type of model value that the accessors should handle.

Remarks

This can be used to register several TModelValue to the same type of PropertyData.

Explicit Interface Implementations

IPropertyDataInterceptor.GetValue(PropertyData, Type)

Declaration
object IPropertyDataInterceptor.GetValue(PropertyData propertyData, Type returnType)
Parameters
Type Name Description
PropertyData propertyData
System.Type returnType
Returns
Type Description
System.Object

IPropertyDataInterceptor.SetValue(PropertyData, Type, Object)

Declaration
void IPropertyDataInterceptor.SetValue(PropertyData propertyData, Type valueType, object value)
Parameters
Type Name Description
PropertyData propertyData
System.Type valueType
System.Object value

Implements

Extension Methods