Software Disclaimer

Class UML 2.4.1::Parameter

Description:

Parameters are allowed to be treated as connectable elements.A parameter is a specification of an argument used to pass information into or out of an invocation of a behavioral feature.Parameters have support for streaming, exceptions, and parameter sets.

Direct Superclasses: MultiplicityElement, ConnectableElement

Direct Subclasses:

Class Precedence List: Parameter, MultiplicityElement, ConnectableElement, TypedElement, NamedElement, ParameterableElement, Element

Properties:

default : String (0 1); -- source Parameter
defaultValue : ValueSpecification (0 1); -- source Parameter
direction : ParameterDirectionKind (1 1); -- source Parameter
effect : ParameterEffectKind (0 1); -- source Parameter
isException : Boolean (1 1); -- source Parameter
isStream : Boolean (1 1); -- source Parameter
operation : Operation (0 1); -- source Parameter
parameterSet : ParameterSet (0 *); -- source Parameter
isOrdered : Boolean (1 1); -- source MultiplicityElement
isUnique : Boolean (1 1); -- source MultiplicityElement
lower : Integer (0 1); -- source MultiplicityElement
lowerValue : ValueSpecification (0 1); -- source MultiplicityElement
upper : UnlimitedNatural (0 1); -- source MultiplicityElement
upperValue : ValueSpecification (0 1); -- source MultiplicityElement
end : ConnectorEnd (0 *); -- source ConnectableElement
templateParameter : ConnectableElementTemplateParameter (0 1); -- source ConnectableElement

The ConnectableElementTemplateParameter for this ConnectableElement parameter.
Redefines: ParameterableElement.templateParameter
Opposite: ConnectableElementTemplateParameter.parameteredElement

type : Type (0 1); -- source TypedElement
clientDependency : Dependency (0 *); -- source NamedElement
name : String (0 1); -- source NamedElement
nameExpression : StringExpression (0 1); -- source NamedElement
namespace : Namespace (0 1); -- source NamedElement
qualifiedName : String (0 1); -- source NamedElement
visibility : VisibilityKind (0 1); -- source NamedElement
owningTemplateParameter : TemplateParameter (0 1); -- source ParameterableElement
ownedComment : Comment (0 *); -- source Element
ownedElement : Element (0 *); -- source Element
owner : Element (0 1); -- source Element

Constraints:

Signature: CMOF_14_3_25a() : Boolean;
Description: 14.3 [25] For a TypedElement that is a kind of Parameter or Property typed by an PrimitiveType, the defaultValue, if any, must be a kind of LiteralSpecification. see also: https://sites.google.com/site/metamodelingantipatterns/catalog/mof/typed-element-is-primitive-with-non-literal-default
Expression: type.oclIsKindOf(PrimitiveType) and defaultValue->notEmpty() implies defaultValue.oclIsKindOf(LiteralSpecification)

Signature: CMOF_14_3_24() : Boolean;
Description: 14.3 [24] For a TypedElement that is a kind of Parameter or Property typed by an Enumeration, the defaultValue, if any, must be a kind of InstanceValue. see also: https://sites.google.com/site/metamodelingantipatterns/catalog/mof/typed-element-is-enumeration-with-non-instance-value-default
Expression: type.oclIsKindOf(Enumeration) and defaultValue->notEmpty() implies defaultValue.oclIsKindOf(InstanceValue)

Signature: CMOF_14_3_23a() : Boolean;
Description: 14.3 [23] A TypedElement that is a kind of Parameter or Property typed by a Class cannot have a default value. see also: https://sites.google.com/site/metamodelingantipatterns/catalog/mof/typed-element-is-complex-with-default-value
Expression: type.oclIsKindOf(Class) implies defaultValue->isEmpty()

Signature: CMOF_14_3_20() : Boolean;
Description: 14.3 [20] An Operation Parameter must have no effect, exception or streaming characteristics see also: https://sites.google.com/site/metamodelingantipatterns/catalog/mof/parameter-has-effect see also: https://sites.google.com/site/metamodelingantipatterns/catalog/mof/parameter-is-exception
Expression: effect->isEmpty() and not (isException or isStream)

Signature: CMOF_14_3_12b() : Boolean;
Description: 14.3 [12] A multi-valued Property or Parameter cannot have a default value. The default value of a Property or Parameter typed by a PrimitiveType must be a kind of LiteralSpecification. The default value of a Property or Parameter typed by an Enumeration must be a kind of InstanceValue. A Property or Parameter typed by a Class cannot have a default value. see also: https://sites.google.com/site/metamodelingantipatterns/catalog/mof/parameter-has-invalid-default-value see also: https://sites.google.com/site/metamodelingantipatterns/catalog/mof/property-has-invalid-default-value
Expression: defaultValue->notEmpty() implies (upperBound() <= 1 and ((type.oclIsKindOf(PrimitiveType) and defaultValue.oclIsKindOf(LiteralSpecification)) or (type.oclIsKindOf(Enumeration) and defaultValue.oclIsKindOf(InstanceValue))))

Signature: CMOF_14_3_12a() : Boolean;
Description: 14.3 [12] A multi-valued Property or Parameter cannot have a default value. The default value of a Property or Parameter typed by a PrimitiveType must be a kind of LiteralSpecification. The default value of a Property or Parameter typed by an Enumeration must be a kind of InstanceValue. A Property or Parameter typed by a Class cannot have a default value. see also: https://sites.google.com/site/metamodelingantipatterns/catalog/mof/parameter-has-invalid-default-value see also: https://sites.google.com/site/metamodelingantipatterns/catalog/mof/property-has-invalid-default-value
Expression: (upperBound() > 1 or type.oclIsKindOf(Class) implies defaultValue->isEmpty())

Signature: stream_and_exception() : Boolean;
Description: A parameter cannot be a stream and exception at the same time.
Expression: true

Signature: reentrant_behaviors() : Boolean;
Description: Reentrant behaviors cannot have stream parameters.
Expression: true

Signature: not_exception() : Boolean;
Description: An input parameter cannot be an exception.
Expression: true

Signature: in_and_out() : Boolean;
Description: Only in and inout parameters may have a delete effect. Only out, inout, and return parameters may have a create effect.
Expression: true

Signature: connector_end() : Boolean;
Description: A parameter may only be associated with a connector end within the context of a collaboration.
The OCL used here is not normative.
Editor's notes: collaboration not defined.
Expression: true
Original: self.end.notEmpty() implies self.collaboration.notEmpty()

Operations:

No additional operations.



Send questions or comments to [email protected].