Table of Contents

Interface IOperation

Namespace
NMF.Interop.Legacy.Cmof
Assembly
NMF.UMLInterop.dll

The public interface for Operation

[DefaultImplementationType(typeof(Operation))]
[XmlDefaultImplementationType(typeof(Operation))]
[ModelRepresentationClass("http://schema.omg.org/spec/MOF/2.0/cmof.xml#//Operation")]
public interface IOperation : ITypedElement, IMultiplicityElement, IBehavioralFeature, IFeature, IRedefinableElement, INamespace, INamedElement, IElement, IModelElement, INotifyPropertyChanged, INotifyPropertyChanging
Inherited Members

Properties

BodyCondition

The bodyCondition property

[Browsable(false)]
[XmlElementName("bodyCondition")]
[XmlAttribute(false)]
[Containment]
IOrderedSetExpression<IConstraint> BodyCondition { get; }

Property Value

IOrderedSetExpression<IConstraint>

Class

The class that owns the operation. Subsets RedefinableElement::redefinitionContext and NamedElement::namespace and Feature::featuringClassifier. The class that owns the operation.

[Browsable(false)]
[XmlElementName("class")]
[XmlAttribute(true)]
[XmlOpposite("ownedOperation")]
IClass Class { get; set; }

Property Value

IClass

Datatype

The DataType that owns this Operation. Subsets NamedElement::namespace, Feature::featuringClassifier, and RedefinableElement::redefinitionContext.

[Browsable(false)]
[XmlElementName("datatype")]
[XmlAttribute(true)]
[XmlOpposite("ownedOperation")]
IDataType Datatype { get; set; }

Property Value

IDataType

IsQuery

Specifies whether an execution of the BehavioralFeature leaves the state of the system unchanged (isQuery=true) or whether side effects may occur (isQuery=false). The default value is false.

[TypeConverter(typeof(LowercaseBooleanConverter))]
[XmlElementName("isQuery")]
[XmlAttribute(true)]
bool IsQuery { get; set; }

Property Value

bool

Postcondition

The postcondition property

[Browsable(false)]
[XmlElementName("postcondition")]
[XmlAttribute(false)]
[Containment]
IOrderedSetExpression<IConstraint> Postcondition { get; }

Property Value

IOrderedSetExpression<IConstraint>

Precondition

The precondition property

[Browsable(false)]
[XmlElementName("precondition")]
[XmlAttribute(false)]
[Containment]
IOrderedSetExpression<IConstraint> Precondition { get; }

Property Value

IOrderedSetExpression<IConstraint>

RedefinedOperation

References the Operations that are redefined by this Operation. Subsets RedefinableElement.redefinedElement.

[XmlElementName("redefinedOperation")]
[XmlAttribute(true)]
ISetExpression<IOperation> RedefinedOperation { get; }

Property Value

ISetExpression<IOperation>

Methods

At_most_one_return(object, object)

An operation can have at most one return parameter; i.e., an owned parameter with the direction set to 'return' self.ownedParameter->select(par | par.direction = #return)->size() <= 1

bool At_most_one_return(object diagnostics, object context)

Parameters

diagnostics object
context object

Returns

bool

GetType()

If this operation has a return parameter, type equals the value of type for that parameter. Otherwise type is not defined. result = if returnResult->size() = 1 then returnResult->any().type else Set{} endif

IType GetType()

Returns

IType

Only_body_for_query(object, object)

A bodyCondition can only be specified for a query operation. bodyCondition->notEmpty() implies isQuery

bool Only_body_for_query(object diagnostics, object context)

Parameters

diagnostics object
context object

Returns

bool

ReturnResult()

result = ownedParameter->select (par | par.direction = #return)

ISetExpression<IParameter> ReturnResult()

Returns

ISetExpression<IParameter>