Table of Contents

Class Lifeline

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

A Lifeline represents an individual participant in the Interaction. While parts and structural features may have multiplicity greater than 1, Lifelines represent only one interacting entity. <p>From package UML::Interactions.</p>

[XmlNamespace("http://www.eclipse.org/uml2/5.0.0/UML")]
[XmlNamespacePrefix("uml")]
[ModelRepresentationClass("http://www.eclipse.org/uml2/5.0.0/UML#//Lifeline")]
public class Lifeline : NamedElement, ILifeline, INamedElement, IElement, IEModelElement, IModelElement, INotifyPropertyChanged, INotifyPropertyChanging
Inheritance
Lifeline
Implements
Inherited Members

Constructors

Lifeline()

Creates a new instance

public Lifeline()

Properties

Children

Gets the child model elements of this model element

public override IEnumerableExpression<IModelElement> Children { get; }

Property Value

IEnumerableExpression<IModelElement>

ClassInstance

Gets the Class model for this type

public static IClass ClassInstance { get; }

Property Value

IClass

CoveredBy

References the InteractionFragments in which this Lifeline takes part. <p>From package UML::Interactions.</p>

[XmlElementName("coveredBy")]
[XmlAttribute(true)]
[XmlOpposite("covered")]
public ISetExpression<IInteractionFragment> CoveredBy { get; }

Property Value

ISetExpression<IInteractionFragment>

DecomposedAs

References the Interaction that represents the decomposition. <p>From package UML::Interactions.</p>

[XmlElementName("decomposedAs")]
[XmlAttribute(true)]
public IPartDecomposition DecomposedAs { get; set; }

Property Value

IPartDecomposition

Interaction

References the Interaction enclosing this Lifeline. <p>From package UML::Interactions.</p>

[Browsable(false)]
[XmlElementName("interaction")]
[XmlAttribute(true)]
[XmlOpposite("lifeline")]
public IInteraction Interaction { get; set; }

Property Value

IInteraction

ReferencedElements

Gets the referenced model elements of this model element

public override IEnumerableExpression<IModelElement> ReferencedElements { get; }

Property Value

IEnumerableExpression<IModelElement>

Represents

References the ConnectableElement within the classifier that contains the enclosing interaction. <p>From package UML::Interactions.</p>

[XmlElementName("represents")]
[XmlAttribute(true)]
public IConnectableElement Represents { get; set; }

Property Value

IConnectableElement

Selector

If the referenced ConnectableElement is multivalued, then this specifies the specific individual part within that set. <p>From package UML::Interactions.</p>

[Browsable(false)]
[XmlElementName("selector")]
[XmlAttribute(false)]
[Containment]
public IValueSpecification Selector { get; set; }

Property Value

IValueSpecification

Methods

GetClass()

Gets the Class for this model element

public override IClass GetClass()

Returns

IClass

GetCollectionForFeature(string)

Gets the Model element collection for the given feature

protected override IList GetCollectionForFeature(string feature)

Parameters

feature string

The requested feature

Returns

IList

A non-generic list of elements

GetExpressionForReference(string)

Gets the property expression for the given reference

protected override INotifyExpression<IModelElement> GetExpressionForReference(string reference)

Parameters

reference string

The requested reference in upper case

Returns

INotifyExpression<IModelElement>

An incremental property expression

GetModelElementForReference(string, int)

Resolves the given URI to a child model element

protected override IModelElement GetModelElementForReference(string reference, int index)

Parameters

reference string

The requested reference name

index int

The index of this reference

Returns

IModelElement

The model element or null if it could not be found

GetRelativePathForNonIdentifiedChild(IModelElement)

Gets the relative URI fragment for the given child model element

protected override string GetRelativePathForNonIdentifiedChild(IModelElement element)

Parameters

element IModelElement

The element that should be looked for

Returns

string

A fragment of the relative URI

Interaction_uses_share_lifeline(object, object)

If a lifeline is in an Interaction referred to by an InteractionUse in an enclosing Interaction, and that lifeline is common with another lifeline in an Interaction referred to by another InteractonUse within that same enclosing Interaction, it must be common to a lifeline within that enclosing Interaction. By common Lifelines we mean Lifelines with the same selector and represents associations. let intUses : Set(InteractionUse) = interaction.interactionUse in intUses->forAll ( iuse : InteractionUse | let usingInteraction : Set(Interaction) = iuse.enclosingInteraction->asSet() ->union( iuse.enclosingOperand.combinedFragment->asSet()->closure(enclosingOperand.combinedFragment).enclosingInteraction->asSet() ) in let peerUses : Set(InteractionUse) = usingInteraction.fragment->select(oclIsKindOf(InteractionUse)).oclAsType(InteractionUse)->asSet() ->union( usingInteraction.fragment->select(oclIsKindOf(CombinedFragment)).oclAsType(CombinedFragment)->asSet() ->closure(operand.fragment->select(oclIsKindOf(CombinedFragment)).oclAsType(CombinedFragment)).operand.fragment-> select(oclIsKindOf(InteractionUse)).oclAsType(InteractionUse)->asSet() )->excluding(iuse) in peerUses->forAll( peerUse : InteractionUse | peerUse.refersTo.lifeline->forAll( l : Lifeline | (l.represents = self.represents and ( self.selector.oclIsKindOf(LiteralString) implies l.selector.oclIsKindOf(LiteralString) and self.selector.oclAsType(LiteralString).value = l.selector.oclAsType(LiteralString).value ) and ( self.selector.oclIsKindOf(LiteralInteger) implies l.selector.oclIsKindOf(LiteralInteger) and self.selector.oclAsType(LiteralInteger).value = l.selector.oclAsType(LiteralInteger).value ) )
implies usingInteraction.lifeline->exists(represents = self.represents and ( self.selector.oclIsKindOf(LiteralString) implies l.selector.oclIsKindOf(LiteralString) and self.selector.oclAsType(LiteralString).value = l.selector.oclAsType(LiteralString).value ) and ( self.selector.oclIsKindOf(LiteralInteger) implies l.selector.oclIsKindOf(LiteralInteger) and self.selector.oclAsType(LiteralInteger).value = l.selector.oclAsType(LiteralInteger).value ) ) ) ) )

public bool Interaction_uses_share_lifeline(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

OnParentChanged(IModelElement, IModelElement)

Gets called when the parent model element of the current model element changes

protected override void OnParentChanged(IModelElement newParent, IModelElement oldParent)

Parameters

newParent IModelElement

The new parent model element

oldParent IModelElement

The old parent model element

OnParentChanging(IModelElement, IModelElement)

Gets called when the parent model element of the current model element is about to change

protected override void OnParentChanging(IModelElement newParent, IModelElement oldParent)

Parameters

newParent IModelElement

The new parent model element

oldParent IModelElement

The old parent model element

Same_classifier(object, object)

The classifier containing the referenced ConnectableElement must be the same classifier, or an ancestor, of the classifier that contains the interaction enclosing this lifeline. represents.namespace->closure(namespace)->includes(interaction._'context')

public bool Same_classifier(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

Selector_int_or_string(object, object)

The selector value, if present, must be a LiteralString or a LiteralInteger self.selector->notEmpty() implies self.selector.oclIsKindOf(LiteralInteger) or self.selector.oclIsKindOf(LiteralString)

public bool Selector_int_or_string(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

Selector_specified(object, object)

The selector for a Lifeline must only be specified if the referenced Part is multivalued. self.selector->notEmpty() = (self.represents.oclIsKindOf(MultiplicityElement) and self.represents.oclAsType(MultiplicityElement).isMultivalued())

public bool Selector_specified(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

SetFeature(string, object)

Sets a value to the given feature

protected override void SetFeature(string feature, object value)

Parameters

feature string

The requested feature

value object

The value that should be set to that feature