public class Settings
extends java.lang.Object
implements java.io.Serializable, java.lang.Cloneable
Modifier and Type | Field and Description |
---|---|
protected java.lang.Boolean |
attachRecords |
protected BackslashEscaping |
backslashEscaping |
protected java.lang.Boolean |
debugInfoOnStackTrace |
protected java.lang.String |
delimiter |
protected java.lang.Boolean |
executeLogging |
protected java.lang.Boolean |
executeWithOptimisticLocking |
protected java.lang.Boolean |
executeWithOptimisticLockingExcludeUnversioned |
protected java.lang.Integer |
fetchSize |
protected java.lang.Boolean |
fetchWarnings |
protected java.lang.Boolean |
inListPadding |
protected java.lang.Boolean |
mapJPAAnnotations |
protected java.lang.Integer |
maxRows |
protected ParamCastMode |
paramCastMode |
protected ParamType |
paramType |
protected java.lang.Integer |
queryTimeout |
protected java.lang.Boolean |
reflectionCaching |
protected java.lang.Boolean |
renderCatalog |
protected java.lang.Boolean |
renderFormatted |
protected RenderFormatting |
renderFormatting |
protected RenderKeywordStyle |
renderKeywordStyle |
protected RenderMapping |
renderMapping |
protected RenderNameStyle |
renderNameStyle |
protected java.lang.Boolean |
renderOrderByRownumberForEmulatedPagination |
protected java.lang.Boolean |
renderScalarSubqueriesForStoredFunctions |
protected java.lang.Boolean |
renderSchema |
protected java.lang.Boolean |
returnAllOnUpdatableRecord |
protected java.lang.Boolean |
returnRecordToPojo |
protected StatementType |
statementType |
protected ThrowExceptions |
throwExceptions |
protected java.lang.Boolean |
updatablePrimaryKeys |
Constructor and Description |
---|
Settings() |
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
clone() |
BackslashEscaping |
getBackslashEscaping()
Whether string literals should be escaped with backslash.
|
java.lang.String |
getDelimiter()
[#5826] The delimiter character to be used to delimit statements in batches.
|
java.lang.Integer |
getFetchSize()
The default JDBC fetchSize property that should be applied to all
jOOQ queries, for which no specific fetchSize value was specified.
|
java.lang.Integer |
getMaxRows()
The default JDBC maxRows property that should be applied to all
jOOQ queries, for which no specific maxRows value was specified.
|
ParamCastMode |
getParamCastMode()
Whether rendered bind values should be cast to their respective type.
|
ParamType |
getParamType()
Specify how bind variables are to be rendered.
|
java.lang.Integer |
getQueryTimeout()
The default JDBC queryTimeout property that should be applied to all
jOOQ queries, for which no specific queryTimeout was specified.
|
RenderFormatting |
getRenderFormatting()
All sorts of formatting flags / settings.
|
RenderKeywordStyle |
getRenderKeywordStyle()
Whether SQL keywords should be rendered with upper or lower case.
|
RenderMapping |
getRenderMapping()
Configure render mapping for runtime schema / table rewriting in
generated SQL.
|
RenderNameStyle |
getRenderNameStyle()
Whether rendered schema, table, column names, etc should be quoted
in rendered SQL, or transformed in any other way.
|
StatementType |
getStatementType()
The type of statement that is to be executed.
|
ThrowExceptions |
getThrowExceptions()
A strategy defining how exceptions from the database / JDBC driver should be propagated
|
java.lang.Boolean |
isAttachRecords()
Whether fetched records should be attached to the fetching configuration.
|
java.lang.Boolean |
isDebugInfoOnStackTrace()
[#5570] Whether exception stack traces should be enhanced with additional debug information.
|
java.lang.Boolean |
isExecuteLogging()
When set to true, this will add jOOQ's default logging ExecuteListeners.
|
java.lang.Boolean |
isExecuteWithOptimisticLocking()
Whether store() and delete() methods should be executed with optimistic locking.
|
java.lang.Boolean |
isExecuteWithOptimisticLockingExcludeUnversioned()
Whether store() and delete() methods should be executed with optimistic locking also on "unversioned" tables,
i.e. on tables that do not have a version and/or timestamp column.
|
java.lang.Boolean |
isFetchWarnings()
Whether warnings should be fetched after each query execution.
|
java.lang.Boolean |
isInListPadding()
[#5600] Whether IN lists in IN predicates should be padded to powers of 2.
|
java.lang.Boolean |
isMapJPAAnnotations()
Whether JPA annotations should be considered by the DefaultRecordMapper.
|
java.lang.Boolean |
isReflectionCaching()
Whether reflection information should be cached in the configuration.
|
java.lang.Boolean |
isRenderCatalog()
Whether any catalog name should be rendered at all.
|
java.lang.Boolean |
isRenderFormatted()
Whether rendered SQL should be pretty-printed.
|
java.lang.Boolean |
isRenderOrderByRownumberForEmulatedPagination()
Whether an additional
ORDER BY rn clause should be rendered on emulated paginated queries. |
java.lang.Boolean |
isRenderScalarSubqueriesForStoredFunctions()
Whether stored function calls should be wrapped in scalar subqueries.
|
java.lang.Boolean |
isRenderSchema()
Whether any schema name should be rendered at all.
|
java.lang.Boolean |
isReturnAllOnUpdatableRecord()
Whether calls to store(), insert() and update() should return all columns, not just identity columns.
|
java.lang.Boolean |
isReturnRecordToPojo()
Whether calls to store(), insert(), update(), and delete() that are called on an UpdatableRecord
that is created from a POJO (e.g. in a DAO) should return all Record values to the POJO, including
IDENTITY values, and if
|
java.lang.Boolean |
isUpdatablePrimaryKeys()
Whether primary key values are deemed to be "updatable" in jOOQ.
|
void |
setAttachRecords(java.lang.Boolean value)
Sets the value of the attachRecords property.
|
void |
setBackslashEscaping(BackslashEscaping value)
Sets the value of the backslashEscaping property.
|
void |
setDebugInfoOnStackTrace(java.lang.Boolean value)
Sets the value of the debugInfoOnStackTrace property.
|
void |
setDelimiter(java.lang.String value)
Sets the value of the delimiter property.
|
void |
setExecuteLogging(java.lang.Boolean value)
Sets the value of the executeLogging property.
|
void |
setExecuteWithOptimisticLocking(java.lang.Boolean value)
Sets the value of the executeWithOptimisticLocking property.
|
void |
setExecuteWithOptimisticLockingExcludeUnversioned(java.lang.Boolean value)
Sets the value of the executeWithOptimisticLockingExcludeUnversioned property.
|
void |
setFetchSize(java.lang.Integer value)
Sets the value of the fetchSize property.
|
void |
setFetchWarnings(java.lang.Boolean value)
Sets the value of the fetchWarnings property.
|
void |
setInListPadding(java.lang.Boolean value)
Sets the value of the inListPadding property.
|
void |
setMapJPAAnnotations(java.lang.Boolean value)
Sets the value of the mapJPAAnnotations property.
|
void |
setMaxRows(java.lang.Integer value)
Sets the value of the maxRows property.
|
void |
setParamCastMode(ParamCastMode value)
Sets the value of the paramCastMode property.
|
void |
setParamType(ParamType value)
Sets the value of the paramType property.
|
void |
setQueryTimeout(java.lang.Integer value)
Sets the value of the queryTimeout property.
|
void |
setReflectionCaching(java.lang.Boolean value)
Sets the value of the reflectionCaching property.
|
void |
setRenderCatalog(java.lang.Boolean value)
Sets the value of the renderCatalog property.
|
void |
setRenderFormatted(java.lang.Boolean value)
Sets the value of the renderFormatted property.
|
void |
setRenderFormatting(RenderFormatting value)
Sets the value of the renderFormatting property.
|
void |
setRenderKeywordStyle(RenderKeywordStyle value)
Sets the value of the renderKeywordStyle property.
|
void |
setRenderMapping(RenderMapping value)
Sets the value of the renderMapping property.
|
void |
setRenderNameStyle(RenderNameStyle value)
Sets the value of the renderNameStyle property.
|
void |
setRenderOrderByRownumberForEmulatedPagination(java.lang.Boolean value)
Sets the value of the renderOrderByRownumberForEmulatedPagination property.
|
void |
setRenderScalarSubqueriesForStoredFunctions(java.lang.Boolean value)
Sets the value of the renderScalarSubqueriesForStoredFunctions property.
|
void |
setRenderSchema(java.lang.Boolean value)
Sets the value of the renderSchema property.
|
void |
setReturnAllOnUpdatableRecord(java.lang.Boolean value)
Sets the value of the returnAllOnUpdatableRecord property.
|
void |
setReturnRecordToPojo(java.lang.Boolean value)
Sets the value of the returnRecordToPojo property.
|
void |
setStatementType(StatementType value)
Sets the value of the statementType property.
|
void |
setThrowExceptions(ThrowExceptions value)
Sets the value of the throwExceptions property.
|
void |
setUpdatablePrimaryKeys(java.lang.Boolean value)
Sets the value of the updatablePrimaryKeys property.
|
Settings |
withAttachRecords(java.lang.Boolean value) |
Settings |
withBackslashEscaping(BackslashEscaping value) |
Settings |
withDebugInfoOnStackTrace(java.lang.Boolean value) |
Settings |
withDelimiter(java.lang.String value) |
Settings |
withExecuteLogging(java.lang.Boolean value) |
Settings |
withExecuteWithOptimisticLocking(java.lang.Boolean value) |
Settings |
withExecuteWithOptimisticLockingExcludeUnversioned(java.lang.Boolean value) |
Settings |
withFetchSize(java.lang.Integer value) |
Settings |
withFetchWarnings(java.lang.Boolean value) |
Settings |
withInListPadding(java.lang.Boolean value) |
Settings |
withMapJPAAnnotations(java.lang.Boolean value) |
Settings |
withMaxRows(java.lang.Integer value) |
Settings |
withParamCastMode(ParamCastMode value) |
Settings |
withParamType(ParamType value) |
Settings |
withQueryTimeout(java.lang.Integer value) |
Settings |
withReflectionCaching(java.lang.Boolean value) |
Settings |
withRenderCatalog(java.lang.Boolean value) |
Settings |
withRenderFormatted(java.lang.Boolean value) |
Settings |
withRenderFormatting(RenderFormatting value) |
Settings |
withRenderKeywordStyle(RenderKeywordStyle value) |
Settings |
withRenderMapping(RenderMapping value) |
Settings |
withRenderNameStyle(RenderNameStyle value) |
Settings |
withRenderOrderByRownumberForEmulatedPagination(java.lang.Boolean value) |
Settings |
withRenderScalarSubqueriesForStoredFunctions(java.lang.Boolean value) |
Settings |
withRenderSchema(java.lang.Boolean value) |
Settings |
withReturnAllOnUpdatableRecord(java.lang.Boolean value) |
Settings |
withReturnRecordToPojo(java.lang.Boolean value) |
Settings |
withStatementType(StatementType value) |
Settings |
withThrowExceptions(ThrowExceptions value) |
Settings |
withUpdatablePrimaryKeys(java.lang.Boolean value) |
protected java.lang.Boolean renderCatalog
protected java.lang.Boolean renderSchema
protected RenderMapping renderMapping
protected RenderNameStyle renderNameStyle
protected RenderKeywordStyle renderKeywordStyle
protected java.lang.Boolean renderFormatted
protected RenderFormatting renderFormatting
protected java.lang.Boolean renderScalarSubqueriesForStoredFunctions
protected java.lang.Boolean renderOrderByRownumberForEmulatedPagination
protected BackslashEscaping backslashEscaping
protected ParamType paramType
protected ParamCastMode paramCastMode
protected StatementType statementType
protected java.lang.Boolean executeLogging
protected java.lang.Boolean executeWithOptimisticLocking
protected java.lang.Boolean executeWithOptimisticLockingExcludeUnversioned
protected java.lang.Boolean attachRecords
protected java.lang.Boolean updatablePrimaryKeys
protected java.lang.Boolean reflectionCaching
protected ThrowExceptions throwExceptions
protected java.lang.Boolean fetchWarnings
protected java.lang.Boolean returnAllOnUpdatableRecord
protected java.lang.Boolean returnRecordToPojo
protected java.lang.Boolean mapJPAAnnotations
protected java.lang.Integer queryTimeout
protected java.lang.Integer maxRows
protected java.lang.Integer fetchSize
protected java.lang.Boolean debugInfoOnStackTrace
protected java.lang.Boolean inListPadding
protected java.lang.String delimiter
public java.lang.Boolean isRenderCatalog()
Use this for single-catalog environments, or when all objects are made available using synonyms
Boolean
public void setRenderCatalog(java.lang.Boolean value)
value
- allowed object is
Boolean
public java.lang.Boolean isRenderSchema()
Setting this to false also implicitly sets "renderCatalog" to false.
Use this for single-schema environments, or when all objects are made available using synonyms
Boolean
public void setRenderSchema(java.lang.Boolean value)
value
- allowed object is
Boolean
public RenderMapping getRenderMapping()
RenderMapping
public void setRenderMapping(RenderMapping value)
value
- allowed object is
RenderMapping
public RenderNameStyle getRenderNameStyle()
This is set to "QUOTED" by default for backwards-compatibility
RenderNameStyle
public void setRenderNameStyle(RenderNameStyle value)
value
- allowed object is
RenderNameStyle
public RenderKeywordStyle getRenderKeywordStyle()
RenderKeywordStyle
public void setRenderKeywordStyle(RenderKeywordStyle value)
value
- allowed object is
RenderKeywordStyle
public java.lang.Boolean isRenderFormatted()
Boolean
public void setRenderFormatted(java.lang.Boolean value)
value
- allowed object is
Boolean
public RenderFormatting getRenderFormatting()
RenderFormatting
public void setRenderFormatting(RenderFormatting value)
value
- allowed object is
RenderFormatting
public java.lang.Boolean isRenderScalarSubqueriesForStoredFunctions()
Oracle 11g (and potentially, other databases too) implements scalar subquery caching. With this flag set to true, users can automatically profit from this feature in all SQL statements.
Boolean
public void setRenderScalarSubqueriesForStoredFunctions(java.lang.Boolean value)
value
- allowed object is
Boolean
public java.lang.Boolean isRenderOrderByRownumberForEmulatedPagination()
ORDER BY rn
clause should be rendered on emulated paginated queries.
Older databases did not support OFFSET .. FETCH pagination, so jOOQ emulates it using derived
tables and ROWNUM
(Oracle 11g and older) or ROW_NUMBER()
(e.g. DB2,
SQL Server, etc.) filtering. While these subqueries are ordered, the ordering is not
guaranteed to be stable in the outer most queries. It may be stable (and e.g. in Oracle,
it mostly is, if queries are not parallel, or joined to other queries, etc.), so the excess
ORDER BY
clause may add some additional performance overhead. This setting forces
jOOQ to not generate the additional ORDER BY
clause.
For details, see https://github.com/jOOQ/jOOQ/issues/7609.
Boolean
public void setRenderOrderByRownumberForEmulatedPagination(java.lang.Boolean value)
value
- allowed object is
Boolean
public BackslashEscaping getBackslashEscaping()
BackslashEscaping
public void setBackslashEscaping(BackslashEscaping value)
value
- allowed object is
BackslashEscaping
public ParamType getParamType()
Possibilities include: - question marks - named parameters - named or inlined parameters - inlined parameters This value is overridden by statementType == STATIC_STATEMENT, in case of which, this defaults to INLINED
ParamType
public void setParamType(ParamType value)
value
- allowed object is
ParamType
public ParamCastMode getParamCastMode()
ParamCastMode
public void setParamCastMode(ParamCastMode value)
value
- allowed object is
ParamCastMode
public StatementType getStatementType()
StatementType
public void setStatementType(StatementType value)
value
- allowed object is
StatementType
public java.lang.Boolean isExecuteLogging()
Boolean
public void setExecuteLogging(java.lang.Boolean value)
value
- allowed object is
Boolean
public java.lang.Boolean isExecuteWithOptimisticLocking()
Boolean
public void setExecuteWithOptimisticLocking(java.lang.Boolean value)
value
- allowed object is
Boolean
public java.lang.Boolean isExecuteWithOptimisticLockingExcludeUnversioned()
This flag has no effect when "executeWithOptimisticLocking" is turned off.
Boolean
public void setExecuteWithOptimisticLockingExcludeUnversioned(java.lang.Boolean value)
value
- allowed object is
Boolean
public java.lang.Boolean isAttachRecords()
Boolean
public void setAttachRecords(java.lang.Boolean value)
value
- allowed object is
Boolean
public java.lang.Boolean isUpdatablePrimaryKeys()
Setting this to "true" will allow for updating primary key values through UpdatableRecord.store() and UpdatableRecord.update().
Boolean
public void setUpdatablePrimaryKeys(java.lang.Boolean value)
value
- allowed object is
Boolean
public java.lang.Boolean isReflectionCaching()
Boolean
public void setReflectionCaching(java.lang.Boolean value)
value
- allowed object is
Boolean
public ThrowExceptions getThrowExceptions()
ThrowExceptions
public void setThrowExceptions(ThrowExceptions value)
value
- allowed object is
ThrowExceptions
public java.lang.Boolean isFetchWarnings()
Boolean
public void setFetchWarnings(java.lang.Boolean value)
value
- allowed object is
Boolean
public java.lang.Boolean isReturnAllOnUpdatableRecord()
Do note that only few databases support this feature. It is supported only in case the INSERT's or UPDATE's RETURNING clause is fully supported, also for non-IDENTITY columns.
Boolean
public void setReturnAllOnUpdatableRecord(java.lang.Boolean value)
value
- allowed object is
Boolean
public java.lang.Boolean isReturnRecordToPojo()
Boolean
public void setReturnRecordToPojo(java.lang.Boolean value)
value
- allowed object is
Boolean
public java.lang.Boolean isMapJPAAnnotations()
Boolean
public void setMapJPAAnnotations(java.lang.Boolean value)
value
- allowed object is
Boolean
public java.lang.Integer getQueryTimeout()
Integer
public void setQueryTimeout(java.lang.Integer value)
value
- allowed object is
Integer
public java.lang.Integer getMaxRows()
Integer
public void setMaxRows(java.lang.Integer value)
value
- allowed object is
Integer
public java.lang.Integer getFetchSize()
Integer
public void setFetchSize(java.lang.Integer value)
value
- allowed object is
Integer
public java.lang.Boolean isDebugInfoOnStackTrace()
Boolean
public void setDebugInfoOnStackTrace(java.lang.Boolean value)
value
- allowed object is
Boolean
public java.lang.Boolean isInListPadding()
Boolean
public void setInListPadding(java.lang.Boolean value)
value
- allowed object is
Boolean
public java.lang.String getDelimiter()
String
public void setDelimiter(java.lang.String value)
value
- allowed object is
String
public Settings withRenderCatalog(java.lang.Boolean value)
public Settings withRenderSchema(java.lang.Boolean value)
public Settings withRenderMapping(RenderMapping value)
public Settings withRenderNameStyle(RenderNameStyle value)
public Settings withRenderKeywordStyle(RenderKeywordStyle value)
public Settings withRenderFormatted(java.lang.Boolean value)
public Settings withRenderFormatting(RenderFormatting value)
public Settings withRenderScalarSubqueriesForStoredFunctions(java.lang.Boolean value)
public Settings withRenderOrderByRownumberForEmulatedPagination(java.lang.Boolean value)
public Settings withBackslashEscaping(BackslashEscaping value)
public Settings withParamCastMode(ParamCastMode value)
public Settings withStatementType(StatementType value)
public Settings withExecuteLogging(java.lang.Boolean value)
public Settings withExecuteWithOptimisticLocking(java.lang.Boolean value)
public Settings withExecuteWithOptimisticLockingExcludeUnversioned(java.lang.Boolean value)
public Settings withAttachRecords(java.lang.Boolean value)
public Settings withUpdatablePrimaryKeys(java.lang.Boolean value)
public Settings withReflectionCaching(java.lang.Boolean value)
public Settings withThrowExceptions(ThrowExceptions value)
public Settings withFetchWarnings(java.lang.Boolean value)
public Settings withReturnAllOnUpdatableRecord(java.lang.Boolean value)
public Settings withReturnRecordToPojo(java.lang.Boolean value)
public Settings withMapJPAAnnotations(java.lang.Boolean value)
public Settings withQueryTimeout(java.lang.Integer value)
public Settings withMaxRows(java.lang.Integer value)
public Settings withFetchSize(java.lang.Integer value)
public Settings withDebugInfoOnStackTrace(java.lang.Boolean value)
public Settings withInListPadding(java.lang.Boolean value)
public Settings withDelimiter(java.lang.String value)
public java.lang.Object clone()
clone
in class java.lang.Object
Copyright © 2018. All Rights Reserved.