|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ResourceSet
ResourceSet is a container for a set of resources. Generally a
ResourceSet
is obtained as the result of a query.
Method Summary | |
---|---|
void |
addAll(ResourceSet rSet)
Adds all Resource instances in the resourceSet
to this set. |
void |
addResource(Resource res)
Adds a Resource instance to the set. |
void |
clear()
Removes all Resource instances from the set. |
ResourceIterator |
getIterator()
Returns an iterator over all Resource instances stored in the set. |
Resource |
getMembersAsResource()
Returns a Resource containing an XML representation of all resources stored in the set. |
Resource |
getResource(int index)
Returns the Resource instance stored at the index specified
by index. |
int |
getSize()
Returns the number of resources contained in the set. |
void |
removeResource(int index)
Removes the Resource located at index from the set. |
Method Detail |
---|
Resource getResource(int index) throws XMLDBException
Resource
instance stored at the index specified
by index.
If the underlying implementation uses a paging or streaming optimization
for retrieving Resource instances. Calling this method MAY result in a
block until the requested Resource has been downloaded.
index
- the index of the resource to retrieve.
Resource
instance
XMLDBException
- with expected error codes.ErrorCodes.VENDOR_ERROR
for any vendor
specific errors that occur.ErrorCodes.NO_SUCH_RESOURCE if the index is out of range for the
set.
void addResource(Resource res) throws XMLDBException
Resource
instance to the set.
res
- The Resource
to add to the set.
XMLDBException
- with expected error codes.ErrorCodes.VENDOR_ERROR
for any vendor
specific errors that occur.void addAll(ResourceSet rSet) throws XMLDBException
Resource
instances in the resourceSet
to this set.
rSet
- The ResourceSet
containing all the Resource
's
to add to the set.
XMLDBException
- with expected error codes.ErrorCodes.VENDOR_ERROR
for any vendor
specific errors that occur.void removeResource(int index) throws XMLDBException
index
from the set.
index
- The index of the Resource
instance to remove.
XMLDBException
- with expected error codes.ErrorCodes.VENDOR_ERROR
for any vendor
specific errors that occur.ResourceIterator getIterator() throws XMLDBException
Resource
instances stored in the set.
ResourceIterator
over all Resource
instances in the set.
XMLDBException
- with expected error codes.ErrorCodes.VENDOR_ERROR
for any vendor
specific errors that occur.Resource getMembersAsResource() throws XMLDBException
Resource
instance containing an XML representation
of all set members.
XMLDBException
- with expected error codes.ErrorCodes.VENDOR_ERROR
for any vendor
specific errors that occur.int getSize() throws XMLDBException
Resource
instances. Calling this method MAY
force the downloading of all set members before the size can be determined.
Resource
instances in the set.
XMLDBException
- with expected error codes.ErrorCodes.VENDOR_ERROR
for any vendor
specific errors that occur.void clear() throws XMLDBException
Resource
instances from the set.
XMLDBException
- with expected error codes.ErrorCodes.VENDOR_ERROR
for any vendor
specific errors that occur.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |