Class FormModel
- java.lang.Object
-
- de.xima.fc.gui.designer.form.model.FormModel
-
- All Implemented Interfaces:
Serializable
public class FormModel extends Object implements Serializable
POJO model holding data related to the current form edited in the designer.- Since:
- 7.0.0
- Author:
- XIMA MEDIA GmbH
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description FormModel(IXFormRenderConfig formRenderConfig, List<CssInclude> cssIncludes, String clientI18nScript, String designerConfig, String metaDataScript, String formI18nScript, String xmFormVRulesScript, String xmFormPluginVRulesScript)
Creates a new POJO model with the given data.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static FormModel
empty()
String
getClientI18nScript()
List<CssInclude>
getCssIncludes()
String
getDesignerConfig()
String
getFormI18nScript()
IXFormRenderConfig
getFormRenderConfig()
String
getMetaDataScript()
String
getXmFormPluginVRulesScript()
String
getXmFormVRulesScript()
void
setDesignerConfig(String designerConfig)
-
-
-
Constructor Detail
-
FormModel
public FormModel(IXFormRenderConfig formRenderConfig, List<CssInclude> cssIncludes, String clientI18nScript, String designerConfig, String metaDataScript, String formI18nScript, String xmFormVRulesScript, String xmFormPluginVRulesScript)
Creates a new POJO model with the given data.- Parameters:
formRenderConfig
- The value returned bygetFormRenderConfig()
cssIncludes
- The value returned bygetCssIncludes()
clientI18nScript
- The value returned bygetClientI18nScript()
designerConfig
- The value returned bygetDesignerConfig()
metaDataScript
- The value returned bygetMetaDataScript()
formI18nScript
- The value returned bygetFormI18nScript()
xmFormPluginVRulesScript
- The value returned bygetXmFormPluginVRulesScript()
xmFormVRulesScript
- The value returned bygetXmFormVRulesScript()
-
-
Method Detail
-
getClientI18nScript
public String getClientI18nScript()
- Returns:
- The script for making the i18n keys from the
designer-client.multiproperties
file available to the client. Adds the i18n key value pairs towindow.Designer.Lang[code]
.
-
getCssIncludes
public List<CssInclude> getCssIncludes()
- Returns:
- A list of additional CSS files to be included in the designer, such as CSS files from form and client files.
-
getDesignerConfig
public String getDesignerConfig()
- Returns:
- The JSON object with the client side configuration for the designer.
-
getFormI18nScript
public String getFormI18nScript()
- Returns:
- The script for making the i18n keys from the i18n client templates available to the client. Creates a
variable
XM_FORM_I18N
in the global window scope.
-
getFormRenderConfig
public IXFormRenderConfig getFormRenderConfig()
- Returns:
- The form render config for the form that is being edited in the designer.
-
getMetaDataScript
public String getMetaDataScript()
- Returns:
- The script for creating the
XFC_METADATA
object in the global window scope.
-
getXmFormPluginVRulesScript
public String getXmFormPluginVRulesScript()
- Returns:
- The script for creating the
XM_FORM_PLUGIN_VRULES
object in the global window scope.
-
getXmFormVRulesScript
public String getXmFormVRulesScript()
- Returns:
- The script for creating the
XM_FORM_VRULES
object in the global window scope.
-
setDesignerConfig
public void setDesignerConfig(String designerConfig)
- Parameters:
designerConfig
- The JSON object with the client side configuration for the designer.
-
empty
public static FormModel empty()
- Returns:
- A new empty form model with no data.
-
-