|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.olat.core.gui.components.form.flexible.impl.FormItemImpl
org.olat.core.gui.components.form.flexible.impl.elements.AbstractTextElement
public abstract class AbstractTextElement
Description:
TODO: patrickb Class Description for AbstractTextElement
Initial Date: 27.11.2006
| Field Summary |
|---|
| Fields inherited from interface org.olat.core.gui.components.form.flexible.FormItem |
|---|
ERRORC, EXAMPLEC, LABELC |
| Fields inherited from interface org.olat.core.gui.components.form.flexible.FormBaseComponentIdProvider |
|---|
DISPPREFIX |
| Constructor Summary | |
|---|---|
AbstractTextElement(java.lang.String name)
|
|
| Method Summary | |
|---|---|
java.lang.String |
getValue()
Get the value of the text element. |
java.lang.String |
getValue(Filter filter)
Get the value and filter it using the given filter. |
boolean |
isEmpty()
Check if the text element is empty |
boolean |
isEmpty(java.lang.String errorKey)
Check if the text element is empty |
void |
reset()
reset the data in the field to a initial/predefined value. |
void |
setDisplaySize(int displaySize)
defines the desired display size of the element |
void |
setIsEqualCheck(java.lang.String otherValue,
java.lang.String errorKey)
compares a text value with another value |
void |
setItemValidatorProvider(ItemValidatorProvider itemValidatorProvider)
to be set if TextElement should be validated with its validate() method |
void |
setMaxLength(int maxLength)
|
void |
setNewOriginalValue(java.lang.String value)
Set a new value as the original value that is used when resetting the form. |
void |
setNotEmptyCheck(java.lang.String errorKey)
|
void |
setNotLongerThanCheck(int maxLength,
java.lang.String errorKey)
|
void |
setRegexMatchCheck(java.lang.String regExp,
java.lang.String errorKey)
|
void |
setValue(java.lang.String value)
Sets the value. |
void |
validate(java.util.List validationResults)
validate the data in the field, create error messages or update any component. |
| Methods inherited from class org.olat.core.gui.components.form.flexible.impl.FormItemImpl |
|---|
addActionListener, clearError, doDispatchFormRequest, evalFormRequest, getAction, getActionListenersFor, getComponent, getEmptyDisplayText, getErrorC, getErrorText, getExampleC, getExampleText, getFormDispatchId, getLabelC, getLabelText, getName, getRootForm, getTranslator, getUserObject, hasError, hasExample, hasFocus, hasLabel, isEnabled, isInlineEditingOn, isMandatory, isVisible, setEmptyDisplayText, setEnabled, setErrorComponent, setErrorKey, setExampleKey, setFocus, setLabel, setLabelComponent, setMandatory, setRootForm, setTranslator, setUserObject, setVisible, showError, showExample, showLabel, toString |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.olat.core.gui.components.form.flexible.FormItem |
|---|
addActionListener, clearError, doDispatchFormRequest, evalFormRequest, getAction, getActionListenersFor, getComponent, getErrorC, getErrorText, getExampleC, getExampleText, getLabelC, getLabelText, getName, getRootForm, getTranslator, getUserObject, hasError, hasExample, hasFocus, hasLabel, isEnabled, isMandatory, isVisible, setEnabled, setErrorComponent, setErrorKey, setExampleKey, setFocus, setLabel, setLabelComponent, setMandatory, setRootForm, setTranslator, setUserObject, setVisible, showError, showExample, showLabel |
| Methods inherited from interface org.olat.core.gui.components.form.flexible.FormBaseComponentIdProvider |
|---|
getFormDispatchId |
| Constructor Detail |
|---|
public AbstractTextElement(java.lang.String name)
| Method Detail |
|---|
public void validate(java.util.List validationResults)
FormItemThis method must be implemented by a specialised form item provider.
validate in interface FormItemvalidate in class FormItemImplorg.olat.core.gui.components.form.flexible.FormComponent#validate(java.util.List)public void reset()
FormItem
reset in interface FormItemreset in class FormItemImplFormItem.reset()public java.lang.String getValue()
TextElement
getValue in interface TextElementTextElement.getValue()public java.lang.String getValue(Filter filter)
TextElement
getValue in interface TextElementTextElement.getValue(org.olat.core.util.filter.Filter)public void setValue(java.lang.String value)
setValue in interface TextElementvalue - The value to setpublic void setNewOriginalValue(java.lang.String value)
Does not change the value of the element, just the reset-value!
setNewOriginalValue in interface TextElementvalue - The new original valuepublic void setDisplaySize(int displaySize)
TextElement
setDisplaySize in interface TextElementTextElement.setDisplaySize(int)public void setMaxLength(int maxLength)
setMaxLength in interface TextElementmaxLength - The maximum numbe of characters allowed in this field. Set
-1 for no limitTextElement.setMaxLength(int)public void setNotEmptyCheck(java.lang.String errorKey)
setNotEmptyCheck in interface TextElementerrorKey -
public void setNotLongerThanCheck(int maxLength,
java.lang.String errorKey)
setNotLongerThanCheck in interface TextElementmaxLength - if value is -1 maxlength will not be checkederrorKey - TextElement.setNotLongerThanCheck(int,
java.lang.String)
public void setIsEqualCheck(java.lang.String otherValue,
java.lang.String errorKey)
setIsEqualCheck in interface TextElementotherValue - errorKey - public boolean isEmpty()
isEmpty in interface TextElementpublic boolean isEmpty(java.lang.String errorKey)
isEmpty in interface TextElementerrorKey -
public void setRegexMatchCheck(java.lang.String regExp,
java.lang.String errorKey)
setRegexMatchCheck in interface TextElementregExp - errorKey - public void setItemValidatorProvider(ItemValidatorProvider itemValidatorProvider)
TextElement
setItemValidatorProvider in interface TextElement
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||