public abstract class KaidenAbstractValidator extends Object
修飾子とタイプ | フィールドと説明 |
---|---|
protected static String |
ARGS_DELIMITER
引数区切り理文字.
|
ContextHelper |
contextHelper
ContextHelper.
|
DateHelper |
dateHelper
DateHelper.
|
PropertyHelper |
propertyHelper
PropertyHelper.
|
ValidateMapHelper |
validateMapHelper
ValidateMapHelper.
|
コンストラクタと説明 |
---|
KaidenAbstractValidator() |
修飾子とタイプ | メソッドと説明 |
---|---|
protected String |
anyValueToSingleString(Object... args)
複数項目に対してチェックを行う場合の値を作成して返却します.
|
protected void |
argsLengthCheck(String[] args,
int minLength)
アーギュメント文字列の必須パラメータ数チェックを行う.
|
protected boolean |
chkPattern(String chk,
String optionRegularExpression)
正規表現チェック.
|
protected int |
getIntValue(String arg)
文字列を整数に変換して返却.
|
protected String |
getSurface(String surfaceKey)
サーフェスキーに紐づく値を取得し、返却.
|
protected void |
inputCheck(Object... objects)
入力値チェックを行う.
|
protected KaidenValidateResult |
makeNewValidateResult(String fieldKey,
Map<String,String> surfaces)
バリデート処理結果格納用インスタンスを生成、返却.
|
protected KaidenValidateResult |
makeNewValidateResult(String fieldKey,
Map<String,String> surfaces,
String value)
バリデート処理結果格納用インスタンスを生成、返却.
|
protected void |
setErrorDetail(KaidenValidateResult result,
String messageKey,
Object... args)
エラー発生時のエラー詳細を設定します.
|
@Autowired public DateHelper dateHelper
@Autowired public ContextHelper contextHelper
@Autowired public ValidateMapHelper validateMapHelper
@Autowired public PropertyHelper propertyHelper
protected KaidenValidateResult makeNewValidateResult(String fieldKey, Map<String,String> surfaces)
fieldKey
- フィールドキーsurfaces
- 表層定義protected KaidenValidateResult makeNewValidateResult(String fieldKey, Map<String,String> surfaces, String value)
fieldKey
- フィールドキーsurfaces
- 表層定義value
- 値protected boolean chkPattern(String chk, String optionRegularExpression)
chk
- チェック対象文字列optionRegularExpression
- 正規表現protected void inputCheck(Object... objects)
objects
- 入力チェック対象オブジェクト配列protected void argsLengthCheck(String[] args, int minLength)
args
- アーギュメント文字列minLength
- 必須パラメータ数protected int getIntValue(String arg)
変換に失敗した場合は、例外をスローします。
arg
- 文字列protected String anyValueToSingleString(Object... args)
値を連結して1つの文字列として返却します。 連結する際の区切り文字はカンマ固定で、指定することはできません。
args
- チェック対象項目protected String getSurface(String surfaceKey)
値を取得する際のロケールはログインユーザロケールを利用します。
surfaceKey
- サーフェスキーprotected void setErrorDetail(KaidenValidateResult result, String messageKey, Object... args)
メッセージを取得する際のロケールはログインユーザロケールを利用します。
result
- バリデート処理結果インスタンスargs
- メッセージ引数messageKey
- メッセージキーCopyright © 2024 Sumitomo Life Information Systems Co., Ltd. All Rights Reserved.