Platform SDK Java 8.5 API Reference

com.genesyslab.platform.applicationblocks.com
Class CfgQuery<TT extends ICfgObject>

java.lang.Object
  extended by com.genesyslab.platform.applicationblocks.com.CfgQuery<TT>
All Implemented Interfaces:
ICfgQuery<TT>
Direct Known Subclasses:
CfgFilterBasedQuery, CfgXPathBasedQuery

public class CfgQuery<TT extends ICfgObject>
extends java.lang.Object
implements ICfgQuery<TT>

The base class for all types of Configuration Server queries.


Constructor Summary
CfgQuery()
          Creates a new instance of the class.
CfgQuery(IConfService confService)
          Deprecated.  
 
Method Summary
<T extends ICfgObject>
AsyncRequestResult<T>
beginExecute(java.lang.Class<T> clazz, Action<AsyncRequestResult<T>> callback, java.lang.Object state)
          Deprecated. Use IConfService.beginRetrieveMultipleObjects(java.lang.Class, com.genesyslab.platform.applicationblocks.com.ICfgQuery, com.genesyslab.platform.applicationblocks.commons.Action>) directly.
<T extends ICfgObject>
java.util.Collection<T>
endExecute(AsyncRequestResult<T> asyncResult)
          Deprecated. Use IConfService.endRetrieveMultipleObjects(com.genesyslab.platform.applicationblocks.com.AsyncRequestResult) directly.
 java.util.Collection<? extends ICfgObject> execute()
          Executes the query and returns a list of objects read from the configuration server.
<T extends ICfgObject>
java.util.Collection<T>
execute(java.lang.Class<T> clazz)
          Deprecated. Use IConfService.retrieveMultipleObjects(java.lang.Class, com.genesyslab.platform.applicationblocks.com.ICfgQuery) directly.
 ICfgObject executeSingleResult()
          Executes a query the result of which is a single object of the specified type.
<T extends ICfgObject>
T
executeSingleResult(java.lang.Class<T> clazz)
          Deprecated. Use IConfService.retrieveObject(com.genesyslab.platform.applicationblocks.com.ICfgQuery) directly.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CfgQuery

public CfgQuery()
Creates a new instance of the class.


CfgQuery

@Deprecated
public CfgQuery(IConfService confService)
Deprecated. 

Creates a new instance of the class.

Parameters:
confService - reference to IConfService to be used for query execution.
Method Detail

execute

@Deprecated
public <T extends ICfgObject> java.util.Collection<T> execute(java.lang.Class<T> clazz)
                                                   throws ConfigException,
                                                          java.lang.InterruptedException
Deprecated. Use IConfService.retrieveMultipleObjects(java.lang.Class, com.genesyslab.platform.applicationblocks.com.ICfgQuery) directly.

Executes the query and returns a list of objects read from the configuration server. It may return null if no objects read.

Specified by:
execute in interface ICfgQuery<TT extends ICfgObject>
Type Parameters:
T - The type of configuration object returned
Parameters:
clazz - class used for generic matching
Returns:
A collection of configuration objects or null
Throws:
ConfigException
java.lang.InterruptedException

execute

public java.util.Collection<? extends ICfgObject> execute()
                                                   throws ConfigException,
                                                          java.lang.InterruptedException
Executes the query and returns a list of objects read from the configuration server. It may return null if no objects read.

Returns:
A collection of configuration objects or null
Throws:
ConfigException
java.lang.InterruptedException

beginExecute

@Deprecated
public <T extends ICfgObject> AsyncRequestResult<T> beginExecute(java.lang.Class<T> clazz,
                                                                            Action<AsyncRequestResult<T>> callback,
                                                                            java.lang.Object state)
                                                      throws ConfigException
Deprecated. Use IConfService.beginRetrieveMultipleObjects(java.lang.Class, com.genesyslab.platform.applicationblocks.com.ICfgQuery, com.genesyslab.platform.applicationblocks.commons.Action>) directly.

Begins the asynchronous execution of the current query.

Specified by:
beginExecute in interface ICfgQuery<TT extends ICfgObject>
Type Parameters:
T - the type of object returned
Parameters:
callback - The method to be called when query results are available
state - a user-defined object that qualifies or contains information about an asynchronous operation
clazz - class used for generic matching
Returns:
AsyncRequestResult describing the current operation
Throws:
ConfigException

endExecute

@Deprecated
public <T extends ICfgObject> java.util.Collection<T> endExecute(AsyncRequestResult<T> asyncResult)
                                                      throws ConfigException,
                                                             java.lang.InterruptedException
Deprecated. Use IConfService.endRetrieveMultipleObjects(com.genesyslab.platform.applicationblocks.com.AsyncRequestResult) directly.

Called to retrieve the result of asynchronous BeginExecute operation. Should be called on execution of AsyncCallback passed to BeginExecute. Will block calling thread until results are received if called before operation is completed.

Specified by:
endExecute in interface ICfgQuery<TT extends ICfgObject>
Type Parameters:
T - the type of object returned
Parameters:
asyncResult - The AsyncRequestResult object used to track the current request
Returns:
A list of retrieved objects or null
Throws:
ConfigException
java.lang.InterruptedException

executeSingleResult

@Deprecated
public <T extends ICfgObject> T executeSingleResult(java.lang.Class<T> clazz)
                                         throws ConfigException
Deprecated. Use IConfService.retrieveObject(com.genesyslab.platform.applicationblocks.com.ICfgQuery) directly.

Executes a query the result of which is a single object of the specified type. Exception will be thrown if multiple objects are returned by the configuration server.

Specified by:
executeSingleResult in interface ICfgQuery<TT extends ICfgObject>
Type Parameters:
T - the type of object returned
Parameters:
clazz - class used for generic matching
Returns:
a configuration object or null
Throws:
ConfigException

executeSingleResult

public ICfgObject executeSingleResult()
                               throws ConfigException
Executes a query the result of which is a single object of the specified type. Exception will be thrown if multiple objects are returned by the configuration server.

Returns:
a configuration object or null
Throws:
ConfigException

Platform SDK Java 8.5 API Reference

Send comments on this topicTechpubs.webadmin@genesys.com.
Document version: 8.5.302.00
Copyright © 2006–2017 Genesys Telecommunications Laboratories, Inc. All rights reserved.