public class Config extends Object
Constructor and Description |
---|
Config() |
Modifier and Type | Method and Description |
---|---|
String |
getCatalog() |
String |
getIdentity() |
String |
getIDENTITY()
获取主键自增回写SQL
|
List<Class> |
getMappers() |
String |
getPrefix()
获取表前缀,带catalog或schema
|
Class<? extends EntityResolve> |
getResolveClass() |
String |
getSchema() |
String |
getSeqFormat()
获取序列格式化模板
|
Style |
getStyle() |
String |
getWrapKeyword() |
boolean |
isBefore() |
boolean |
isBEFORE()
获取SelectKey的Order
|
boolean |
isCheckExampleEntityClass() |
boolean |
isEnableMethodAnnotation() |
boolean |
isEnumAsSimpleType() |
boolean |
isNotEmpty() |
boolean |
isSafeDelete() |
boolean |
isSafeUpdate() |
boolean |
isUseJavaType() |
boolean |
isUseSimpleType() |
void |
setBefore(boolean before) |
void |
setBEFORE(boolean BEFORE) |
void |
setCatalog(String catalog)
设置全局的catalog,默认为空,如果设置了值,操作表时的sql会是catalog.tablename
|
void |
setCheckExampleEntityClass(boolean checkExampleEntityClass) |
void |
setEnableMethodAnnotation(boolean enableMethodAnnotation) |
void |
setEnumAsSimpleType(boolean enumAsSimpleType) |
void |
setIdentity(String identity) |
void |
setIDENTITY(String IDENTITY)
主键自增回写方法,默认值MYSQL,详细说明请看文档
|
void |
setMappers(List<Class> mappers) |
void |
setNotEmpty(boolean notEmpty) |
void |
setOrder(String order)
主键自增回写方法执行顺序,默认AFTER,可选值为(BEFORE|AFTER)
|
void |
setProperties(Properties properties)
配置属性
|
void |
setResolveClass(Class<? extends EntityResolve> resolveClass) |
void |
setSafeDelete(boolean safeDelete) |
void |
setSafeUpdate(boolean safeUpdate) |
void |
setSchema(String schema)
设置全局的schema,默认为空,如果设置了值,操作表时的sql会是schema.tablename
如果同时设置了catalog,优先使用catalog.tablename |
void |
setSeqFormat(String seqFormat)
序列的获取规则,使用{num}格式化参数,默认值为{0}.nextval,针对Oracle
可选参数一共3个,对应0,1,2,3分别为SequenceName,ColumnName, PropertyName,TableName |
void |
setStyle(Style style) |
void |
setUseJavaType(boolean useJavaType) |
void |
setUseSimpleType(boolean useSimpleType) |
void |
setWrapKeyword(String wrapKeyword) |
public static final String PREFIX
public String getCatalog()
public void setCatalog(String catalog)
catalog
- public String getIDENTITY()
public void setIDENTITY(String IDENTITY)
IDENTITY
- public String getPrefix()
public String getSchema()
public void setSchema(String schema)
schema
- public String getSeqFormat()
public void setSeqFormat(String seqFormat)
seqFormat
- public Style getStyle()
public void setStyle(Style style)
public String getWrapKeyword()
public void setWrapKeyword(String wrapKeyword)
public boolean isBEFORE()
public void setBEFORE(boolean BEFORE)
public boolean isCheckExampleEntityClass()
public void setCheckExampleEntityClass(boolean checkExampleEntityClass)
public boolean isEnableMethodAnnotation()
public void setEnableMethodAnnotation(boolean enableMethodAnnotation)
public boolean isEnumAsSimpleType()
public void setEnumAsSimpleType(boolean enumAsSimpleType)
public boolean isNotEmpty()
public void setNotEmpty(boolean notEmpty)
public boolean isUseSimpleType()
public void setUseSimpleType(boolean useSimpleType)
public void setOrder(String order)
order
- public String getIdentity()
public void setIdentity(String identity)
public boolean isBefore()
public void setBefore(boolean before)
public Class<? extends EntityResolve> getResolveClass()
public void setResolveClass(Class<? extends EntityResolve> resolveClass)
public boolean isSafeDelete()
public void setSafeDelete(boolean safeDelete)
public boolean isSafeUpdate()
public void setSafeUpdate(boolean safeUpdate)
public boolean isUseJavaType()
public void setUseJavaType(boolean useJavaType)
public void setProperties(Properties properties)
properties
- Copyright © 2018. All rights reserved.