Aipoには日時データを取り扱うためのクラスが2つあります。
https://github.com/aipocom/aipo/blob/master/core/src/main/java/com/aimluck/commons/field/ALDateField.java
https://github.com/aipocom/aipo/blob/master/core/src/main/java/com/aimluck/commons/field/ALDateTimeField.java
ALDateTimeFieldでは日時処理の際によく使う文字列・日付変換処理や日付フォーマット処理用のメソッドがあらかじめ用意されています。
/**
* 時刻を含む月日(MM/dd HH:mm)の文字列表現を取得します。
*
* @return
*/
public String toStringDateTime() {
String date_time;
try {
date_time =
new SimpleDateFormat(DEFAULT_DATE_TIME_FORMAT).format(calendar
.getTime());
} catch (Exception ex) {
date_time = null;
}
if (calendar == null || isNullDateTime(date_time)) {
return ALStringUtil.sanitizing(null);
} else {
return ALStringUtil.sanitizing(date_time);
}
}また、toString()メソッドがオーバライドされているため、テンプレート内でも意識することなくALDateTimeFieldのクラスをうまいこと出力してくれます。
/**
* 入力フィールド値の文字列表現を取得します。
*
*/
@Override
public String toString() {
if (calendar == null) {
return ALStringUtil.sanitizing(null);
} else {
return ALStringUtil.sanitizing(translateDate(getValue(), format));
}
}

