@Deprecated public class GraphUtil extends Object
Graph
objects. Note that since
release 2.7.0, most of the functionality here is also available (in more
convenient form) in the Model
interface, which
extends Graph
.Constructor and Description |
---|
GraphUtil()
Deprecated.
|
@Deprecated public static Iterator<Resource> getSubjectIterator(Graph graph, URI pred, Value obj, Resource... contexts)
Model.filter(Resource, URI, Value, Resource...)
and
Model.subjects()
instead.Graph.match(Resource, URI, Value, Resource[])
for a
description of the parameter values.@Deprecated public static Set<Resource> getSubjects(Graph graph, URI pred, Value obj, Resource... contexts)
Model.filter(Resource, URI, Value, Resource...)
and
Model.subjects()
instead.Graph.match(Resource, URI, Value, Resource[])
for a description of
the parameter values.@Deprecated public static Resource getUniqueSubject(Graph graph, URI pred, Value obj, Resource... contexts) throws GraphUtilException
Model.filter(Resource, URI, Value, Resource...)
and
Model.subjectResource()
instead.GraphUtilException
is thrown if these conditions are not met. See
Graph.match(Resource, URI, Value, Resource[])
for a description of
the parameter values.GraphUtilException
- If the statements matched by the specified parameters do not have
exactly one unique subject.@Deprecated public static URI getUniqueSubjectURI(Graph graph, URI pred, Value obj, Resource... contexts) throws GraphUtilException
Model.filter(Resource, URI, Value, Resource...)
and
Model.subjectURI()
instead.getUniqueSubject(Graph, URI, Value, Resource[])
to a URI, or
throws a GraphUtilException if that value is not a URI.GraphUtilException
- If such an exception is thrown by
getUniqueSubject(Graph, URI, Value, Resource[])
or if its
return value is not a URI.@Deprecated public static Resource getOptionalSubject(Graph graph, URI pred, Value obj, Resource... contexts) throws GraphUtilException
Model.filter(Resource, URI, Value, Resource...)
and
Model.subjectResource()
instead.GraphUtilException
is thrown if this is not the case. See
Graph.match(Resource, URI, Value, Resource[])
for a description of
the parameter values.GraphUtilException
- If the statements matched by the specified parameters have more
than one unique subject.@Deprecated public static URI getOptionalSubjectURI(Graph graph, URI pred, Value obj, Resource... contexts) throws GraphUtilException
Model.filter(Resource, URI, Value, Resource...)
and
Model.subjectURI()
instead.getOptionalSubject(Graph, URI, Value, Resource[])
to a URI, or
throws a GraphUtilException if that value is not a URI.GraphUtilException
- If such an exception is thrown by
getOptionalSubject(Graph, URI, Value, Resource[])
or if
its return value is not a URI.@Deprecated public static Iterator<Value> getObjectIterator(Graph graph, Resource subj, URI pred, Resource... contexts)
Model.filter(Resource, URI, Value, Resource...)
and
Model.objects()
instead.Graph.match(Resource, URI, Value, Resource[])
for a
description of the parameter values.@Deprecated public static Set<Value> getObjects(Graph graph, Resource subj, URI pred, Resource... contexts)
Model.filter(Resource, URI, Value, Resource...)
and
Model.objects()
instead.Graph.match(Resource, URI, Value, Resource[])
for a description of
the parameter values.@Deprecated public static Value getUniqueObject(Graph graph, Resource subj, URI pred, Resource... contexts) throws GraphUtilException
Model.filter(Resource, URI, Value, Resource...)
and
Model.objectValue()
instead.GraphUtilException
is thrown if these conditions
are not met. See Graph.match(Resource, URI, Value, Resource[])
for
a description of the parameter values.GraphUtilException
- If the statements matched by the specified parameters do not have
exactly one unique object.@Deprecated public static void setUniqueObject(Graph graph, Resource subj, URI pred, Value obj, Resource... contexts)
Models.setProperty(Model, Resource, URI, Value, Resource...)
instead.@Deprecated public static Resource getUniqueObjectResource(Graph graph, Resource subj, URI pred) throws GraphUtilException
Model.filter(Resource, URI, Value, Resource...)
and
Model.objectResource()
instead.getUniqueObject(Graph, Resource, URI, Resource[])
to a Resource,
or throws a GraphUtilException if that value is not a Resource.GraphUtilException
- If such an exception is thrown by
getUniqueObject(Graph, Resource, URI, Resource[])
or if
its return value is not a Resource.@Deprecated public static URI getUniqueObjectURI(Graph graph, Resource subj, URI pred) throws GraphUtilException
Model.filter(Resource, URI, Value, Resource...)
and
Model.objectURI()
instead.getUniqueObject(Graph, Resource, URI, Resource[])
to a URI, or
throws a GraphUtilException if that value is not a URI.GraphUtilException
- If such an exception is thrown by
getUniqueObject(Graph, Resource, URI, Resource[])
or if
its return value is not a URI.@Deprecated public static Literal getUniqueObjectLiteral(Graph graph, Resource subj, URI pred) throws GraphUtilException
Model.filter(Resource, URI, Value, Resource...)
and
Model.objectLiteral()
instead.getUniqueObject(Graph, Resource, URI, Resource[])
to a Literal,
or throws a GraphUtilException if that value is not a Literal.GraphUtilException
- If such an exception is thrown by
getUniqueObject(Graph, Resource, URI, Resource[])
or if
its return value is not a Literal.@Deprecated public static Value getOptionalObject(Graph graph, Resource subj, URI pred, Resource... contexts) throws GraphUtilException
Model.filter(Resource, URI, Value, Resource...)
and
Model.objectValue()
instead.GraphUtilException
is thrown if this is not the case. See
Graph.match(Resource, URI, Value, Resource[])
for a description of
the parameter values.GraphUtilException
- If the statements matched by the specified parameters have more
than one unique object.@Deprecated public static Resource getOptionalObjectResource(Graph graph, Resource subj, URI pred) throws GraphUtilException
Model.filter(Resource, URI, Value, Resource...)
and
Model.objectResource()
instead.getOptionalObject(Graph, Resource, URI, Resource[])
to a
Resource, or throws a GraphUtilException if that value is not a Resource.GraphUtilException
- If such an exception is thrown by
getOptionalObject(Graph, Resource, URI, Resource[])
or if
its return value is not a Resource.@Deprecated public static URI getOptionalObjectURI(Graph graph, Resource subj, URI pred) throws GraphUtilException
Model.filter(Resource, URI, Value, Resource...)
and
Model.objectURI()
instead.getOptionalObject(Graph, Resource, URI, Resource[])
to a URI, or
throws a GraphUtilException if that value is not a URI.GraphUtilException
- If such an exception is thrown by
getOptionalObject(Graph, Resource, URI, Resource[])
or if
its return value is not a URI.@Deprecated public static Literal getOptionalObjectLiteral(Graph graph, Resource subj, URI pred) throws GraphUtilException
Model.filter(Resource, URI, Value, Resource...)
and
Model.objectLiteral()
instead.getOptionalObject(Graph, Resource, URI, Resource[])
to a Literal,
or throws a GraphUtilException if that value is not a Literal.GraphUtilException
- If such an exception is thrown by
getOptionalObject(Graph, Resource, URI, Resource[])
or if
its return value is not a Literal.@Deprecated public static void remove(Graph graph, Resource subj, URI pred, Value obj, Resource... contexts)
Model.remove(Resource, URI, Value, Resource...)
instead.graph
- The graph to remove the statements from.subj
- The subject of the statements to match, null to match
statements with any subject.pred
- The predicate of the statements to match, null to match
statements with any predicate.obj
- The object of the statements to match, null to match
statements with any object.contexts
- The contexts of the statements to match. If no contexts are
specified, statements will match disregarding their context. If one
or more contexts are specified, statements with a context matching
one of these will match.IllegalArgumentException
- If a null-array is specified as the value for
contexts. See
OpenRDFUtil.verifyContextNotNull(Resource[])
for more
info.Copyright © 2001-2016 Aduna. All Rights Reserved.