model1
Class Namespace

The Namespace Class classifies and characterizes Elements that can contain other Elements. Along with containing the Elements, a Namespace defines a namespace, the allowable set of names and the naming constraints, for these elements.



Subclasses of the Namespace Class have mechanisms for effectively extending their namespace, without actually containing additional Elements. Thus Namespace can be viewed in terms of its two roles, as a container and as a namespace mechanism. Because only subclasses extend the namespace, the namespace and contents are coincident in the definition of the Namespace Class. Each Namespace has four collections (the latter three derivable) that are used in the MOF Model’s Constraints. These collections are:


Operations
Class NamespaceFindElementsByTypeResult findElementsByType findElementsByType

Returns all the Elements identified by the contents reference defined for this Namespace that are of the Class supplied. The returned list of Elements is a subset of the Elements contained by this Namespace. This operation can either return only those Elements that exactly match the specified class or those Elements that are instances of the specified class and one or more of its subclasses.


Because Element is an abstract class, invoking this operation with the ofType argument specified as Element and the includeSubtypes argument set to false returns an empty list. Because Element is the base type for all instances that can be contained by a Namespace, invoking the operation with the ofType argument specified as Element, and includeSubtypes set to true, returns all the contained elements of the Namespace.


Returns all the ModelElements identified by the contents reference defined for this
Namespace that are of the Class supplied. The returned list of ModelElements is a subset of
the ModelElements contained by this Namespace. This operation can either return only
those ModelElements that exactly match the specified class or those ModelElements that
are instances of the specified class and one or more of its subclasses.
Because ModelElement is an abstract class, invoking this operation with the ofType
argument specified as ModelElement and the includeSubtypes argument set to false returns
an empty list. Because ModelElement is the base type for all instances which can be
contained by a Namespace, Invoking the operation with the ofType argument specified as
ModelElement, and includeSubtypes set to true, returns all the contained elements of the
Namespace.

Class NamespaceLookupElementResult lookupElement lookupElement

Searches for an element contained by this Namespace whose name is precisely equal (as a string) to the supplied name. The operation either returns an Element that satisfies the above, or raises ServiceException (NameNotFound).

Class NamespaceResolveQualifiedNameResult resolveQualifiedName resolveQualifiedName

Searches for an Element contained within this Namespace that is identified by the supplied qualifiedName. The qualifiedName is interpreted as a 'path' starting from this Namespace.


Properties:

Alias
Classifier Behavior
Collections
Is Abstracttrue
Is Activefalse
Is Leaffalse
Keywords
NameNamespace
Name Expression
Owned Template Signature
OwnerPackage model1
Owning Parameter
PackagePackage model1
Packageable Element visibilitypublic
Qualified Namemodel1::model1::Namespace
Representation
Stereotype
Template Parameter
Visibilitypublic

Operation Details

 findElementsByType
public Class NamespaceFindElementsByTypeResult findElementsByType( Primitive Type boolean, Primitive Type string  )

Returns all the Elements identified by the contents reference defined for this Namespace that are of the Class supplied. The returned list of Elements is a subset of the Elements contained by this Namespace. This operation can either return only those Elements that exactly match the specified class or those Elements that are instances of the specified class and one or more of its subclasses.


Because Element is an abstract class, invoking this operation with the ofType argument specified as Element and the includeSubtypes argument set to false returns an empty list. Because Element is the base type for all instances that can be contained by a Namespace, invoking the operation with the ofType argument specified as Element, and includeSubtypes set to true, returns all the contained elements of the Namespace.


Returns all the ModelElements identified by the contents reference defined for this
Namespace that are of the Class supplied. The returned list of ModelElements is a subset of
the ModelElements contained by this Namespace. This operation can either return only
those ModelElements that exactly match the specified class or those ModelElements that
are instances of the specified class and one or more of its subclasses.
Because ModelElement is an abstract class, invoking this operation with the ofType
argument specified as ModelElement and the includeSubtypes argument set to false returns
an empty list. Because ModelElement is the base type for all instances which can be
contained by a Namespace, Invoking the operation with the ofType argument specified as
ModelElement, and includeSubtypes set to true, returns all the contained elements of the
Namespace.

Parameters:
Primitive Type boolean includeSubtypes
Primitive Type string ofType
Returns:
Class NamespaceFindElementsByTypeResult
Properties:

Alias
Body Condition
Class Class Namespace
Collections
Concurrencysequential
Datatype
Is Abstractfalse
Is Leaffalse
Is Orderedfalse
isQuerytrue
Is Querytrue
Is Staticfalse
Is Uniquetrue
Keywords
Lower1
Lower Value
Multiplicity1
NamefindElementsByType
Name Expression
Owned Template Signature
OwnerClass Namespace
Owning Parameter
Qualified Namemodel1::model1::Namespace::findElementsByType
Stereotypedefault
Template Parameter
TypeClass NamespaceFindElementsByTypeResult
Upper1
Upper Value
Visibilitypublic


 lookupElement
public Class NamespaceLookupElementResult lookupElement( Primitive Type string  )

Searches for an element contained by this Namespace whose name is precisely equal (as a string) to the supplied name. The operation either returns an Element that satisfies the above, or raises ServiceException (NameNotFound).

Parameters:
Primitive Type string name
Returns:
Class NamespaceLookupElementResult
Properties:

Alias
Body Condition
Class Class Namespace
Collections
Concurrencysequential
Datatype
Is Abstractfalse
Is Leaffalse
Is Orderedfalse
isQuerytrue
Is Querytrue
Is Staticfalse
Is Uniquetrue
Keywords
Lower1
Lower Value
Multiplicity1
NamelookupElement
Name Expression
Owned Template Signature
OwnerClass Namespace
Owning Parameter
Qualified Namemodel1::model1::Namespace::lookupElement
Stereotypedefault
Template Parameter
TypeClass NamespaceLookupElementResult
Upper1
Upper Value
Visibilitypublic


 resolveQualifiedName
public Class NamespaceResolveQualifiedNameResult resolveQualifiedName( Primitive Type string  )

Searches for an Element contained within this Namespace that is identified by the supplied qualifiedName. The qualifiedName is interpreted as a 'path' starting from this Namespace.

Parameters:
Primitive Type string qualifiedName
Returns:
Class NamespaceResolveQualifiedNameResult
Properties:

Alias
Body Condition
Class Class Namespace
Collections
Concurrencysequential
Datatype
Is Abstractfalse
Is Leaffalse
Is Orderedfalse
isQuerytrue
Is Querytrue
Is Staticfalse
Is Uniquetrue
Keywords
Lower1
Lower Value
Multiplicity1
NameresolveQualifiedName
Name Expression
Owned Template Signature
OwnerClass Namespace
Owning Parameter
Qualified Namemodel1::model1::Namespace::resolveQualifiedName
Stereotypedefault
Template Parameter
TypeClass NamespaceResolveQualifiedNameResult
Upper1
Upper Value
Visibilitypublic

Comments