Class Prefixes

java.lang.Object
org.apache.jena.riot.system.Prefixes

public class Prefixes extends Object
Functions related to PrefixMap.
See Also:
  • Field Details

    • dftGraphPrefixSet

      public static final String dftGraphPrefixSet
      Special name for default graph prefixes. This is different to the datasetPrefixSet. Only used by (TDB1) GraphTxnTDB_Prefixes and (TDB2) GraphViewSwitchable_Prefixes which have separated dataset/default graph prefixes. For legacy migration reasons, TDB1 uses "" and TDB2 uses defaultGraphNodeGenerated for the dataset prefix set. See TDB1 ) TDB2 StoragePrefixesView
      See Also:
    • datasetPrefixSet

      public static final String datasetPrefixSet
      Name for dataset-wide prefixes.
      See Also:
    • nodeDefaultGraph

      public static org.apache.jena.graph.Node nodeDefaultGraph
      Name assigned to the default graph.
    • nodeDataset

      public static org.apache.jena.graph.Node nodeDataset
      Name for dataset prefixes.
  • Constructor Details

    • Prefixes

      public Prefixes()
  • Method Details

    • prefix

      public static String prefix(String prefix)
      Canonical prefix - remove a trailing ":". The return is not null.
    • findByURI

      public static String findByURI(PrefixMap pmap, String uriStr)
      Reverse lookup of URI to a prefix. General implementation by scanning the PrefixMap. Returns a prefix if found or null. If several prefixes for the same URI, returns one at random.
    • adapt

      public static PrefixMap adapt(org.apache.jena.graph.Graph graph)
      Provide, via an adapter if necessary, the PrefixMap for a Graph.
    • adapt

      public static org.apache.jena.shared.PrefixMapping adapt(PrefixMap prefixMap)
      Apply a wrapper to a PrefixMap to provide the PrefixMapping API.
    • adapt

      public static PrefixMap adapt(org.apache.jena.shared.PrefixMapping prefixMapping)
      Apply a wrapper to a PrefixMapping to provide the PrefixMap API.
    • toString

      public static String toString(PrefixMap prefixMap)
      Calculate a printable multi-line string.