com.mysema.query.sql
Class SQLTemplates

java.lang.Object
  extended by com.mysema.query.types.Templates
      extended by com.mysema.query.sql.SQLTemplates
Direct Known Subclasses:
DerbyTemplates, H2Templates, HSQLDBTemplates, MySQLTemplates, OracleTemplates, PostgresTemplates, SQLServerTemplates

public class SQLTemplates
extends Templates

SQLTemplates extended Templates to provided SQL specific extensions and acts as database specific Dialect for Querydsl SQL

Version:
$Id$
Author:
tiwe

Field Summary
static Operator<Object> CAST
           
static SQLTemplates DEFAULT
           
 
Constructor Summary
protected SQLTemplates()
           
protected SQLTemplates(String quoteStr)
           
 
Method Summary
 void addClass2TypeMappings(String type, Class<?>... classes)
           
 String getAsc()
           
 String getColumnAlias()
           
 String getCount()
           
 String getCountStar()
           
 String getDeleteFrom()
           
 String getDesc()
           
 String getDistinctCountEnd()
           
 String getDistinctCountStart()
           
 String getDummyTable()
           
 String getFrom()
           
 String getFullJoin()
           
 String getGroupBy()
           
 String getHaving()
           
 String getInnerJoin()
           
 String getInsertInto()
           
 String getJoin()
           
 String getJoinSymbol(JoinType joinType)
           
 String getLeftJoin()
           
 String getLimitTemplate()
           
 String getOffsetTemplate()
           
 String getOn()
           
 String getOrderBy()
           
 String getSelect()
           
 String getSelectDistinct()
           
 String getTableAlias()
           
 String getTypeForClass(Class<?> cl)
           
 String getUnion()
           
 String getUpdate()
           
 String getValues()
           
 String getWhere()
           
 boolean isSupportsAlias()
           
 SQLTemplates newLineToSingleSpace()
           
 String quoteColumnName(String column)
           
 String quoteTableName(String table)
           
 void serialize(QueryMetadata metadata, boolean forCountRow, SerializationContext context)
           
protected  void serializeModifiers(QueryMetadata metadata, SerializationContext context)
           
protected  void setAsc(String asc)
           
protected  void setColumnAlias(String columnAlias)
           
protected  void setCount(String count)
           
protected  void setCountStar(String countStar)
           
protected  void setDeleteFrom(String deleteFrom)
           
protected  void setDesc(String desc)
           
protected  void setDistinctCountEnd(String distinctCountEnd)
           
protected  void setDistinctCountStart(String distinctCountStart)
           
protected  void setDummyTable(String dummyTable)
           
protected  void setFrom(String from)
           
protected  void setFullJoin(String fullJoin)
           
protected  void setGroupBy(String groupBy)
           
protected  void setHaving(String having)
           
protected  void setInnerJoin(String innerJoin)
           
protected  void setInsertInto(String insertInto)
           
protected  void setJoin(String join)
           
protected  void setLeftJoin(String leftJoin)
           
protected  void setOffsetTemplate(String offsetTemplate)
           
protected  void setOn(String on)
           
protected  void setOrderBy(String orderBy)
           
protected  void setSelect(String select)
           
protected  void setSelectDistinct(String selectDistinct)
           
protected  void setTableAlias(String tableAlias)
           
protected  void setUnion(String union)
           
protected  void setUpdate(String update)
           
protected  void setValues(String values)
           
protected  void setWhere(String where)
           
 
Methods inherited from class com.mysema.query.types.Templates
add, add, getPrecedence, getTemplate
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CAST

public static final Operator<Object> CAST

DEFAULT

public static final SQLTemplates DEFAULT
Constructor Detail

SQLTemplates

protected SQLTemplates()

SQLTemplates

protected SQLTemplates(@Nullable
                       String quoteStr)
Method Detail

addClass2TypeMappings

public void addClass2TypeMappings(String type,
                                  Class<?>... classes)

getAsc

public String getAsc()

getTypeForClass

public String getTypeForClass(Class<?> cl)

getColumnAlias

public String getColumnAlias()

getCount

public String getCount()

getCountStar

public String getCountStar()

getDeleteFrom

public String getDeleteFrom()

getDesc

public String getDesc()

getDistinctCountEnd

public String getDistinctCountEnd()

getDistinctCountStart

public String getDistinctCountStart()

getDummyTable

public String getDummyTable()

getFrom

public String getFrom()

getFullJoin

public String getFullJoin()

getGroupBy

public String getGroupBy()

getHaving

public String getHaving()

getInnerJoin

public String getInnerJoin()

getInsertInto

public String getInsertInto()

getJoin

public String getJoin()

getJoinSymbol

public String getJoinSymbol(JoinType joinType)

getLeftJoin

public String getLeftJoin()

getLimitTemplate

public String getLimitTemplate()

getOffsetTemplate

public String getOffsetTemplate()

getOn

public String getOn()

getOrderBy

public String getOrderBy()

getSelect

public String getSelect()

getSelectDistinct

public String getSelectDistinct()

getTableAlias

public String getTableAlias()

getUnion

public String getUnion()

getUpdate

public String getUpdate()

getValues

public String getValues()

getWhere

public String getWhere()

isSupportsAlias

public boolean isSupportsAlias()

newLineToSingleSpace

public SQLTemplates newLineToSingleSpace()

quoteColumnName

public final String quoteColumnName(String column)

quoteTableName

public final String quoteTableName(String table)

serialize

public void serialize(QueryMetadata metadata,
                      boolean forCountRow,
                      SerializationContext context)

serializeModifiers

protected void serializeModifiers(QueryMetadata metadata,
                                  SerializationContext context)

setAsc

protected void setAsc(String asc)

setColumnAlias

protected void setColumnAlias(String columnAlias)

setCount

protected void setCount(String count)

setCountStar

protected void setCountStar(String countStar)

setDeleteFrom

protected void setDeleteFrom(String deleteFrom)

setDesc

protected void setDesc(String desc)

setDistinctCountEnd

protected void setDistinctCountEnd(String distinctCountEnd)

setDistinctCountStart

protected void setDistinctCountStart(String distinctCountStart)

setDummyTable

protected void setDummyTable(String dummyTable)

setFrom

protected void setFrom(String from)

setFullJoin

protected void setFullJoin(String fullJoin)

setGroupBy

protected void setGroupBy(String groupBy)

setHaving

protected void setHaving(String having)

setInnerJoin

protected void setInnerJoin(String innerJoin)

setInsertInto

protected void setInsertInto(String insertInto)

setJoin

protected void setJoin(String join)

setLeftJoin

protected void setLeftJoin(String leftJoin)

setOffsetTemplate

protected void setOffsetTemplate(String offsetTemplate)

setOn

protected void setOn(String on)

setOrderBy

protected void setOrderBy(String orderBy)

setSelect

protected void setSelect(String select)

setSelectDistinct

protected void setSelectDistinct(String selectDistinct)

setTableAlias

protected void setTableAlias(String tableAlias)

setUnion

protected void setUnion(String union)

setUpdate

protected void setUpdate(String update)

setValues

protected void setValues(String values)

setWhere

protected void setWhere(String where)


Copyright © 2007-2010 Mysema Ltd. All Rights Reserved.