Class JsonLdQuadLikeImpl<S extends RDFTerm,P extends RDFTerm,O extends RDFTerm,G extends RDFTerm>
- java.lang.Object
-
- org.apache.commons.rdf.jsonldjava.JsonLdQuadLikeImpl<S,P,O,G>
-
- All Implemented Interfaces:
QuadLike<G>,TripleLike,JsonLdQuadLike<G>,JsonLdTripleLike
- Direct Known Subclasses:
JsonLdQuadImpl,JsonLdTripleImpl
class JsonLdQuadLikeImpl<S extends RDFTerm,P extends RDFTerm,O extends RDFTerm,G extends RDFTerm> extends java.lang.Object implements JsonLdQuadLike<G>
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.StringblankNodePrefixprivate com.github.jsonldjava.core.RDFDataset.Quadquadprivate static JsonLdRDFrdfTermFactory
-
Constructor Summary
Constructors Constructor Description JsonLdQuadLikeImpl(com.github.jsonldjava.core.RDFDataset.Quad jsonldQuad, java.lang.String blankNodePrefix)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description com.github.jsonldjava.core.RDFDataset.QuadasJsonLdQuad()Return the underlying JsonLDRDFDataset.Quadjava.util.Optional<G>getGraphName()The graph name (graph label) of this statement, if present.OgetObject()The object of this statement.PgetPredicate()The predicate of this statement.SgetSubject()The subject of this statement.java.lang.StringtoString()
-
-
-
Field Detail
-
rdfTermFactory
private static JsonLdRDF rdfTermFactory
-
quad
private final com.github.jsonldjava.core.RDFDataset.Quad quad
-
blankNodePrefix
private final java.lang.String blankNodePrefix
-
-
Method Detail
-
getGraphName
public java.util.Optional<G> getGraphName()
Description copied from interface:QuadLikeThe graph name (graph label) of this statement, if present.If
Optional.isPresent(), then theOptional.get()indicate the graph name of this statement. If the graph name is not present,e.g. the value isOptional.empty(), it indicates that this Quad is in the default graph.
-
getSubject
public S getSubject()
Description copied from interface:TripleLikeThe subject of this statement.- Specified by:
getSubjectin interfaceTripleLike- Returns:
- The subject, typically an
IRIorBlankNode.
-
getPredicate
public P getPredicate()
Description copied from interface:TripleLikeThe predicate of this statement.- Specified by:
getPredicatein interfaceTripleLike- Returns:
- The predicate, typically an
IRI.
-
getObject
public O getObject()
Description copied from interface:TripleLikeThe object of this statement.- Specified by:
getObjectin interfaceTripleLike- Returns:
- The object, typically an
IRI,BlankNodeorLiteral.
-
asJsonLdQuad
public com.github.jsonldjava.core.RDFDataset.Quad asJsonLdQuad()
Description copied from interface:JsonLdTripleLikeReturn the underlying JsonLDRDFDataset.Quad- Specified by:
asJsonLdQuadin interfaceJsonLdTripleLike- Returns:
- The JsonLD
RDFDataset.Quad
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-