Class RDFWriterRegistry

java.lang.Object
org.apache.jena.riot.RDFWriterRegistry

public class RDFWriterRegistry extends Object
Writer registry. This is for writers presenting the functionality to write graphs and datasets, not streams. See StreamRDFWriter for registration of streaming writers. To register the language: see RDFLanguages.
See Also:
  • Constructor Details

    • RDFWriterRegistry

      public RDFWriterRegistry()
  • Method Details

    • init

      public static void init()
    • register

      public static void register(RDFFormat serialization, WriterGraphRIOTFactory graphWriterFactory)
      Register the serialization for graphs and it's associated factory
      Parameters:
      serialization - RDFFormat for the output format.
      graphWriterFactory - Source of writer engines
    • register

      public static void register(RDFFormat serialization, WriterDatasetRIOTFactory datasetWriterFactory)
      Register the serialization for datasets and it's associated factory
      Parameters:
      serialization - RDFFormat for the output format.
      datasetWriterFactory - Source of writer engines
    • register

      public static void register(Lang lang, RDFFormat format)
      Register the default serialization for the language (replace any existing registration).
      Parameters:
      lang - Languages
      format - The serialization format to use when the language is used for writing.
    • defaultSerialization

      public static RDFFormat defaultSerialization(Lang lang)
      Return the format registered as the default for the language
    • contains

      public static boolean contains(Lang lang)
      Does the language have a registered output format?
    • contains

      public static boolean contains(RDFFormat format)
      Is the RDFFormat registered for use?
    • registeredGraphFormats

      public static Collection<RDFFormat> registeredGraphFormats()
      All registered graph formats
    • registeredDatasetFormats

      public static Collection<RDFFormat> registeredDatasetFormats()
      All registered dataset formats
    • registeredFormats

      public static Collection<RDFFormat> registeredFormats()
      All registered formats
    • registeredLangs

      public static Collection<Lang> registeredLangs()
      All registered languages
    • getWriterGraphFactory

      public static WriterGraphRIOTFactory getWriterGraphFactory(Lang lang)
      Get the graph writer factory associated with the language
    • getWriterGraphFactory

      public static WriterGraphRIOTFactory getWriterGraphFactory(RDFFormat serialization)
      Get the graph writer factory associated with the output format
    • getWriterDatasetFactory

      public static WriterDatasetRIOTFactory getWriterDatasetFactory(Lang lang)
      Get the dataset writer factory associated with the language
    • getWriterDatasetFactory

      public static WriterDatasetRIOTFactory getWriterDatasetFactory(RDFFormat serialization)
      Get the dataset writer factory associated with the output format