Class RddRdfWriterSettings<SELF extends RddRdfWriterSettings>

java.lang.Object
net.sansa_stack.spark.io.rdf.output.RddRdfWriterSettings<SELF>
Direct Known Subclasses:
RddRdfWriter, RddRdfWriterFactory

public class RddRdfWriterSettings<SELF extends RddRdfWriterSettings> extends Object
  • Field Details

    • partitionFolder

      protected org.apache.hadoop.fs.Path partitionFolder
    • targetFile

      protected org.apache.hadoop.fs.Path targetFile
    • useCoalesceOne

      protected boolean useCoalesceOne
    • deletePartitionFolderAfterMerge

      protected boolean deletePartitionFolderAfterMerge
    • globalPrefixMapping

      protected org.apache.jena.shared.PrefixMapping globalPrefixMapping
    • outputFormat

      protected org.apache.jena.riot.RDFFormat outputFormat
    • allowOverwriteFiles

      protected boolean allowOverwriteFiles
    • useElephas

      protected boolean useElephas
    • partitionsAsIndependentFiles

      protected boolean partitionsAsIndependentFiles
    • mapQuadsToTriplesForTripleLangs

      protected boolean mapQuadsToTriplesForTripleLangs
      Whether to convert quads to triples if a triple-based output format is requested
    • postProcessingSettings

      protected RdfPostProcessingSettingsMutable postProcessingSettings
    • deferOutputForUsedPrefixes

      protected long deferOutputForUsedPrefixes
      Only for console output: Instead of writing tuples out immediatly, collect up to this number of tuples in order to derive the used prefixes. Upon reaching this threshold, print out all seen prefixes and emit the held-back data as well as any further data immediately
    • consoleOutSupplier

      protected Supplier<OutputStream> consoleOutSupplier
  • Constructor Details

    • RddRdfWriterSettings

      public RddRdfWriterSettings()
  • Method Details

    • isMapQuadsToTriplesForTripleLangs

      public boolean isMapQuadsToTriplesForTripleLangs()
    • self

      protected SELF self()
    • configureFrom

      public SELF configureFrom(RddRdfWriterSettings<?> other)
    • setMapQuadsToTriplesForTripleLangs

      public SELF setMapQuadsToTriplesForTripleLangs(boolean mapQuadsToTriplesForTripleLangs)
      Whether to convert quads to triples if a triple-based output format is requested Jena by default discards any quad outside of the default graph when writing to a triple format. Setting this flag to true will map each quad in a named graph to the default graph.
    • isUseCoalesceOne

      public boolean isUseCoalesceOne()
    • setUseCoalesceOne

      public void setUseCoalesceOne(boolean useCoalesceOne)
    • isDeletePartitionFolderAfterMerge

      public boolean isDeletePartitionFolderAfterMerge()
    • setDeletePartitionFolderAfterMerge

      public SELF setDeletePartitionFolderAfterMerge(boolean deletePartitionFolderAfterMerge)
    • getGlobalPrefixMapping

      public org.apache.jena.shared.PrefixMapping getGlobalPrefixMapping()
    • getPartitionFolder

      public org.apache.hadoop.fs.Path getPartitionFolder()
    • setPartitionFolder

      public SELF setPartitionFolder(org.apache.hadoop.fs.Path partitionFolder)
    • setPartitionFolder

      public SELF setPartitionFolder(String partitionFolder)
    • getTargetFile

      public org.apache.hadoop.fs.Path getTargetFile()
    • setTargetFile

      public SELF setTargetFile(org.apache.hadoop.fs.Path targetFile)
    • setTargetFile

      public SELF setTargetFile(String targetFile)
    • setGlobalPrefixMapping

      public SELF setGlobalPrefixMapping(org.apache.jena.shared.PrefixMapping globalPrefixMapping)
      Set a prefix mapping to be used "globally" across all partitions.
      Parameters:
      globalPrefixMapping -
      Returns:
    • setGlobalPrefixMapping

      public SELF setGlobalPrefixMapping(Map<String,String> globalPrefixMap)
    • getOutputFormat

      public org.apache.jena.riot.RDFFormat getOutputFormat()
    • setOutputFormat

      public SELF setOutputFormat(org.apache.jena.riot.RDFFormat format)
    • setOutputFormat

      public SELF setOutputFormat(String formatName)
      Raises an exception if the format is not found
    • getFallbackOutputFormat

      public org.apache.jena.riot.RDFFormat getFallbackOutputFormat()
    • isAllowOverwriteFiles

      public boolean isAllowOverwriteFiles()
    • setAllowOverwriteFiles

      public SELF setAllowOverwriteFiles(boolean allowOverwriteFiles)
    • isUseElephas

      public boolean isUseElephas()
    • setUseElephas

      public SELF setUseElephas(boolean useElephas)
    • isPartitionsAsIndependentFiles

      public boolean isPartitionsAsIndependentFiles()
    • setPartitionsAsIndependentFiles

      public SELF setPartitionsAsIndependentFiles(boolean partitionsAsIndependentFiles)
    • setDeferOutputForUsedPrefixes

      public SELF setDeferOutputForUsedPrefixes(long deferOutputForUsedPrefixes)
    • isConsoleOutput

      public boolean isConsoleOutput()
      If neither partition folder nor targe file is set the output goes to the console
    • setConsoleOutput

      public SELF setConsoleOutput()
    • setConsoleOutSupplier

      public SELF setConsoleOutSupplier(Supplier<OutputStream> consoleOutSupplier)
    • getConsoleOutSupplier

      public Supplier<OutputStream> getConsoleOutSupplier()
    • getPostProcessingSettings

      public RdfPostProcessingSettingsMutable getPostProcessingSettings()
    • setPostProcessingSettings

      public SELF setPostProcessingSettings(RdfPostProcessingSettingsMutable postProcessingSettings)