public final class TemporalAccessorPrinter extends Object implements Printer<java.time.temporal.TemporalAccessor>
Printer implementation for a JSR-310 TemporalAccessor,
using a DateTimeFormatter) (the contextual one, if available).DateTimeContextHolder.getFormatter(java.time.format.DateTimeFormatter, java.util.Locale),
DateTimeFormatter.format(java.time.temporal.TemporalAccessor)| Constructor and Description |
|---|
TemporalAccessorPrinter(java.time.format.DateTimeFormatter formatter)
Create a new TemporalAccessorPrinter.
|
| Modifier and Type | Method and Description |
|---|---|
String |
print(java.time.temporal.TemporalAccessor partial,
Locale locale)
Print the object of type T for display.
|
public TemporalAccessorPrinter(java.time.format.DateTimeFormatter formatter)
formatter - the base DateTimeFormatter instance