getHiddenSuffixEncoder
Call Signature
getHiddenSuffixEncoder<
TFrom
>(encoder
,suffixedEncoders
):FixedSizeEncoder
<TFrom
>
Returns an encoder that appends hidden data after the encoded value.
This encoder applies a list of void encoders after encoding the main value. The suffixed data is encoded after the main value without being exposed to the user.
For more details, see getHiddenSuffixCodec.
Type Parameters
Type Parameter | Description |
---|---|
TFrom | The type of the main value being encoded. |
Parameters
Parameter | Type | Description |
---|---|---|
encoder | FixedSizeEncoder <TFrom > | The encoder for the main value. |
suffixedEncoders | readonly FixedSizeEncoder <void >[] | A list of void encoders that produce the hidden suffix. |
Returns
FixedSizeEncoder
<TFrom
>
A FixedSizeEncoder
or VariableSizeEncoder
that encodes the value with a hidden suffix.
Example
Suffixing a value with constants.
See
Call Signature
getHiddenSuffixEncoder<
TFrom
>(encoder
,suffixedEncoders
):VariableSizeEncoder
<TFrom
>
Returns an encoder that appends hidden data after the encoded value.
This encoder applies a list of void encoders after encoding the main value. The suffixed data is encoded after the main value without being exposed to the user.
For more details, see getHiddenSuffixCodec.
Type Parameters
Type Parameter | Description |
---|---|
TFrom | The type of the main value being encoded. |
Parameters
Parameter | Type | Description |
---|---|---|
encoder | Encoder <TFrom > | The encoder for the main value. |
suffixedEncoders | readonly Encoder <void >[] | A list of void encoders that produce the hidden suffix. |
Returns
VariableSizeEncoder
<TFrom
>
A FixedSizeEncoder
or VariableSizeEncoder
that encodes the value with a hidden suffix.
Example
Suffixing a value with constants.