Package org.mybatis.dynamic.sql
Class AliasableSqlTable<T extends AliasableSqlTable<T>>
java.lang.Object
org.mybatis.dynamic.sql.SqlTable
org.mybatis.dynamic.sql.AliasableSqlTable<T>
- All Implemented Interfaces:
TableExpression
-
Field Summary
Fields inherited from class org.mybatis.dynamic.sql.SqlTable
nameSupplier
-
Constructor Summary
ModifierConstructorDescriptionprotected
AliasableSqlTable
(String tableName, Supplier<T> constructor) -
Method Summary
Methods inherited from class org.mybatis.dynamic.sql.SqlTable
accept, allColumns, column, column, column, of, tableNameAtRuntime
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.mybatis.dynamic.sql.TableExpression
isSubQuery
-
Constructor Details
-
AliasableSqlTable
-
-
Method Details
-
withAlias
-
withName
Returns a new instance of this table with the specified name. All column instances are recreated. This is useful for sharding where the table name may change at runtime based on some sharding algorithm, but all other table attributes are the same.- Parameters:
name
- new name for the table- Returns:
- a new AliasableSqlTable with the specified name, all other table attributes are copied
-
tableAlias
- Overrides:
tableAlias
in classSqlTable
-