case class Attribute(name: String, type: String = "string", array: Option[Boolean] = None, required: Boolean = true, privacy: PrivacyLevel = PrivacyLevel.None, comment: Option[String] = None, rename: Option[String] = None, metricType: Option[MetricType] = None, attributes: Option[List[Attribute]] = None, position: Option[Position] = None, default: Option[String] = None, tags: Option[Set[String]] = None, trim: Option[Trim] = None, script: Option[String] = None, foreignKey: Option[String] = None, ignore: Option[Boolean] = None) extends LazyLogging with Product with Serializable

A field in the schema. For struct fields, the field "attributes" contains all sub attributes

name

: Attribute name as defined in the source dataset and as received in the file

array

: Is it an array ?

required

: Should this attribute always be present in the source

privacy

: Should this attribute be applied a privacy transformation at ingestion time

comment

: free text for attribute description

rename

: If present, the attribute is renamed with this name

metricType

: If present, what kind of stat should be computed for this field

attributes

: List of sub-attributes (valid for JSON and XML files only)

position

: Valid only when file format is POSITION

default

: Default value for this attribute when it is not present.

tags

: Tags associated with this attribute

trim

: Should we trim the attribute value ?

script

: Scripted field : SQL request on renamed column

Linear Supertypes
Serializable, Serializable, Product, Equals, LazyLogging, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Attribute
  2. Serializable
  3. Serializable
  4. Product
  5. Equals
  6. LazyLogging
  7. AnyRef
  8. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new Attribute(name: String, type: String = "string", array: Option[Boolean] = None, required: Boolean = true, privacy: PrivacyLevel = PrivacyLevel.None, comment: Option[String] = None, rename: Option[String] = None, metricType: Option[MetricType] = None, attributes: Option[List[Attribute]] = None, position: Option[Position] = None, default: Option[String] = None, tags: Option[Set[String]] = None, trim: Option[Trim] = None, script: Option[String] = None, foreignKey: Option[String] = None, ignore: Option[Boolean] = None)

    name

    : Attribute name as defined in the source dataset and as received in the file

    array

    : Is it an array ?

    required

    : Should this attribute always be present in the source

    privacy

    : Should this attribute be applied a privacy transformation at ingestion time

    comment

    : free text for attribute description

    rename

    : If present, the attribute is renamed with this name

    metricType

    : If present, what kind of stat should be computed for this field

    attributes

    : List of sub-attributes (valid for JSON and XML files only)

    position

    : Valid only when file format is POSITION

    default

    : Default value for this attribute when it is not present.

    tags

    : Tags associated with this attribute

    trim

    : Should we trim the attribute value ?

    script

    : Scripted field : SQL request on renamed column

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. val array: Option[Boolean]
  5. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  6. val attributes: Option[List[Attribute]]
  7. def checkValidity(schemaHandler: SchemaHandler): Either[List[String], Boolean]

    Check attribute validity An attribute is valid if :

    Check attribute validity An attribute is valid if :

    • Its name is a valid identifier
    • its type is defined
    • When a privacy function is defined its primitive type is a string
    returns

    true if attribute is valid

  8. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()
  9. val comment: Option[String]
  10. val default: Option[String]
  11. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  12. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  13. val foreignKey: Option[String]
  14. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  15. def getFinalName(): String

    returns

    renamed column if defined, source name otherwise

    Annotations
    @JsonIgnore()
  16. def getMetricType(schemaHandler: SchemaHandler): MetricType
    Annotations
    @JsonIgnore()
  17. def getPrivacy(): PrivacyLevel
  18. val ignore: Option[Boolean]
  19. def isArray(): Boolean
  20. def isIgnore(): Boolean
  21. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  22. def isRequired(): Boolean
  23. lazy val logger: Logger
    Attributes
    protected
    Definition Classes
    LazyLogging
    Annotations
    @transient()
  24. def mapping(schemaHandler: SchemaHandler): String
  25. val metricType: Option[MetricType]
  26. val name: String
  27. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  28. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  29. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  30. val position: Option[Position]
  31. def primitiveSparkType(schemaHandler: SchemaHandler): DataType

    Spark Type if this attribute is a primitive type of array of primitive type

    Spark Type if this attribute is a primitive type of array of primitive type

    returns

    Primitive type if attribute is a leaf node or array of primitive type, None otherwise

  32. val privacy: PrivacyLevel
  33. val rename: Option[String]
  34. val required: Boolean
  35. val script: Option[String]
  36. def sparkType(schemaHandler: SchemaHandler): DataType

    Go get recursively the Spark tree type of this object

    Go get recursively the Spark tree type of this object

    returns

    Spark type of this attribute

  37. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  38. val tags: Option[Set[String]]
  39. def toString(): String
    Definition Classes
    Attribute → AnyRef → Any
  40. def tpe(schemaHandler: SchemaHandler): Option[Type]
  41. val trim: Option[Trim]
  42. val type: String
  43. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  44. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  45. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()

Inherited from Serializable

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from LazyLogging

Inherited from AnyRef

Inherited from Any

Ungrouped