Package lumis.doui.control
Interface IValidatorControl
-
- All Superinterfaces:
IControl
- All Known Implementing Classes:
DateCompareValidatorControl
,DateDataTypeValidatorControl
,EmailValidatorControl
,FileNameValidatorControl
,FileSizeValidatorControl
,FilterUniqueIdValidator
,FriendlyIdValidationControl
,HtmlEditorBlocksValidatorControl
,HtmlEditorValidatorControl
,IntegerDataTypeValidatorControl
,LengthValidatorControl
,MultiFileUploadExtensionCheckControl
,MultiFileUploadRequiredValueValidatorControl
,NumberDataTypeValidatorControl
,RegularExpressionValidatorControl
,RequiredValueValidatorControl
,RequiredValueWhenEnableControl
,RequiredValueWhenVisibleValidatorControl
,RestShortNameValidationControl
,SearchQueryValidatorControl
,ValidatorControl
@StableMinor(version="17.0", sinceVersion="4.0") public interface IValidatorControl extends IControl
Interface que controls que faz validação devem implementar- Since:
- 4.0.0
- Version:
- $Revision$ $Date$
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.util.Collection<java.lang.String>
getControlToValidateIds()
Returns a collection with the ids of the controls to be validated by this validator control.java.lang.String
getLocalizedErrorMessage()
Returns the error message generated for the control.java.lang.String
getScriptClear()
Clears the message displayed by this validator.java.lang.String
getScriptValidate()
Returns the code that needs to be executed on the client side for this validation.java.lang.String
getScriptValidateRegistration()
Returns a script that must be placed on the page.java.lang.String
getScriptValidationFunctionImplementation()
Returns the client side code that must be placed in a client side function to perform the validationjava.lang.String
getScriptValidationFunctionName()
Returns the name of the client side validation function.boolean
isClientSideValidationEnabled()
Verify if the parameter ClienteSideValidation is enable.boolean
serverValidate()
Validates all dependent control values on the server side-
Methods inherited from interface lumis.doui.control.IControl
buildSubControls, createContainer, disconnect, getChildControls, getControlResource, getId, getName, getParentControl, getPrepareForReadScript, getRenderData, getResources, getType, init, isValid, registerOnEventScript, removeChild, removeChildren, setRenderData, setRuntimeAttributes, setValid
-
-
-
-
Method Detail
-
serverValidate
boolean serverValidate() throws PortalException
Validates all dependent control values on the server side- Returns:
- true if controls are valid and false if not
- Throws:
ControlException
PortalException
-
getScriptValidationFunctionName
java.lang.String getScriptValidationFunctionName() throws PortalException
Returns the name of the client side validation function. e.g. return value: Validate_- Returns:
- the validation function name that was registered for this validator
- Throws:
PortalException
-
getScriptValidate
java.lang.String getScriptValidate() throws PortalException
Returns the code that needs to be executed on the client side for this validation. Usually returns a call to the validation function name. e.g. return value: Validate_- Returns:
- a String.
- Throws:
PortalException
-
getScriptValidationFunctionImplementation
java.lang.String getScriptValidationFunctionImplementation() throws PortalException
Returns the client side code that must be placed in a client side function to perform the validation- Returns:
- a String.
- Throws:
PortalException
-
getScriptValidateRegistration
java.lang.String getScriptValidateRegistration() throws PortalException
Returns a script that must be placed on the page. This script contains function to perform client side validation. This method internally calls getScriptValidationFunctionImplementation() to get the code for validation.- Returns:
- script that is used for performing client side validation.
- Throws:
PortalException
-
getScriptClear
java.lang.String getScriptClear() throws PortalException
Clears the message displayed by this validator.- Returns:
- a String.
- Throws:
PortalException
-
getControlToValidateIds
java.util.Collection<java.lang.String> getControlToValidateIds() throws PortalException
Returns a collection with the ids of the controls to be validated by this validator control.- Returns:
- a collection with the controls ids.
- Throws:
PortalException
-
isClientSideValidationEnabled
boolean isClientSideValidationEnabled()
Verify if the parameter ClienteSideValidation is enable.- Returns:
- true if the ClienteSideValidation is enable and false otherwise.
-
getLocalizedErrorMessage
java.lang.String getLocalizedErrorMessage() throws PortalException
Returns the error message generated for the control. Null if no error message.- Returns:
- the error message.
- Throws:
PortalException
- Since:
- 10.0.0
-
-