org.ispheres.shared.core
Interface ISpherePublicInterface

All Known Implementing Classes:
ISphere, ISphereClient

public interface ISpherePublicInterface

An interface defining the public user functions of an iSphere, only functions defined by the public interface are accessible to the outside world via SOAP.

Author:
Owen Jones, Clinton Freeman, Jonathan Mezach

Field Summary
static boolean LOCAL_SCHEMA
          The boolean constant for Local schema.
static boolean UNIVERSAL_SCHEMA
          The boolean constant for Universal schema.
 
Method Summary
 ProcessPublicInterface add(int collectionId, MetadataObject localMetadata, DigitalObject digitalObject)
          Add the metadata and digital object to the local repository.
 TransformInterface[] getCapabilities(int collectionId)
          Returns the list of transforms that can be performed on the objects stored in the specified collection.
 MetadataObject getCollectionMetadata(int collectionId)
          Returns the metadata for the collection with the specified identifier.
 MetadataObject getISphereMetadata()
          Returns the metadata object describing the iSphere.
 Schema getLocalSchema(int collectionId)
          Returns the local schema used for a particular collection.
 ProcessPublicInterface getMetadata(int collectionId, int sri, boolean schema)
          Retrieve the specified metadata record from the collection.
 ProcessPublicInterface getObject(int collectionId, int sri)
          Retrieve the specified ISphereObject from the collection.
 ProcessPublicInterface getTransformedObject(int collectionId, int sri, TransformInterface[] trans)
          Retrieves a transformed object using the object in the specified collection at the specified record index as the source and using the supplied array of transforms as input for the transformation process.
 ProcessPublicInterface numSearchCollectionResults(int collectionId, java.lang.String searchTerm)
          Returns the total number of objects that match the specified search term.
 ProcessPublicInterface remove(int collectionId, int sri)
          Remove the specified record from the collection.
 ProcessPublicInterface searchCollection(int collectionId, java.lang.String searchTerm, int offSet, int num, boolean universal)
          Searches the local collection for objects that match the specified search term and are within the specified bounds and optionally returns results in the universal schema rather than the local schema.
 SearchPublicInterface searchForCollections(java.lang.String searchTerm, int num)
          Search for a specific collection, this function will search the local and authority isphere for collections.
 SearchPublicInterface searchForISpheres(java.lang.String searchTerm, int num)
          Searches for a specific iSphere, this function will search the authority server for iSpheres.
 SearchPublicInterface searchLocalCollection(int collectionId, java.lang.String searchTerm, int num)
          Spawns a search process which will search a local collection for objects that match the specified search parameters.
 ProcessPublicInterface setMetadata(int collectionId, int sri, MetadataObject localMetadata)
          Replace the current records metadata with the new metadata.
 

Field Detail

UNIVERSAL_SCHEMA

static final boolean UNIVERSAL_SCHEMA
The boolean constant for Universal schema.

See Also:
Constant Field Values

LOCAL_SCHEMA

static final boolean LOCAL_SCHEMA
The boolean constant for Local schema.

See Also:
Constant Field Values
Method Detail

add

ProcessPublicInterface add(int collectionId,
                           MetadataObject localMetadata,
                           DigitalObject digitalObject)
                           throws ISphereException
Add the metadata and digital object to the local repository.

Parameters:
collectionId - the collection to add the new digital object too.
localMetadata - The metadata of the digtial object being added to the local repository.
digitalObject - The ISphereObject that is being added to the local repository.
Returns:
A reference to the Process that will execute this action.
Throws:
ISphereException - Thrown when unable to spawn the add process.
See Also:
Add

getCapabilities

TransformInterface[] getCapabilities(int collectionId)
                                     throws ISphereException
Returns the list of transforms that can be performed on the objects stored in the specified collection. When the specified collection does not exist, an ISphereException is thrown.

Parameters:
collectionId - The collection identifier of the collection to get the capabilities for.
Returns:
The TransformInterface of objects stored in the collection.
Throws:
ISphereException - If the specified collection does not exist.

getCollectionMetadata

MetadataObject getCollectionMetadata(int collectionId)
                                     throws ISphereException
Returns the metadata for the collection with the specified identifier.

Parameters:
collectionId - The unique identifier of the collection to get the metadata for.
Returns:
A reference to the Process that will perform this action.
Throws:
ISphereException - If the specified collection does not exist.
See Also:
org.ispheres.server.core.process.GetCollectionMetadata

getISphereMetadata

MetadataObject getISphereMetadata()
                                  throws ISphereException
Returns the metadata object describing the iSphere.

Returns:
The metadata for the iSphere.
Throws:
ISphereException - if unable to fetch iSphere metadata.

getLocalSchema

Schema getLocalSchema(int collectionId)
                      throws ISphereException
Returns the local schema used for a particular collection.

Parameters:
collectionId - The id of the collection.
Returns:
A reference to the Process that will perform this action.
Throws:
ISphereException - If the specified collection does not exist.

getMetadata

ProcessPublicInterface getMetadata(int collectionId,
                                   int sri,
                                   boolean schema)
                                   throws ISphereException
Retrieve the specified metadata record from the collection.

Parameters:
collectionId - The collection containing the record
sri - The simple repository index of the record we want to retrieve.
schema - Return the metadata object in the universal or local schema. Use either UNIVERSAL_SCHEMA or LOCAL_SCHEMA.
Returns:
A reference to the Process that will perform this action.
Throws:
ISphereException - When unable to spawn the process which fetches the metadata.
See Also:
GetMetadata

getObject

ProcessPublicInterface getObject(int collectionId,
                                 int sri)
                                 throws ISphereException
Retrieve the specified ISphereObject from the collection.

Parameters:
collectionId - The collection containing the digital object.
sri - The simple repository index of the object we wish to fetch from the local repository.
Returns:
A reference to the Process that will perform this action.
Throws:
ISphereException - When unable to spawn the process which fetches the digital object.
See Also:
GetObject

getTransformedObject

ProcessPublicInterface getTransformedObject(int collectionId,
                                            int sri,
                                            TransformInterface[] trans)
                                            throws ISphereException
Retrieves a transformed object using the object in the specified collection at the specified record index as the source and using the supplied array of transforms as input for the transformation process.

Parameters:
collectionId - The collection to retrieve a transformed object from.
sri - The simple repository index of the original digital object.
trans - An array of TransformInterfaces that holds the information for each of the transformations to apply.
Returns:
A reference to the Process that will perform this action.
Throws:
ISphereException - When unable to spawn the process which fetches the transformed digital object.
See Also:
GetTransformedObject

remove

ProcessPublicInterface remove(int collectionId,
                              int sri)
                              throws ISphereException
Remove the specified record from the collection.

Parameters:
collectionId - The collection to remove the digital object and metadata from.
sri - The simple repository index of the digital object you wish to remove.
Returns:
A reference to the Process that will perform this action.
Throws:
ISphereException - When unable to spawn the process that will remove the entry.
See Also:
Remove

searchForCollections

SearchPublicInterface searchForCollections(java.lang.String searchTerm,
                                           int num)
                                           throws ISphereException
Search for a specific collection, this function will search the local and authority isphere for collections.

Parameters:
searchTerm - The term to use when searching for collections.
num - The amount of results returned by calls to the getResults function on the handle returned by this function.
Returns:
A reference to the Process that will perform this action.
Throws:
ISphereException - thrown when unable to create the process.
See Also:
org.ispheres.server.core.process.CollectionSearch

searchForISpheres

SearchPublicInterface searchForISpheres(java.lang.String searchTerm,
                                        int num)
                                        throws ISphereException
Searches for a specific iSphere, this function will search the authority server for iSpheres.

Parameters:
searchTerm - The term to use when searching for iSpheres.
num - The number of results to return when calling getResults on the handle that is returned by this function.
Returns:
A reference to the search that will perform this action.
Throws:
ISphereException - thrown when unable to create the process.

searchCollection

ProcessPublicInterface searchCollection(int collectionId,
                                        java.lang.String searchTerm,
                                        int offSet,
                                        int num,
                                        boolean universal)
                                        throws ISphereException
Searches the local collection for objects that match the specified search term and are within the specified bounds and optionally returns results in the universal schema rather than the local schema.

Parameters:
collectionId - The unique identifier of the collection to search for objects.
searchTerm - The term to use when searching for digital objects.
offSet - The simple repository index to start searching from.
num - The number of results to return when calling getResults on the handle that is returned by this function.
universal - Set to true when results should be returned in the universal schema, rather than the local schema.
Returns:
A reference to the Process that will perform this action.
Throws:
ISphereException - Thrown when unable to fetch the collection and search it for metadata records.
See Also:
org.ispheres.server.core.process.LocalObjectSearch

numSearchCollectionResults

ProcessPublicInterface numSearchCollectionResults(int collectionId,
                                                  java.lang.String searchTerm)
                                                  throws ISphereException
Returns the total number of objects that match the specified search term.

Parameters:
collectionId - The unique identifier of the collection to search for objects.
searchTerm - The term to use when searching for digital objects.
Returns:
A reference to the Process that will perform this action.
Throws:
ISphereException - Thrown when unable to fetch the collection and count the number of metadatarecords that match the search term.
See Also:
NumSearchCollectionResults

searchLocalCollection

SearchPublicInterface searchLocalCollection(int collectionId,
                                            java.lang.String searchTerm,
                                            int num)
                                            throws ISphereException
Spawns a search process which will search a local collection for objects that match the specified search parameters.

Parameters:
collectionId - The unique id of the local collection to search.
searchTerm - The term to use when searching for digital objects.
num - The number of results to return per page.
Returns:
A reference to the search that will perform the action.
Throws:
ISphereException - thrown when unable to create the searchProcess.

setMetadata

ProcessPublicInterface setMetadata(int collectionId,
                                   int sri,
                                   MetadataObject localMetadata)
                                   throws ISphereException
Replace the current records metadata with the new metadata.

Parameters:
collectionId - The collection containing the record, you wish to update the metadata object of.
sri - The simple repository index of the metadata record to update.
localMetadata - The metadata to replace the old metadata with. (in the local schema).
Returns:
A reference to the Process that will perform this action.
Throws:
ISphereException - Thrown on client side implementations of this interface when exceptions occur.
See Also:
SetMetadata


Copyright © 2004-2005 The Archaeological Computing Laboratory, University of Sydney. All Rights Reserved.