Documentation Language: Swift

Structure

ATLMatchedRule

Represents an ATL matched rule for declarative transformation.

struct ATLMatchedRule

Overview

Matched rules form the core of ATL’s declarative transformation approach. They are automatically executed for all source elements that match their input patterns and satisfy their optional guard conditions. Each matched rule transforms source elements into one or more target elements through pattern-based specifications.

Overview

Matched rules operate through several key components:

Example Usage

let member2MaleRule = ATLMatchedRule(
    name: "Member2Male",
    sourcePattern: ATLSourcePattern(
        variableName: "s",
        type: "Families!Member"
    ),
    targetPatterns: [
        ATLTargetPattern(
            variableName: "t",
            type: "Persons!Male",
            bindings: ["fullName": concatenationExpression]
        )
    ],
    guard: genderCheckExpression
)

Topics

Operators

Initializers

?
init(name:sourcePattern:targetPatterns:guard:)

Creates a new ATL matched rule.

Instance Properties

V
guard

The optional guard condition for conditional rule execution.

V
name

The name of the matched rule.

V
sourcePattern

The source pattern that defines the input specification.

V
targetPatterns

The target patterns that define the output specifications.

Instance Methods

Default Implementations

Relationships

Conforms To

See Also

Modules and Rules

S
ATLModule

Represents an ATL (Atlas Transformation Language) module.

S
ATLCalledRule

Represents an ATL called rule for imperative transformation.

S
ATLHelper

Represents an ATL helper function.