Class ColumnSpec

java.lang.Object
org.apache.druid.catalog.model.ColumnSpec

public class ColumnSpec extends Object
Specification of table columns.
  • Constructor Details

  • Method Details

    • name

      public String name()
    • dataType

      public String dataType()
    • properties

      public Map<String,Object> properties()
    • validate

      public void validate()
    • merge

      public ColumnSpec merge(Map<String,ModelProperties.PropertyDefn<?>> columnProperties, ColumnSpec update)
      Merges an updated version of this column with an existing version.

      The name cannot be changed (it is what links the existing column and the update). The SQL type will be that provided in the update, if non-null, else the original type. Properties are merged using standard rules: those in the update take precedence. Null values in the update remove the existing property, non-null values update the property. Any properties in the update but not in the existing set, are inserted (if non-null).

    • toString

      public String toString()
      Overrides:
      toString in class Object
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object