Table of Contents

Interface IElement

Namespace
NMF.Interop.Uml
Assembly
NMF.UMLInterop.dll

The public interface for Element

[DefaultImplementationType(typeof(Element))]
[XmlDefaultImplementationType(typeof(Element))]
[ModelRepresentationClass("http://www.eclipse.org/uml2/5.0.0/UML#//Element")]
public interface IElement : IEModelElement, IModelElement, INotifyPropertyChanged, INotifyPropertyChanging
Inherited Members

Properties

OwnedComment

The Comments owned by this Element. <p>From package UML::CommonStructure.</p>

[Browsable(false)]
[XmlElementName("ownedComment")]
[XmlAttribute(false)]
[Containment]
IOrderedSetExpression<IComment> OwnedComment { get; }

Property Value

IOrderedSetExpression<IComment>

Methods

AddKeyword(string)

Adds the specified keyword to this element.

bool AddKeyword(string keyword)

Parameters

keyword string

The keyword to add.

Returns

bool

AllOwnedElements()

The query allOwnedElements() gives all of the direct and indirect ownedElements of an Element. result = (ownedElement->union(ownedElement->collect(e | e.allOwnedElements()))->asSet()) <p>From package UML::CommonStructure.</p>

ISetExpression<IElement> AllOwnedElements()

Returns

ISetExpression<IElement>

ApplyStereotype(IStereotype)

Applies the specified stereotype to this element.

IEObject ApplyStereotype(IStereotype stereotype)

Parameters

stereotype IStereotype

The stereotype to apply.

Returns

IEObject

CreateEAnnotation(string)

Creates an annotation with the specified source and this element as its model element.

IEAnnotation CreateEAnnotation(string source)

Parameters

source string

The source for the new annotation.

Returns

IEAnnotation

Destroy()

Destroys this element by removing all cross references to/from it and removing it from its containing resource or object.

void Destroy()

GetApplicableStereotype(string)

Retrieves the stereotype with the specified qualified name that is applicable to this element, or null if no such stereotype is applicable.

IStereotype GetApplicableStereotype(string qualifiedName)

Parameters

qualifiedName string

The qualified name of the applicable stereotype to retrieve.

Returns

IStereotype

GetApplicableStereotypes()

Retrieves the stereotypes that are applicable to this element, including those that are required and/or may already be applied.

ISetExpression<IStereotype> GetApplicableStereotypes()

Returns

ISetExpression<IStereotype>

GetAppliedStereotype(string)

Retrieves the stereotype with the specified qualified name that is applied to this element, or null if no such stereotype is applied.

IStereotype GetAppliedStereotype(string qualifiedName)

Parameters

qualifiedName string

The qualified name of the applied stereotype to retrieve.

Returns

IStereotype

GetAppliedStereotypes()

Retrieves the stereotypes that are applied to this element.

ISetExpression<IStereotype> GetAppliedStereotypes()

Returns

ISetExpression<IStereotype>

GetAppliedSubstereotype(IStereotype, string)

Retrieves the substereotype of the specified stereotype with the specified qualified name that is applied to this element, or null if no such stereotype is applied.

IStereotype GetAppliedSubstereotype(IStereotype stereotype, string qualifiedName)

Parameters

stereotype IStereotype

The superstereotype of the applied substereotype to retrieve.

qualifiedName string

The qualified name of the applied substereotype to retrieve.

Returns

IStereotype

GetAppliedSubstereotypes(IStereotype)

Retrieves the substereotypes of the specified stereotype that are applied to this element.

ISetExpression<IStereotype> GetAppliedSubstereotypes(IStereotype stereotype)

Parameters

stereotype IStereotype

The superstereotype of the applied substereotypes to retrieve.

Returns

ISetExpression<IStereotype>

GetKeywords()

Retrieves the keywords for this element.

ISetExpression<string> GetKeywords()

Returns

ISetExpression<string>

GetModel()

Retrieves the model that owns (either directly or indirectly) this element.

IModel GetModel()

Returns

IModel

GetNearestPackage()

Retrieves the nearest package that owns (either directly or indirectly) this element, or the element itself (if it is a package).

IPackage GetNearestPackage()

Returns

IPackage

GetRelationships()

Retrieves the relationships in which this element is involved.

ISetExpression<IRelationship> GetRelationships()

Returns

ISetExpression<IRelationship>

GetRelationships(IEClass)

Retrieves the relationships of the specified type in which this element is involved.

ISetExpression<IRelationship> GetRelationships(IEClass eClass)

Parameters

eClass IEClass

The (meta)type of the relationships to retrieve.

Returns

ISetExpression<IRelationship>

GetRequiredStereotype(string)

Retrieves the stereotype with the specified qualified name that is required for this element, or null if no such stereotype is required.

IStereotype GetRequiredStereotype(string qualifiedName)

Parameters

qualifiedName string

The qualified name of the required stereotype to retrieve.

Returns

IStereotype

GetRequiredStereotypes()

Retrieves the stereotypes that are required for this element.

ISetExpression<IStereotype> GetRequiredStereotypes()

Returns

ISetExpression<IStereotype>

GetSourceDirectedRelationships()

Retrieves the directed relationships for which this element is a source.

ISetExpression<IDirectedRelationship> GetSourceDirectedRelationships()

Returns

ISetExpression<IDirectedRelationship>

GetSourceDirectedRelationships(IEClass)

Retrieves the directed relationships of the specified type for which this element is a source.

ISetExpression<IDirectedRelationship> GetSourceDirectedRelationships(IEClass eClass)

Parameters

eClass IEClass

The (meta)type of the directed relationships to retrieve.

Returns

ISetExpression<IDirectedRelationship>

GetStereotypeApplication(IStereotype)

Retrieves the application of the specified stereotype for this element, or null if no such stereotype application exists.

IEObject GetStereotypeApplication(IStereotype stereotype)

Parameters

stereotype IStereotype

The stereotype for which to retrieve an application.

Returns

IEObject

GetStereotypeApplications()

Retrieves the stereotype applications for this element.

ISetExpression<IEObject> GetStereotypeApplications()

Returns

ISetExpression<IEObject>

GetTargetDirectedRelationships()

Retrieves the directed relationships for which this element is a target.

ISetExpression<IDirectedRelationship> GetTargetDirectedRelationships()

Returns

ISetExpression<IDirectedRelationship>

GetTargetDirectedRelationships(IEClass)

Retrieves the directed relationships of the specified type for which this element is a target.

ISetExpression<IDirectedRelationship> GetTargetDirectedRelationships(IEClass eClass)

Parameters

eClass IEClass

The (meta)type of the directed relationships to retrieve.

Returns

ISetExpression<IDirectedRelationship>

GetValue(IStereotype, string)

Retrieves the value of the property with the specified name in the specified stereotype for this element.

object GetValue(IStereotype stereotype, string propertyName)

Parameters

stereotype IStereotype

The stereotype for which to retrieve the value.

propertyName string

The name of the property whose value to retrieve.

Returns

object

HasKeyword(string)

Determines whether this element has the specified keyword.

bool HasKeyword(string keyword)

Parameters

keyword string

The keyword in question.

Returns

bool

HasValue(IStereotype, string)

Determines whether this element has a (non-default) value for the property with the specified name in the specified stereotype.

bool HasValue(IStereotype stereotype, string propertyName)

Parameters

stereotype IStereotype

The stereotype for which to test the property.

propertyName string

The name of the property in question.

Returns

bool

Has_owner(object, object)

Elements that must be owned must have an owner. mustBeOwned() implies owner->notEmpty()

bool Has_owner(object diagnostics, object context)

Parameters

diagnostics object

The chain of diagnostics to which problems are to be appended.

context object

The cache of context-specific information.

Returns

bool

IsStereotypeApplicable(IStereotype)

Determines whether the specified stereotype is applicable to this element.

bool IsStereotypeApplicable(IStereotype stereotype)

Parameters

stereotype IStereotype

The stereotype in question.

Returns

bool

IsStereotypeApplied(IStereotype)

Determines whether the specified stereotype is applied to this element.

bool IsStereotypeApplied(IStereotype stereotype)

Parameters

stereotype IStereotype

The stereotype in question.

Returns

bool

IsStereotypeRequired(IStereotype)

Determines whether the specified stereotype is required for this element.

bool IsStereotypeRequired(IStereotype stereotype)

Parameters

stereotype IStereotype

The stereotype in question.

Returns

bool

MustBeOwned()

The query mustBeOwned() indicates whether Elements of this type must have an owner. Subclasses of Element that do not require an owner must override this operation. result = (true) <p>From package UML::CommonStructure.</p>

bool MustBeOwned()

Returns

bool

Not_own_self(object, object)

An element may not directly or indirectly own itself. not allOwnedElements()->includes(self)

bool Not_own_self(object diagnostics, object context)

Parameters

diagnostics object

The chain of diagnostics to which problems are to be appended.

context object

The cache of context-specific information.

Returns

bool

RemoveKeyword(string)

Removes the specified keyword from this element.

bool RemoveKeyword(string keyword)

Parameters

keyword string

The keyword to remove.

Returns

bool

SetValue(IStereotype, string, object)

Sets the value of the property with the specified name in the specified stereotype for this element.

void SetValue(IStereotype stereotype, string propertyName, object newValue)

Parameters

stereotype IStereotype

The stereotype for which to set the value.

propertyName string

The name of the property whose value to set.

newValue object

The new value for the property.

UnapplyStereotype(IStereotype)

Unapplies the specified stereotype from this element.

IEObject UnapplyStereotype(IStereotype stereotype)

Parameters

stereotype IStereotype

The stereotype to unapply.

Returns

IEObject