Class FormMeta
java.lang.Object
com.inductiveautomation.ignition.gateway.localdb.persistence.FormMeta
- All Implemented Interfaces:
- Serializable,- Comparable<FormMeta>
This class encapsulates all of the additional information that we add to each persistent field so that we can
 automatically create web UIs that deal with the fields.
- See Also:
- 
Nested Class SummaryNested Classes
- 
Field SummaryFieldsModifier and TypeFieldDescriptionprotected CategoryThe category that the field belongs to.protected booleanControls whether or not the field, if visible, is enabled on an add/edit screenprotected booleanWhether or not the value of this field should be escaped when displayed.protected SFieldMetaprotected Stringprotected Stringprotected Stringprotected Stringprotected intThe relative order (within this field's category) that the field should appear.protected booleanalternate required method.protected booleanWhether or not the field's default value should be shown on an add/edit screenprotected List<org.apache.wicket.validation.IValidator>A list of wicket validators that should be applied to the fieldprotected booleanControls whether or not the field is visible on an add/edit screen
- 
Constructor SummaryConstructorsConstructorDescriptionFormMeta(SFieldMeta field) FormMeta(SFieldMeta field, IEditorSource editorSource) 
- 
Method SummaryModifier and TypeMethodDescriptionaddValidator(org.apache.wicket.validation.IValidator validator) intorg.apache.wicket.model.IModelProvided for subclasses to have custom logic to look up any record-specific instructions for a fieldgetField()intList<org.apache.wicket.validation.IValidator>org.apache.wicket.markup.html.form.FormComponentinstallValidators(org.apache.wicket.markup.html.form.FormComponent c) booleanbooleanbooleanbooleanbooleanorg.apache.wicket.ComponentnewEditorComponent(String id, RecordEditMode mode, SRecordInstance record) setCategory(Category category) setCategory(String displayKey, int order) setEditorSource(IEditorSource editorSource) setEnabled(boolean enabled) setEscapeHTMLOnDisplay(boolean escapeHtmlOnDisplay) setExtendedDescriptionSource(FormMeta.IExtendedDescriptionSource extendedDescriptionSource) setFieldDescriptionKey(String fieldDescriptionKey) setFieldDescriptionKeyAddMode(String fieldDescriptionKeyAddMode) setFieldDescriptionKeyEditMode(String fieldDescriptionKeyEditMode) setFieldNameKey(String fieldNameKey) setFieldOrder(int fieldOrder) setRequired(boolean required) Normally, a field is marked as required by using the SMANDATORY field flag.setShowDefault(boolean showDefault) setVisible(boolean visible) toString()
- 
Field Details- 
field
- 
fieldNameKey
- 
fieldDescriptionKey
- 
fieldDescriptionKeyAddMode
- 
fieldDescriptionKeyEditMode
- 
showDefaultprotected boolean showDefaultWhether or not the field's default value should be shown on an add/edit screen
- 
visibleprotected boolean visibleControls whether or not the field is visible on an add/edit screen
- 
enabledprotected boolean enabledControls whether or not the field, if visible, is enabled on an add/edit screen
- 
requiredprotected boolean requiredalternate required method. see setter docs.
- 
escapeHtmlOnDisplayprotected boolean escapeHtmlOnDisplayWhether or not the value of this field should be escaped when displayed.
- 
fieldOrderprotected int fieldOrderThe relative order (within this field's category) that the field should appear. Lower numbers appear first. Set automatically based on the order that the field is added to the category.
- 
validatorsA list of wicket validators that should be applied to the field
- 
categoryThe category that the field belongs to.
 
- 
- 
Constructor Details- 
FormMeta
- 
FormMeta
 
- 
- 
Method Details- 
toString
- 
getField
- 
addValidator
- 
getValidators
- 
isVisiblepublic boolean isVisible()
- 
setVisible
- 
isRequiredpublic boolean isRequired()
- 
setRequiredNormally, a field is marked as required by using the SMANDATORY field flag. But sometimes we can't use that flag because it adds a NOT_NULL constraint to the DB, which isn't acceptable for legacy reasons, and so a field can set this flag on the FormMeta in order to still have the UI treat the field as required.
- 
getCategory
- 
setCategory
- 
setCategory
- 
getFieldOrderpublic int getFieldOrder()
- 
setFieldOrder
- 
getFieldNameKey
- 
setFieldNameKey
- 
getFieldDescriptionKey
- 
setFieldDescriptionKey
- 
getExtendedDescriptionProvided for subclasses to have custom logic to look up any record-specific instructions for a field
- 
newEditorComponentpublic org.apache.wicket.Component newEditorComponent(String id, RecordEditMode mode, SRecordInstance record) 
- 
getEditorSource
- 
setEditorSource
- 
isShowDefaultpublic boolean isShowDefault()
- 
setShowDefault
- 
installValidatorspublic org.apache.wicket.markup.html.form.FormComponent installValidators(org.apache.wicket.markup.html.form.FormComponent c) 
- 
compareTo- Specified by:
- compareToin interface- Comparable<FormMeta>
 
- 
getFieldDescriptionKeyAddMode
- 
setFieldDescriptionKeyAddMode
- 
getFieldDescriptionKeyEditMode
- 
setFieldDescriptionKeyEditMode
- 
getExtendedDescriptionSource
- 
setExtendedDescriptionSourcepublic FormMeta setExtendedDescriptionSource(FormMeta.IExtendedDescriptionSource extendedDescriptionSource) 
- 
isEnabledpublic boolean isEnabled()
- 
setEnabled
- 
isEscapeHTMLOnDisplaypublic boolean isEscapeHTMLOnDisplay()
- 
setEscapeHTMLOnDisplay
 
-