## org.eclipse.uml2.uml
Interface Slot

All Superinterfaces:
  Element, org.eclipse.emf.ecore.EModelElement, org.eclipse.emf.ecore.EObject, org.eclipse.emf.common.notify.Notifier

    public interface Slot

extends Element

A representation of the model object 'Slot'. A slot specifies that an entity modeled by an instance specification has a value or values for a specific structural feature.

The following features are supported:

- `Defining Feature`
- `Value`
- `Owning Instance`

See Also:
  `UMLPackage.getSlot()`

Method Summary
`ValueSpecification` `createValue(java.lang.String name, Type type, org.eclipse.emf.ecore.EClass eClass)` Creates a new `ValueSpecification`, with the specified 'Name', and 'Type', and appends it to the 'Value' containment reference list
`StructuralFeature` `getDefiningFeature()` Returns the value of the 'Defining Feature' reference
`InstanceSpecification` `getOwningInstance()` Returns the value of the 'Owning Instance' container reference.
`ValueSpecification` `getValue(java.lang.String name, Type type)` Retrieves the first `ValueSpecification` with the specified 'Name', and 'Type' from the 'Value' containment reference list
`ValueSpecification` `getValue(java.lang.String name, Type type, boolean ignoreCase, org.eclipse.emf.ecore.EClass eClass, boolean createOnDemand)` Retrieves the first `ValueSpecification` with the specified 'Name', and 'Type' from the 'Value' containment reference list
`org.eclipse.emf.common.util.EList<ValueSpecification>` `getValues()` Returns the value of the 'Value' containment reference list.
`void` `setDefiningFeature(StructuralFeature value)` Sets the value of the '`Defining Feature`' reference
`void` `setOwningInstance(InstanceSpecification value)` Sets the value of the '`Owning Instance`' container reference

Methods inherited from interface org.eclipse.uml2.uml.Element

`addKeyword, allOwnedElements, applyStereotype, createEAnnotation, createOwnedComment, destroy, getApplicableStereotype, getApplicableStereotypes, getAppliedStereotype, getAppliedStereotypes, getAppliedSubstereotype, getAppliedSubstereotypes, getKeywords, getModel, getNearestPackage, getOwnedComments, getOwnedElements, getOwner, getRelationships, getRelationships, getRequiredStereotype, getRequiredStereotypes, getSourceDirectedRelationships, getSourceDirectedRelationships, getStereotypeApplication, getStereotypeApplications, getTargetDirectedRelationships, getTargetDirectedRelationships, getValue, hasKeyword, hasValue, isStereotypeApplicable, isStereotypeApplied, isStereotypeRequired, mustBeOwned, removeKeyword, setValue, unapplyStereotype, validateHasOwner, validateNotOwnSelf`

Methods inherited from interface org.eclipse.emf.ecore.EModelElement
`getEAnnotation, getEAnnotations`

Methods inherited from interface org.eclipse.emf.ecore.EObject
`eAllContents, eClass, eContainer, eContainingFeature, eContainmentFeature, eContents, eCrossReferences, eGet, eGet, eIsProxy, eIsSet, eResource, eSet, eUnset`

Methods inherited from interface org.eclipse.emf.common.notify.Notifier
`eAdapters, eDeliver, eNotify, eSetDeliver`

Method Detail

### getOwningInstance

    InstanceSpecification getOwningInstance()

  Returns the value of the 'Owning Instance' container reference. It is bidirectional and its opposite is '`Slot`'. The instance specification that owns this slot.

  Returns:
    the value of the 'Owning Instance' container reference.
  See Also:
    `setOwningInstance(InstanceSpecification)`, `UMLPackage.getSlot_OwningInstance()`, `InstanceSpecification.getSlots()`

### setOwningInstance

    void setOwningInstance(InstanceSpecification value)

  Sets the value of the '`Owning Instance`' container reference.

  Parameters:
    `value` - the new value of the 'Owning Instance' container reference.
  See Also:
    `getOwningInstance()`

### getDefiningFeature

    StructuralFeature getDefiningFeature()

  Returns the value of the 'Defining Feature' reference. The structural feature that specifies the values that may be held by the slot.

  Returns:
    the value of the 'Defining Feature' reference.
  See Also:
    `setDefiningFeature(StructuralFeature)`, `UMLPackage.getSlot_DefiningFeature()`

### setDefiningFeature

    void setDefiningFeature(StructuralFeature value)

  Sets the value of the '`Defining Feature`' reference.

  Parameters:
    `value` - the new value of the 'Defining Feature' reference.
  See Also:
    `getDefiningFeature()`

### getValues

    org.eclipse.emf.common.util.EList<ValueSpecification> getValues()

  Returns the value of the 'Value' containment reference list. The list contents are of type `ValueSpecification`. The value or values corresponding to the defining feature for the owning instance specification.

  Returns:
    the value of the 'Value' containment reference list.
  See Also:
    `UMLPackage.getSlot_Value()`

### createValue

    ValueSpecification createValue(java.lang.String name,
                                   Type type,
                                   org.eclipse.emf.ecore.EClass eClass)

  Creates a new `ValueSpecification`, with the specified 'Name', and 'Type', and appends it to the 'Value' containment reference list.

  Parameters:
    `name` - The 'Name' for the new `ValueSpecification`, or `null`.
    `type` - The 'Type' for the new `ValueSpecification`, or `null`.
    `eClass` - The Ecore class of the `ValueSpecification` to create.
  Returns:
    The new `ValueSpecification`.
  See Also:
    `getValues()`

### getValue

    ValueSpecification getValue(java.lang.String name,
                                Type type)

  Retrieves the first `ValueSpecification` with the specified 'Name', and 'Type' from the 'Value' containment reference list.

  Parameters:
    `name` - The 'Name' of the `ValueSpecification` to retrieve, or `null`.
    `type` - The 'Type' of the `ValueSpecification` to retrieve, or `null`.
  Returns:
    The first `ValueSpecification` with the specified 'Name', and 'Type', or `null`.
  See Also:
    `getValues()`

### getValue

    ValueSpecification getValue(java.lang.String name,
                                Type type,
                                boolean ignoreCase,
                                org.eclipse.emf.ecore.EClass eClass,
                                boolean createOnDemand)

  Retrieves the first `ValueSpecification` with the specified 'Name', and 'Type' from the 'Value' containment reference list.

  Parameters:
    `name` - The 'Name' of the `ValueSpecification` to retrieve, or `null`.
    `type` - The 'Type' of the `ValueSpecification` to retrieve, or `null`.
    `ignoreCase` - Whether to ignore case in `String` comparisons.
    `eClass` - The Ecore class of the `ValueSpecification` to retrieve, or `null`.
    `createOnDemand` - Whether to create a `ValueSpecification` on demand if not found.
  Returns:
    The first `ValueSpecification` with the specified 'Name', and 'Type', or `null`.
  See Also:
    `getValues()`

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