- Type Parameters:
E - the type of the element
T - the type of the source collection to encode
- All Superinterfaces:
Encoder<T>
public interface ElementEncoder<E,T>
extends Encoder<T>
-
Nested Class Summary
Nested Classes
static interface
An interface for processing elements of the collection.
-
Method Summary
default <O> @NotNull dev.siroshun.jfun.result.Result<O,EncodeError>
encode(@NotNull Out<O> out,
@UnknownNullability T input)
Encodes the data from the provided
Encoder to the provided
Out.
-
Method Details
-
-
-
encode
@NotNull
default <O>
@NotNull dev.siroshun.jfun.result.Result<O,EncodeError> encode(@NotNull
@NotNull Out<O> out,
@UnknownNullability T input)
Description copied from interface: Encoder
Encodes the data from the provided
Encoder to the provided
Out.
- Specified by:
encode in interface Encoder<E>
- Type Parameters:
O - the type of the output destination
- Parameters:
out - the Out for writing the encoded data
input - the input data to encode
- Returns:
- a result containing the encoded data, or a
EncodeError if the operation failed