Class Any23ValueFactoryWrapper

  • All Implemented Interfaces:
    org.eclipse.rdf4j.model.ValueFactory

    public class Any23ValueFactoryWrapper
    extends Object
    implements org.eclipse.rdf4j.model.ValueFactory
    Any23 specialization of the ValueFactory. It provides a wrapper to instantiate RDF objects.
    • Constructor Detail

      • Any23ValueFactoryWrapper

        public Any23ValueFactoryWrapper​(org.eclipse.rdf4j.model.ValueFactory factory,
                                        IssueReport er,
                                        String defaultLitLanguage)
        Constructor with error reporter.
        Parameters:
        factory - the wrapped value factory, cannot be null.
        er - the error reporter.
        defaultLitLanguage - the default literal language.
      • Any23ValueFactoryWrapper

        public Any23ValueFactoryWrapper​(org.eclipse.rdf4j.model.ValueFactory vFactory,
                                        IssueReport er)
      • Any23ValueFactoryWrapper

        public Any23ValueFactoryWrapper​(org.eclipse.rdf4j.model.ValueFactory vFactory)
    • Method Detail

      • setIssueReport

        public void setIssueReport​(IssueReport er)
      • getDefaultLiteralLanguage

        public String getDefaultLiteralLanguage()
      • createBNode

        public org.eclipse.rdf4j.model.BNode createBNode()
        Specified by:
        createBNode in interface org.eclipse.rdf4j.model.ValueFactory
      • createBNode

        public org.eclipse.rdf4j.model.BNode createBNode​(String id)
        Specified by:
        createBNode in interface org.eclipse.rdf4j.model.ValueFactory
      • createLiteral

        public org.eclipse.rdf4j.model.Literal createLiteral​(String content)
        Specified by:
        createLiteral in interface org.eclipse.rdf4j.model.ValueFactory
      • createLiteral

        public org.eclipse.rdf4j.model.Literal createLiteral​(boolean b)
        Specified by:
        createLiteral in interface org.eclipse.rdf4j.model.ValueFactory
      • createLiteral

        public org.eclipse.rdf4j.model.Literal createLiteral​(byte b)
        Specified by:
        createLiteral in interface org.eclipse.rdf4j.model.ValueFactory
      • createLiteral

        public org.eclipse.rdf4j.model.Literal createLiteral​(short i)
        Specified by:
        createLiteral in interface org.eclipse.rdf4j.model.ValueFactory
      • createLiteral

        public org.eclipse.rdf4j.model.Literal createLiteral​(int i)
        Specified by:
        createLiteral in interface org.eclipse.rdf4j.model.ValueFactory
      • createLiteral

        public org.eclipse.rdf4j.model.Literal createLiteral​(long l)
        Specified by:
        createLiteral in interface org.eclipse.rdf4j.model.ValueFactory
      • createLiteral

        public org.eclipse.rdf4j.model.Literal createLiteral​(float v)
        Specified by:
        createLiteral in interface org.eclipse.rdf4j.model.ValueFactory
      • createLiteral

        public org.eclipse.rdf4j.model.Literal createLiteral​(double v)
        Specified by:
        createLiteral in interface org.eclipse.rdf4j.model.ValueFactory
      • createLiteral

        public org.eclipse.rdf4j.model.Literal createLiteral​(BigDecimal v)
        Specified by:
        createLiteral in interface org.eclipse.rdf4j.model.ValueFactory
      • createLiteral

        public org.eclipse.rdf4j.model.Literal createLiteral​(BigInteger v)
        Specified by:
        createLiteral in interface org.eclipse.rdf4j.model.ValueFactory
      • createLiteral

        public org.eclipse.rdf4j.model.Literal createLiteral​(XMLGregorianCalendar calendar)
        Specified by:
        createLiteral in interface org.eclipse.rdf4j.model.ValueFactory
      • createLiteral

        public org.eclipse.rdf4j.model.Literal createLiteral​(String label,
                                                             String language)
        Specified by:
        createLiteral in interface org.eclipse.rdf4j.model.ValueFactory
      • createLiteral

        public org.eclipse.rdf4j.model.Literal createLiteral​(String pref,
                                                             org.eclipse.rdf4j.model.IRI value)
        Specified by:
        createLiteral in interface org.eclipse.rdf4j.model.ValueFactory
      • createLiteral

        public org.eclipse.rdf4j.model.Literal createLiteral​(Date date)
        Specified by:
        createLiteral in interface org.eclipse.rdf4j.model.ValueFactory
      • createStatement

        public org.eclipse.rdf4j.model.Statement createStatement​(org.eclipse.rdf4j.model.Resource sub,
                                                                 org.eclipse.rdf4j.model.IRI pre,
                                                                 org.eclipse.rdf4j.model.Value obj)
        Specified by:
        createStatement in interface org.eclipse.rdf4j.model.ValueFactory
      • createStatement

        public org.eclipse.rdf4j.model.Statement createStatement​(org.eclipse.rdf4j.model.Resource sub,
                                                                 org.eclipse.rdf4j.model.IRI pre,
                                                                 org.eclipse.rdf4j.model.Value obj,
                                                                 org.eclipse.rdf4j.model.Resource context)
        Specified by:
        createStatement in interface org.eclipse.rdf4j.model.ValueFactory
      • createIRI

        public org.eclipse.rdf4j.model.IRI createIRI​(String uriStr)
        Specified by:
        createIRI in interface org.eclipse.rdf4j.model.ValueFactory
        Parameters:
        uriStr - input string to create URI from.
        Returns:
        a valid sesame IRI or null if any exception occurred
      • createIRI

        public org.eclipse.rdf4j.model.IRI createIRI​(String namespace,
                                                     String localName)
        Specified by:
        createIRI in interface org.eclipse.rdf4j.model.ValueFactory
        Returns:
        a valid sesame IRI or null if any exception occurred
      • resolveIRI

        public org.eclipse.rdf4j.model.IRI resolveIRI​(String uri,
                                                      URI baseIRI)
        Fixes typical errors in IRIs, and resolves relative IRIs against a base IRI.
        Parameters:
        uri - A IRI, relative or absolute, can have typical syntax errors
        baseIRI - A base IRI to use for resolving relative IRIs
        Returns:
        An absolute IRI, sytnactically valid, or null if not fixable
      • fixIRI

        public org.eclipse.rdf4j.model.IRI fixIRI​(String iri)
        Parameters:
        iri - IRI to fix
        Returns:
        a valid sesame IRI or null if any exception occurred
      • fixLink

        public org.eclipse.rdf4j.model.IRI fixLink​(String link,
                                                   String defaultSchema)
        Helper method to conditionally add a schema to a URI unless it's there, or null if link is empty.
        Parameters:
        link - string representation of the URI
        defaultSchema - schema to add the URI
        Returns:
        a valid sesame IRI or null if any exception occurred
      • fixWhiteSpace

        public String fixWhiteSpace​(String name)