Annotation Type MapKey


@Target({METHOD,FIELD}) @Retention(RUNTIME) @Deprecated public @interface MapKey
Deprecated.
Use MapKeyColumn This is the default behavior for Map properties marked as @OneToMany, @ManyToMany or @ElementCollection
Define the map key columns as an explicit column holding the map key This is completely different from MapKey which use an existing column This annotation and MapKey are mutually exclusive
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    Deprecated.
     
    Deprecated.
    Represent the key class in a Map Only useful if the collection does not use generics
    Deprecated.
    The optional map key type.
  • Element Details

    • columns

      Deprecated.
      Default:
      {}
    • targetElement

      Class targetElement
      Deprecated.
      Represent the key class in a Map Only useful if the collection does not use generics
      Default:
      void.class
    • type

      Type type
      Deprecated.
      The optional map key type. Guessed if default
      Default:
      @org.hibernate.annotations.Type(type="")