Interface IEditablePropertiesCollector
Defines methods for collecting properties editable via FormComponent<TProperties, TValue>s from a model.
public interface IEditablePropertiesCollector
- Extension Methods
Methods
GetEditableProperties(object)
Returns a collection of System.Reflection.PropertyInfos editable in Form builder's UI.
IEnumerable<PropertyInfo> GetEditableProperties(object model)
Parameters
modelobjectObject with editable properties.
Returns
- IEnumerable<PropertyInfo>
Exceptions
- ArgumentNullException
Thrown when
modelis null.
GetEditablePropertiesWithEditors(object, FormComponentContext)
Returns key value pair collection of FormComponents paired with the System.Reflection.PropertyInfo that is edited via given FormComponent in Form builder's UI.
IEnumerable<KeyValuePair<PropertyInfo, FormComponent>> GetEditablePropertiesWithEditors(object model, FormComponentContext context)
Parameters
modelobjectObject with editable properties.
contextFormComponentContextContextual information specifying where the form components are being used.
Returns
- IEnumerable<KeyValuePair<PropertyInfo, FormComponent>>
Exceptions
- ArgumentNullException
Thrown when
modelis null.
GetFormComponents(object, FormComponentContext)
Collects properties annotated with EditingComponentAttribute from given model and
returns collection of FormComponents used for editing those properties in UI.
IEnumerable<FormComponent> GetFormComponents(object model, FormComponentContext context)
Parameters
modelobjectObject with editable properties.
contextFormComponentContextContextual information specifying where the form components are being used.
Returns
- IEnumerable<FormComponent>
Collection of FormComponents that enables to edit
modelin Form builder's UI. Values from themodelare bound to components that display them.
Exceptions
- ArgumentNullException
Thrown when
modelis null.
GetFormComponents(object, string, FormComponentContext)
Collects properties annotated with EditingComponentAttribute from given model and
returns collection of FormComponents used for editing those properties in UI.
IEnumerable<FormComponent> GetFormComponents(object model, string changedFieldName, FormComponentContext context)
Parameters
modelobjectObject with editable properties.
changedFieldNamestringName of the editing component that triggered the request.
contextFormComponentContextContextual information specifying where the form components are being used.
Returns
- IEnumerable<FormComponent>
Collection of FormComponents that enables to edit
modelin Form builder's UI. Values from themodelare bound to components that display them.
Exceptions
- ArgumentNullException
Thrown when
modelis null.