public class Jsr310DateTimeFormatAnnotationFormatterFactory extends EmbeddedValueResolutionSupport implements AnnotationFormatterFactory<DateTimeFormat>
java.time
パッケージを使用して、DateTimeFormat
アノテーションが付けられたフィールドをフォーマットします。DateTimeFormat
コンストラクターと説明 |
---|
Jsr310DateTimeFormatAnnotationFormatterFactory() |
修飾子と型 | メソッドと説明 |
---|---|
SetSE<ClassSE<?>> | getFieldTypes() アノテーションでアノテーションを付けることができるフィールドの型 <A>。</a> |
protected DateTimeFormatterSE | getFormatter(DateTimeFormat annotation, ClassSE<?> fieldType) DateTimeFormatter SE の作成に使用されるファクトリメソッド。 |
Parser<?> | getParser(DateTimeFormat annotation, ClassSE<?> fieldType) annotation のアノテーションが付けられた fieldType のフィールドに対して送信された値を解析するパーサーを取得します。 |
Printer<?> | getPrinter(DateTimeFormat annotation, ClassSE<?> fieldType) annotation のアノテーションが付けられた fieldType のフィールドの値を出力するプリンターを取得します。 |
resolveEmbeddedValue, setEmbeddedValueResolver
cloneSE, equalsSE, finalizeSE, getClassSE, hashCodeSE, notifySE, notifyAllSE, toStringSE, waitSE, waitSE, waitSE
public Jsr310DateTimeFormatAnnotationFormatterFactory()
public final SetSE<ClassSE<?>> getFieldTypes()
AnnotationFormatterFactory
AnnotationFormatterFactory<DateTimeFormat>
の getFieldTypes
public Printer<?> getPrinter(DateTimeFormat annotation, ClassSE<?> fieldType)
AnnotationFormatterFactory
annotation
のアノテーションが付けられた fieldType
のフィールドの値を出力するプリンターを取得します。 プリンターが受け入れる型 T が fieldType
に割り当て可能でない場合、プリンターが呼び出される前に fieldType
から T への強制が試行されます。
AnnotationFormatterFactory<DateTimeFormat>
の getPrinter
annotation
- アノテーションインスタンス fieldType
- アノテーションが付けられたフィールドの型 public Parser<?> getParser(DateTimeFormat annotation, ClassSE<?> fieldType)
AnnotationFormatterFactory
annotation
のアノテーションが付けられた fieldType
のフィールドに対して送信された値を解析するパーサーを取得します。 パーサーが返すオブジェクトが fieldType
に割り当てられない場合、フィールドが設定される前に fieldType
への強制が試行されます。
AnnotationFormatterFactory<DateTimeFormat>
の getParser
annotation
- アノテーションインスタンス fieldType
- アノテーションが付けられたフィールドの型 protected DateTimeFormatterSE getFormatter(DateTimeFormat annotation, ClassSE<?> fieldType)
DateTimeFormatter
SE の作成に使用されるファクトリメソッド。annotation
- フィールドのフォーマットアノテーション fieldType
- フィールドの宣言された型 DateTimeFormatter
SE インスタンス