Class StreamRDFWriterEx

java.lang.Object
org.aksw.jenax.arq.util.streamrdf.StreamRDFWriterEx

public class StreamRDFWriterEx extends Object
Special purpose RDF writer generation. Especially blank nodes are preserved as given.
Author:
raven
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static org.apache.jena.riot.system.StreamRDF
    enhanceWriter(org.apache.jena.riot.system.StreamRDF rawWriter, org.apache.jena.riot.Lang lang, org.apache.jena.shared.PrefixMapping fixedPrefixes, org.apache.jena.irix.IRIx irix, org.apache.jena.riot.out.NodeToLabel nodeToLabel, Boolean mapQuadsToTriplesForTripleLangs)
     
    static org.apache.jena.riot.system.StreamRDF
    enhanceWriterAsGiven(org.apache.jena.riot.system.StreamRDF rawWriter, org.apache.jena.riot.Lang lang)
     
    static org.apache.jena.riot.system.StreamRDF
    getWriterStream(OutputStream out, org.apache.jena.riot.Lang lang, org.apache.jena.sparql.util.Context context)
     
    static org.apache.jena.riot.system.StreamRDF
    getWriterStream(OutputStream out, org.apache.jena.riot.RDFFormat rdfFormat, org.apache.jena.sparql.util.Context context)
     
    static org.apache.jena.riot.system.StreamRDF
    getWriterStream(OutputStream out, org.apache.jena.riot.RDFFormat rdfFormat, org.apache.jena.sparql.util.Context context, org.apache.jena.shared.PrefixMapping fixedPrefixes, org.apache.jena.irix.IRIx irix, org.apache.jena.riot.out.NodeToLabel nodeToLabel, Boolean mapQuadsToTriplesForTripleLangs)
    Create a StreamRDF writer with extended options.
    static void
    writeAsGiven(org.apache.jena.graph.Graph graph, OutputStream out, org.apache.jena.riot.RDFFormat format, org.apache.jena.sparql.util.Context cxt, Function<org.apache.jena.riot.system.StreamRDF,org.apache.jena.riot.system.StreamRDF> applyWrapper)
     
    static void
    writeAsGiven(org.apache.jena.sparql.core.DatasetGraph dg, OutputStream out, org.apache.jena.riot.RDFFormat format, org.apache.jena.sparql.util.Context cxt, Function<org.apache.jena.riot.system.StreamRDF,org.apache.jena.riot.system.StreamRDF> applyWrapper)
     
    static <T> void
    writeAsGiven(T data, BiConsumer<T,org.apache.jena.riot.system.StreamRDF> sendToStream, OutputStream out, org.apache.jena.riot.RDFFormat format, org.apache.jena.sparql.util.Context cxt, Function<org.apache.jena.riot.system.StreamRDF,org.apache.jena.riot.system.StreamRDF> applyWrapper)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • StreamRDFWriterEx

      public StreamRDFWriterEx()
  • Method Details

    • getWriterStream

      public static org.apache.jena.riot.system.StreamRDF getWriterStream(OutputStream out, org.apache.jena.riot.RDFFormat rdfFormat, org.apache.jena.sparql.util.Context context)
    • getWriterStream

      public static org.apache.jena.riot.system.StreamRDF getWriterStream(OutputStream out, org.apache.jena.riot.Lang lang, org.apache.jena.sparql.util.Context context)
    • writeAsGiven

      public static void writeAsGiven(org.apache.jena.sparql.core.DatasetGraph dg, OutputStream out, org.apache.jena.riot.RDFFormat format, org.apache.jena.sparql.util.Context cxt, Function<org.apache.jena.riot.system.StreamRDF,org.apache.jena.riot.system.StreamRDF> applyWrapper)
    • writeAsGiven

      public static void writeAsGiven(org.apache.jena.graph.Graph graph, OutputStream out, org.apache.jena.riot.RDFFormat format, org.apache.jena.sparql.util.Context cxt, Function<org.apache.jena.riot.system.StreamRDF,org.apache.jena.riot.system.StreamRDF> applyWrapper)
    • writeAsGiven

      public static <T> void writeAsGiven(T data, BiConsumer<T,org.apache.jena.riot.system.StreamRDF> sendToStream, OutputStream out, org.apache.jena.riot.RDFFormat format, org.apache.jena.sparql.util.Context cxt, Function<org.apache.jena.riot.system.StreamRDF,org.apache.jena.riot.system.StreamRDF> applyWrapper)
      Parameters:
      dg - The dataset
      out - The output stream
      format - The RDF format
      cxt - The context for riot
      applyWrapper - A callback for optionally wrapping the internal streamRdf (e.g. deferring output while sampling used prefixes); may be null.
    • getWriterStream

      public static org.apache.jena.riot.system.StreamRDF getWriterStream(OutputStream out, org.apache.jena.riot.RDFFormat rdfFormat, org.apache.jena.sparql.util.Context context, org.apache.jena.shared.PrefixMapping fixedPrefixes, org.apache.jena.irix.IRIx irix, org.apache.jena.riot.out.NodeToLabel nodeToLabel, Boolean mapQuadsToTriplesForTripleLangs)
      Create a StreamRDF writer with extended options.
      Parameters:
      out - The output stream.
      rdfFormat - The rdf format; a registration of a streamable writer must exist for it
      context - The context passed to the writer creation.
      fixedPrefixes - If non-null, only this set prefixes will be written out; the returned writer will ignore prefix events.
      nodeToLabel - The blank node strategy. If null, blank nodes are preserved as given.
      mapQuadsToTriplesForTripleLangs - If false, the writer for a quad language will ignore triples. If true, triples become quads in the default graph. Defaults to true.
      Returns:
      A writer according to parameterization.
    • enhanceWriterAsGiven

      public static org.apache.jena.riot.system.StreamRDF enhanceWriterAsGiven(org.apache.jena.riot.system.StreamRDF rawWriter, org.apache.jena.riot.Lang lang)
    • enhanceWriter

      public static org.apache.jena.riot.system.StreamRDF enhanceWriter(org.apache.jena.riot.system.StreamRDF rawWriter, org.apache.jena.riot.Lang lang, org.apache.jena.shared.PrefixMapping fixedPrefixes, org.apache.jena.irix.IRIx irix, org.apache.jena.riot.out.NodeToLabel nodeToLabel, Boolean mapQuadsToTriplesForTripleLangs)