Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: REQUIRED | OPTIONAL | DETAIL: ELEMENT

## org.hibernate.annotations
Annotation Type ManyToAny

    @Target(value={METHOD,FIELD})
    @Retention(value=RUNTIME)
    public @interface ManyToAny

Defined a ToMany association pointing to different entity types. Matching the according entity type is doe through a metadata discriminator column This kind of mapping should be only marginal.

Author:
  Emmanuel Bernard

Required Element Summary
`javax.persistence.Column` | `metaColumn` Metadata dicriminator column description, This column will hold the meta value corresponding to the targeted entity.

Optional Element Summary
`javax.persistence.FetchType` | `fetch` Defines whether the value of the field or property should be lazily loaded or must be eagerly fetched.
`String` | `metaDef` Metadata definition used.

Element Detail

### metaColumn

    public abstract javax.persistence.Column metaColumn

  Metadata dicriminator column description, This column will hold the meta value corresponding to the targeted entity.

### metaDef

    public abstract String metaDef

  Metadata definition used. If defined, should point to a @AnyMetaDef name If not defined, the local (ie in the same field or property) @AnyMetaDef is used

  Default:
    ""

### fetch

    public abstract javax.persistence.FetchType fetch

  Defines whether the value of the field or property should be lazily loaded or must be eagerly fetched. The EAGER strategy is a requirement on the persistence provider runtime that the value must be eagerly fetched. The LAZY strategy is applied when bytecode enhancement is used. If not specified, defaults to EAGER.

  Default:
    EAGER

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: REQUIRED | OPTIONAL | DETAIL: ELEMENT