SPeCS Packages Documentation
    Preparing search index...

    Utility methods related with the type join points.

    Index

    Constructors

    Methods

    • Makes sure the given parameter is an expression join point.

      Parameters

      • $expression: Expression | undefined

        If a string, returns a literal expression with the code of the string. Otherwise, returns $expression

      • isOptional: boolean = false

        If false and $expression is undefined, throws an exception. Otherwise, returns undefined if $expression is undefined.

      Returns Expression | undefined

    • Makes sure the given parameter is a statement join point.

      Parameters

      • code: Joinpoint | undefined

        If a string, returns a literal statement with the code of the string. Otherwise, tries to transform the given node to a $statement

      • isOptional: boolean = false

        If false and code is undefined, throws an exception. Otherwise, returns undefined if code is undefined.

      Returns Statement | undefined

    • Makes sure the given parameter is a type join point.

      Parameters

      • $type: Type

        If a string, returns a literal type with the code of the string. Otherwise, returns $type

      Returns Type

      This method does not do anything, it is only kept for compatibility with the old API