- Type Parameters:
T- The type of the variable argument value.
- All Known Implementing Classes:
ListVarargCodec
public interface VarargCodec<T>
A codec for variable argument values.
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic interfaceBuilds paths for elements of a variable argument. -
Method Summary
Modifier and TypeMethodDescriptiondecodeVararg(List<ESExpr> exprs, @NotNull VarargCodec.PositionalPathBuilder pathBuilder) Decode a list of expressions into a variable argument value.encodeVararg(T value) Encode a variable argument value into a list of expressions.
-
Method Details
-
encodeVararg
-
decodeVararg
T decodeVararg(List<ESExpr> exprs, @NotNull @NotNull VarargCodec.PositionalPathBuilder pathBuilder) throws DecodeException Decode a list of expressions into a variable argument value.- Parameters:
exprs- The expressions.pathBuilder- A path builder of the current expressions within the decoded object for diagnostic purposes.- Returns:
- The variable argument value.
- Throws:
DecodeException- when the value cannot be decoded.
-