Annotation Type ElementCollection


@Retention(CLASS) @Target(FIELD) public @interface ElementCollection
Mapping for an owned collection of scalar values.
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    Names the scalar value column in the collection table.
    Controls relationship initialization.
  • Element Details

    • fetch

      FetchType fetch
      Controls relationship initialization.
      Returns:
      fetch policy; EAGER for to-one and LAZY for collections by default
      Default:
      LAZY
    • column

      String column
      Names the scalar value column in the collection table.
      Returns:
      column name; element_value by default
      Default:
      "element_value"