public static class LogicalTypes.Decimal extends LogicalType
LOGICAL_TYPE_PROP| Modifier and Type | Method and Description |
|---|---|
Schema |
addToSchema(Schema schema)
Add this logical type to the given Schema.
|
boolean |
equals(Object o) |
int |
getPrecision() |
int |
getScale() |
int |
hashCode() |
void |
validate(Schema schema)
Validate this logical type for the given Schema.
|
getNamepublic Schema addToSchema(Schema schema)
LogicalTypeThe "logicalType" property will be set to this type's name, and other type-specific properties may be added. The Schema is first validated to ensure it is compatible.
addToSchema in class LogicalTypeschema - a Schemapublic int getPrecision()
public int getScale()
public void validate(Schema schema)
LogicalTypeThis will throw an exception if the Schema is incompatible with this type. For example, a date is stored as an int and is incompatible with a fixed Schema.
validate in class LogicalTypeschema - a SchemaCopyright © 2009–2023 The Apache Software Foundation. All rights reserved.