public class FieldBase extends ComponentBase implements Field
Field implementations
Sets the component type name so that all field templates have a fixed contract
Holds a nested Label with configuration for rendering the
label and configuration on label placement.
INITIAL_ORDER_VALUE| Constructor and Description |
|---|
FieldBase() |
| Modifier and Type | Method and Description |
|---|---|
protected <T> void |
copyProperties(T component)
Copies the properties over for the copy method
|
protected Class<? extends ComponentSecurity> |
getComponentSecurityClass()
Returns the security class that is associated with the component (used for initialization and validation)
|
List<Component> |
getComponentsForLifecycle()
List of components that are contained within the component and should be sent through
the lifecycle
|
String |
getComponentTypeName()
The name for the component type
|
Label |
getFieldLabel()
Label instance for the field |
FieldSecurity |
getFieldSecurity()
Field Security object that indicates what authorization (permissions) exist for the field
|
String |
getLabel()
Label text for the field
|
int |
getLabelColSpan()
Label column span for the field
|
UifConstants.Position |
getLabelPlacement()
Indicates where the label is placed in relation to the field (valid options are
LEFT, RIGHT, BOTTOM, and TOP
|
List<String> |
getLabelStyleClasses()
Label style classes for the field
|
String |
getShortLabel()
Short label for the field
|
boolean |
isLabelRendered()
Indicates whether the contained
Label has been rendered
as part of another field and thus should not be rendered with the
attribute |
void |
performFinalize(View view,
Object model,
Component parent)
The following finalization is performed:
Set the labelForComponentId to this component id
Set the label text on the label field from the field's label property
Set the render property on the label's required message field if this
field is marked as required
If label placement is right, set render colon to false
|
void |
performInitialization(View view,
Object model)
The following initialization is performed:
|
void |
setComponentSecurity(ComponentSecurity componentSecurity)
Override to assert a
FieldSecurity instance is set |
void |
setFieldLabel(Label fieldLabel)
Setter for the field's label field
|
void |
setLabel(String labelText)
Setter for the field's label text
|
void |
setLabelColSpan(int labelColSpan)
Setter for the field's label column span
|
void |
setLabelPlacement(UifConstants.Position labelPlacement)
Setter for the label's position in relation to the field (control if editable)
|
void |
setLabelRendered(boolean labelRendered)
Setter for the label field rendered indicator
|
void |
setLabelStyleClasses(List<String> labelStyleClasses)
Setter for the field's label style classes
|
protected void |
setNestedComponentIdAndSuffix(Component component,
String suffix)
Helper method for suffixing the ids of the fields nested components
|
void |
setShortLabel(String shortLabel)
Setter for the field's short label text
|
void |
setShowLabel(boolean showLabel)
Sets whether the label should be displayed
|
addCellCssClass, addDataAttribute, addDataAttributeIfNonEmpty, addStyleClass, appendToStyle, completeValidation, copy, getAdditionalComponentsToRefresh, getAdditionalComponentsToRefreshJs, getAdditionalCssClasses, getAlign, getBaseId, getCellCssClasses, getCellStyle, getCellStyleClassesAsString, getCellWidth, getColSpan, getComponentModifiers, getComponentPrototypes, getComponentSecurity, getConditionalRefresh, getConditionalRefreshConditionJs, getConditionalRefreshControlNames, getContext, getCssClasses, getDataAttributes, getEventHandlerScript, getFinalizeMethodAdditionalArguments, getFinalizeMethodInvoker, getFinalizeMethodToCall, getId, getLibraryCssClasses, getMethodToCallOnRefresh, getOnBlurScript, getOnChangeScript, getOnClickScript, getOnCloseScript, getOnDblClickScript, getOnDocumentReadyScript, getOnFocusScript, getOnKeyDownScript, getOnKeyPressScript, getOnKeyUpScript, getOnLoadScript, getOnMouseDownScript, getOnMouseMoveScript, getOnMouseOutScript, getOnMouseOverScript, getOnMouseUpScript, getOnSubmitScript, getOnUnloadScript, getOrder, getPostRenderContent, getPreRenderContent, getProgressiveDisclosureConditionJs, getProgressiveDisclosureControlNames, getProgressiveRender, getPropertyReplacerComponents, getPropertyReplacers, getRefreshTimer, getRefreshWhenChangedPropertyNames, getRenderedHtmlOutput, getRequired, getRowSpan, getSimpleDataAttributes, getStyle, getStyleClassesAsString, getTemplate, getTemplateName, getTemplateOptions, getTemplateOptionsJSString, getTitle, getToolTip, getValign, getWidth, isDisableSessionPersistence, isDisclosedByAction, isForceSessionPersistence, isHidden, isProgressiveRenderAndRefresh, isProgressiveRenderViaAJAX, isReadOnly, isRefreshedByAction, isRender, isResetDataOnRefresh, isRetrieveViaAjax, isSelfRendered, isSkipInTabOrder, performApplyModel, pushAllToContext, pushObjectToContext, pushToPropertyReplacerContext, setAdditionalComponentsToRefresh, setAdditionalCssClasses, setAlign, setBaseId, setCellCssClasses, setCellStyle, setCellWidth, setColSpan, setComponentModifiers, setConditionalRefresh, setContext, setCssClasses, setDataAttributes, setDisableSessionPersistence, setDisclosedByAction, setFinalizeMethodAdditionalArguments, setFinalizeMethodInvoker, setFinalizeMethodToCall, setForceSessionPersistence, setHidden, setId, setLibraryCssClasses, setMethodToCallOnRefresh, setOnBlurScript, setOnChangeScript, setOnClickScript, setOnCloseScript, setOnDblClickScript, setOnDocumentReadyScript, setOnFocusScript, setOnKeyDownScript, setOnKeyPressScript, setOnKeyUpScript, setOnLoadScript, setOnMouseDownScript, setOnMouseMoveScript, setOnMouseOutScript, setOnMouseOverScript, setOnMouseUpScript, setOnSubmitScript, setOnUnloadScript, setOrder, setPostRenderContent, setPreRenderContent, setProgressiveRender, setProgressiveRenderAndRefresh, setProgressiveRenderViaAJAX, setPropertyReplacers, setReadOnly, setRefreshedByAction, setRefreshTimer, setRefreshWhenChangedPropertyNames, setRender, setRenderedHtmlOutput, setRequired, setResetDataOnRefresh, setRetrieveViaAjax, setRowSpan, setSelfRendered, setSkipInTabOrder, setStyle, setTemplate, setTemplateName, setTemplateOptions, setTemplateOptionsJSString, setTitle, setToolTip, setValign, setWidthgetExpressionGraph, getPropertyExpression, getPropertyExpressions, getRefreshExpressionGraph, setExpressionGraph, setPropertyExpressions, setRefreshExpressionGraphgetComponentCode, getNamespaceCode, setComponentCode, setNamespaceCodeclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitaddCellCssClass, addDataAttribute, addStyleClass, appendToStyle, completeValidation, copy, getAdditionalComponentsToRefresh, getAdditionalComponentsToRefreshJs, getAdditionalCssClasses, getAlign, getBaseId, getCellCssClasses, getCellStyle, getCellWidth, getColSpan, getComponentModifiers, getComponentPrototypes, getComponentSecurity, getConditionalRefresh, getConditionalRefreshConditionJs, getConditionalRefreshControlNames, getContext, getCssClasses, getDataAttributes, getEventHandlerScript, getFinalizeMethodAdditionalArguments, getFinalizeMethodInvoker, getFinalizeMethodToCall, getId, getLibraryCssClasses, getOrder, getPostRenderContent, getPreRenderContent, getProgressiveDisclosureConditionJs, getProgressiveDisclosureControlNames, getProgressiveRender, getPropertyReplacerComponents, getPropertyReplacers, getRefreshTimer, getRefreshWhenChangedPropertyNames, getRenderedHtmlOutput, getRequired, getRowSpan, getSimpleDataAttributes, getStyle, getTemplate, getTemplateName, getTemplateOptions, getTemplateOptionsJSString, getTitle, getToolTip, getValign, getWidth, isDisableSessionPersistence, isDisclosedByAction, isForceSessionPersistence, isHidden, isProgressiveRenderAndRefresh, isProgressiveRenderViaAJAX, isReadOnly, isRefreshedByAction, isRender, isResetDataOnRefresh, isRetrieveViaAjax, isSelfRendered, performApplyModel, pushAllToContext, pushObjectToContext, setAdditionalComponentsToRefresh, setAdditionalCssClasses, setAlign, setBaseId, setCellCssClasses, setCellStyle, setCellWidth, setColSpan, setComponentModifiers, setConditionalRefresh, setContext, setCssClasses, setDataAttributes, setDisableSessionPersistence, setDisclosedByAction, setForceSessionPersistence, setHidden, setId, setLibraryCssClasses, setOrder, setPostRenderContent, setPreRenderContent, setProgressiveRender, setProgressiveRenderAndRefresh, setProgressiveRenderViaAJAX, setPropertyReplacers, setReadOnly, setRefreshedByAction, setRefreshTimer, setRefreshWhenChangedPropertyNames, setRender, setRenderedHtmlOutput, setRequired, setResetDataOnRefresh, setRetrieveViaAjax, setRowSpan, setSelfRendered, setStyle, setTemplate, setTemplateName, setTemplateOptions, setTemplateOptionsJSString, setTitle, setToolTip, setValign, setWidthgetExpressionGraph, getPropertyExpression, getPropertyExpressions, getRefreshExpressionGraph, setExpressionGraph, setPropertyExpressions, setRefreshExpressionGraphgetComponentCode, getNamespaceCodegetOnBlurScript, getOnChangeScript, getOnClickScript, getOnCloseScript, getOnDblClickScript, getOnDocumentReadyScript, getOnFocusScript, getOnKeyDownScript, getOnKeyPressScript, getOnKeyUpScript, getOnLoadScript, getOnMouseDownScript, getOnMouseMoveScript, getOnMouseOutScript, getOnMouseOverScript, getOnMouseUpScript, getOnSubmitScript, getOnUnloadScript, setOnBlurScript, setOnChangeScript, setOnClickScript, setOnCloseScript, setOnDblClickScript, setOnDocumentReadyScript, setOnFocusScript, setOnKeyDownScript, setOnKeyPressScript, setOnKeyUpScript, setOnLoadScript, setOnMouseDownScript, setOnMouseMoveScript, setOnMouseOutScript, setOnMouseOverScript, setOnMouseUpScript, setOnSubmitScript, setOnUnloadScriptpublic FieldBase()
public void performInitialization(View view, Object model)
performInitialization in interface ComponentperformInitialization in class ComponentBaseview - - view instance in which the component belongsmodel - - object instance containing the view dataComponentBase.performInitialization(org.kuali.rice.krad.uif.view.View, java.lang.Object)public void performFinalize(View view, Object model, Component parent)
performFinalize in interface ComponentperformFinalize in class ComponentBaseview - - view instance that should be finalized for renderingmodel - - top level object containing the dataparent - - parent componentComponentBase.performFinalize(org.kuali.rice.krad.uif.view.View,
java.lang.Object, org.kuali.rice.krad.uif.component.Component)protected void setNestedComponentIdAndSuffix(Component component, String suffix)
component - component to adjust id forsuffix - suffix to append to idpublic final String getComponentTypeName()
ComponentThis is used within the rendering layer to pass the component instance into the template. The component instance is exported under the name given by this method.
getComponentTypeName in interface ComponentComponent.getComponentTypeName()public List<Component> getComponentsForLifecycle()
Component
Used by ViewHelperService for the various lifecycle callbacks
getComponentsForLifecycle in interface ComponentgetComponentsForLifecycle in class ComponentBaseComponentBase.getComponentsForLifecycle()public String getLabel()
FieldThe label is generally used to identify the field in the user interface
getLabel in interface FieldField.getLabel()public void setLabel(String labelText)
FieldsetLabel in interface FieldField.setLabel(java.lang.String)public List<String> getLabelStyleClasses()
FieldgetLabelStyleClasses in interface FieldField.getLabelStyleClasses()public void setLabelStyleClasses(List<String> labelStyleClasses)
FieldsetLabelStyleClasses in interface FieldField.setLabelStyleClasses(java.util.List<java.lang.String>)public int getLabelColSpan()
FieldgetLabelColSpan in interface FieldField.getLabelColSpan()public void setLabelColSpan(int labelColSpan)
FieldsetLabelColSpan in interface FieldField.setLabelColSpan(int)public String getShortLabel()
FieldFor areas of the user interface that have limited area (such as table headers), the short label can be used to identify the field
getShortLabel in interface FieldField.getShortLabel()public void setShortLabel(String shortLabel)
FieldsetShortLabel in interface FieldField.setShortLabel(java.lang.String)public void setShowLabel(boolean showLabel)
Convenience method for configuration that sets the render indicator on
the fields Label instance
showLabel - true if label should be displayed, false if the label
should not be displayedpublic Label getFieldLabel()
FieldLabel instance for the field
The label field contains the labeling text for the field in addition to configuration for rendering in the user interface (such as the styling for the label area)
getFieldLabel in interface FieldField.getLabel()public void setFieldLabel(Label fieldLabel)
FieldsetFieldLabel in interface FieldField.setFieldLabel(org.kuali.rice.krad.uif.element.Label)public UifConstants.Position getLabelPlacement()
public void setLabelPlacement(UifConstants.Position labelPlacement)
labelPlacement - public boolean isLabelRendered()
FieldLabel has been rendered
as part of another field and thus should not be rendered with the
attributeisLabelRendered in interface FieldField.isLabelRendered()public void setLabelRendered(boolean labelRendered)
FieldsetLabelRendered in interface FieldField.setLabelRendered(boolean)public FieldSecurity getFieldSecurity()
FieldgetFieldSecurity in interface FieldField.getFieldSecurity()public void setComponentSecurity(ComponentSecurity componentSecurity)
FieldSecurity instance is setsetComponentSecurity in interface ComponentsetComponentSecurity in class ComponentBasecomponentSecurity - instance of FieldSecurityComponent.setComponentSecurity(org.kuali.rice.krad.uif.component.ComponentSecurity)protected Class<? extends ComponentSecurity> getComponentSecurityClass()
ComponentBasegetComponentSecurityClass in class ComponentBaseComponentBase.getComponentSecurityClass()protected <T> void copyProperties(T component)
ComponentBasecopyProperties in class ComponentBasecomponent - base beanComponentBase.copy()Copyright © 2005–2016 The Kuali Foundation. All rights reserved.