Options
All
  • Public
  • Public/Protected
  • All
Menu

Mendix Model SDK

Index

Type aliases

AbstractStructureProperty

AbstractStructureProperty: PartProperty<any> | PartListProperty<any> | StructuralChildProperty<any> | StructuralChildListProperty<any>

AppState

AppState: "APP_NOT_FOUND" | "STAGING" | "UPDATING" | "STARTING" | "FAILED_STAGING" | "FAILED" | "STARTED" | "MXBUILD_STARTED" | "STOPPED" | "UNKNOWN"

Change

Change: IDeltaChange[]

ContainmentInfo

ContainmentInfo: object

Type declaration

  • element: AbstractElement
  • Optional index?: number
  • parentId: string
  • parentPropertyName: string

Delta

Evaluatable

Evaluatable: expressions.MxExpression | expressions.MxFeatureCall

Union/sum type to be able to recurse over types other than MxExpression. This should match with ExpressionsTypesHelper#evaluatableTypes in the Model SDK generator.

IAbstractUnitConstructor

IAbstractUnitConstructor: ModelUnit | AbstractUnit

IChecksResolver

IChecksResolver: function

Type declaration

    • (qualifiedStructureName: string): ICheck[]
    • Parameters

      • qualifiedStructureName: string

      Returns ICheck[]

IElementConstructor

IElementConstructor: object

Type declaration

  • constructor: function
    • new __type(...args: any[]): __type
    • Parameters

      • Rest ...args: any[]

      Returns __type

IQueryMap

IQueryMap: object

Type declaration

  • [qualifiedTypeName: string]: object

IQueryResolver

IQueryResolver: function

Type declaration

    • (queryName: string, qualifiedStructureName: string): IQuery
    • Parameters

      • queryName: string
      • qualifiedStructureName: string

      Returns IQuery

ISuperTypeMap

ISuperTypeMap: object

Type declaration

  • [qualifiedTypeName: string]: string

IUpdateAppJobStatus

IUpdateAppJobStatus: "updating" | "resuming" | "provisioning" | "started" | "consistencyerrors" | "failed"

InstanceConstructor

InstanceConstructor: elements.IElementConstructor | units.IAbstractUnitConstructor

IteratorLambda

IteratorLambda: function

Algebraic data type (!) of (ostensibly: iterator-)functions/lambdas taking a value and its previous value of a list, with previousValue === null for the head list item.

Type declaration

    • (value: T, index: number, array: Array<T>): R
    • Parameters

      • value: T
      • index: number
      • array: Array<T>

      Returns R

LockType

LockType: "bidi" | "conversion"

ModelSdkClient

ModelSdkClient: ModelSdkClientImpl<IModel, Model>

Mutator

PrimitiveValue

PrimitiveValue: boolean | number | string | IPoint | ISize | IColor

StructureState

StructureState: "new" | "attached" | "detached" | "deleted"

Variables

MAX_METAMODEL_VERSION

MAX_METAMODEL_VERSION: string

Highest supported Metamodel version: 7.7.0

SDK_VERSION

SDK_VERSION: string

Current SDK version: 4.3.0

falseExpr

falseExpr: expressions.MxBooleanLiteralExpression

loadChecks

loadChecks: function

Type declaration

loadQueries

loadQueries: function

Type declaration

loadSuperTypes

loadSuperTypes: function

Type declaration

standardIterators

standardIterators: object

Type declaration

  • [name: string]: function

standardLibraryMethods

standardLibraryMethods: object

Type declaration

  • [name: string]: function
      • (source: any | void, args: any[] | void): any
      • Parameters

        • source: any | void
        • args: any[] | void

        Returns any

testDataPathPrefix

testDataPathPrefix: "./data/"

trueExpr

trueExpr: expressions.MxBooleanLiteralExpression

undefinedExpr

undefinedExpr: expressions.MxUndefinedExpression

wrap

Alias for mkFeatureCallWrapper.

Functions

asModelUnit

assertValidateName

  • assertValidateName(validationFunction: function): void
  • Parameters

    • validationFunction: function
        • (source: any, args: void | any[]): any
        • Parameters

          • source: any
          • args: void | any[]

          Returns any

    Returns void

calculateMessage

chain

  • chain(...featureCalls: expressions.MxFeatureCall[]): expressions.MxFeatureCallWrapper
  • Wraps a chain of MxFeatureCall-s in the required way in MxFeatureCallWrapper-s. (Essentially: foldRight(featureCalls)(wrap(, )) :))

    Parameters

    • Rest ...featureCalls: expressions.MxFeatureCall[]

    Returns expressions.MxFeatureCallWrapper

checkInsertionIndex

  • checkInsertionIndex(index: number, property: AbstractProperty<any[], any>): void

checkMutator

checkUpdateOrRemovalIndex

  • checkUpdateOrRemovalIndex(index: number, property: AbstractProperty<any[], any>): void

contains

createInVersionCheck

evaluateCheck

evaluateCheckBody

evaluateExpression

findElement

findProperty

getContainmentInfo

getUnitForDelta

isAtLeast

  • Parameters

    Returns boolean

isListProperty

isNothing

  • isNothing(arg: any): boolean
  • Checks whether the argument is "nothing", i.e. either undefined or null.

    Parameters

    • arg: any

    Returns boolean

logBaseEval

  • logBaseEval(evaluatable: Evaluatable, source: any, baseEval: any): void
  • Parameters

    Returns void

logMethodCall

  • logMethodCall(expr: MxMethodCall, source: any, argValues: any[], result: any): void
  • Parameters

    • expr: MxMethodCall
    • source: any
    • argValues: any[]
    • result: any

    Returns void

lookupByVersion

  • lookupByVersion<T>(versionedThings: T[], mmVersion: Version): T
  • Type parameters

    Parameters

    • versionedThings: T[]
    • mmVersion: Version

    Returns T

makeChecksResolver

makeQueryResolver

mkBinaryExpr

  • mkBinaryExpr(left: expressions.MxExpression, operator: expressions.MxOperator, right: expressions.MxExpression): expressions.MxBinaryExpression
  • Parameters

    • left: expressions.MxExpression
    • operator: expressions.MxOperator
    • right: expressions.MxExpression

    Returns expressions.MxBinaryExpression

mkFeatureCallWrapper

  • mkFeatureCallWrapper(featureCall: expressions.MxFeatureCall, appliedFeature?: expressions.MxFeatureCallWrapper): expressions.MxFeatureCallWrapper
  • Parameters

    • featureCall: expressions.MxFeatureCall
    • Optional appliedFeature: expressions.MxFeatureCallWrapper

    Returns expressions.MxFeatureCallWrapper

mkFollow

  • mkFollow(variableName: string, path: expressions.MxExpression, including: boolean): expressions.MxAbstractFollow
  • Parameters

    • variableName: string
    • path: expressions.MxExpression
    • including: boolean

    Returns expressions.MxAbstractFollow

mkIteratorCall

  • mkIteratorCall(type: expressions.MxIteratorType, iteratorVariableName: string, body: expressions.MxExpression): expressions.MxIteratorCall
  • Parameters

    • type: expressions.MxIteratorType
    • iteratorVariableName: string
    • body: expressions.MxExpression

    Returns expressions.MxIteratorCall

mkMethodCall

  • mkMethodCall(referredMethod: string): expressions.MxMethodCall
  • Parameters

    • referredMethod: string

    Returns expressions.MxMethodCall

mkPrefixExpression

  • mkPrefixExpression(expr: expressions.MxExpression): expressions.MxPrefixExpression
  • Parameters

    • expr: expressions.MxExpression

    Returns expressions.MxPrefixExpression

mkPreviousExpr

  • mkPreviousExpr(variable: expressions.MxVariableRefExpression, appliedFeature?: expressions.MxFeatureCallWrapper): expressions.MxPreviousExpression
  • Parameters

    • variable: expressions.MxVariableRefExpression
    • Optional appliedFeature: expressions.MxFeatureCallWrapper

    Returns expressions.MxPreviousExpression

mkPropertyCall

  • mkPropertyCall(referredProperty: string): expressions.MxPropertyCall
  • Parameters

    • referredProperty: string

    Returns expressions.MxPropertyCall

mkStringLiteral

  • mkStringLiteral(str: string): expressions.MxStringLiteralExpression
  • Parameters

    • str: string

    Returns expressions.MxStringLiteralExpression

mkVariableRef

  • mkVariableRef(referredVariable: string, appliedFeature?: expressions.MxFeatureCallWrapper): expressions.MxVariableRefExpression
  • Parameters

    • referredVariable: string
    • Optional appliedFeature: expressions.MxFeatureCallWrapper

    Returns expressions.MxVariableRefExpression

parseAsNormalizedVersion

  • parseAsNormalizedVersion(versionString: string): Version
  • Parses the given string as a sem-Version, ignoring non-numeric and "extra" data, and padding with ".0" where necessary.

    Parameters

    • versionString: string

    Returns Version

rawList

rawValue

readJson

  • readJson<T>(fileName: string): T
  • Reads the file with the given name relative to 'mendixmodelsdk', and parses and returns it as JSON.

    Type parameters

    • T

    Parameters

    • fileName: string

    Returns T

removeUselessDeltas

runChecksOn

sendListChangeDeltas

  • sendListChangeDeltas<T, P>(property: AbstractProperty<T[], IList<P>> & { toRawChangeValue: (value: P) => any; }, change: IArrayWillSplice | IArrayWillChange): void
  • Type parameters

    • T

    • P

    Parameters

    • property: AbstractProperty<T[], IList<P>> & { toRawChangeValue: (value: P) => any; }
    • change: IArrayWillSplice | IArrayWillChange

    Returns void

thisExpr

  • thisExpr(appliedFeature?: expressions.MxFeatureCallWrapper): expressions.MxThisExpression
  • Parameters

    • Optional appliedFeature: expressions.MxFeatureCallWrapper

    Returns expressions.MxThisExpression

updateStructure

  • updateStructure(structure: Structure, updateAction: function): void
  • Parameters

    • structure: Structure
    • updateAction: function
        • (): void
        • Returns void

    Returns void

validateSyntax

  • validateSyntax(name: string): string | null
  • Validates the name syntactically without looking at the context (so no uniqueness check).

    Parameters

    • name: string

    Returns string | null

    with error message or null in which case name is valid.

writeJson

  • writeJson(fileName: string, json: Object): void
  • Writes the given JSON under the given file name into the test-output directory.

    Parameters

    • fileName: string
    • json: Object

    Returns void

xTimes

  • xTimes(n: number): string
  • Parameters

    • n: number

    Returns string

    a string consisting of n times an 'x'.

Generated using TypeDoc