com.j_spaces.core.client.view
Class View<T>

java.lang.Object
  extended by com.j_spaces.core.client.SQLQuery<T>
      extended by com.j_spaces.core.client.ContinousQuery<T>
          extended by com.j_spaces.core.client.view.View<T>
All Implemented Interfaces:
Query<T>, Serializable, Entry

public class View<T>
extends ContinousQuery<T>

Extends the ContinousQuery interface to allow creation of space view.
Code Example:


        Properties prop = new Properties();
        View[] views = new View[]{ new View( MyClass, "myField>10")};
        prop.put( SpaceURL.VIEWS, views); 
        SpaceFinder.find( spaceUrl, prop);
 

Since:
5.2
See Also:
SpaceFinder, Serialized Form

Field Summary
 
Fields inherited from class com.j_spaces.core.client.SQLQuery
CALL, COUNT_PREFIX, DELETE_PREFIX, GROUP, ORDER, SELECT_PREFIX
 
Constructor Summary
View()
          Empty constructor.
View(Class<T> clazz, String sqlQuery)
          Constructor for setting the className of the entry to query with the SQL query expression.
View(Entry entry, String sqlQuery)
          Constructor for setting the entry as a template to query with the sql query expression.
View(String className, String sqlQuery)
          Constructor for setting the className of the entry to query with the SQL query expression.
View(T object, String sqlQuery)
          Constructor for setting the object as a template to query with the SQL query expression.
 
Method Summary
 
Methods inherited from class com.j_spaces.core.client.SQLQuery
getClassName, getEntry, getFromQuery, getObject, getParameters, getQuery, getSelectAllQuery, getSelectCountQuery, hasParameters, hasWhereClause, isExternalEntry, isNullExpression, isStoredProcedure, setClassName, setExternalEntry, setParameter, setParameters, setQuery, setTemplate, setTemplate, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

View

public View()
Empty constructor.


View

public View(String className,
            String sqlQuery)
Constructor for setting the className of the entry to query with the SQL query expression.

Parameters:
className - - Entry class name to be queried.
sqlQuery - - The SQL Query expression (contents of the WHERE part).

View

public View(Class<T> clazz,
            String sqlQuery)
Constructor for setting the className of the entry to query with the SQL query expression.

Parameters:
clazz - - Entry class to be queried.
sqlQuery - - The SQL Query expression (contents of the WHERE part).

View

public View(T object,
            String sqlQuery)
Constructor for setting the object as a template to query with the SQL query expression. The constructor behaves in a similar manner to the former, but incase of an ExternalEntry its class name is extracted implicitly.

Parameters:
object - - The POJO to query by
sqlQuery - - The SQL Query expression (contents of the WHERE part).
See Also:
SQLQuery.SQLQuery(String className, String sqlQuery)

View

public View(Entry entry,
            String sqlQuery)
Constructor for setting the entry as a template to query with the sql query expression. The constructor behaves in a similar manner to the former, but incase of an ExternalEntry its class name is extracted implicitly.

Parameters:
entry - - The entry to query by
sqlQuery - - The SQL Query expression (contents of the WHERE part).
See Also:
SQLQuery.SQLQuery(String className, String sqlQuery)