Interface FieldEncoder<T>
- All Known Subinterfaces:
FieldCodec<T,F>
public interface FieldEncoder<T>
-
Method Summary
Modifier and TypeMethodDescriptionbooleanstatic <T,F> @NotNull FieldEncoder <T> create(@NotNull String fieldName, @NotNull Encoder<F> fieldEncoder, @NotNull Function<T, F> getter, @Nullable Predicate<T> canOmit) <O> @NotNull dev.siroshun.jfun.result.Result<O, EncodeError> encodeFieldValue(@NotNull Out<O> out, @UnknownNullability T input) @NotNull String
-
Method Details
-
create
@Contract("_, _, _, _ -> new") @NotNull static <T,F> @NotNull FieldEncoder<T> create(@NotNull @NotNull String fieldName, @NotNull @NotNull Encoder<F> fieldEncoder, @NotNull @NotNull Function<T, F> getter, @Nullable @Nullable Predicate<T> canOmit) -
fieldName
-
encodeFieldValue
@NotNull <O> @NotNull dev.siroshun.jfun.result.Result<O,EncodeError> encodeFieldValue(@NotNull @NotNull Out<O> out, @UnknownNullability T input) -
canOmit
-