Class TripleImpl
java.lang.Object
org.apache.commons.rdf.rdf4j.impl.TripleImpl
- All Implemented Interfaces:
Triple, TripleLike, RDF4JTriple, RDF4JTripleLike
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.eclipse.rdf4j.model.StatementReturn the corresponding RDF4JStatement.booleanCheck it this Triple is equal to another Triple.The predicateIRIof this triple.The subject of this triple, which may be either aBlankNodeor anIRI, which are represented in Commons RDF by the interfaceBlankNodeOrIRI.inthashCode()Calculate a hash code for this Triple.toString()
-
Field Details
-
salt
-
statement
private final org.eclipse.rdf4j.model.Statement statement
-
-
Constructor Details
-
TripleImpl
TripleImpl(org.eclipse.rdf4j.model.Statement statement, UUID salt)
-
-
Method Details
-
asStatement
public org.eclipse.rdf4j.model.Statement asStatement()Description copied from interface:RDF4JTripleLikeReturn the corresponding RDF4JStatement.- Specified by:
asStatementin interfaceRDF4JTripleLike- Returns:
- The corresponding RDF4J Statement.
-
equals
Description copied from interface:TripleCheck it this Triple is equal to another Triple.Two Triples are equal if and only if their
Triple.getSubject(),Triple.getPredicate()andTriple.getObject()are equal.Implementations MUST also override
Triple.hashCode()so that two equal Triples produce the same hash code. -
getObject
Description copied from interface:TripleThe object of this triple, which may be either aBlankNode, anIRI, or aLiteral, which are represented in Commons RDF by the interfaceRDFTerm.- Specified by:
getObjectin interfaceTriple- Specified by:
getObjectin interfaceTripleLike- Returns:
- The object
RDFTermof this triple. - See Also:
-
getPredicate
Description copied from interface:TripleThe predicateIRIof this triple.- Specified by:
getPredicatein interfaceTriple- Specified by:
getPredicatein interfaceTripleLike- Returns:
- The predicate
IRIof this triple. - See Also:
-
getSubject
Description copied from interface:TripleThe subject of this triple, which may be either aBlankNodeor anIRI, which are represented in Commons RDF by the interfaceBlankNodeOrIRI.- Specified by:
getSubjectin interfaceTriple- Specified by:
getSubjectin interfaceTripleLike- Returns:
- The subject
BlankNodeOrIRIof this triple. - See Also:
-
hashCode
public int hashCode()Description copied from interface:TripleCalculate a hash code for this Triple.The returned hash code MUST be equal to the result of
Objects.hash(Object...)with the argumentsTriple.getSubject(),Triple.getPredicate(),Triple.getObject().This method MUST be implemented in conjunction with
Triple.equals(Object)so that two equalTriples produce the same hash code. -
toString
-