- All Superinterfaces:
Container
,FrontsNode
,RDFNode
,Resource
- All Known Implementing Classes:
SeqImpl
This interface defines methods for accessing RDF Sequence resources. These methods operate on the RDF statements contained in a model. The Sequence implementation may cache state from the underlying model, so objects should not be added to or removed from the Sequence by directly manipulating its properties, whilst the Sequence is being accessed through this interface.
When a member is deleted from a sequence using this interface, or an iterator returned through this interface, all the other members with higher ordinals are renumbered to one below what they previously were.
This interface provides methods supporting typed literals. This means
that methods are provided which will translate a built in type, or an
object to an RDF Literal. This translation is done by invoking the
toString()
method of the object, or its built in equivalent.
The reverse translation is also supported. This is built in for built
in types. Factory objects, provided by the application, are used
for application objects.
This interface provides methods for supporting enhanced resources. An enhanced resource is a resource to which the application has added behaviour. RDF containers are examples of enhanced resources built in to this package. Enhanced resources are supported by encapsulating a resource created by an implementation in another class which adds the extra behaviour. Factory objects are used to construct such enhanced resources.
-
Method Summary
Modifier and TypeMethodDescriptionadd
(int index, boolean o) Insert a new member into the sequence at the specified position.add
(int index, char o) Insert a new member into the sequence at the specified position.add
(int index, double o) Insert a new member into the sequence at the specified position.add
(int index, float o) Insert a new member into the sequence at the specified position.add
(int index, long o) Insert a new member into the sequence at the specified position.Insert a new member into the sequence at the specified position.Insert a new member into the sequence at the specified position.Insert a new member into the sequence at the specified position.Insert a new member into the sequence at the specified position.getAlt
(int index) Get the member at a given index.getBag
(int index) Get the member at a given index.boolean
getBoolean
(int index) Get the member at a given index.byte
getByte
(int index) Get the member at a given index.char
getChar
(int index) Get the member at a given index.double
getDouble
(int index) Get the member at a given index.float
getFloat
(int index) Get the member at a given index.int
getInt
(int index) Get the member at a given index.getLanguage
(int index) Get the language of the member at a given index.getLiteral
(int index) Get the member at a given index.long
getLong
(int index) Get the member at a given index.getObject
(int index) Get the member at a given index.getResource
(int index) Get the member at a given index.getSeq
(int index) Get the member at a given index.short
getShort
(int index) Get the member at a given index.getString
(int index) Get the member at a given index.int
indexOf
(boolean o) Return the index of a given member of the sequence.int
indexOf
(char o) Return the index of a given member of the sequence.int
indexOf
(double o) Return the index of a given member of the sequence.int
indexOf
(float o) Return the index of a given member of the sequence.int
indexOf
(long o) Return the index of a given member of the sequence.int
Return the index of a given member of the sequence.int
Return the index of a given member of the sequence.int
Return the index of a given member of the sequence.int
Return the index of a given member of the sequence.remove
(int index) Remove the member at the specified index.set
(int index, boolean o) Set the value at a given index in the sequence.set
(int index, char o) Set the value at a given index in the sequence.set
(int index, double o) Set the value at a given index in the sequence.set
(int index, float o) Set the value at a given index in the sequence.set
(int index, long o) Set the value at a given index in the sequence.Set the value at a given index in the sequence.Set the value at a given index in the sequence.Set the value at a given index in the sequence.Set the value at a given index in the sequence.Methods inherited from interface org.apache.jena.rdf.model.Container
add, add, add, add, add, add, add, add, add, contains, contains, contains, contains, contains, contains, contains, contains, contains, isAlt, isBag, isSeq, iterator, remove, size
Methods inherited from interface org.apache.jena.graph.FrontsNode
asNode
Methods inherited from interface org.apache.jena.rdf.model.RDFNode
as, asLiteral, asResource, canAs, getModel, isAnon, isLiteral, isResource, isStmtResource, isURIResource, visitWith
Methods inherited from interface org.apache.jena.rdf.model.Resource
abort, addLiteral, addLiteral, addLiteral, addLiteral, addLiteral, addLiteral, addLiteral, addProperty, addProperty, addProperty, addProperty, begin, commit, equals, getId, getLocalName, getNameSpace, getProperty, getProperty, getPropertyResourceValue, getRequiredProperty, getRequiredProperty, getStmtTerm, getURI, hasLiteral, hasLiteral, hasLiteral, hasLiteral, hasLiteral, hasLiteral, hasProperty, hasProperty, hasProperty, hasProperty, hasURI, inModel, listProperties, listProperties, listProperties, removeAll, removeProperties, toString
-
Method Details
-
add
Insert a new member into the sequence at the specified position.The existing member at that position, and all others with higher indexes, have their index increased by one.
- Parameters:
index
- The index of the new member,o
- The member to be added.- Returns:
- this object to enable cascading of method calls.
-
add
Insert a new member into the sequence at the specified position.The existing member at that position, and all others with higher indexes, have their index increased by one.
- Parameters:
index
- The index of the new member,o
- The member to be added.- Returns:
- this object to enable cascading of method calls.
-
add
Insert a new member into the sequence at the specified position.The existing member at that position, and all others with higher indexes, have their index increased by one.
- Parameters:
index
- The index of the new member,o
- The member to be added.- Returns:
- this object to enable cascading of method calls.
-
add
Insert a new member into the sequence at the specified position.The existing member at that position, and all others with higher indexes, have their index increased by one.
- Parameters:
index
- The index of the new member,o
- The member to be added.- Returns:
- this object to enable cascading of method calls.
-
add
Insert a new member into the sequence at the specified position.The existing member at that position, and all others with higher indexes, have their index increased by one.
- Parameters:
index
- The index of the new member,o
- The member to be added.- Returns:
- this object to enable cascading of method calls.
-
add
Insert a new member into the sequence at the specified position.The existing member at that position, and all others with higher indexes, have their index increased by one.
- Parameters:
index
- The index of the new member,o
- The member to be added.- Returns:
- this object to enable cascading of method calls.
-
add
Insert a new member into the sequence at the specified position.The existing member at that position, and all others with higher indexes, have their index increased by one.
- Parameters:
index
- The index of the new member,o
- The member to be added.- Returns:
- this object to enable cascading of method calls.
-
add
Insert a new member into the sequence at the specified position.The existing member at that position, and all others with higher indexes, have their index increased by one.
- Parameters:
index
- The index of the new member,o
- The member to be added.l
- the language of the value added- Returns:
- this object to enable cascading of method calls.
-
add
Insert a new member into the sequence at the specified position.The existing member at that position, and all others with higher indexes, have their index increased by one.
- Parameters:
index
- The index of the new member,o
- The member to be added.- Returns:
- this object to enable cascading of method calls.
-
getBoolean
boolean getBoolean(int index) Get the member at a given index.- Parameters:
index
- The index of the required member.- Returns:
- The member at the given index.
-
getByte
byte getByte(int index) Get the member at a given index.- Parameters:
index
- The index of the required member.- Returns:
- The member at the given index.
-
getShort
short getShort(int index) Get the member at a given index.- Parameters:
index
- The index of the required member.- Returns:
- The member at the given index.
-
getInt
int getInt(int index) Get the member at a given index.- Parameters:
index
- The index of the required member.- Returns:
- The member at the given index.
-
getLong
long getLong(int index) Get the member at a given index.- Parameters:
index
- The index of the required member.- Returns:
- The member at the given index.
-
getChar
char getChar(int index) Get the member at a given index.- Parameters:
index
- The index of the required member.- Returns:
- The member at the given index.
-
getFloat
float getFloat(int index) Get the member at a given index.- Parameters:
index
- The index of the required member.- Returns:
- The member at the given index.
-
getDouble
double getDouble(int index) Get the member at a given index.- Parameters:
index
- The index of the required member.- Returns:
- The member at the given index.
-
getString
Get the member at a given index.- Parameters:
index
- The index of the required member.- Returns:
- The member at the given index.
-
getLanguage
Get the language of the member at a given index.- Parameters:
index
- The index of the required member.- Returns:
- The member at the given index.
-
getLiteral
Get the member at a given index.- Parameters:
index
- The index of the required member.- Returns:
- The member at the given index.
-
getResource
Get the member at a given index.- Parameters:
index
- The index of the required member. .- Returns:
- The member at the given index.
-
getObject
Get the member at a given index.- Parameters:
index
- The index of the required member.- Returns:
- The member at the given index.
-
getBag
Get the member at a given index.- Parameters:
index
- The index of the required member.- Returns:
- The member at the given index.
-
getAlt
Get the member at a given index.- Parameters:
index
- The index of the required member.- Returns:
- The member at the given index.
-
getSeq
Get the member at a given index.- Parameters:
index
- The index of the required member.- Returns:
- The member at the given index.
-
remove
Remove the member at the specified index.All other members with a higher index will have their index reduced by one.
- Parameters:
index
- The index of the member to be removed.- Returns:
- this object to enable cascading of method calls.
-
indexOf
Return the index of a given member of the sequence.If more the same value appears more than once in the sequence, it is undefined which of the indexes will be returned.
If the member is not found in this sequence, a value of 0 is returned.
- Parameters:
o
- The member sought.- Returns:
- an index of the member in this sequence or 0 if the member is not found in this sequence.
-
indexOf
int indexOf(boolean o) Return the index of a given member of the sequence.If more the same value appears more than once in the sequence, it is undefined which of the indexes will be returned.
If the member is not found in this sequence, a value of 0 is returned.
- Parameters:
o
- The member sought.- Returns:
- an index of the member in this sequence or 0 if the member is not found in this sequence.
-
indexOf
int indexOf(long o) Return the index of a given member of the sequence.If more the same value appears more than once in the sequence, it is undefined which of the indexes will be returned.
If the member is not found in this sequence, a value of 0 is returned.
- Parameters:
o
- The member sought.- Returns:
- an index of the member in this sequence or 0 if the member is not found in this sequence.
-
indexOf
int indexOf(char o) Return the index of a given member of the sequence.If more the same value appears more than once in the sequence, it is undefined which of the indexes will be returned.
If the member is not found in this sequence, a value of 0 is returned.
- Parameters:
o
- The member sought.- Returns:
- an index of the member in this sequence or 0 if the member is not found in this sequence.
-
indexOf
int indexOf(float o) Return the index of a given member of the sequence.If more the same value appears more than once in the sequence, it is undefined which of the indexes will be returned.
If the member is not found in this sequence, a value of 0 is returned.
- Parameters:
o
- The member sought. .- Returns:
- an index of the member in this sequence or 0 if the member is not found in this sequence.
-
indexOf
int indexOf(double o) Return the index of a given member of the sequence.If more the same value appears more than once in the sequence, it is undefined which of the indexes will be returned.
If the member is not found in this sequence, a value of 0 is returned.
- Parameters:
o
- The member sought.- Returns:
- an index of the member in this sequence or 0 if the member is not found in this sequence.
-
indexOf
Return the index of a given member of the sequence.If more the same value appears more than once in the sequence, it is undefined which of the indexes will be returned.
If the member is not found in this sequence, a value of 0 is returned.
- Parameters:
o
- The member sought.- Returns:
- an index of the member in this sequence or 0 if the member is not found in this sequence.
-
indexOf
Return the index of a given member of the sequence.If more the same value appears more than once in the sequence, it is undefined which of the indexes will be returned.
If the member is not found in this sequence, a value of 0 is returned.
- Parameters:
o
- The member sought.l
- the language of the member sought- Returns:
- an index of the member in this sequence or 0 if the member is not found in this sequence.
-
indexOf
Return the index of a given member of the sequence.If more the same value appears more than once in the sequence, it is undefined which of the indexes will be returned.
If the member is not found in this sequence, a value of 0 is returned.
- Parameters:
o
- The member sought.- Returns:
- an index of the member in this sequence or 0 if the member is not found in this sequence.
-
set
Set the value at a given index in the sequence.If the index is not in the range 1 to the size of the sequence, then an exception is raised.
- Parameters:
index
- The index whose member is to be set.o
- The value to be set.- Returns:
- this object to enable cascading method calls.
- Throws:
SeqIndexBoundsException
-
set
Set the value at a given index in the sequence.If the index is not in the range 1 to the size of the sequence, then a Jena exception is raised.
- Parameters:
index
- The index whose member is to be set.o
- The value to be set.- Returns:
- this object to enable cascading method calls.
- Throws:
SeqIndexBoundsException
-
set
Set the value at a given index in the sequence.If the index is not in the range 1 to the size of the sequence, then a Jena exception is raised.
- Parameters:
index
- The index whose member is to be set.o
- The value to be set.- Returns:
- this object to enable cascading method calls.
- Throws:
SeqIndexBoundsException
-
set
Set the value at a given index in the sequence.If the index is not in the range 1 to the size of the sequence, then a Jena exception is raised.
- Parameters:
index
- The index whose member is to be set.o
- The value to be set.- Returns:
- this object to enable cascading method calls.
- Throws:
SeqIndexBoundsException
-
set
Set the value at a given index in the sequence.If the index is not in the range 1 to the size of the sequence, then a Jena exception is raised.
- Parameters:
index
- The index whose member is to be set.o
- The value to be set.- Returns:
- this object to enable cascading method calls.
- Throws:
SeqIndexBoundsException
-
set
Set the value at a given index in the sequence.If the index is not in the range 1 to the size of the sequence, then a Jena exception is raised.
- Parameters:
index
- The index whose member is to be set.o
- The value to be set.- Returns:
- this object to enable cascading method calls.
- Throws:
SeqIndexBoundsException
-
set
Set the value at a given index in the sequence.If the index is not in the range 1 to the size of the sequence, then a Jena exception is raised.
- Parameters:
index
- The index whose member is to be set.o
- The value to be set.- Returns:
- this object to enable cascading method calls.
- Throws:
SeqIndexBoundsException
-
set
Set the value at a given index in the sequence.If the index is not in the range 1 to the size of the sequence, then a Jena exception is raised.
- Parameters:
index
- The index whose member is to be set.o
- The value to be set.l
- The language of the value set.- Returns:
- this object to enable cascading method calls.
- Throws:
SeqIndexBoundsException
-
set
Set the value at a given index in the sequence.If the index is not in the range 1 to the size of the sequence, then a Jena exception is raised.
- Parameters:
index
- The index whose member is to be set.o
- The value to be set.- Returns:
- this object to enable cascading method calls.
- Throws:
SeqIndexBoundsException
-