Class ItemField
- Namespace
- Dynamicweb.Content.Items.Metadata
- Assembly
- Dynamicweb.dll
Represents an item field metadata.
public class ItemField : IComparable<ItemField>
- Inheritance
-
ItemField
- Implements
- Inherited Members
Constructors
ItemField()
Initializes a new instance of an object.
public ItemField()
ItemField(ItemField)
Initializes a new instance of an object.
public ItemField(ItemField copyFrom)
Parameters
copyFrom
ItemField- Object to copy state from.
Exceptions
- ArgumentNullException
copyFrom
is null.
Properties
DefaultValue
Gets or sets the default value for the field.
public object DefaultValue { get; set; }
Property Value
DefaultValueCulture
Gets the culture information that indicates under which culture the default value was saved.
public CultureInfo DefaultValueCulture { get; set; }
Property Value
DefaultValueExpression
Gets or sets the default value expression for the field.
public string DefaultValueExpression { get; set; }
Property Value
Description
Gets or sets the field description.
public string Description { get; set; }
Property Value
Editor
Gets or sets the editor metadata.
public EditorMetadata Editor { get; set; }
Property Value
EditorConfiguration
Gets or sets the editor configuration (ConfigurableAddin extensibility).
public string EditorConfiguration { get; set; }
Property Value
ExcludeFromSearch
public bool ExcludeFromSearch { get; set; }
Property Value
Name
Gets or sets the user-friendly name of the field.
public string Name { get; set; }
Property Value
Options
Gets or sets the value options setup for this field.
public FieldOptionSetupMetadata Options { get; set; }
Property Value
Parent
Gets or sets the system name of parent item type.
public string Parent { get; set; }
Property Value
SystemName
Gets or sets the system name of the field.
public string SystemName { get; set; }
Property Value
Type
Gets or sets the underlying type of the item field.
[Obsolete("Use UnderlyingType instead")]
public Type Type { get; set; }
Property Value
UnderlyingType
Gets or sets the underlying type of the item field.
public Type UnderlyingType { get; set; }
Property Value
Validators
Gets or sets the list of field validators.
public ValidatorMetadataCollection Validators { get; set; }
Property Value
Methods
CheckRequired()
Returns value indicating whether this field is required.
public bool CheckRequired()
Returns
- bool
- Value indicating whether this field is required.
CompareTo(ItemField)
Compares the current object with the given one and returns the comparison result.
public int CompareTo(ItemField other)
Parameters
other
ItemField- Object to compare with.
Returns
- int
- Comparison result.
CopyTo(ItemField)
Copies the state of the current object into the given one.
public void CopyTo(ItemField target)
Parameters
target
ItemField- Object to copy state into.
Exceptions
- ArgumentNullException
target
is null.
CreateEditorInstance(bool)
Gets the field editor instance with loaded configuration
public Editor CreateEditorInstance(bool isEditing)
Parameters
isEditing
bool- If editor is needed for editing.
Returns
- Editor
- Editor instance.
IsEditor(Type, bool)
public bool IsEditor(Type type, bool checkBaseType = false)
Parameters
Returns
IsEditorType(Type, bool)
[Obsolete("Use IsEditor instead.")]
public bool IsEditorType(Type t, bool checkBaseType = false)
Parameters
Returns
ParseFrom(PropertyInfo)
Returns the field metadata that is parsed from the metadata of the given property.
public static ItemField ParseFrom(PropertyInfo property)
Parameters
property
PropertyInfo- Property to examine.
Returns
- ItemField
- Field metadata.