Class FixedFileFieldBasicValidator
- java.lang.Object
-
- org.fugerit.java.core.cfg.helpers.AbstractConfigurableObject
-
- org.fugerit.java.core.cfg.helpers.XMLConfigurableObject
-
- org.fugerit.java.core.fixed.parser.FixedFileFieldBasicValidator
-
- All Implemented Interfaces:
Serializable
,ConfigurableObject
,FixedFileFieldValidator
,LogObject
- Direct Known Subclasses:
FixedFileFieldDateValidator
,FixedFileFieldRegexValidator
public abstract class FixedFileFieldBasicValidator extends XMLConfigurableObject implements FixedFileFieldValidator
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static String
ATT_NAME_ID
static String
ATT_NAME_LOCALE
static String
ATT_NAME_REGEX
static String
ATT_NAME_REQUIRED
static String
DEFAULT_BUNDLE_PATH
protected static org.slf4j.Logger
logger
-
Fields inherited from class org.fugerit.java.core.cfg.helpers.XMLConfigurableObject
DO_NOTHING
-
-
Constructor Summary
Constructors Constructor Description FixedFileFieldBasicValidator()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected FixedFileFieldValidationResult
checkRequired(String fieldLabel, String fieldValue, int rowNumber, int colNumber)
protected void
configure(Element tag, String bundlePath)
protected String
defaultFormatMessage(String errorKey, String fieldLabel, String fieldValue, int rowNumber, int colNumber, String addInfo)
ResourceBundle
getBundle()
String
getId()
boolean
isRequired()
static String
messageFormatWorker(ResourceBundle bundle, String errorKey, String fieldLabel, String fieldValue, int rowNumber, int colNumber, String addInfo)
static ResourceBundle
newBundle(String locale)
static ResourceBundle
newBundle(String bundlePath, String locale)
-
Methods inherited from class org.fugerit.java.core.cfg.helpers.XMLConfigurableObject
configure, newXMLConfigurableObject
-
Methods inherited from class org.fugerit.java.core.cfg.helpers.AbstractConfigurableObject
configureProperties, configureXML, getLogger, setConfigProvider
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.fugerit.java.core.cfg.ConfigurableObject
configure, configure, configureProperties, configureXML
-
Methods inherited from interface org.fugerit.java.core.fixed.parser.FixedFileFieldValidator
checkField
-
-
-
-
Field Detail
-
DEFAULT_BUNDLE_PATH
public static final String DEFAULT_BUNDLE_PATH
- See Also:
- Constant Field Values
-
logger
protected static final org.slf4j.Logger logger
-
ATT_NAME_ID
public static final String ATT_NAME_ID
- See Also:
- Constant Field Values
-
ATT_NAME_REGEX
public static final String ATT_NAME_REGEX
- See Also:
- Constant Field Values
-
ATT_NAME_LOCALE
public static final String ATT_NAME_LOCALE
- See Also:
- Constant Field Values
-
ATT_NAME_REQUIRED
public static final String ATT_NAME_REQUIRED
- See Also:
- Constant Field Values
-
-
Method Detail
-
newBundle
public static ResourceBundle newBundle(String locale)
-
messageFormatWorker
public static String messageFormatWorker(ResourceBundle bundle, String errorKey, String fieldLabel, String fieldValue, int rowNumber, int colNumber, String addInfo)
-
newBundle
public static ResourceBundle newBundle(String bundlePath, String locale)
-
isRequired
public boolean isRequired()
-
getId
public String getId()
-
getBundle
public ResourceBundle getBundle()
-
defaultFormatMessage
protected String defaultFormatMessage(String errorKey, String fieldLabel, String fieldValue, int rowNumber, int colNumber, String addInfo)
-
checkRequired
protected FixedFileFieldValidationResult checkRequired(String fieldLabel, String fieldValue, int rowNumber, int colNumber)
-
configure
protected void configure(Element tag, String bundlePath) throws ConfigException
- Throws:
ConfigException
-
-