withOptions method
Creates a new decoder with the specified options
This method returns a new instance of the decoder configured with the provided options. The original decoder instance remains unchanged.
Parameters:
optionsConfiguration options to customize the decoder's behavior.
Returns:
- A new
RdfGraphDecoderinstance with the specified options applied.
This pattern allows for immutable configuration of decoders and enables method chaining for readable configuration code.
Implementation
@override
RdfGraphDecoder withOptions(RdfGraphDecoderOptions options) {
return JsonLdGraphDecoder(
options: JsonLdGraphDecoderOptions.from(options),
iriTermFactory: _iriTermFactory);
}