public abstract class MetaImpl extends Object implements Meta
Meta.
Each sub-class must implement the two remaining abstract methods,
Meta.prepare(org.apache.calcite.avatica.Meta.ConnectionHandle, java.lang.String, int) and
Meta.prepareAndExecute(org.apache.calcite.avatica.Meta.ConnectionHandle, java.lang.String, int, org.apache.calcite.avatica.Meta.PrepareCallback).
It should also override metadata methods such as getCatalogs() and
getTables(java.lang.String, org.apache.calcite.avatica.Meta.Pat, org.apache.calcite.avatica.Meta.Pat, java.util.List<java.lang.String>) for the element types for which it has instances; the
default metadata methods return empty collections.
| Modifier and Type | Class and Description |
|---|---|
static class |
MetaImpl.MetaAttribute
Metadata describing an attribute.
|
static class |
MetaImpl.MetaBestRowIdentifier
Metadata describing the best identifier for a row.
|
static class |
MetaImpl.MetaCatalog
Metadata describing a catalog.
|
static class |
MetaImpl.MetaClientInfoProperty
Metadata describing a client info property.
|
static class |
MetaImpl.MetaColumn
Metadata describing a column.
|
static class |
MetaImpl.MetaColumnPrivilege
Metadata describing a column privilege.
|
static class |
MetaImpl.MetaCrossReference
Metadata describing a cross reference.
|
static class |
MetaImpl.MetaExportedKey
Metadata describing an exported key.
|
static class |
MetaImpl.MetaFunction
Metadata describing a function.
|
static class |
MetaImpl.MetaFunctionColumn
Metadata describing a function column.
|
static class |
MetaImpl.MetaImportedKey
Metadata describing an imported key.
|
static class |
MetaImpl.MetaIndexInfo
Metadata describing index info.
|
static class |
MetaImpl.MetaPrimaryKey
Metadata describing a primary key.
|
static class |
MetaImpl.MetaProcedure
Metadata describing a procedure.
|
static class |
MetaImpl.MetaProcedureColumn
Metadata describing a procedure column.
|
static class |
MetaImpl.MetaPseudoColumn
Metadata describing a pseudo column.
|
static class |
MetaImpl.MetaSchema
Metadata describing a schema.
|
static class |
MetaImpl.MetaSuperTable
Metadata describing a super-table.
|
static class |
MetaImpl.MetaSuperType
Metadata describing a super-type.
|
static class |
MetaImpl.MetaTable
Metadata describing a table.
|
static class |
MetaImpl.MetaTablePrivilege
Metadata describing a table privilege.
|
static class |
MetaImpl.MetaTableType
Metadata describing a table type.
|
static class |
MetaImpl.MetaTypeInfo
Metadata describing type info.
|
static class |
MetaImpl.MetaUdt
Metadata describing a user-defined type.
|
static class |
MetaImpl.MetaVersionColumn
Metadata describing a version column.
|
static interface |
MetaImpl.Named
An object that has a name.
|
Meta.ConnectionHandle, Meta.ConnectionProperties, Meta.CursorFactory, Meta.ExecuteResult, Meta.Factory, Meta.Frame, Meta.MetaResultSet, Meta.Pat, Meta.PrepareCallback, Meta.Signature, Meta.StatementHandle, Meta.Style| Modifier and Type | Field and Description |
|---|---|
protected AvaticaConnection |
connection
The
AvaticaConnection backing this. |
protected ConnectionPropertiesImpl |
connProps
Represents the various states specific to
connection. |
| Constructor and Description |
|---|
MetaImpl(AvaticaConnection connection) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcloseStatement, prepare, prepareAndExecuteprotected final AvaticaConnection connection
AvaticaConnection backing this.protected final ConnectionPropertiesImpl connProps
connection.
Note: this instance is used recursively with connection's getter and setter
methods.
public MetaImpl(AvaticaConnection connection)
public static Cursor createCursor(Meta.CursorFactory cursorFactory, Iterable<Object> iterable)
public static List<List<Object>> collect(Meta.CursorFactory cursorFactory, Iterable<Object> iterable, List<List<Object>> list)
public void closeConnection(Meta.ConnectionHandle ch)
MetacloseConnection in interface Metapublic Meta.ConnectionProperties connectionSync(Meta.ConnectionHandle ch, Meta.ConnectionProperties connProps)
MetaNote: this interface is considered "experimental" and may undergo further changes as this
functionality is extended to other aspects of state management for
Connection, Statement, and ResultSet.
connectionSync in interface Metapublic Meta.StatementHandle createStatement(Meta.ConnectionHandle ch)
MetacreateStatement in interface Metach - Connection handleprotected <E> Meta.MetaResultSet createEmptyResultSet(Class<E> clazz)
protected static ColumnMetaData columnMetaData(String name, int index, Class<?> type)
protected static ColumnMetaData.StructType fieldMetaData(Class clazz)
protected Meta.MetaResultSet createResultSet(Map<String,Object> internalParameters, List<ColumnMetaData> columns, Meta.CursorFactory cursorFactory, Meta.Frame firstFrame)
public String getSqlKeywords()
getSqlKeywords in interface Metapublic String getNumericFunctions()
getNumericFunctions in interface Metapublic String getStringFunctions()
getStringFunctions in interface Metapublic String getSystemFunctions()
getSystemFunctions in interface Metapublic String getTimeDateFunctions()
getTimeDateFunctions in interface Metapublic Meta.MetaResultSet getTables(String catalog, Meta.Pat schemaPattern, Meta.Pat tableNamePattern, List<String> typeList)
public Meta.MetaResultSet getColumns(String catalog, Meta.Pat schemaPattern, Meta.Pat tableNamePattern, Meta.Pat columnNamePattern)
getColumns in interface Metapublic Meta.MetaResultSet getSchemas(String catalog, Meta.Pat schemaPattern)
getSchemas in interface Metapublic Meta.MetaResultSet getCatalogs()
getCatalogs in interface Metapublic Meta.MetaResultSet getTableTypes()
getTableTypes in interface Metapublic Meta.MetaResultSet getProcedures(String catalog, Meta.Pat schemaPattern, Meta.Pat procedureNamePattern)
getProcedures in interface Metapublic Meta.MetaResultSet getProcedureColumns(String catalog, Meta.Pat schemaPattern, Meta.Pat procedureNamePattern, Meta.Pat columnNamePattern)
getProcedureColumns in interface Metapublic Meta.MetaResultSet getColumnPrivileges(String catalog, String schema, String table, Meta.Pat columnNamePattern)
getColumnPrivileges in interface Metapublic Meta.MetaResultSet getTablePrivileges(String catalog, Meta.Pat schemaPattern, Meta.Pat tableNamePattern)
getTablePrivileges in interface Metapublic Meta.MetaResultSet getBestRowIdentifier(String catalog, String schema, String table, int scope, boolean nullable)
getBestRowIdentifier in interface Metapublic Meta.MetaResultSet getVersionColumns(String catalog, String schema, String table)
getVersionColumns in interface Metapublic Meta.MetaResultSet getPrimaryKeys(String catalog, String schema, String table)
getPrimaryKeys in interface Metapublic Meta.MetaResultSet getImportedKeys(String catalog, String schema, String table)
getImportedKeys in interface Metapublic Meta.MetaResultSet getExportedKeys(String catalog, String schema, String table)
getExportedKeys in interface Metapublic Meta.MetaResultSet getCrossReference(String parentCatalog, String parentSchema, String parentTable, String foreignCatalog, String foreignSchema, String foreignTable)
getCrossReference in interface Metapublic Meta.MetaResultSet getTypeInfo()
getTypeInfo in interface Metapublic Meta.MetaResultSet getIndexInfo(String catalog, String schema, String table, boolean unique, boolean approximate)
getIndexInfo in interface Metapublic Meta.MetaResultSet getUDTs(String catalog, Meta.Pat schemaPattern, Meta.Pat typeNamePattern, int[] types)
public Meta.MetaResultSet getSuperTypes(String catalog, Meta.Pat schemaPattern, Meta.Pat typeNamePattern)
getSuperTypes in interface Metapublic Meta.MetaResultSet getSuperTables(String catalog, Meta.Pat schemaPattern, Meta.Pat tableNamePattern)
getSuperTables in interface Metapublic Meta.MetaResultSet getAttributes(String catalog, Meta.Pat schemaPattern, Meta.Pat typeNamePattern, Meta.Pat attributeNamePattern)
getAttributes in interface Metapublic Meta.MetaResultSet getClientInfoProperties()
getClientInfoProperties in interface Metapublic Meta.MetaResultSet getFunctions(String catalog, Meta.Pat schemaPattern, Meta.Pat functionNamePattern)
getFunctions in interface Metapublic Meta.MetaResultSet getFunctionColumns(String catalog, Meta.Pat schemaPattern, Meta.Pat functionNamePattern, Meta.Pat columnNamePattern)
getFunctionColumns in interface Metapublic Meta.MetaResultSet getPseudoColumns(String catalog, Meta.Pat schemaPattern, Meta.Pat tableNamePattern, Meta.Pat columnNamePattern)
getPseudoColumns in interface Metapublic Iterable<Object> createIterable(Meta.StatementHandle handle, Meta.Signature signature, List<Object> parameterValues, Meta.Frame firstFrame)
MetaThe default implementation just returns iterable, which it
requires to be not null; derived classes may instead choose to execute the
relational expression in signature.
createIterable in interface Metapublic Meta.Frame fetch(Meta.StatementHandle h, List<Object> parameterValues, int offset, int fetchMaxRowCount)
MetaThe frame describes whether there may be another frame. If there is not another frame, the current iteration is done when we have finished the rows in the this frame.
The default implementation always returns null.
fetch in interface Metah - Statement handleparameterValues - A list of parameter values, if statement is to be
executed; otherwise nulloffset - Zero-based offset of first row in the requested framefetchMaxRowCount - Maximum number of rows to return; negative means
no limitCopyright © 2012–2015 The Apache Software Foundation. All rights reserved.