public class ExtensibleStatementImpl extends SimpleStatement implements ExtensibleStatement
Constructor and Description |
---|
ExtensibleStatementImpl(Resource subject,
IRI predicate,
Value object,
boolean inferred)
Creates a new Statement with the supplied subject, predicate and object.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object o)
Compares this statement to another object.
|
int |
hashCode()
Computes the hash code of this statement.
|
boolean |
isInferred() |
getContext, getObject, getPredicate, getSubject
toString
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
getContext, getObject, getPredicate, getSubject
public ExtensibleStatementImpl(Resource subject, IRI predicate, Value object, boolean inferred)
Note that creating SimpleStatement objects directly via this constructor is not the recommended approach.
Instead, use a ValueFactory
(obtained from your repository or by using
SimpleValueFactory.getInstance()
) to create new Statement objects.
subject
- The statement's subject, must not be null.predicate
- The statement's predicate, must not be null.object
- The statement's object, must not be null.SimpleValueFactory.createStatement(Resource, IRI, Value)
public boolean isInferred()
isInferred
in interface ExtensibleStatement
public boolean equals(Object o)
Statement
equals
in interface Statement
equals
in class AbstractStatement
o
- the object to compare this statement totrue
if the other object is an instance of Statement
and if their
subjects, predicates, objects and contexts are equal; false
otherwisepublic int hashCode()
Statement
hashCode
in interface Statement
hashCode
in class AbstractStatement
Objects.hash
(
Statement.getSubject()
, Statement.getPredicate()
, Statement.getObject()
, Statement.getContext()
)Copyright © 2015-2020 Eclipse Foundation. All Rights Reserved.