| Package | Description |
|---|---|
| org.apache.calcite.adapter.enumerable |
Query optimizer rules for Java calling convention.
|
| org.apache.calcite.adapter.jdbc |
Query provider based on a JDBC data source.
|
| org.apache.calcite.rel.type |
Defines a type system for relational expressions.
|
| org.apache.calcite.rex |
Provides a language for representing row-expressions.
|
| org.apache.calcite.sql |
Provides a SQL parser and object model.
|
| org.apache.calcite.sql.dialect |
SQL unparsers for JDBC dialects.
|
| org.apache.calcite.sql.fun |
Defines the set of standard SQL row-level functions and
operators.
|
| org.apache.calcite.sql.type |
SQL type system.
|
| org.apache.calcite.tools |
Provides utility classes.
|
| Modifier and Type | Method and Description |
|---|---|
private RexImpTable.MethodImplementor |
RexImpTable.ItemImplementor.getImplementor(SqlTypeName sqlTypeName) |
private Expression |
RexImpTable.DatetimeArithmeticImplementor.normalize(SqlTypeName typeName,
Expression e)
Normalizes a TIME value into 00:00:00..23:59:39.
|
| Modifier and Type | Method and Description |
|---|---|
private Method |
JdbcToEnumerableConverter.getMethod(SqlTypeName sqlTypeName,
boolean nullable,
boolean offset) |
private Method |
JdbcToEnumerableConverter.getMethod2(SqlTypeName sqlTypeName) |
| Modifier and Type | Method and Description |
|---|---|
SqlTypeName |
RelRecordType.getSqlTypeName() |
SqlTypeName |
RelDataTypeFactoryImpl.JavaType.getSqlTypeName() |
SqlTypeName |
DynamicRecordTypeImpl.getSqlTypeName() |
SqlTypeName |
RelDataTypeImpl.getSqlTypeName() |
SqlTypeName |
RelDataType.getSqlTypeName()
Gets the
SqlTypeName of this type. |
| Modifier and Type | Method and Description |
|---|---|
RelDataTypeFactory.FieldInfoBuilder |
RelDataTypeFactory.FieldInfoBuilder.add(String name,
SqlTypeName typeName)
Deprecated.
|
RelDataTypeFactory.Builder |
RelDataTypeFactory.Builder.add(String name,
SqlTypeName typeName)
Adds a field with a type created using
RelDataTypeFactory.createSqlType(org.apache.calcite.sql.type.SqlTypeName). |
RelDataTypeFactory.FieldInfoBuilder |
RelDataTypeFactory.FieldInfoBuilder.add(String name,
SqlTypeName typeName,
int precision)
Deprecated.
|
RelDataTypeFactory.Builder |
RelDataTypeFactory.Builder.add(String name,
SqlTypeName typeName,
int precision)
Adds a field with a type created using
RelDataTypeFactory.createSqlType(org.apache.calcite.sql.type.SqlTypeName, int). |
RelDataTypeFactory.FieldInfoBuilder |
RelDataTypeFactory.FieldInfoBuilder.add(String name,
SqlTypeName typeName,
int precision,
int scale)
Deprecated.
|
RelDataTypeFactory.Builder |
RelDataTypeFactory.Builder.add(String name,
SqlTypeName typeName,
int precision,
int scale)
Adds a field with a type created using
RelDataTypeFactory.createSqlType(org.apache.calcite.sql.type.SqlTypeName, int, int). |
RelDataType |
RelDataTypeFactory.createSqlType(SqlTypeName typeName)
Creates a SQL type with no precision or scale.
|
RelDataType |
RelDataTypeFactory.createSqlType(SqlTypeName typeName,
int precision)
Creates a SQL type with length (precision) but no scale.
|
RelDataType |
RelDataTypeFactory.createSqlType(SqlTypeName typeName,
int precision,
int scale)
Creates a SQL type with precision and scale.
|
int |
RelDataTypeSystem.getDefaultPrecision(SqlTypeName typeName)
Returns default precision for this type if supported, otherwise -1 if
precision is either unsupported or must be specified explicitly.
|
int |
RelDataTypeSystemImpl.getDefaultPrecision(SqlTypeName typeName) |
String |
RelDataTypeSystem.getLiteral(SqlTypeName typeName,
boolean isPrefix)
Returns the LITERAL string for the type, either PREFIX/SUFFIX.
|
String |
RelDataTypeSystemImpl.getLiteral(SqlTypeName typeName,
boolean isPrefix) |
int |
RelDataTypeSystem.getMaxPrecision(SqlTypeName typeName)
Returns the maximum precision (or length) allowed for this type, or -1 if
precision/length are not applicable for this type.
|
int |
RelDataTypeSystemImpl.getMaxPrecision(SqlTypeName typeName) |
int |
RelDataTypeSystem.getMaxScale(SqlTypeName typeName)
Returns the maximum scale of a given type.
|
int |
RelDataTypeSystemImpl.getMaxScale(SqlTypeName typeName) |
int |
RelDataTypeSystem.getNumTypeRadix(SqlTypeName typeName)
Returns the numeric type radix, typically 2 or 10.
|
int |
RelDataTypeSystemImpl.getNumTypeRadix(SqlTypeName typeName) |
boolean |
RelDataTypeSystem.isAutoincrement(SqlTypeName typeName)
Returns whether the type can be auto increment.
|
boolean |
RelDataTypeSystemImpl.isAutoincrement(SqlTypeName typeName) |
boolean |
RelDataTypeSystem.isCaseSensitive(SqlTypeName typeName)
Returns whether the type is case sensitive.
|
boolean |
RelDataTypeSystemImpl.isCaseSensitive(SqlTypeName typeName) |
static RelProtoDataType |
RelDataTypeImpl.proto(SqlTypeName typeName,
boolean nullable)
Returns a
RelProtoDataType
that will create a type typeName. |
static RelProtoDataType |
RelDataTypeImpl.proto(SqlTypeName typeName,
int precision,
boolean nullable)
Returns a
RelProtoDataType
that will create a type typeName(precision). |
static RelProtoDataType |
RelDataTypeImpl.proto(SqlTypeName typeName,
int precision,
int scale,
boolean nullable)
Returns a
RelProtoDataType
that will create a type typeName(precision, scale). |
| Modifier and Type | Field and Description |
|---|---|
private SqlTypeName |
RexLiteral.typeName
An indication of the broad type of this literal -- even if its type isn't
a SQL type.
|
| Modifier and Type | Method and Description |
|---|---|
SqlTypeName |
RexLiteral.getTypeName() |
| Modifier and Type | Method and Description |
|---|---|
protected static org.apache.calcite.avatica.util.TimeUnit |
RexBuilder.baseUnit(SqlTypeName unit)
Returns the lowest granularity unit for the given unit.
|
(package private) boolean |
RexBuilder.canRemoveCastFromLiteral(RelDataType toType,
Comparable value,
SqlTypeName fromTypeName) |
static RexLiteral |
RexLiteral.fromJdbcString(RelDataType type,
SqlTypeName typeName,
String literal)
Converts a Jdbc string into a RexLiteral.
|
private static String |
RexLiteral.getCalendarFormat(SqlTypeName typeName) |
private static List<org.apache.calcite.avatica.util.TimeUnit> |
RexLiteral.getTimeUnits(SqlTypeName typeName)
Returns a list of the time units covered by an interval type such
as HOUR TO SECOND.
|
protected RexLiteral |
RexBuilder.makeLiteral(Comparable o,
RelDataType type,
SqlTypeName typeName)
Internal method to create a call to a literal.
|
RexNode |
RexBuilder.makeNullLiteral(SqlTypeName typeName)
Deprecated.
|
RexNode |
RexBuilder.makeNullLiteral(SqlTypeName typeName,
int precision)
Deprecated.
|
private static void |
RexLiteral.printAsJava(Comparable value,
PrintWriter pw,
SqlTypeName typeName,
boolean java)
Prints a value as a Java string.
|
private static String |
RexLiteral.toJavaString(Comparable value,
SqlTypeName typeName) |
static boolean |
RexLiteral.valueMatchesType(Comparable value,
SqlTypeName typeName,
boolean strict) |
| Constructor and Description |
|---|
RexLiteral(Comparable value,
RelDataType type,
SqlTypeName typeName)
Creates a
RexLiteral. |
| Modifier and Type | Field and Description |
|---|---|
private SqlTypeName |
SqlJdbcDataTypeName.typeName |
private SqlTypeName |
SqlLiteral.typeName
The type with which this literal was declared.
|
| Modifier and Type | Method and Description |
|---|---|
SqlTypeName |
SqlLiteral.getTypeName() |
SqlTypeName |
SqlIntervalQualifier.typeName() |
| Modifier and Type | Method and Description |
|---|---|
static boolean |
SqlLiteral.valueMatchesType(Object value,
SqlTypeName typeName) |
| Constructor and Description |
|---|
SqlAbstractDateTimeLiteral(Object d,
boolean tz,
SqlTypeName typeName,
int precision,
SqlParserPos pos)
Constructs a datetime literal.
|
SqlAbstractStringLiteral(Object value,
SqlTypeName typeName,
SqlParserPos pos) |
SqlIntervalLiteral(int sign,
String intervalStr,
SqlIntervalQualifier intervalQualifier,
SqlTypeName sqlTypeName,
SqlParserPos pos) |
SqlIntervalLiteral(SqlIntervalLiteral.IntervalValue intervalValue,
SqlTypeName sqlTypeName,
SqlParserPos pos) |
SqlJdbcDataTypeName(SqlTypeName typeName) |
SqlJdbcDataTypeName(SqlTypeName typeName,
org.apache.calcite.avatica.util.TimeUnitRange range) |
SqlLiteral(Object value,
SqlTypeName typeName,
SqlParserPos pos)
Creates a
SqlLiteral. |
| Modifier and Type | Field and Description |
|---|---|
private List<SqlTypeName> |
JethroDataSqlDialect.JethroSupportedFunction.operandTypes |
| Modifier and Type | Method and Description |
|---|---|
private SqlTypeName |
JethroDataSqlDialect.JethroSupportedFunction.parse(String strType) |
| Modifier and Type | Field and Description |
|---|---|
private SqlTypeName |
SqlAbstractTimeFunction.typeName |
| Constructor and Description |
|---|
SqlAbstractTimeFunction(String name,
SqlTypeName typeName) |
| Modifier and Type | Field and Description |
|---|---|
protected SqlTypeName |
AbstractSqlType.typeName |
| Modifier and Type | Field and Description |
|---|---|
static List<SqlTypeName> |
SqlTypeName.ALL_TYPES |
static List<SqlTypeName> |
SqlTypeName.APPROX_TYPES |
static List<SqlTypeName> |
SqlTypeName.BINARY_TYPES |
static List<SqlTypeName> |
SqlTypeName.BOOLEAN_TYPES |
static List<SqlTypeName> |
SqlTypeName.CHAR_TYPES |
private static List<SqlTypeName> |
SqlTypeExplicitPrecedenceList.COMPACT_NUMERIC_TYPES |
static List<SqlTypeName> |
SqlTypeName.DATETIME_TYPES |
static Set<SqlTypeName> |
SqlTypeName.DAY_INTERVAL_TYPES |
static List<SqlTypeName> |
SqlTypeName.EXACT_TYPES |
static List<SqlTypeName> |
SqlTypeName.FRACTIONAL_TYPES |
static List<SqlTypeName> |
SqlTypeName.INT_TYPES |
static Set<SqlTypeName> |
SqlTypeName.INTERVAL_TYPES |
private static Map<Integer,SqlTypeName> |
SqlTypeName.JDBC_TYPE_TO_NAME |
private Map<SqlTypeName,com.google.common.collect.ImmutableSet<SqlTypeName>> |
SqlTypeAssignmentRules.map |
private Map<SqlTypeName,com.google.common.collect.ImmutableSet<SqlTypeName>> |
SqlTypeAssignmentRules.map |
(package private) Map<SqlTypeName,com.google.common.collect.ImmutableSet<SqlTypeName>> |
SqlTypeAssignmentRules.Builder.map |
(package private) Map<SqlTypeName,com.google.common.collect.ImmutableSet<SqlTypeName>> |
SqlTypeAssignmentRules.Builder.map |
static List<SqlTypeName> |
SqlTypeName.NUMERIC_TYPES |
private static List<SqlTypeName> |
SqlTypeExplicitPrecedenceList.NUMERIC_TYPES |
private Map<Class<?>,SqlTypeName> |
JavaToSqlTypeConversionRules.rules |
(package private) com.google.common.cache.LoadingCache<Set<SqlTypeName>,com.google.common.collect.ImmutableSet<SqlTypeName>> |
SqlTypeAssignmentRules.Builder.sets |
(package private) com.google.common.cache.LoadingCache<Set<SqlTypeName>,com.google.common.collect.ImmutableSet<SqlTypeName>> |
SqlTypeAssignmentRules.Builder.sets |
static List<SqlTypeName> |
SqlTypeName.STRING_TYPES |
private static Map<SqlTypeName,SqlTypeExplicitPrecedenceList> |
SqlTypeExplicitPrecedenceList.TYPE_NAME_TO_PRECEDENCE_LIST
Map from SqlTypeName to corresponding precedence list.
|
private List<SqlTypeName> |
MatchReturnTypeInference.typeNames |
private List<SqlTypeName> |
SqlTypeExplicitPrecedenceList.typeNames |
private static Map<String,SqlTypeName> |
SqlTypeName.VALUES_MAP |
static Set<SqlTypeName> |
SqlTypeName.YEAR_INTERVAL_TYPES |
| Modifier and Type | Method and Description |
|---|---|
static SqlTypeName |
SqlTypeName.get(String name)
Looks up a type name from its name.
|
static SqlTypeName |
SqlTypeName.getNameForJdbcType(int jdbcType)
Gets the SqlTypeName corresponding to a JDBC type.
|
SqlTypeName |
AbstractSqlType.getSqlTypeName() |
SqlTypeName |
JavaToSqlTypeConversionRules.lookup(Class javaClass)
Returns a corresponding
SqlTypeName for a given Java class. |
static SqlTypeName |
SqlTypeName.valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static SqlTypeName[] |
SqlTypeName.values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
| Modifier and Type | Method and Description |
|---|---|
private static List<SqlTypeName> |
SqlTypeName.combine(List<SqlTypeName> list0,
List<SqlTypeName> list1) |
(package private) com.google.common.collect.ImmutableSet.Builder<SqlTypeName> |
SqlTypeAssignmentRules.Builder.copyValues(SqlTypeName typeName) |
Collection<SqlTypeName> |
SqlTypeFamily.getTypeNames() |
| Modifier and Type | Method and Description |
|---|---|
(package private) void |
SqlTypeAssignmentRules.Builder.add(SqlTypeName fromType,
Set<SqlTypeName> toTypes) |
private void |
SqlTypeFactoryImpl.assertBasic(SqlTypeName typeName) |
boolean |
SqlTypeAssignmentRules.canCastFrom(SqlTypeName to,
SqlTypeName from)
Returns whether it is valid to cast a value of from type
from to
type to. |
boolean |
SqlTypeAssignmentRules.canCastFrom(SqlTypeName to,
SqlTypeName from,
boolean coerce)
Deprecated.
|
(package private) com.google.common.collect.ImmutableSet.Builder<SqlTypeName> |
SqlTypeAssignmentRules.Builder.copyValues(SqlTypeName typeName) |
RelDataType |
SqlTypeFactoryImpl.createSqlType(SqlTypeName typeName) |
RelDataType |
SqlTypeFactoryImpl.createSqlType(SqlTypeName typeName,
int precision) |
RelDataType |
SqlTypeFactoryImpl.createSqlType(SqlTypeName typeName,
int precision,
int scale) |
static ExplicitReturnTypeInference |
ReturnTypes.explicit(SqlTypeName typeName)
Creates an inference rule which returns a type with no precision or scale,
such as
DATE. |
static ExplicitReturnTypeInference |
ReturnTypes.explicit(SqlTypeName typeName,
int precision)
Creates an inference rule which returns a type with precision but no scale,
such as
VARCHAR(100). |
private static int |
SqlTypeExplicitPrecedenceList.getListPosition(SqlTypeName type,
List<SqlTypeName> list) |
static boolean |
SqlTypeUtil.inCharFamily(SqlTypeName typeName) |
static boolean |
SqlTypeUtil.isOfSameTypeName(SqlTypeName typeName,
RelDataType type)
Returns typeName.equals(type.getSqlTypeName()).
|
private static SqlTypeExplicitPrecedenceList |
SqlTypeExplicitPrecedenceList.list(SqlTypeName... typeNames) |
private static SqlTypeExplicitPrecedenceList |
SqlTypeExplicitPrecedenceList.numeric(SqlTypeName typeName) |
| Modifier and Type | Method and Description |
|---|---|
(package private) void |
SqlTypeAssignmentRules.Builder.add(SqlTypeName fromType,
Set<SqlTypeName> toTypes) |
private static List<SqlTypeName> |
SqlTypeName.combine(List<SqlTypeName> list0,
List<SqlTypeName> list1) |
private static List<SqlTypeName> |
SqlTypeName.combine(List<SqlTypeName> list0,
List<SqlTypeName> list1) |
private static int |
SqlTypeExplicitPrecedenceList.getListPosition(SqlTypeName type,
List<SqlTypeName> list) |
static boolean |
SqlTypeUtil.isOfSameTypeName(Collection<SqlTypeName> typeNames,
RelDataType type)
Returns true if any element in
typeNames matches
type.getSqlTypeName(). |
private static SqlTypeExplicitPrecedenceList |
SqlTypeExplicitPrecedenceList.list(Iterable<SqlTypeName> typeNames) |
| Constructor and Description |
|---|
AbstractSqlType(SqlTypeName typeName,
boolean isNullable,
List<? extends RelDataTypeField> fields)
Creates an AbstractSqlType.
|
BasicSqlType(RelDataTypeSystem typeSystem,
SqlTypeName typeName)
Constructs a type with no parameters.
|
BasicSqlType(RelDataTypeSystem typeSystem,
SqlTypeName typeName,
boolean nullable,
int precision,
int scale)
Internal constructor.
|
BasicSqlType(RelDataTypeSystem typeSystem,
SqlTypeName typeName,
int precision)
Constructs a type with precision/length but no scale.
|
BasicSqlType(RelDataTypeSystem typeSystem,
SqlTypeName typeName,
int precision,
int scale)
Constructs a type with precision/length and scale.
|
MatchReturnTypeInference(int start,
SqlTypeName... typeNames)
Returns the first type of typeName at or after position start (zero
based).
|
ObjectSqlType(SqlTypeName typeName,
SqlIdentifier sqlIdentifier,
boolean nullable,
List<? extends RelDataTypeField> fields,
RelDataTypeComparability comparability)
Constructs an object type.
|
| Constructor and Description |
|---|
MatchReturnTypeInference(int start,
Iterable<SqlTypeName> typeNames)
Returns the first type matching any type in typeNames at or after
position start (zero based).
|
SqlTypeAssignmentRules(Map<SqlTypeName,com.google.common.collect.ImmutableSet<SqlTypeName>> map) |
SqlTypeAssignmentRules(Map<SqlTypeName,com.google.common.collect.ImmutableSet<SqlTypeName>> map) |
SqlTypeExplicitPrecedenceList(Iterable<SqlTypeName> typeNames) |
| Modifier and Type | Method and Description |
|---|---|
RexNode |
RelBuilder.cast(RexNode expr,
SqlTypeName typeName)
Creates an expression that casts an expression to a given type.
|
RexNode |
RelBuilder.cast(RexNode expr,
SqlTypeName typeName,
int precision)
Creates an expression that casts an expression to a type with a given name
and precision or length.
|
RexNode |
RelBuilder.cast(RexNode expr,
SqlTypeName typeName,
int precision,
int scale)
Creates an expression that casts an expression to a type with a given
name, precision and scale.
|
Copyright © 2012–2018 The Apache Software Foundation. All rights reserved.