Microsoft SDK for Java

queryService

This method of the IServiceObjectProvider Interface requests a service from an object. The object that provides the service can be the current object or a different object.

To determine whether the object supports the requested service, a typical implementation would check to see if any of the following items are true:

If the object does not support the requested service, it delegates the method call to an upper level object (such as a containing frame). Finally, if no object in the chain supports the requested service, a ServiceNotFoundException is thrown.

Syntax

public Object queryService(Object id) throws ServiceNotFoundException;

Return Value

Returns the service object, if it is available.

Parameters

id The identifier of the requested service.

Exceptions

ServiceNotFoundException if no object supports the requested service.

© 1999 Microsoft Corporation. All rights reserved. Terms of use.