Tabnine Logo
RelDataTypeFactory.copyType
Code IndexAdd Tabnine to your IDE (free)

How to use
copyType
method
in
org.apache.calcite.rel.type.RelDataTypeFactory

Best Java code snippets using org.apache.calcite.rel.type.RelDataTypeFactory.copyType (Showing top 6 results out of 315)

origin: Qihoo360/Quicksql

/**
 * Returns an implementation of
 * {@link RelProtoDataType}
 * that copies a given type using the given type factory.
 */
public static RelProtoDataType proto(final RelDataType protoType) {
 assert protoType != null;
 return typeFactory -> typeFactory.copyType(protoType);
}
origin: org.apache.calcite/calcite-core

/**
 * Returns an implementation of
 * {@link RelProtoDataType}
 * that copies a given type using the given type factory.
 */
public static RelProtoDataType proto(final RelDataType protoType) {
 assert protoType != null;
 return typeFactory -> typeFactory.copyType(protoType);
}
origin: dremio/dremio-oss

public RelDataType copyOf(RelDataType type) {
 return cluster.getTypeFactory().copyType(type);
}
origin: Qihoo360/Quicksql

private RelDataType copy(RelDataType type) {
 return builder.getTypeFactory().copyType(type);
}
origin: org.apache.calcite/calcite-core

private RelDataType copy(RelDataType type) {
 return builder.getTypeFactory().copyType(type);
}
origin: dremio/dremio-oss

@Override
public T read(final Kryo kryo, final Input input, final Class<T> type) {
 // do not use delegate.read because we do not want it to cache the object. Rather, we will cache the normalized type.
 final T dataType = kryo.newInstance(type);
 final FieldSerializer.CachedField[] fields = delegate.getFields();
 for (int i = 0, n = fields.length; i < n; i++) {
  fields[i].read(input, dataType);
 }
 // be gentle to calcite and normalize the returned data type. normalization here means to use same type instances.
 final T result = (T) typeFactory.copyType(dataType);
 kryo.reference(result);
 return result;
}
org.apache.calcite.rel.typeRelDataTypeFactorycopyType

Javadoc

Duplicates a type, making a deep copy. Normally, this is a no-op, since canonical type objects are returned. However, it is useful when copying a type from one factory to another.

Popular methods of RelDataTypeFactory

  • createSqlType
    Creates a SQL type with precision and scale.
  • createTypeWithNullability
    Creates a type that is the same as another type but with possibly different nullability. The output
  • createStructType
    Creates a type that represents a structured collection of fields, given lists of the names and types
  • builder
    Creates a org.apache.calcite.rel.type.RelDataTypeFactory.FieldInfoBuilder. But since FieldInfoBuilde
  • createMapType
    Creates a map type. Maps are unordered collections of key/value pairs.
  • getTypeSystem
    Returns the type system.
  • createArrayType
    Creates an array type. Arrays are ordered collections of elements.
  • createJavaType
    Creates a type that corresponds to a Java class.
  • createSqlIntervalType
    Creates a SQL interval type.
  • createTypeWithCharsetAndCollation
    Creates a type that is the same as another type but with possibly different charset or collation. Fo
  • leastRestrictive
    Returns the most general of a set of types (that is, one type to which they can all be cast), or nul
  • createMultisetType
    Creates a multiset type. Multisets are unordered collections of elements.
  • leastRestrictive,
  • createMultisetType,
  • createUnknownType,
  • getDefaultCharset,
  • createJoinType,
  • useDoubleMultiplication

Popular in Java

  • Reading from database using SQL prepared statement
  • setRequestProperty (URLConnection)
  • requestLocationUpdates (LocationManager)
  • setContentView (Activity)
  • HttpServer (com.sun.net.httpserver)
    This class implements a simple HTTP server. A HttpServer is bound to an IP address and port number a
  • Thread (java.lang)
    A thread is a thread of execution in a program. The Java Virtual Machine allows an application to ha
  • Socket (java.net)
    Provides a client-side TCP socket.
  • Connection (java.sql)
    A connection represents a link from a Java application to a database. All SQL statements and results
  • Time (java.sql)
    Java representation of an SQL TIME value. Provides utilities to format and parse the time's represen
  • Modifier (javassist)
    The Modifier class provides static methods and constants to decode class and member access modifiers
  • Top plugins for Android Studio
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now