Class RepeatValidatorSettings
- java.lang.Object
-
- net.anotheria.anosite.handler.validation.RepeatValidatorSettings
-
- All Implemented Interfaces:
Serializable,ValidatorSettings
public class RepeatValidatorSettings extends Object implements ValidatorSettings
Repeat validator settings. For example can be used for configure password confirm validation.- Author:
- Alexandr Bolbat
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static StringJSON_SETTINGS_ERROR_KEY_NAMEJSON name for this setting.static StringJSON_SETTINGS_FIELD_NAMEJSON name for this setting.static StringJSON_SETTINGS_NAMEJSON name for this settings.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static RepeatValidatorSettingscreate()Create new instance of this class.StringgetName()Get validator settings name.RepeatValidatorSettingssetErrorKey(String aErrorKey)Set error key for not valid field value.RepeatValidatorSettingssetRepeatField(String aFieldName)Set repeat field name with what we need check current field value.org.json.JSONObjecttoJSON()Get validator settings asJSONObject.StringtoString()
-
-
-
Field Detail
-
JSON_SETTINGS_NAME
public static final String JSON_SETTINGS_NAME
JSON name for this settings.- See Also:
- Constant Field Values
-
JSON_SETTINGS_FIELD_NAME
public static final String JSON_SETTINGS_FIELD_NAME
JSON name for this setting.- See Also:
- Constant Field Values
-
JSON_SETTINGS_ERROR_KEY_NAME
public static final String JSON_SETTINGS_ERROR_KEY_NAME
JSON name for this setting.- See Also:
- Constant Field Values
-
-
Method Detail
-
create
public static final RepeatValidatorSettings create()
Create new instance of this class.- Returns:
RepeatValidatorSettings
-
setRepeatField
public RepeatValidatorSettings setRepeatField(String aFieldName)
Set repeat field name with what we need check current field value.- Parameters:
aFieldName- - set is need validate email format- Returns:
RepeatValidatorSettings
-
setErrorKey
public RepeatValidatorSettings setErrorKey(String aErrorKey)
Set error key for not valid field value.- Parameters:
aErrorKey- - error key- Returns:
RepeatValidatorSettings
-
getName
public String getName()
Description copied from interface:ValidatorSettingsGet validator settings name.- Specified by:
getNamein interfaceValidatorSettings- Returns:
String
-
toJSON
public org.json.JSONObject toJSON()
Description copied from interface:ValidatorSettingsGet validator settings asJSONObject.- Specified by:
toJSONin interfaceValidatorSettings- Returns:
- TODO dummy comment for javadoc.
-
-