Class TermHashMap

    • Nested Class Summary

      • Nested classes/interfaces inherited from class java.util.AbstractMap

        java.util.AbstractMap.SimpleEntry<K extends java.lang.Object,​V extends java.lang.Object>, java.util.AbstractMap.SimpleImmutableEntry<K extends java.lang.Object,​V extends java.lang.Object>
      • Nested classes/interfaces inherited from interface java.util.Map

        java.util.Map.Entry<K extends java.lang.Object,​V extends java.lang.Object>
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private static long serialVersionUID  
    • Constructor Summary

      Constructors 
      Constructor Description
      TermHashMap()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      RdfResource createBlankNode​(java.lang.String value)
      Creates a blank node with the specified value.
      RdfResource createIRI​(java.lang.String value)
      Creates an IRI (Internationalized Resource Identifier) with the specified value.
      RdfLiteral createLangString​(java.lang.String lexicalValue, java.lang.String datatype, java.lang.String langTag, RdfLiteral.Direction direction)
      Creates an RDF language-tagged string with the specified lexical value, datatype, and language tag.
      RdfLiteral createLiteral​(java.lang.String lexicalValue, java.lang.String datatype)
      Creates an RDF literal with the specified lexical value and datatype.
      RdfQuad createQuad​(RdfResource subject, RdfResource predicate, RdfTerm object, RdfResource graph)
      Creates a quad consisting of a subject, predicate, object, and graph.
      RdfTriple createTriple​(RdfResource subject, RdfResource predicate, RdfTerm object)
      Creates a triple consisting of a subject, predicate, and object.
      • Methods inherited from class java.util.HashMap

        clear, clone, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, entrySet, forEach, get, getOrDefault, isEmpty, keySet, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size, values
      • Methods inherited from class java.util.AbstractMap

        equals, hashCode, toString
      • Methods inherited from class java.lang.Object

        finalize, getClass, notify, notifyAll, wait, wait, wait
      • Methods inherited from interface java.util.Map

        equals, hashCode
    • Constructor Detail

      • TermHashMap

        public TermHashMap()
    • Method Detail

      • createBlankNode

        public RdfResource createBlankNode​(java.lang.String value)
        Description copied from interface: RdfTermFactory
        Creates a blank node with the specified value.

        A blank node is an anonymous resource that does not have an IRI.

        Specified by:
        createBlankNode in interface RdfTermFactory
        Parameters:
        value - the value of the blank node (usually a string identifier)
        Returns:
        RdfResource representing the blank node
      • createIRI

        public RdfResource createIRI​(java.lang.String value)
        Description copied from interface: RdfTermFactory
        Creates an IRI (Internationalized Resource Identifier) with the specified value.

        An IRI is a globally unique identifier used to refer to a resource.

        Specified by:
        createIRI in interface RdfTermFactory
        Parameters:
        value - the value of the IRI (usually a URI string)
        Returns:
        RdfResource representing the IRI
      • createTriple

        public RdfTriple createTriple​(RdfResource subject,
                                      RdfResource predicate,
                                      RdfTerm object)
        Description copied from interface: RdfTermFactory
        Creates a triple consisting of a subject, predicate, and object.

        A triple is the core structure of RDF data, consisting of a subject, predicate, and object.

        Specified by:
        createTriple in interface RdfTermFactory
        Parameters:
        subject - the subject of the triple, must be a RdfResource
        predicate - the predicate of the triple, must be a RdfResource
        object - the object of the triple, can be any RdfTerm
        Returns:
        RdfTriple representing the RDF triple
      • createQuad

        public RdfQuad createQuad​(RdfResource subject,
                                  RdfResource predicate,
                                  RdfTerm object,
                                  RdfResource graph)
        Description copied from interface: RdfTermFactory
        Creates a quad consisting of a subject, predicate, object, and graph.

        A quad extends the triple structure by including an additional graph name, allowing RDF data to be associated with a specific graph.

        Specified by:
        createQuad in interface RdfTermFactory
        Parameters:
        subject - the subject of the quad, must be a RdfResource
        predicate - the predicate of the quad, must be a RdfResource
        object - the object of the quad, can be any RdfTerm
        graph - the graph name for the quad, must be a RdfResource
        Returns:
        RdfQuad representing the RDF quad
      • createLiteral

        public RdfLiteral createLiteral​(java.lang.String lexicalValue,
                                        java.lang.String datatype)
        Description copied from interface: RdfTermFactory
        Creates an RDF literal with the specified lexical value and datatype.

        RDF literals are used to represent values like strings, numbers, and dates.

        Specified by:
        createLiteral in interface RdfTermFactory
        Parameters:
        lexicalValue - the lexical value of the literal (e.g., "42", "hello")
        datatype - the datatype of the literal (e.g., xsd:string, xsd:int)
        Returns:
        RdfLiteral representing the RDF literal
      • createLangString

        public RdfLiteral createLangString​(java.lang.String lexicalValue,
                                           java.lang.String datatype,
                                           java.lang.String langTag,
                                           RdfLiteral.Direction direction)
        Description copied from interface: RdfTermFactory
        Creates an RDF language-tagged string with the specified lexical value, datatype, and language tag.

        Language-tagged strings are literals that also have a language tag, e.g., "hello"@en for English.

        Specified by:
        createLangString in interface RdfTermFactory
        Parameters:
        lexicalValue - the lexical value of the language-tagged string
        datatype - the datatype of the literal (should be rdf:langString)
        langTag - the language tag (e.g., "en", "fr")
        direction - the text direction of the string (LTR or RTL)
        Returns:
        RdfLiteral representing the language-tagged string