@InterfaceAudience.Public @InterfaceStability.Evolving public enum Type extends Enum<Type>
Enum Constant and Description |
---|
BINARY |
BOOL |
DECIMAL |
DOUBLE |
FLOAT |
INT16 |
INT32 |
INT64 |
INT8 |
STRING |
UNIXTIME_MICROS |
Modifier and Type | Method and Description |
---|---|
org.apache.kudu.Common.DataType |
getDataType()
Deprecated.
|
org.apache.kudu.Common.DataType |
getDataType(ColumnTypeAttributes typeAttributes)
Get the data type from the common's pb
|
String |
getName()
Get the string representation of this type
|
int |
getSize()
Deprecated.
|
int |
getSize(ColumnTypeAttributes typeAttributes)
The size of this type on the wire
|
static Type |
getTypeForDataType(org.apache.kudu.Common.DataType type)
Convert the pb DataType to a Type
|
String |
toString() |
static Type |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static Type[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final Type INT8
public static final Type INT16
public static final Type INT32
public static final Type INT64
public static final Type BINARY
public static final Type STRING
public static final Type BOOL
public static final Type FLOAT
public static final Type DOUBLE
public static final Type UNIXTIME_MICROS
public static final Type DECIMAL
public static Type[] values()
for (Type c : Type.values()) System.out.println(c);
public static Type valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic org.apache.kudu.Common.DataType getDataType()
getDataType(ColumnTypeAttributes)
public org.apache.kudu.Common.DataType getDataType(ColumnTypeAttributes typeAttributes)
typeAttributes
- the additional attributes of the type.public String getName()
public int getSize()
getSize(ColumnTypeAttributes)
public int getSize(ColumnTypeAttributes typeAttributes)
typeAttributes
- the additional attributes of the type.public static Type getTypeForDataType(org.apache.kudu.Common.DataType type)
type
- DataType to convertCopyright © 2018 The Apache Software Foundation. All rights reserved.