## org.opengis.feature.type
Interface AssociationType

All Superinterfaces:
  PropertyType

    public interface AssociationType

extends PropertyType

Association information, immutable.

The model must recognise the following specific Association types:

- aggregation
- spatial
- temporal

Note that as usual multiplicity is left for the AssociationDescriptor, this class is used to capture relationships between types.

Note: I am treating the domain of the association type similar to that of Attribute Type, the intention is to indicate the relationship that a FeatureCollection has with its contents (specifically a memberOf).

Care should be taken with associations, keep the aggregation, spatial, temporal goal in mind:

- aggregation: a university may contain the buildings
- spatial: "touches" the current feature would be used in a graph package
- temporal: "before" the current feature would be used in a versioning system

You should not use Associations to capture information such as "super" as this represents a relationship of abstractions used to define a type, with associations we are aiming to let you describe how the types in your system are related.

You may gather associations into a hierarchy and refine where needed, thus a lake could be associated with "connected" rivers, and thus refined with "up stream" and "down stream".

Method Summary
`AttributeType` `getReferenceType()` AttributeType related by this association.
`Set<Filter>` `getRestrictions()` List of restrictions used to limit the allowable values for objects of this type.
`AssociationType` `getSuper()` Access to super type information.
`boolean` `isAbstract()` Indicate that this AttributeType may not be used directly.
`boolean` `isIdentified()` True if this type is usable as a target of a reference.

Methods inherited from interface PropertyType
`equals, getDescription, getName, getUserData, hashCode, putUserData`

Method Detail

### isIdentified

    boolean isIdentified()

  True if this type is usable as a target of a reference.

  Returns:
    true if this complex type must have non null getID()

### getSuper

    AssociationType getSuper()

  Access to super type information.

  The super type may contain additional restrictions to be considered, or a definition of isNilable.

  Specified by:
    `getSuper` in interface `PropertyType`
  Returns:
    AttributeType of supertype

### isAbstract

    boolean isAbstract()

  Indicate that this AttributeType may not be used directly.

  An example abstract association would be "spatial" which would need to be sub typed to indicate "touches" or "contained".

  Specified by:
    `isAbstract` in interface `PropertyType`

### getReferenceType

    AttributeType getReferenceType()

  AttributeType related by this association.

  This is the AttributeType you are in effect pointing to by using an association.

### getRestrictions

    Set<Filter> getRestrictions()

  List of restrictions used to limit the allowable values for objects of this type.

  These restrictions should be considered in light of those available through getSuper, in the case where Restrictions conflict these should be considered complete overrides of the restrictions available via the getSuper.

  Specified by:
    `getRestrictions` in interface `PropertyType`
  Returns:
    List<Restriction> used to validate allowable values.

Copyright © 1994-2008 Open Geospatial Consortium. All Rights Reserved.