|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
This interface defines all the data access methods for collections. Wherever addresses are involved in creating new collections, all non-existing collections in the specified path will be created automatically.
All the methods throw the following exceptions:
| Method Summary | |
boolean |
createCollection(String address)
Creates a collection specified by the address. |
boolean |
deleteCollection(String address,
boolean force)
Deletes the collection specified by the address. |
ResourceList |
getCollectionContents(String collectionAddress)
Returns a ResourceList containing resource descriptors for each of the resources and collections in the specified collection. |
boolean |
isCollection(String address)
Returns true if the specified address points to a collection. |
ResourceList |
scanCollection(String address,
Pattern pattern,
boolean includeCollections)
Returns a ResourceList containing resource descriptors for each of the resources (and possibly collections) located within the specified collection which match the given pattern. |
| Method Detail |
public boolean isCollection(String address)
throws MalformedAddressException,
IOException
address - the address to check
MalformedAddressException
IOException
public boolean createCollection(String address)
throws MalformedAddressException,
IOException
address - address of the collection
MalformedAddressException
IOException
public boolean deleteCollection(String address,
boolean force)
throws MalformedAddressException,
IOException
address - address of the collectionforce - if true, then the collection will be deleted even if it contains resources and other sub-collections.
Use with caution, as all resources contained within the collection will be deleted
MalformedAddressException
IOException
public ResourceList getCollectionContents(String collectionAddress)
throws MalformedAddressException,
ResourceNotFoundException,
IOException
There is no guarantee that the resource descriptors in the resulting resourcelist will appear in any specific order; they are not, in particular, guaranteed to appear in alphabetical order of resource names.
collectionAddress - path to the collection
ResourceNotFoundException - if the specified collection doesnt exist
MalformedAddressException
IOException
public ResourceList scanCollection(String address,
Pattern pattern,
boolean includeCollections)
throws MalformedAddressException,
ResourceNotFoundException,
IOException
getCollectionContents(java.lang.String), this method perfoms a recursive search.
There is no guarantee that the resource descriptors in the resulting resourcelist will appear in any specific order; they are not, in particular, guaranteed to appear in alphabetical order of resource names.
address - path to the collectionpattern - pattern to match againstincludeCollections -
ResourceNotFoundException - if the specified collection doesnt exist
MalformedAddressException
IOException
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||