org.qi4j.api.query.grammar

## Class AssociationFunction<T>

- java.lang.Object
- - org.qi4j.api.query.grammar.AssociationFunction<T>

- All Implemented Interfaces:
    Function<Composite,Association<T>>

      public class AssociationFunction<T>
      extends Object
      implements Function<Composite,Association<T>>

  Function to get Entity Associations

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `AssociationFunction(AssociationFunction<?> traversedAssociation, ManyAssociationFunction<?> traversedManyAssociation, NamedAssociationFunction<?> traversedNamedAssociation, AccessibleObject accessor)`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `AccessibleObject` | `accessor()`
    `Association<T>` | `map(Composite entity)` Map a single item from one type to another
    `String` | `toString()`
    `AssociationFunction<?>` | `traversedAssociation()`
    `ManyAssociationFunction<?>` | `traversedManyAssociation()`
    `NamedAssociationFunction<?>` | `traversedNamedAssociation()`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### AssociationFunction

          public AssociationFunction(AssociationFunction<?> traversedAssociation,
                             ManyAssociationFunction<?> traversedManyAssociation,
                             NamedAssociationFunction<?> traversedNamedAssociation,
                             AccessibleObject accessor)

  - ### Method Detail

    - #### traversedAssociation

          public AssociationFunction<?> traversedAssociation()

    - #### traversedManyAssociation

          public ManyAssociationFunction<?> traversedManyAssociation()

    - #### traversedNamedAssociation

          public NamedAssociationFunction<?> traversedNamedAssociation()

    - #### accessor

          public AccessibleObject accessor()

    - #### map

          public Association<T> map(Composite entity)

      Description copied from interface: `Function`
      Map a single item from one type to another
      Specified by:
        `map` in interface `Function<Composite,Association<T>>`
      Parameters:
        `entity` - the input item
      Returns:
        the mapped item

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`