spring-framework / org.springframework.format.datetime.standard / TemporalAccessorPrinter

TemporalAccessorPrinter

class TemporalAccessorPrinter : Printer<TemporalAccessor>

Printer implementation for a JSR-310 java.time.temporal.TemporalAccessor, using a java.time.format.DateTimeFormatter) (the contextual one, if available).

Author
Juergen Hoeller

Since
4.0

See Also
DateTimeContextHolder#getFormatterjava.time.format.DateTimeFormatter#format(java.time.temporal.TemporalAccessor)

Constructors

<init>

TemporalAccessorPrinter(formatter: DateTimeFormatter)

Create a new TemporalAccessorPrinter.

Functions

print

fun print(partial: TemporalAccessor, locale: Locale): String