Class COM.odi.coll.Query

java.lang.Object
   |
   +----COM.odi.jcpp.CPlusPlus
           |
           +----COM.odi.coll.Query

public class Query
extends CPlusPlus
A Query object represents a query that can have zero or more free variables. Every Query object is a transient peer object.

A Query object is a transient Java peer object. When you are finished with a Query object, call ObjectStore.destroy() on it to free the C++ transient storage. The application accesses the Query object through a Java peer object and the associated C++ object is not automatically garbage collected. You must explicitly delete it.


Constructor Index

 o Query(ClassInfo)
Create a hollow Query object.

Method Index

 o create(String, String, Database)
Create a Query object usable in a BoundQuery that will be queried with Collection.query.
 o createExists(String, String, Database)
Create a Query object usable in a BoundQuery that will be queried with Collection.exists.
 o createPick(String, String, Database)
Create a Query object usable in a BoundQuery that will be queried with Collection.queryPick.

Constructors

 o Query
  protected Query(ClassInfo c)
Create a hollow Query object.

Methods

 o create
  public static Query create(String elementType,
                             String query,
                             Database database)
Create a Query object usable in a BoundQuery that will be queried with Collection.query.

Parameters:
elementType - A fully-qualified Java class name. Every element of the collection to which this query will be applied must be an instance of (in the sense of instanceof) the named class.

query - The query string.

database - A database specification. The schema of the specified database must describe the class specified for elementType. You must not specify the transient database. Note that the Query object itself is transient; it is not created in this database.

Returns:
The new Query object.
 o createPick
  public static Query createPick(String elementType,
                                 String query,
                                 Database database)
Create a Query object usable in a BoundQuery that will be queried with Collection.queryPick.

Parameters:
elementType - A fully-qualified Java class name. Every element of the collection to which this query will be applied must be an instance of (in the sense of instanceof) the named class. If every element in the collection is not an instance of the named class, you can expect random errors and crashes.

query - The query string.

database - A database specification. The schema of the specified database must describe the class specified for elementType. You must not specify the transient database. Note that the Query object itself is transient; it is not created in this database.

Returns:
The new Query object.
 o createExists
  public static Query createExists(String elementType,
                                   String query,
                                   Database database)
Create a Query object usable in a BoundQuery that will be queried with Collection.exists.

Parameters:
elementType - A fully-qualified Java class name. Every element of the collection to which this query will be applied must be an instance of (in the sense of instanceof) the named class.

query - The query string.

database - A database specification. The schema of the specified database must describe the class specified for elementType. You must not specify the transient database. Note that the Query object itself is transient; it is not created in this database.

Returns:
The new Query object.

Copyright © 1996, 1997, 1998 Object Design, Inc. All rights reserved.