Class DictionarySelectionFactory
A selection factory that uses the values from the dictionary of the meta field as EPiServer.Shell.ObjectEditing.SelectItem
Inheritance
System.Object
DictionarySelectionFactory
Implements
EPiServer.Shell.ObjectEditing.ISelectionFactory
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.Commerce.SpecializedProperties
Assembly: EPiServer.Business.Commerce.dll
Version: 9.24.1Syntax
public class DictionarySelectionFactory : ISelectionFactory
Constructors
DictionarySelectionFactory()
Declaration
public DictionarySelectionFactory()
Methods
GetSelections(ExtendedMetadata)
Creates a list of select items from the dictionary of the meta field.
Declaration
public virtual IEnumerable<ISelectItem> GetSelections(ExtendedMetadata metadata)
Parameters
| Type | Name | Description |
|---|---|---|
| EPiServer.Shell.ObjectEditing.ExtendedMetadata | metadata | The metadata for a property. |
Returns
| Type | Description |
|---|---|
| System.Collections.Generic.IEnumerable<EPiServer.Shell.ObjectEditing.ISelectItem> | A list of selection items. |
LoadDictionary(String)
Load the dictionary from the specified meta field.
Declaration
protected virtual MetaDictionary LoadDictionary(string metaFieldName)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | metaFieldName | The name of the meta field. |
Returns
| Type | Description |
|---|---|
| MetaDictionary | The dictionary from the meta field. |
ShouldHaveEmptyOption(String)
Determines if an empty select item should be used.
Declaration
protected virtual bool ShouldHaveEmptyOption(string metaFieldName)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | metaFieldName | The name of the metafield. |
Returns
| Type | Description |
|---|---|
| System.Boolean |
|
Implements
EPiServer.Shell.ObjectEditing.ISelectionFactory