uk.ac.ucl.cs.uml.jmi.Foundation.Core
Interface StructuralFeature

All Superinterfaces:
Element, ExtObject, Feature, ModelElement, javax.jmi.reflect.RefBaseObject, javax.jmi.reflect.RefFeatured, javax.jmi.reflect.RefObject
All Known Subinterfaces:
Attribute
All Known Implementing Classes:
Attribute_Impl, StructuralFeature_Impl

public interface StructuralFeature
extends Feature

A structural feature refers to a static feature of a model element, such as an attribute. In the metamodel, a StructuralFeature declares a structural aspect of an Instance of a Classifier, such as an Attribute. For example, it specifies the multiplicity and changeability of the StructuralFeature. StructuralFeature is an abstract metaclass.


Method Summary
 ChangeableKind getChangeability()
          Whether the value may be modified after the object is initialized.
 Multiplicity getMultiplicity()
          The possible number of data values for the feature that may be held by an instance.
 OrderingKind getOrdering()
          Specifies whether the set of instances is ordered.
 ScopeKind getTargetScope()
          Specifies whether the targets are ordinary Instances or Classifiers.
 Classifier getType()
          Designates the classifier whose instances are values of the feature.
 void setChangeability(ChangeableKind changeability)
          Setter for atomic property changeability)
 void setMultiplicity(Multiplicity multiplicity)
          Setter for atomic property multiplicity)
 void setOrdering(OrderingKind ordering)
          Setter for atomic property ordering)
 void setTargetScope(ScopeKind targetScope)
          Setter for atomic property targetScope)
 void setType(Classifier type)
          Setter for atomic property type)
 
Methods inherited from interface uk.ac.ucl.cs.uml.jmi.Foundation.Core.Feature
getOwner, getOwnerScope, setOwner, setOwnerScope
 
Methods inherited from interface uk.ac.ucl.cs.uml.jmi.Foundation.Core.ModelElement
getAsArgument, getBehavior, getClientDependency, getComment, getConstraint, getContainer, getDefaultElement, getIsSpecification, getName, getNamespace, getPackage, getPresentation, getReferenceTag, getSourceFlow, getStereotype, getSupplierDependency, getTaggedValue, getTargetFlow, getTemplate, getTemplateArgument, getTemplateParameter, getVisibility, setDefaultElement, setIsSpecification, setName, setNamespace, setTemplate, setVisibility
 
Methods inherited from interface uk.ac.ucl.cs.emofocl.jmi.reflect.extended.ExtObject
extAddObjectListener, extDeepCopy, extDeepCopy, extEquals, extRemoveObjectListener, extValueHash, extVisit
 
Methods inherited from interface javax.jmi.reflect.RefObject
refClass, refDelete, refImmediateComposite, refIsInstanceOf, refOutermostComposite
 
Methods inherited from interface javax.jmi.reflect.RefFeatured
refGetValue, refGetValue, refInvokeOperation, refInvokeOperation, refSetValue, refSetValue
 
Methods inherited from interface javax.jmi.reflect.RefBaseObject
equals, hashCode, refImmediatePackage, refMetaObject, refMofId, refOutermostPackage, refVerifyConstraints
 

Method Detail

getChangeability

ChangeableKind getChangeability()
                                throws javax.jmi.reflect.JmiException
Whether the value may be modified after the object is initialized. Possibilities are: • changeable - No restrictions on modification. • frozen - No values may be added or removed after the object is initialized. • addOnly - Values may be added anytime. No values may be removed after the object is initialized.

Throws:
javax.jmi.reflect.JmiException

setChangeability

void setChangeability(ChangeableKind changeability)
                      throws javax.jmi.reflect.JmiException
Setter for atomic property changeability)

Throws:
javax.jmi.reflect.JmiException

getMultiplicity

Multiplicity getMultiplicity()
                             throws javax.jmi.reflect.JmiException
The possible number of data values for the feature that may be held by an instance. The cardinality of the set of values is an implicit part of the feature. In the common case in which the multiplicity is 1..1, then the feature is a scalar (i.e., it holds exactly one value).

Throws:
javax.jmi.reflect.JmiException

setMultiplicity

void setMultiplicity(Multiplicity multiplicity)
                     throws javax.jmi.reflect.JmiException
Setter for atomic property multiplicity)

Throws:
javax.jmi.reflect.JmiException

getOrdering

OrderingKind getOrdering()
                         throws javax.jmi.reflect.JmiException
Specifies whether the set of instances is ordered. The ordering must be determined and maintained by Operations that add values to the feature. This property is only relevant if the multiplicity is greater than one. Possibilities are: • unordered - The instances form a set with no inherent ordering. • ordered - A set of ordered instances can be scanned in order. • Other possibilities (such as sorted) may be defined later by declaring additional keywords. As with user-defined stereotypes, this would be a private extension supported by particular editing tools.

Throws:
javax.jmi.reflect.JmiException

setOrdering

void setOrdering(OrderingKind ordering)
                 throws javax.jmi.reflect.JmiException
Setter for atomic property ordering)

Throws:
javax.jmi.reflect.JmiException

getTargetScope

ScopeKind getTargetScope()
                         throws javax.jmi.reflect.JmiException
Specifies whether the targets are ordinary Instances or Classifiers. Possibilities are: • instance - Each value contains a reference to an Instance of the target Classifier. This is the setting for a normal Attribute. • classifier - Each value contains a reference to the target Classifier itself. This represents a way to store meta-information.

Throws:
javax.jmi.reflect.JmiException

setTargetScope

void setTargetScope(ScopeKind targetScope)
                    throws javax.jmi.reflect.JmiException
Setter for atomic property targetScope)

Throws:
javax.jmi.reflect.JmiException

getType

Classifier getType()
                   throws javax.jmi.reflect.JmiException
Designates the classifier whose instances are values of the feature. Must be a Class, Interface, or DataType. The actual type may be a descendant of the declared type or (for an Interface) a Class that realizes the declared type.

Throws:
javax.jmi.reflect.JmiException

setType

void setType(Classifier type)
             throws javax.jmi.reflect.JmiException
Setter for atomic property type)

Throws:
javax.jmi.reflect.JmiException