@Test public void testInstant() { Instant expected = Instant.now(); Instant actual = Config.EMPTY.get(ofInstant(), THIS, expected); assertEquals(expected, actual); }
public static ConfigConverter<Instant> ofInstant() { return new SimpleConfigConverter<Instant>() { @Override protected Instant fromString(String string) { return StringFormatUtils.parseInstant(string); } @Override protected String toString(Instant value) { return StringFormatUtils.formatInstant(value); } }; }
ConfigConverters { public static ConfigConverter<Instant> ofInstant() { return new SimpleConfigConverter<Instant>() { @Override protected Instant fromString(String string) { return StringFormatUtils.parseInstant(string); } @Override protected String toString(Instant value) { return StringFormatUtils.formatInstant(value); } }; } }
ConfigConverters { public static ConfigConverter<Instant> ofInstant() { return new SimpleConfigConverter<Instant>() { @Override protected Instant fromString(String string) { return StringFormatUtils.parseInstant(string); } @Override protected String toString(Instant value) { return StringFormatUtils.formatInstant(value); } }; }  }
ConfigConverters { public static ConfigConverter<Instant> ofInstant() { return new SimpleConfigConverter<Instant>() { @Override protected Instant fromString(String string) { return StringFormatUtils.parseInstant(string); } @Override protected String toString(Instant value) { return StringFormatUtils.formatInstant(value); } }; }  static ConfigConverter<LocalDate> ofLocalDate(); static ConfigConverter<LocalTime> ofLocalTime(); static ConfigConverter<LocalDateTime> ofLocalDateTime(); static ConfigConverter<Period> ofPeriod(); static ConfigConverter<Integer> ofPeriodAsDays(); static ConfigConverter<Duration> ofDuration(); static ConfigConverter<Long> ofDurationAsMillis(); static ConfigConverter<Instant> ofInstant(); static ConfigConverter<Long> ofInstantAsEpochMillis(); static ConfigConverter<String> ofString(); static ConfigConverter<String> ofNullableString(); static ConfigConverter<Byte> ofByte(); static ConfigConverter<Integer> ofInteger(); static ConfigConverter<Long> ofLong(); static ConfigConverter<Float> ofFloat(); static ConfigConverter<Double> ofDouble(); static ConfigConverter<Boolean> ofBoolean(); static SimpleConfigConverter<E> ofEnum(Class<E> enumClass); static ConfigConverter<Class<?>> ofClass(); static ConfigConverter<InetAddress> ofInetAddress(); static ConfigConverter<InetSocketAddress> ofInetSocketAddress(); static ConfigConverter<Path> ofPath(); static ConfigConverter<MemSize> ofMemSize(); static ConfigConverter<Long> ofMemSizeAsLong(); static ConfigConverter<Integer> ofMemSizeAsInt(); static ConfigConverter<List<T>> ofList(ConfigConverter<T> elementConverter, CharSequence separators); static ConfigConverter<List<T>> ofList(ConfigConverter<T> elementConverter); static ConfigConverter<ServerSocketSettings> ofServerSocketSettings(); static ConfigConverter<SocketSettings> ofSocketSettings(); static ConfigConverter<DatagramSocketSettings> ofDatagramSocketSettings(); static ConfigConverter<FatalErrorHandler> ofFatalErrorHandler(); static ConfigConverter<Schedule> ofEventloopTaskSchedule(); static ConfigConverter<RetryPolicy> ofRetryPolicy(); static ConfigConverter<ThrottlingController> ofThrottlingController(); static ConfigConverter<SimpleThreadFactory> ofThreadFactory(); static ExecutorService getExecutor(Config config); static ConfigConverter<ExecutorService> ofExecutor(); static UnaryOperator<T> apply(BiFunction<T, ? super V, T> modifier, V value); static UnaryOperator<T> applyIf(BiFunction<T, ? super V, T> modifier, V value, Predicate<? super V> predicate); static UnaryOperator<T> applyIfNotNull(BiFunction<T, ? super V, T> modifier, V value); }
ConfigConverters { public static ConfigConverter<Instant> ofInstant() { return new SimpleConfigConverter<Instant>() { @Override protected Instant fromString(String string) { return StringFormatUtils.parseInstant(string); } @Override protected String toString(Instant value) { return StringFormatUtils.formatInstant(value); } }; }  static ConfigConverter<LocalDate> ofLocalDate(); static ConfigConverter<LocalTime> ofLocalTime(); static ConfigConverter<LocalDateTime> ofLocalDateTime(); static ConfigConverter<Period> ofPeriod(); static ConfigConverter<Integer> ofPeriodAsDays(); static ConfigConverter<Duration> ofDuration(); static ConfigConverter<Long> ofDurationAsMillis(); static ConfigConverter<Instant> ofInstant(); static ConfigConverter<Long> ofInstantAsEpochMillis(); static ConfigConverter<String> ofString(); static ConfigConverter<String> ofNullableString(); static ConfigConverter<Byte> ofByte(); static ConfigConverter<Integer> ofInteger(); static ConfigConverter<Long> ofLong(); static ConfigConverter<Float> ofFloat(); static ConfigConverter<Double> ofDouble(); static ConfigConverter<Boolean> ofBoolean(); static SimpleConfigConverter<E> ofEnum(Class<E> enumClass); static ConfigConverter<Class<?>> ofClass(); static ConfigConverter<InetAddress> ofInetAddress(); static ConfigConverter<InetSocketAddress> ofInetSocketAddress(); static ConfigConverter<Path> ofPath(); static ConfigConverter<MemSize> ofMemSize(); static ConfigConverter<Long> ofMemSizeAsLong(); static ConfigConverter<Integer> ofMemSizeAsInt(); static ConfigConverter<List<T>> ofList(ConfigConverter<T> elementConverter, CharSequence separators); static ConfigConverter<List<T>> ofList(ConfigConverter<T> elementConverter); static ConfigConverter<ServerSocketSettings> ofServerSocketSettings(); static ConfigConverter<SocketSettings> ofSocketSettings(); static ConfigConverter<DatagramSocketSettings> ofDatagramSocketSettings(); static ConfigConverter<FatalErrorHandler> ofFatalErrorHandler(); static ConfigConverter<Schedule> ofEventloopTaskSchedule(); static ConfigConverter<RetryPolicy> ofRetryPolicy(); static ConfigConverter<ThrottlingController> ofThrottlingController(); static ConfigConverter<SimpleThreadFactory> ofThreadFactory(); static ExecutorService getExecutor(Config config); static ConfigConverter<ExecutorService> ofExecutor(); static UnaryOperator<T> apply(BiFunction<T, ? super V, T> modifier, V value); static UnaryOperator<T> applyIf(BiFunction<T, ? super V, T> modifier, V value, Predicate<? super V> predicate); static UnaryOperator<T> applyIfNotNull(BiFunction<T, ? super V, T> modifier, V value); static final ConfigConverter<List<Class<?>>> OF_CLASSES; }