Package com.alibaba.druid.sql.repository
Class Schema
- java.lang.Object
-
- com.alibaba.druid.sql.repository.Schema
-
public class Schema extends Object
Created by wenshao on 21/07/2017.
-
-
Field Summary
Fields Modifier and Type Field Description protected Map<Long,SchemaObject>functionsprotected Map<Long,SchemaObject>objects
-
Constructor Summary
Constructors Modifier Constructor Description protectedSchema(SchemaRepository repository)protectedSchema(SchemaRepository repository, String name)protectedSchema(SchemaRepository repository, String catalog, String name)
-
Method Summary
-
-
-
Field Detail
-
objects
protected final Map<Long,SchemaObject> objects
-
functions
protected final Map<Long,SchemaObject> functions
-
-
Constructor Detail
-
Schema
protected Schema(SchemaRepository repository)
-
Schema
protected Schema(SchemaRepository repository, String name)
-
Schema
protected Schema(SchemaRepository repository, String catalog, String name)
-
-
Method Detail
-
getRepository
public SchemaRepository getRepository()
-
getName
public String getName()
-
getSimpleName
public String getSimpleName()
-
setName
public void setName(String name)
-
findTable
public SchemaObject findTable(String tableName)
-
findTable
public SchemaObject findTable(long nameHashCode64)
-
findView
public SchemaObject findView(String viewName)
-
findView
public SchemaObject findView(long nameHashCode64)
-
findTableOrView
public SchemaObject findTableOrView(String tableName)
-
findTableOrView
public SchemaObject findTableOrView(long hashCode64)
-
findFunction
public SchemaObject findFunction(String functionName)
-
isSequence
public boolean isSequence(String name)
-
findTable
public SchemaObject findTable(SQLTableSource tableSource, String alias)
-
findColumn
public SQLColumnDefinition findColumn(SQLTableSource tableSource, SQLSelectItem selectItem)
-
findColumn
public SQLColumnDefinition findColumn(SQLTableSource tableSource, SQLExpr expr)
-
findTable
public SchemaObject findTable(SQLTableSource tableSource, SQLSelectItem selectItem)
-
findTable
public SchemaObject findTable(SQLTableSource tableSource, SQLExpr expr)
-
getTables
public Map<String,SchemaObject> getTables(SQLTableSource x)
-
computeTables
protected void computeTables(SQLTableSource x, Map<String,SchemaObject> tables)
-
getTableCount
public int getTableCount()
-
getObjects
public Collection<SchemaObject> getObjects()
-
removeObject
public boolean removeObject(Long nameHashCode64)
-
getViewCount
public int getViewCount()
-
getCatalog
public String getCatalog()
-
-