de.fuberlin.wiwiss.ng4j
Interface NamedGraphSetReader

All Known Implementing Classes:
TriGReader, TriXReader, TriXReaderWithExtensions

public interface NamedGraphSetReader

Reads a serialized set of Named Graphs from a Reader, InputStream, or URL into a NamedGraphSet. An Implementation will provide support for a single serialization syntax, such as TriX or TriG.

A NamedGraphSetReader instance can only be used to read one file. To read another file, a new instance must be created.

NamedGraphSetReaders are used through NamedGraphSet's read methods, or through a GraphReaderService.

Author:
Richard Cyganiak (richard@cyganiak.de)

Method Summary
 void read(NamedGraphSet namedGraphSet, InputStream source, String baseURI, String defaultGraphName)
          Reads Named Graphs from an InputStream into a NamedGraphSet.
 void read(NamedGraphSet namedGraphSet, Reader source, String baseURI, String defaultGraphName)
          Reads Named Graphs from a Reader into a NamedGraphSet.
 

Method Detail

read

void read(NamedGraphSet namedGraphSet,
          Reader source,
          String baseURI,
          String defaultGraphName)
Reads Named Graphs from a Reader into a NamedGraphSet. If some of the graph names from the source are already used in the NamedGraphSet, then the statements from the old graphs will be replaced by those from the source.

Parameters:
namedGraphSet - Graphs read from the source will be stored into this NamedGraphSet
source - The source of the input serialization
baseURI - The URI from where the input was read
defaultGraphName - If a graph in the input has no name attached, then this will be used. When in doubt, use the baseURI.

read

void read(NamedGraphSet namedGraphSet,
          InputStream source,
          String baseURI,
          String defaultGraphName)
Reads Named Graphs from an InputStream into a NamedGraphSet. If some of the graph names from the source are already used in the NamedGraphSet, then the statements from the old graphs will be replaced by those from the source.

Parameters:
namedGraphSet - Graphs read from the source will be stored into this NamedGraphSet
source - The source of the input serialization
baseURI - The URI from where the input was read
defaultGraphName - If a graph in the input has no name attached, then this will be used. When in doubt, use the baseURI.