Package cc.carm.lib.easysql.action
Class PreparedSQLUpdateActionImpl<T extends java.lang.Number>
- java.lang.Object
-
- cc.carm.lib.easysql.action.AbstractSQLAction<T>
-
- cc.carm.lib.easysql.action.SQLUpdateActionImpl<T>
-
- cc.carm.lib.easysql.action.PreparedSQLUpdateActionImpl<T>
-
- All Implemented Interfaces:
PreparedSQLUpdateAction<T>,SQLUpdateAction<T>,SQLAction<T>
public class PreparedSQLUpdateActionImpl<T extends java.lang.Number> extends SQLUpdateActionImpl<T> implements PreparedSQLUpdateAction<T>
-
-
Field Summary
-
Fields inherited from class cc.carm.lib.easysql.action.SQLUpdateActionImpl
numberClass, returnGeneratedKeys
-
Fields inherited from class cc.carm.lib.easysql.action.AbstractSQLAction
sqlContent
-
-
Constructor Summary
Constructors Constructor Description PreparedSQLUpdateActionImpl(@NotNull SQLManagerImpl manager, @NotNull java.lang.Class<T> numberClass, @NotNull java.lang.String sql)PreparedSQLUpdateActionImpl(@NotNull SQLManagerImpl manager, @NotNull java.lang.Class<T> numberClass, @NotNull java.lang.String sql, @Nullable java.lang.Object[] params)PreparedSQLUpdateActionImpl(@NotNull SQLManagerImpl manager, @NotNull java.lang.Class<T> numberClass, @NotNull java.lang.String sql, @Nullable java.util.List<java.lang.Object> params)PreparedSQLUpdateActionImpl(@NotNull SQLManagerImpl manager, @NotNull java.lang.Class<T> numberClass, @NotNull java.util.UUID uuid, @NotNull java.lang.String sql, java.lang.Object[] params)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Texecute()执行该Action对应的SQL语句<N extends java.lang.Number>
SQLUpdateAction<N>returnGeneratedKey(java.lang.Class<N> keyTypeClass)设定该操作返回自增键序列。PreparedSQLUpdateActionImpl<T>setParams(@Nullable java.lang.Iterable<java.lang.Object> params)设定SQL语句中所有 ?PreparedSQLUpdateActionImpl<T>setParams(java.lang.Object... params)设定SQL语句中所有 ?-
Methods inherited from class cc.carm.lib.easysql.action.SQLUpdateActionImpl
returnGeneratedKey
-
Methods inherited from class cc.carm.lib.easysql.action.AbstractSQLAction
debugMessage, executeAsync, executeFuture, getActionUUID, getCreateTime, getManager, getShortID, getSQLContent
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface cc.carm.lib.easysql.api.SQLAction
defaultExceptionHandler, execute, execute, execute, executeAsync, executeAsync, executeAsync, executeFunction, executeFunction, executeFuture, executeFuture, getActionUUID, getCreateTime, getCreateTime, getManager, getShortID, getSQLContent, getSQLContents, handleException, setExceptionHandler
-
Methods inherited from interface cc.carm.lib.easysql.api.action.SQLUpdateAction
returnGeneratedKey
-
-
-
-
Constructor Detail
-
PreparedSQLUpdateActionImpl
public PreparedSQLUpdateActionImpl(@NotNull @NotNull SQLManagerImpl manager, @NotNull @NotNull java.lang.Class<T> numberClass, @NotNull @NotNull java.lang.String sql)
-
PreparedSQLUpdateActionImpl
public PreparedSQLUpdateActionImpl(@NotNull @NotNull SQLManagerImpl manager, @NotNull @NotNull java.lang.Class<T> numberClass, @NotNull @NotNull java.lang.String sql, @Nullable @Nullable java.util.List<java.lang.Object> params)
-
PreparedSQLUpdateActionImpl
public PreparedSQLUpdateActionImpl(@NotNull @NotNull SQLManagerImpl manager, @NotNull @NotNull java.lang.Class<T> numberClass, @NotNull @NotNull java.lang.String sql, @Nullable @Nullable java.lang.Object[] params)
-
PreparedSQLUpdateActionImpl
public PreparedSQLUpdateActionImpl(@NotNull @NotNull SQLManagerImpl manager, @NotNull @NotNull java.lang.Class<T> numberClass, @NotNull @NotNull java.util.UUID uuid, @NotNull @NotNull java.lang.String sql, java.lang.Object[] params)
-
-
Method Detail
-
setParams
public PreparedSQLUpdateActionImpl<T> setParams(java.lang.Object... params)
Description copied from interface:PreparedSQLUpdateAction设定SQL语句中所有 ? 对应的参数- Specified by:
setParamsin interfacePreparedSQLUpdateAction<T extends java.lang.Number>- Parameters:
params- 参数内容- Returns:
PreparedSQLUpdateAction
-
setParams
public PreparedSQLUpdateActionImpl<T> setParams(@Nullable @Nullable java.lang.Iterable<java.lang.Object> params)
Description copied from interface:PreparedSQLUpdateAction设定SQL语句中所有 ? 对应的参数- Specified by:
setParamsin interfacePreparedSQLUpdateAction<T extends java.lang.Number>- Parameters:
params- 参数内容- Returns:
PreparedSQLUpdateAction
-
execute
@NotNull public T execute() throws java.sql.SQLException
Description copied from interface:SQLAction执行该Action对应的SQL语句
-
returnGeneratedKey
public <N extends java.lang.Number> SQLUpdateAction<N> returnGeneratedKey(java.lang.Class<N> keyTypeClass)
Description copied from interface:SQLUpdateAction设定该操作返回自增键序列。- Specified by:
returnGeneratedKeyin interfaceSQLUpdateAction<T extends java.lang.Number>- Overrides:
returnGeneratedKeyin classSQLUpdateActionImpl<T extends java.lang.Number>- Type Parameters:
N- 自增键序列类型Number- Parameters:
keyTypeClass- 自增序列的数字类型- Returns:
SQLUpdateAction
-
-