## org.eclipse.emf.ocl.internal.parser
Class CompatibilityTypeResolver

    java.lang.Object
      org.eclipse.emf.ocl.internal.parser.CompatibilityTypeResolver

All Implemented Interfaces:
  TypeResolver<EClassifier,EOperation,EStructuralFeature>

    public class CompatibilityTypeResolver

extends Object
implements TypeResolver<EClassifier,EOperation,EStructuralFeature>

Constructor Summary
`CompatibilityTypeResolver(Environment env, TypeResolver oldStyle)`

Method Summary
`List<EStructuralFeature>` `getAdditionalAttributes(EClassifier owner)` Obtains the additional attributes defined (via OCL) in the specified classifier context.
`List<EOperation>` `getAdditionalOperations(EClassifier owner)` Obtains the additional operations defined (via OCL) in the specified classifier context.
`Resource` `getResource()` Obtains the resource in which the types that I generate are stored for persistence.
`EClassifier` `resolve(EClassifier type)` Resolves the specified `type`, returning my own persistent type instance representing the same OCL type.
`EStructuralFeature` `resolveAdditionalAttribute(EClassifier owner, EStructuralFeature property)` Resolves the specified "additional attribute" defined by the OCL client on the specified `owner` type.
`EOperation` `resolveAdditionalOperation(EClassifier owner, EOperation operation)` Resolves the specified "additional operation" defined by the OCL client on the specified `owner` type.
`CollectionType<EClassifier,EOperation>` `resolveCollectionType(CollectionKind kind, EClassifier elementType)` Resolves the collection type of the specified `kind` and element type, either created anew or previously created.
`MessageType<EClassifier,EOperation,EStructuralFeature>` `resolveOperationMessageType(EOperation operation)` Resolves the type for a message expression referencing the specified `operation`.
`MessageType<EClassifier,EOperation,EStructuralFeature>` `resolveSignalMessageType(EClassifier signal)` Resolves the type for a message expression referencing the specified `signal`.
`TupleType<EOperation,EStructuralFeature>` `resolveTupleType(EList<? extends TypedElement<EClassifier>> parts)` Resolves the tuple type consisting of the specified `parts`, in no particular order, either created anew or previously created.
`TypeType<EClassifier,EOperation>` `resolveTypeType(EClassifier type)` Resolves the type for a type expression referencing the specified `type`.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### CompatibilityTypeResolver

    public CompatibilityTypeResolver(Environment env,
                                     TypeResolver oldStyle)

Method Detail

### getResource

    public Resource getResource()

  Description copied from interface: `TypeResolver`
  Obtains the resource in which the types that I generate are stored for persistence.

  Specified by:
    `getResource` in interface `TypeResolver<EClassifier,EOperation,EStructuralFeature>`
  Returns:
    my resource

### resolve

    public EClassifier resolve(EClassifier type)

  Description copied from interface: `TypeResolver`
  Resolves the specified `type`, returning my own persistent type instance representing the same OCL type.

  The `type` may have been newly created by the parser and be a duplicate of a type previously resolved, or it may actually be a type that was previously resolved. In the latter case, the `type` is returned as is. The `null` type is considered to be resolved (i.e., the result is also `null`).

  Usually, this method will delegate to one of the `resolveXyzType()` methods defined by this interface.

  Specified by:
    `resolve` in interface `TypeResolver<EClassifier,EOperation,EStructuralFeature>`
  Parameters:
    `type` - a type to resolve
  Returns:
    the resolved type, or `type` if it is already resolved

### resolveAdditionalOperation

    public EOperation resolveAdditionalOperation(EClassifier owner,
                                                 EOperation operation)

  Description copied from interface: `TypeResolver`
  Resolves the specified "additional operation" defined by the OCL client on the specified `owner` type.

  Specified by:
    `resolveAdditionalOperation` in interface `TypeResolver<EClassifier,EOperation,EStructuralFeature>`
  Parameters:
    `owner` - the type on which the additional operation is defined
    `operation` - the additional operation
  Returns:
    the persistent operation

### getAdditionalOperations

    public List<EOperation> getAdditionalOperations(EClassifier owner)

  Description copied from interface: `TypeResolver`
  Obtains the additional operations defined (via OCL) in the specified classifier context.

  Specified by:
    `getAdditionalOperations` in interface `TypeResolver<EClassifier,EOperation,EStructuralFeature>`
  Parameters:
    `owner` - the context classifier
  Returns:
    its additional operations, or an empty list if none

### resolveAdditionalAttribute

    public EStructuralFeature resolveAdditionalAttribute(EClassifier owner,
                                                         EStructuralFeature property)

  Description copied from interface: `TypeResolver`
  Resolves the specified "additional attribute" defined by the OCL client on the specified `owner` type.

  Specified by:
    `resolveAdditionalAttribute` in interface `TypeResolver<EClassifier,EOperation,EStructuralFeature>`
  Parameters:
    `owner` - the type on which the additional attribute is defined
    `property` - the additional attribute
  Returns:
    the persistent attribute

### getAdditionalAttributes

    public List<EStructuralFeature> getAdditionalAttributes(EClassifier owner)

  Description copied from interface: `TypeResolver`
  Obtains the additional attributes defined (via OCL) in the specified classifier context.

  Specified by:
    `getAdditionalAttributes` in interface `TypeResolver<EClassifier,EOperation,EStructuralFeature>`
  Parameters:
    `owner` - the context classifier
  Returns:
    its additional attributes, or an empty list if none

### resolveCollectionType

    public CollectionType<EClassifier,EOperation> resolveCollectionType(CollectionKind kind,
                                                                        EClassifier elementType)

  Description copied from interface: `TypeResolver`
  Resolves the collection type of the specified `kind` and element type, either created anew or previously created.

  Specified by:
    `resolveCollectionType` in interface `TypeResolver<EClassifier,EOperation,EStructuralFeature>`
  Parameters:
    `kind` - the kind of collection type to create
    `elementType` - the element type
  Returns:
    the new or existing collection type

### resolveOperationMessageType

    public MessageType<EClassifier,EOperation,EStructuralFeature> resolveOperationMessageType(EOperation operation)

  Description copied from interface: `TypeResolver`
  Resolves the type for a message expression referencing the specified `operation`.

  Specified by:
    `resolveOperationMessageType` in interface `TypeResolver<EClassifier,EOperation,EStructuralFeature>`
  Parameters:
    `operation` - the operation call that the message represents
  Returns:
    the new or existing message type

### resolveSignalMessageType

    public MessageType<EClassifier,EOperation,EStructuralFeature> resolveSignalMessageType(EClassifier signal)

  Description copied from interface: `TypeResolver`
  Resolves the type for a message expression referencing the specified `signal`.

  Specified by:
    `resolveSignalMessageType` in interface `TypeResolver<EClassifier,EOperation,EStructuralFeature>`
  Parameters:
    `signal` - the signal send that the message represents
  Returns:
    the new or existing message type

### resolveTupleType

    public TupleType<EOperation,EStructuralFeature> resolveTupleType(EList<? extends TypedElement<EClassifier>> parts)

  Description copied from interface: `TypeResolver`
  Resolves the tuple type consisting of the specified `parts`, in no particular order, either created anew or previously created. The resulting type is uniquely defined by the names and types of its parts, and twp tuple types are considered equal if they have the same number of parts and their parts correspond one-for-one in name and type (order is not significant).

  Specified by:
    `resolveTupleType` in interface `TypeResolver<EClassifier,EOperation,EStructuralFeature>`
  Parameters:
    `parts` - a list of `TypedElement`s defining the name and type of each tuple part. The part names are unique
  Returns:
    the new or existing tuple type

### resolveTypeType

    public TypeType<EClassifier,EOperation> resolveTypeType(EClassifier type)

  Description copied from interface: `TypeResolver`
  Resolves the type for a type expression referencing the specified `type`. This is, effectively, the OCL metatype counterpart for the specified model type.

  Specified by:
    `resolveTypeType` in interface `TypeResolver<EClassifier,EOperation,EStructuralFeature>`
  Parameters:
    `type` - a model type
  Returns:
    the new or existing type type

Copyright 2002, 2007 IBM Corporation and others. All Rights Reserved.