org.eclipse.uml2
Interface Classifier

All Superinterfaces:
Element, EModelElement, EObject, NamedElement, Namespace, Notifier, PackageableElement, ParameterableElement, RedefinableElement, TemplateableElement, Type
All Known Subinterfaces:
Activity, Actor, Artifact, Association, AssociationClass, Behavior, BehavioredClassifier, Class, Collaboration, CommunicationPath, Component, DataType, DeploymentSpecification, Device, EncapsulatedClassifier, Enumeration, ExecutionEnvironment, Extension, InformationItem, Interaction, Interface, Node, ParameterableClassifier, PrimitiveType, ProtocolStateMachine, Signal, StateMachine, Stereotype, StructuredClassifier, TemplateableClassifier, UseCase

public interface Classifier
extends Namespace, Type, RedefinableElement

A representation of the model object 'Classifier'. A classifier is a namespace whose members can include features. Classifier is an abstract metaclass. A classifier is a type and can own generalizations, thereby making it possible to define generalization relationships to other classifiers. A classifier can specify a generalization hierarchy by referencing its general classifiers. A classifier is a redefinable element, meaning that it is possible to redefine nested classifiers.

The following features are supported:

See Also:
UML2Package.getClassifier()

Field Summary
static java.lang.String copyright
           
 
Fields inherited from interface org.eclipse.uml2.NamedElement
SEPARATOR
 
Method Summary
 java.util.Set allFeatures()
           A query based on the following OCL expression: member->select(oclIsKindOf(Feature))
 java.util.Set allParents()
           A query based on the following OCL expression: self.parents()->union(self.parents()->collect(p | p.allParents())
 boolean conformsTo(Classifier other)
           A query based on the following OCL expression: (self=other) or (self.allParents()->includes(other))
 Generalization createGeneralization()
          Creates a Generalization and appends it to the 'Generalization' containment reference list
 Generalization createGeneralization(Classifier generalClassifier)
          Creates a generalization between this classifier and the specified general classifier.
 Generalization createGeneralization(EClass eClass)
          Deprecated. Use #createGeneralization() instead.
 CollaborationOccurrence createOccurrence()
          Creates a CollaborationOccurrence and appends it to the 'Occurrence' containment reference list
 CollaborationOccurrence createOccurrence(EClass eClass)
          Deprecated. Use #createOccurrence() instead.
 UseCase createOwnedUseCase()
          Creates a UseCase and appends it to the 'Owned Use Case' containment reference list
 UseCase createOwnedUseCase(EClass eClass)
          Deprecated. Use #createOwnedUseCase() instead.
 Substitution createSubstitution()
          Creates a Substitution and appends it to the 'Substitution' containment reference list
 Substitution createSubstitution(EClass eClass)
          Deprecated. Use #createSubstitution() instead.
 java.util.Set general()
           A query based on the following OCL expression: self.parents()
 Property getAttribute(java.lang.String name)
          Retrieves the Property with the specified 'Name' from the 'Attribute' reference list
 EList getAttributes()
          Returns the value of the 'Attribute' reference list.
 Feature getFeature(java.lang.String name)
          Retrieves the Feature with the specified 'Name' from the 'Feature' reference list
 EList getFeatures()
          Returns the value of the 'Feature' reference list.
 Classifier getGeneral(java.lang.String name)
          Retrieves the Classifier with the specified 'Name' from the 'General' reference list
 EList getGeneralizations()
          Returns the value of the 'Generalization' containment reference list.
 EList getGenerals()
          Returns the value of the 'General' reference list.
 NamedElement getInheritedMember(java.lang.String name)
          Retrieves the NamedElement with the specified 'Name' from the 'Inherited Member' reference list
 EList getInheritedMembers()
          Returns the value of the 'Inherited Member' reference list.
 CollaborationOccurrence getOccurrence(java.lang.String name)
          Retrieves the CollaborationOccurrence with the specified 'Name' from the 'Occurrence' containment reference list
 EList getOccurrences()
          Returns the value of the 'Occurrence' containment reference list.
 UseCase getOwnedUseCase(java.lang.String name)
          Retrieves the UseCase with the specified 'Name' from the 'Owned Use Case' containment reference list
 EList getOwnedUseCases()
          Returns the value of the 'Owned Use Case' containment reference list.
 GeneralizationSet getPowertypeExtent(java.lang.String name)
          Retrieves the GeneralizationSet with the specified 'Name' from the 'Powertype Extent' reference list
 EList getPowertypeExtents()
          Returns the value of the 'Powertype Extent' reference list.
 Classifier getRedefinedClassifier(java.lang.String name)
          Retrieves the Classifier with the specified 'Name' from the 'Redefined Classifier' reference list
 EList getRedefinedClassifiers()
          Returns the value of the 'Redefined Classifier' reference list.
 CollaborationOccurrence getRepresentation()
          Returns the value of the 'Representation' reference
 Substitution getSubstitution(java.lang.String name)
          Retrieves the Substitution with the specified 'Name' from the 'Substitution' containment reference list
 EList getSubstitutions()
          Returns the value of the 'Substitution' containment reference list.
 UseCase getUseCase(java.lang.String name)
          Retrieves the UseCase with the specified 'Name' from the 'Use Case' reference list
 EList getUseCases()
          Returns the value of the 'Use Case' reference list.
 java.util.Set getUsedInterfaces()
          Retrieves the interfaces on which this classifier has a usage dependency.
 boolean hasVisibilityOf(NamedElement n)
           A query based on the following OCL expression: true
 java.util.Set inherit(java.util.Set inhs)
           A query based on the following OCL expression: inhs
 java.util.Set inheritableMembers(Classifier c)
           A query based on the following OCL expression: member->select(m | c.hasVisibilityOf(m))
 java.util.Set inheritedMember()
           A query based on the following OCL expression: self.inherit(self.parents()->collect(p | p.inheritableMembers(self))
 boolean isAbstract()
          Returns the value of the 'Is Abstract' attribute.
 boolean maySpecializeType(Classifier c)
           A query based on the following OCL expression: self.oclIsKindOf(c.oclType)
 java.util.Set parents()
           A query based on the following OCL expression: generalization.general
 void setIsAbstract(boolean value)
          Sets the value of the 'Is Abstract' attribute
 void setRepresentation(CollaborationOccurrence value)
          Sets the value of the 'Representation' reference
 boolean validateGeneralEqualsParents(DiagnosticChain diagnostics, java.util.Map context)
           An invariant constraint based on the following OCL expression: general = self.parents()
 boolean validateInheritedMember(DiagnosticChain diagnostics, java.util.Map context)
           An invariant constraint based on the following OCL expression: self.inheritedMember->includesAll(self.inherit(self.parents()->collect(p | p.inheritableMembers(self)))
 boolean validateNoCyclesInGeneralization(DiagnosticChain diagnostics, java.util.Map context)
           An invariant constraint based on the following OCL expression: not self.allParents()->includes(self)
 boolean validateSpecializeType(DiagnosticChain diagnostics, java.util.Map context)
           An invariant constraint based on the following OCL expression: self.parents()->forAll(c | self.maySpecializeType(c))
 
Methods inherited from interface org.eclipse.uml2.Namespace
createElementImport, createElementImport, createOwnedRule, createOwnedRule, createPackageImport, createPackageImport, excludeCollisions, getElementImports, getImportedMember, getImportedMembers, getImportedPackages, getMember, getMembers, getNamesOfMember, getOwnedMember, getOwnedMembers, getOwnedRule, getOwnedRules, getPackageImports, importedMember, importElement, importMembers, importPackage, membersAreDistinguishable, validateImportedMemberDerived, validateMembersAreDistinguishable
 
Methods inherited from interface org.eclipse.uml2.NamedElement
allNamespaces, createDependency, createNameExpression, createNameExpression, getClientDependencies, getClientDependency, getLabel, getLabel, getName, getNameExpression, getNamespace, getQualifiedName, getVisibility, isDistinguishableFrom, qualifiedName, separator, setName, setNameExpression, setVisibility, validateNoName, validateQualifiedName, validateVisibilityNeedsOwnership
 
Methods inherited from interface org.eclipse.uml2.TemplateableElement
createOwnedTemplateSignature, createOwnedTemplateSignature, createTemplateBinding, createTemplateBinding, getOwnedTemplateSignature, getTemplateBindings, parameterableElements, setOwnedTemplateSignature
 
Methods inherited from interface org.eclipse.uml2.Element
addKeyword, allOwnedElements, apply, createEAnnotation, createOwnedComment, createOwnedComment, destroy, getApplicableStereotype, getApplicableStereotypes, getAppliedStereotype, getAppliedStereotypes, getAppliedVersion, getKeywords, getModel, getNearestPackage, getOwnedComments, getOwnedElements, getOwner, getValue, hasKeyword, hasValue, isApplied, isRequired, mustBeOwned, removeKeyword, setValue, unapply, 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
 
Methods inherited from interface org.eclipse.uml2.Type
conformsTo, createAssociation, getPackage
 
Methods inherited from interface org.eclipse.uml2.PackageableElement
getPackageableElement_visibility, setPackageableElement_visibility
 
Methods inherited from interface org.eclipse.uml2.ParameterableElement
getOwningParameter, getTemplateParameter, setOwningParameter, setTemplateParameter
 
Methods inherited from interface org.eclipse.uml2.RedefinableElement
getRedefinedElement, getRedefinedElements, getRedefinitionContext, getRedefinitionContexts, isConsistentWith, isLeaf, isRedefinitionContextValid, setIsLeaf, validateRedefinitionConsistent, validateRedefinitionContextValid
 

Field Detail

copyright

public static final java.lang.String copyright

See Also:
Constant Field Values
Method Detail

isAbstract

public boolean isAbstract()
Returns the value of the 'Is Abstract' attribute. The default value is "false".

If the meaning of the 'Is Abstract' attribute isn't clear, there really should be more of a description here...

If true, the Classifier does not provide a complete declaration and can typically not be instantiated. An abstract classifier is intended to be used by other classifiers e.g. as the target of general metarelationships or generalization relationships. Default value is false.

Returns:
the value of the 'Is Abstract' attribute.
See Also:
setIsAbstract(boolean), UML2Package.getClassifier_IsAbstract()

setIsAbstract

public void setIsAbstract(boolean value)
Sets the value of the 'Is Abstract' attribute.

Parameters:
value - the new value of the 'Is Abstract' attribute.
See Also:
isAbstract()

getFeatures

public EList getFeatures()
Returns the value of the 'Feature' reference list. The list contents are of type Feature. It is bidirectional and its opposite is 'Featuring Classifier'.

If the meaning of the 'Feature' reference list isn't clear, there really should be more of a description here...

Returns:
the value of the 'Feature' reference list.
See Also:
UML2Package.getClassifier_Feature(), Feature.getFeaturingClassifiers()

getFeature

public Feature getFeature(java.lang.String name)
Retrieves the Feature with the specified 'Name' from the 'Feature' reference list.

Parameters:
name - The 'Name' of the Feature to retrieve.
Returns:
The Feature with the specified 'Name', or null.
See Also:
getFeatures()

getInheritedMembers

public EList getInheritedMembers()
Returns the value of the 'Inherited Member' reference list. The list contents are of type NamedElement.

If the meaning of the 'Inherited Member' reference list isn't clear, there really should be more of a description here...

Returns:
the value of the 'Inherited Member' reference list.
See Also:
UML2Package.getClassifier_InheritedMember()

getInheritedMember

public NamedElement getInheritedMember(java.lang.String name)
Retrieves the NamedElement with the specified 'Name' from the 'Inherited Member' reference list.

Parameters:
name - The 'Name' of the NamedElement to retrieve.
Returns:
The NamedElement with the specified 'Name', or null.
See Also:
getInheritedMembers()

getGenerals

public EList getGenerals()
Returns the value of the 'General' reference list. The list contents are of type Classifier.

If the meaning of the 'General' reference list isn't clear, there really should be more of a description here...

Returns:
the value of the 'General' reference list.
See Also:
UML2Package.getClassifier_General()

getGeneral

public Classifier getGeneral(java.lang.String name)
Retrieves the Classifier with the specified 'Name' from the 'General' reference list.

Parameters:
name - The 'Name' of the Classifier to retrieve.
Returns:
The Classifier with the specified 'Name', or null.
See Also:
getGenerals()

getGeneralizations

public EList getGeneralizations()
Returns the value of the 'Generalization' containment reference list. The list contents are of type Generalization. It is bidirectional and its opposite is 'Specific'.

If the meaning of the 'Generalization' containment reference list isn't clear, there really should be more of a description here...

Returns:
the value of the 'Generalization' containment reference list.
See Also:
UML2Package.getClassifier_Generalization(), Generalization.getSpecific()

createGeneralization

public Generalization createGeneralization(EClass eClass)
Deprecated. Use #createGeneralization() instead.

Creates a Generalization and appends it to the 'Generalization' containment reference list.

Parameters:
eClass - The Ecore class of the Generalization to create.
Returns:
The new Generalization.
See Also:
getGeneralizations()

createGeneralization

public Generalization createGeneralization()
Creates a Generalization and appends it to the 'Generalization' containment reference list.

Returns:
The new Generalization.
See Also:
getGeneralizations()

getAttributes

public EList getAttributes()
Returns the value of the 'Attribute' reference list. The list contents are of type Property.

If the meaning of the 'Attribute' reference list isn't clear, there really should be more of a description here...

Returns:
the value of the 'Attribute' reference list.
See Also:
UML2Package.getClassifier_Attribute()

getAttribute

public Property getAttribute(java.lang.String name)
Retrieves the Property with the specified 'Name' from the 'Attribute' reference list.

Parameters:
name - The 'Name' of the Property to retrieve.
Returns:
The Property with the specified 'Name', or null.
See Also:
getAttributes()

getRedefinedClassifiers

public EList getRedefinedClassifiers()
Returns the value of the 'Redefined Classifier' reference list. The list contents are of type Classifier.

If the meaning of the 'Redefined Classifier' reference list isn't clear, there really should be more of a description here...

Returns:
the value of the 'Redefined Classifier' reference list.
See Also:
UML2Package.getClassifier_RedefinedClassifier()

getRedefinedClassifier

public Classifier getRedefinedClassifier(java.lang.String name)
Retrieves the Classifier with the specified 'Name' from the 'Redefined Classifier' reference list.

Parameters:
name - The 'Name' of the Classifier to retrieve.
Returns:
The Classifier with the specified 'Name', or null.
See Also:
getRedefinedClassifiers()

getSubstitutions

public EList getSubstitutions()
Returns the value of the 'Substitution' containment reference list. The list contents are of type Substitution. It is bidirectional and its opposite is 'Substituting Classifier'.

If the meaning of the 'Substitution' containment reference list isn't clear, there really should be more of a description here...

Returns:
the value of the 'Substitution' containment reference list.
See Also:
UML2Package.getClassifier_Substitution(), Substitution.getSubstitutingClassifier()

getSubstitution

public Substitution getSubstitution(java.lang.String name)
Retrieves the Substitution with the specified 'Name' from the 'Substitution' containment reference list.

Parameters:
name - The 'Name' of the Substitution to retrieve.
Returns:
The Substitution with the specified 'Name', or null.
See Also:
getSubstitutions()

createSubstitution

public Substitution createSubstitution(EClass eClass)
Deprecated. Use #createSubstitution() instead.

Creates a Substitution and appends it to the 'Substitution' containment reference list.

Parameters:
eClass - The Ecore class of the Substitution to create.
Returns:
The new Substitution.
See Also:
getSubstitutions()

createSubstitution

public Substitution createSubstitution()
Creates a Substitution and appends it to the 'Substitution' containment reference list.

Returns:
The new Substitution.
See Also:
getSubstitutions()

getPowertypeExtents

public EList getPowertypeExtents()
Returns the value of the 'Powertype Extent' reference list. The list contents are of type GeneralizationSet. It is bidirectional and its opposite is 'Powertype'.

If the meaning of the 'Powertype Extent' reference list isn't clear, there really should be more of a description here...

Returns:
the value of the 'Powertype Extent' reference list.
See Also:
UML2Package.getClassifier_PowertypeExtent(), GeneralizationSet.getPowertype()

getPowertypeExtent

public GeneralizationSet getPowertypeExtent(java.lang.String name)
Retrieves the GeneralizationSet with the specified 'Name' from the 'Powertype Extent' reference list.

Parameters:
name - The 'Name' of the GeneralizationSet to retrieve.
Returns:
The GeneralizationSet with the specified 'Name', or null.
See Also:
getPowertypeExtents()

getOwnedUseCases

public EList getOwnedUseCases()
Returns the value of the 'Owned Use Case' containment reference list. The list contents are of type UseCase.

If the meaning of the 'Owned Use Case' containment reference list isn't clear, there really should be more of a description here...

Returns:
the value of the 'Owned Use Case' containment reference list.
See Also:
UML2Package.getClassifier_OwnedUseCase()

getOwnedUseCase

public UseCase getOwnedUseCase(java.lang.String name)
Retrieves the UseCase with the specified 'Name' from the 'Owned Use Case' containment reference list.

Parameters:
name - The 'Name' of the UseCase to retrieve.
Returns:
The UseCase with the specified 'Name', or null.
See Also:
getOwnedUseCases()

createOwnedUseCase

public UseCase createOwnedUseCase(EClass eClass)
Deprecated. Use #createOwnedUseCase() instead.

Creates a UseCase and appends it to the 'Owned Use Case' containment reference list.

Parameters:
eClass - The Ecore class of the UseCase to create.
Returns:
The new UseCase.
See Also:
getOwnedUseCases()

createOwnedUseCase

public UseCase createOwnedUseCase()
Creates a UseCase and appends it to the 'Owned Use Case' containment reference list.

Returns:
The new UseCase.
See Also:
getOwnedUseCases()

getUseCases

public EList getUseCases()
Returns the value of the 'Use Case' reference list. The list contents are of type UseCase. It is bidirectional and its opposite is 'Subject'.

If the meaning of the 'Use Case' reference list isn't clear, there really should be more of a description here...

Returns:
the value of the 'Use Case' reference list.
See Also:
UML2Package.getClassifier_UseCase(), UseCase.getSubjects()

getUseCase

public UseCase getUseCase(java.lang.String name)
Retrieves the UseCase with the specified 'Name' from the 'Use Case' reference list.

Parameters:
name - The 'Name' of the UseCase to retrieve.
Returns:
The UseCase with the specified 'Name', or null.
See Also:
getUseCases()

getRepresentation

public CollaborationOccurrence getRepresentation()
Returns the value of the 'Representation' reference.

If the meaning of the 'Representation' reference isn't clear, there really should be more of a description here...

References a collaboration occurrence which indicates the collaboration that represents this classifier. (Subsets Classifier.occurrence.)

Returns:
the value of the 'Representation' reference.
See Also:
setRepresentation(CollaborationOccurrence), UML2Package.getClassifier_Representation()

setRepresentation

public void setRepresentation(CollaborationOccurrence value)
Sets the value of the 'Representation' reference.

Parameters:
value - the new value of the 'Representation' reference.
See Also:
getRepresentation()

getOccurrences

public EList getOccurrences()
Returns the value of the 'Occurrence' containment reference list. The list contents are of type CollaborationOccurrence.

If the meaning of the 'Occurrence' containment reference list isn't clear, there really should be more of a description here...

References the collaboration occurrences owned by the classifier. (Subsets Element. ownedElement.)

Returns:
the value of the 'Occurrence' containment reference list.
See Also:
UML2Package.getClassifier_Occurrence()

getOccurrence

public CollaborationOccurrence getOccurrence(java.lang.String name)
Retrieves the CollaborationOccurrence with the specified 'Name' from the 'Occurrence' containment reference list.

Parameters:
name - The 'Name' of the CollaborationOccurrence to retrieve.
Returns:
The CollaborationOccurrence with the specified 'Name', or null.
See Also:
getOccurrences()

createOccurrence

public CollaborationOccurrence createOccurrence(EClass eClass)
Deprecated. Use #createOccurrence() instead.

Creates a CollaborationOccurrence and appends it to the 'Occurrence' containment reference list.

Parameters:
eClass - The Ecore class of the CollaborationOccurrence to create.
Returns:
The new CollaborationOccurrence.
See Also:
getOccurrences()

createOccurrence

public CollaborationOccurrence createOccurrence()
Creates a CollaborationOccurrence and appends it to the 'Occurrence' containment reference list.

Returns:
The new CollaborationOccurrence.
See Also:
getOccurrences()

allFeatures

public java.util.Set allFeatures()
A query based on the following OCL expression: member->select(oclIsKindOf(Feature))


validateNoCyclesInGeneralization

public boolean validateNoCyclesInGeneralization(DiagnosticChain diagnostics,
                                                java.util.Map context)
An invariant constraint based on the following OCL expression: not self.allParents()->includes(self)


validateSpecializeType

public boolean validateSpecializeType(DiagnosticChain diagnostics,
                                      java.util.Map context)
An invariant constraint based on the following OCL expression: self.parents()->forAll(c | self.maySpecializeType(c))


validateInheritedMember

public boolean validateInheritedMember(DiagnosticChain diagnostics,
                                       java.util.Map context)
An invariant constraint based on the following OCL expression: self.inheritedMember->includesAll(self.inherit(self.parents()->collect(p | p.inheritableMembers(self)))


inheritedMember

public java.util.Set inheritedMember()
A query based on the following OCL expression: self.inherit(self.parents()->collect(p | p.inheritableMembers(self))


parents

public java.util.Set parents()
A query based on the following OCL expression: generalization.general


allParents

public java.util.Set allParents()
A query based on the following OCL expression: self.parents()->union(self.parents()->collect(p | p.allParents())


inheritableMembers

public java.util.Set inheritableMembers(Classifier c)
A query based on the following OCL expression: member->select(m | c.hasVisibilityOf(m))


hasVisibilityOf

public boolean hasVisibilityOf(NamedElement n)
A query based on the following OCL expression: true


inherit

public java.util.Set inherit(java.util.Set inhs)
A query based on the following OCL expression: inhs


maySpecializeType

public boolean maySpecializeType(Classifier c)
A query based on the following OCL expression: self.oclIsKindOf(c.oclType)


general

public java.util.Set general()
A query based on the following OCL expression: self.parents()


validateGeneralEqualsParents

public boolean validateGeneralEqualsParents(DiagnosticChain diagnostics,
                                            java.util.Map context)
An invariant constraint based on the following OCL expression: general = self.parents()


conformsTo

public boolean conformsTo(Classifier other)
A query based on the following OCL expression: (self=other) or (self.allParents()->includes(other))


createGeneralization

public Generalization createGeneralization(Classifier generalClassifier)
Creates a generalization between this classifier and the specified general classifier.

Parameters:
generalClassifier - The classifier to which to create a generalization.
Returns:
The new generalization.
Throws:
java.lang.IllegalArgumentException - If this classifier is identical to the general classifier or is already a direct or indirect parent or child of the general classifier.

getUsedInterfaces

public java.util.Set getUsedInterfaces()
Retrieves the interfaces on which this classifier has a usage dependency.

Returns:
The interfaces used by this classifier.

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