public class ForeignKey extends Constraint<ForeignKey> implements Serializable
Constraint.TYPE| 限定符和类型 | 字段和说明 |
|---|---|
static String |
FIELD_COLUMN |
static String |
FIELD_COLUMN_ON_DELETE |
static String |
FIELD_COLUMN_ON_UPDATE |
static String |
FIELD_COLUMN_POSITION |
static String |
FIELD_KEYWORD |
static String |
FIELD_REFERENCE_CATALOG |
static String |
FIELD_REFERENCE_COLUMN |
static String |
FIELD_REFERENCE_SCHEMA |
static String |
FIELD_REFERENCE_TABLE |
protected String |
keyword |
protected String |
onDelete |
protected String |
onUpdate |
protected Table |
reference |
protected ForeignKey |
update |
columns, FIELD_ORDER, FIELD_POSITION, FIELD_TYPE, orders, positions, typeFIELD_TABLE, tableaction, alias, catalog, checkSchemaTime, comment, database, databaseType, datasource, ddls, definition, drop, engine, execute, extend, FIELD_ACTION, FIELD_ALIAS, FIELD_CATALOG, FIELD_CHECK_SCHEMA_TIME, FIELD_COMMENT, FIELD_DATABASE, FIELD_DATASOURCE, FIELD_DDL, FIELD_DEFINITION, FIELD_DROP, FIELD_DROP_CHECK, FIELD_DROP_CHECK_VALUE, FIELD_ENGINE, FIELD_EXECUTE, FIELD_EXECUTE_CHECK, FIELD_EXECUTE_CHECK_VALUE, FIELD_EXTEND, FIELD_GETMAP, FIELD_GETMAP_CHECK, FIELD_GETMAP_CHECK_VALUE, FIELD_ID, FIELD_IDENTITY, FIELD_METADATA, FIELD_NAME, FIELD_OBJECT_ID, FIELD_PROPERTY, FIELD_RUN, FIELD_SCHEMA, FIELD_SETMAP, FIELD_SETMAP_CHECK, FIELD_SETMAP_CHECK_VALUE, FIELD_SWT, FIELD_TEXT, FIELD_USER, getmap, id, identity, metadata, name, objectId, options, origin, property, runs, schema, setmap, swt, text, user| 构造器和说明 |
|---|
ForeignKey() |
ForeignKey(String name) |
ForeignKey(String table,
String column,
String rtable,
String rcolumn)
外键
|
| 限定符和类型 | 方法和说明 |
|---|---|
ForeignKey |
addColumn(Column column)
添加列
|
ForeignKey |
addColumn(String column,
Column reference)
添加列
|
ForeignKey |
addColumn(String column,
String reference) |
ForeignKey |
addColumn(String column,
String table,
Column reference)
添加列
|
ForeignKey |
clone() |
String |
getKeyword() |
Table |
getReference() |
boolean |
isForeign() |
String |
onDelete() |
void |
onDelete(String onDelete) |
String |
onUpdate() |
void |
onUpdate(String onUpdate) |
ForeignKey |
setReference(String reference)
添加依赖表
|
ForeignKey |
setReference(Table reference) |
addColumn, addColumn, createName, getColumn, getColumns, getOrder, getTable, getTableName, getType, isUnique, setColumns, setOrder, setOrder, setOrders, setType, setTypeaddDdl, addRun, execute, getCatalog, getIdentity, getSchema, getTable, getTableName, setTable, setTableaddOption, check, ddl, ddl, ddls, ddls, delete, drop, execute, getAction, getAlias, getCatalogName, getCheckSchemaTime, getComment, getDatabase, getDatabaseName, getDatabaseType, getDataSource, getDdl, getDdl, getDdls, getDdls, getDefinition, getEngine, getExtend, getFullName, getId, getMetadata, getName, getObjectId, getOrigin, getProperty, getRun, getRun, getRuns, getRuns, getSchemaName, getText, getUpdate, getUser, getUserName, isDelete, isDrop, isEmpty, isRename, match, match, match, match, match, names, names, names, names, options, run, run, runs, runs, setAction, setAlias, setCatalog, setCatalog, setCheckSchemaTime, setComment, setDatabase, setDatabase, setDatabaseType, setDataSource, setDdls, setDefinition, setDelete, setDrop, setEngine, setExtend, setId, setMetadata, setName, setNewName, setNewName, setObjectId, setProperty, setProperty, setRuns, setSchema, setSchema, setText, setUpdate, setUser, setUser, sort, swt, swt, toString, type, types, types, update, updateprotected String keyword
protected Table reference
protected ForeignKey update
protected String onUpdate
protected String onDelete
public ForeignKey()
public ForeignKey(String name)
public boolean isForeign()
public ForeignKey addColumn(String column, String reference)
addColumn 在类中 Constraint<ForeignKey>public ForeignKey setReference(Table reference)
public ForeignKey setReference(String reference)
reference - 依赖表public Table getReference()
public ForeignKey addColumn(Column column)
addColumn 在类中 Constraint<ForeignKey>column - 列 需要设置reference属性public ForeignKey addColumn(String column, String table, Column reference)
column - 列table - 依赖表reference - 依赖列public ForeignKey addColumn(String column, Column reference)
column - 列reference - 依赖列public String getKeyword()
getKeyword 在类中 Constraint<ForeignKey>public ForeignKey clone()
clone 在类中 Constraint<ForeignKey>public String onUpdate()
public void onUpdate(String onUpdate)
public String onDelete()
public void onDelete(String onDelete)
Copyright © 2025. All rights reserved.