public interface QueryManager {
// Public Instance Methods
public abstract javax.xml.registry.infomodel.RegistryObject
getRegistryObject(String id)
throws JAXRException; // L1
public abstract javax.xml.registry.infomodel.RegistryObject getRegistryObject(String id,
String objectType)
throws JAXRException; // L0
public abstract BulkResponse getRegistryObjects( ) throws JAXRException; // L0
public abstract BulkResponse getRegistryObjects(String objectType)
throws JAXRException; // L0
public abstract BulkResponse getRegistryObjects(Collection objectKeys)
throws JAXRException; // L1
public abstract BulkResponse getRegistryObjects(Collection objectKeys,
String objectTypes)
throws JAXRException; // L0
public abstract RegistryService getRegistryService( )
throws JAXRException; // L0
}
QueryManager provides methods that allow objects
in the registry to be retrieved based on type and/or identifier. The
only way to obtain a QueryManager object is by
calling the getBusinessQueryManager( ) or the
getDeclarativeQueryManager( ) method on
RegistryService, which both return one of the two
derived interfaces of QueryManager defined by the
API. The QueryManager getRegistryService(
) method returns the RegistryService
object from which it was obtained.
The zero-argument getRegistryObjects( ) returns a
BulkResponse containing all of the objects in the
registry belonging to the calling user, while
getRegistryObject(String
objectType) returns the subset of those objects
that are of a given type (such as
LifeCycleManager.ORGANIZATION). Both of these
methods throw a JAXRException if the connection
does not have valid credentials associated with it, allowing the
calling user to be identified. The
getRegistryObjects(Collection keys) method returns
all of the objects in the registry whose
javax.xml.registry.infomodel.Key values appear in
the collection passed as its argument, while the
getRegistryObject(String id) method returns the
single object whose identifier (i.e., the result of calling the
getId( ) method on the object's
Key) is supplied. Neither of these methods uses
the caller's identity as an implicit filter.
However, they can be used only with a level 1 registry provider. To
get similar functionality from a level 0 provider, you need to
specify the type of registry object to be retrieved, in the form of a
constant defined by the LifeCycleManager
interface, as well as the keys or registry object identifier.