Class UML 2.4.1::StringExpression
Description:
An expression that specifies a string value that is derived by concatenating
a set of sub string expressions, some of which might be template parameters.
Direct Superclasses: Expression,
TemplateableElementDirect Subclasses: Class Precedence List: StringExpression,
Expression,
ValueSpecification,
TypedElement,
PackageableElement,
ParameterableElement,
NamedElement,
TemplateableElement,
ElementProperties:
![](/se-interop/image/down-arrow.png?hunchentoot-session=20043%3ACA02388712E3AD66FBA41897B1B5CEC7)
owningExpression :
StringExpression (0 1); -- source
StringExpression![](/se-interop/image/down-arrow.png?hunchentoot-session=20043%3ACA02388712E3AD66FBA41897B1B5CEC7)
subExpression :
StringExpression (0 *); -- source
StringExpression![](/se-interop/image/down-arrow.png?hunchentoot-session=20043%3ACA02388712E3AD66FBA41897B1B5CEC7)
operand :
ValueSpecification (0 *); -- source
Expression![](/se-interop/image/down-arrow.png?hunchentoot-session=20043%3ACA02388712E3AD66FBA41897B1B5CEC7)
symbol : String (0 1); -- source
Expression![](/se-interop/image/down-arrow.png?hunchentoot-session=20043%3ACA02388712E3AD66FBA41897B1B5CEC7)
type :
Type (0 1); -- source
TypedElement![](/se-interop/image/down-arrow.png?hunchentoot-session=20043%3ACA02388712E3AD66FBA41897B1B5CEC7)
visibility :
VisibilityKind (1 1); -- source
PackageableElement![](/se-interop/image/down-arrow.png?hunchentoot-session=20043%3ACA02388712E3AD66FBA41897B1B5CEC7)
owningTemplateParameter :
TemplateParameter (0 1); -- source
ParameterableElement![](/se-interop/image/down-arrow.png?hunchentoot-session=20043%3ACA02388712E3AD66FBA41897B1B5CEC7)
templateParameter :
TemplateParameter (0 1); -- source
ParameterableElement![](/se-interop/image/down-arrow.png?hunchentoot-session=20043%3ACA02388712E3AD66FBA41897B1B5CEC7)
clientDependency :
Dependency (0 *); -- source
NamedElement![](/se-interop/image/down-arrow.png?hunchentoot-session=20043%3ACA02388712E3AD66FBA41897B1B5CEC7)
name : String (0 1); -- source
NamedElement![](/se-interop/image/down-arrow.png?hunchentoot-session=20043%3ACA02388712E3AD66FBA41897B1B5CEC7)
nameExpression :
StringExpression (0 1); -- source
NamedElement![](/se-interop/image/down-arrow.png?hunchentoot-session=20043%3ACA02388712E3AD66FBA41897B1B5CEC7)
namespace :
Namespace (0 1); -- source
NamedElement![](/se-interop/image/down-arrow.png?hunchentoot-session=20043%3ACA02388712E3AD66FBA41897B1B5CEC7)
qualifiedName : String (0 1); -- source
NamedElement![](/se-interop/image/down-arrow.png?hunchentoot-session=20043%3ACA02388712E3AD66FBA41897B1B5CEC7)
ownedTemplateSignature :
TemplateSignature (0 1); -- source
TemplateableElement![](/se-interop/image/down-arrow.png?hunchentoot-session=20043%3ACA02388712E3AD66FBA41897B1B5CEC7)
templateBinding :
TemplateBinding (0 *); -- source
TemplateableElement![](/se-interop/image/down-arrow.png?hunchentoot-session=20043%3ACA02388712E3AD66FBA41897B1B5CEC7)
ownedComment :
Comment (0 *); -- source
Element![](/se-interop/image/down-arrow.png?hunchentoot-session=20043%3ACA02388712E3AD66FBA41897B1B5CEC7)
ownedElement :
Element (0 *); -- source
Element![](/se-interop/image/down-arrow.png?hunchentoot-session=20043%3ACA02388712E3AD66FBA41897B1B5CEC7)
owner :
Element (0 1); -- source
ElementConstraints:
Signature: subexpressions() : Boolean;
Description: If a StringExpression has sub-expressions, it cannot have operands and
vice versa (this avoids the problem of having to define a collating sequence
between operands and subexpressions).
The OCL used here is not normative.Editor's notes: missing endif
Expression: if subExpression->notEmpty() then operand->isEmpty() else operand->notEmpty() endif
Original: if subExpression->notEmpty() then operand->isEmpty() else operand->notEmpty()
Signature: operands() : Boolean;
Description: All the operands of a StringExpression must be LiteralStrings
Expression: operand->forAll (op | op.oclIsKindOf (LiteralString))
Operations:
Signature: stringValue() : String;
Description: The query stringValue() returns the string that concatenates, in order,
all the component string literals of all the subexpressions that are part
of the StringExpression.
The OCL used here is not normative.Editor's notes: iterate not iterate().
Expression: result = if subExpression->notEmpty()
then subExpression->iterate(se; stringValue = '' | stringValue.concat(se.stringValue()))
else operand->iterate(op; stringValue = '' | stringValue.concat(op.value)) endif
Original: result = if subExpression->notEmpty() then subExpression->iterate(se; stringValue = | stringValue.concat(se.stringValue())) else operand->iterate()(op; stringValue = | stringValue.concat(op.value))
Send questions or comments to
[email protected].