Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## net.java.ao
Class Query

    java.lang.Object
      net.java.ao.Query

All Implemented Interfaces:
  Serializable

    public class Query

extends Object
implements Serializable

Author:
  Daniel Spiewak
See Also:
  Serialized Form

Nested Class Summary
`static class` | `Query.QueryType`

Constructor Summary
`Query(Query.QueryType type, String fields)`

Method Summary
`Query` | `distinct()`
`Query` | `from(Class<? extends RawEntity<?>> tableType)`
`Query` | `from(String table)`
`String[]` | `getCanonicalFields(Class<? extends RawEntity<?>> type, FieldNameConverter converter)`
`String[]` | `getFields()`
`String` | `getGroupClause()`
`Map<Class<? extends RawEntity<?>>,String>` | `getJoins()`
`int` | `getLimit()`
`int` | `getOffset()`
`String` | `getOrderClause()`
`String` | `getTable()`
`Class<? extends RawEntity<?>>` | `getTableType()`
`Query.QueryType` | `getType()`
`String` | `getWhereClause()`
`Object[]` | `getWhereParams()`
`Query` | `group(String clause)`
`boolean` | `isDistinct()`
`Query` | `join(Class<? extends RawEntity<?>> join)`
`Query` | `join(Class<? extends RawEntity<?>> join, String on)`
`Query` | `limit(int limit)`
`Query` | `offset(int offset)`
`Query` | `order(String clause)`
`static Query` | `select()`
`static Query` | `select(String fields)`
`void` | `setDistinct(boolean distinct)`
`void` | `setGroupClause(String groupClause)`
`void` | `setJoins(Map<Class<? extends RawEntity<?>>,String> joins)`
`void` | `setLimit(int limit)`
`void` | `setOffset(int offset)`
`void` | `setOrderClause(String orderClause)`
`protected void` | `setParameters(EntityManager manager, PreparedStatement stmt)`
`void` | `setTable(String table)`
`void` | `setTableType(Class<? extends RawEntity<?>> tableType)`
`void` | `setWhereClause(String whereClause)`
`void` | `setWhereParams(Object[] whereParams)`
`protected
`<K> String`
` | `toSQL(Class<? extends RawEntity<K>> tableType, DatabaseProvider provider, TableNameConverter converter, FieldNameConverter fieldConverter, boolean count)`
`Query` | `where(String clause, Object... params)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### Query

    public Query(Query.QueryType type,
                 String fields)

Method Detail

### getFields

    public String[] getFields()

### distinct

    public Query distinct()

### from

    public Query from(Class<? extends RawEntity<?>> tableType)

### from

    public Query from(String table)

### where

    public Query where(String clause,
                       Object... params)

### order

    public Query order(String clause)

### group

    public Query group(String clause)

### limit

    public Query limit(int limit)

### offset

    public Query offset(int offset)

### join

    public Query join(Class<? extends RawEntity<?>> join,
                      String on)

### join

    public Query join(Class<? extends RawEntity<?>> join)

### isDistinct

    public boolean isDistinct()

### setDistinct

    public void setDistinct(boolean distinct)

### getTableType

    public Class<? extends RawEntity<?>> getTableType()

### setTableType

    public void setTableType(Class<? extends RawEntity<?>> tableType)

### getTable

    public String getTable()

### setTable

    public void setTable(String table)

### getWhereClause

    public String getWhereClause()

### setWhereClause

    public void setWhereClause(String whereClause)

### getWhereParams

    public Object[] getWhereParams()

### setWhereParams

    public void setWhereParams(Object[] whereParams)

### getOrderClause

    public String getOrderClause()

### setOrderClause

    public void setOrderClause(String orderClause)

### getGroupClause

    public String getGroupClause()

### setGroupClause

    public void setGroupClause(String groupClause)

### getLimit

    public int getLimit()

### setLimit

    public void setLimit(int limit)

### getOffset

    public int getOffset()

### setOffset

    public void setOffset(int offset)

### getJoins

    public Map<Class<? extends RawEntity<?>>,String> getJoins()

### setJoins

    public void setJoins(Map<Class<? extends RawEntity<?>>,String> joins)

### getType

    public Query.QueryType getType()

### getCanonicalFields

    public String[] getCanonicalFields(Class<? extends RawEntity<?>> type,
                                       FieldNameConverter converter)

### toSQL

    protected <K> String toSQL(Class<? extends RawEntity<K>> tableType,
                               DatabaseProvider provider,
                               TableNameConverter converter,
                               FieldNameConverter fieldConverter,
                               boolean count)

### setParameters

    protected void setParameters(EntityManager manager,
                                 PreparedStatement stmt)
                          throws SQLException

  Throws:
    `SQLException`

### select

    public static Query select()

### select

    public static Query select(String fields)

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2007-2011. All Rights Reserved.