NQuadsEncoder class final

Encoder for the N-Quads format.

This class extends the RdfGraphEncoder abstract class to convert RDF graphs into the N-Quads serialization format. N-Quads is a line-based format where each line represents a single triple, making it very simple to parse and generate.

The encoder creates one line for each triple in the form: <subject> <predicate> <object> .

N-Quads is fully compatible with the RDF 1.1 N-Quads specification (https://www.w3.org/TR/n-quads/).

Inheritance

Constructors

NQuadsEncoder.new({NQuadsEncoderOptions options = const NQuadsEncoderOptions()})
Creates a new N-Quads serializer

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

bind(Stream<RdfDataset> stream) Stream<String>
Transforms the provided stream.
inherited
cast<RS, RT>() Converter<RS, RT>
Provides a Converter<RS, RT> view of this stream transformer.
inherited
convert(RdfDataset dataset, {String? baseUri}) String
Encodes an RDF dataset to a string representation in a specific format.
encode(RdfDataset dataset, {Map<BlankNodeTerm, String>? blankNodeLabels, bool generateNewBlankNodeLabels = true}) String
If the generateNewBlankNodeLabels flag is false and blankNodeLabels is not provided, or does not contain all blank nodes in the dataset, an exception is thrown to indicate inconsistent blank node labeling.
fuse<TT>(Converter<String, TT> other) Converter<RdfDataset, TT>
Fuses this with other.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
startChunkedConversion(Sink<String> sink) Sink<RdfDataset>
Starts a chunked conversion.
inherited
toString() String
A string representation of this object.
inherited
withOptions(RdfGraphEncoderOptions options) → RdfDatasetEncoder
Creates a new encoder instance with the specified options.

Operators

operator ==(Object other) bool
The equality operator.
inherited