object IntermediateCodeUtils

Class containing a DSL for easy creation of ImpLanStmt-Blocks and other useful static methods for dealing ImpLan and the translation from TeSSLa

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. IntermediateCodeUtils
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Type Members

  1. sealed trait DeclarationType extends AnyRef

    Represents the types of declared variables

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. def Addition(op1: ImpLanExpr, op2: ImpLanExpr): ImpLanExpr

    Generates an addition expression

    Generates an addition expression

    op1

    First parameter sub-expression, must be of IntermediateCode.LongType

    op2

    Second parameter sub-expression, must be of IntermediateCode.LongType

    returns

    Addition expression

  5. def And(ops: Seq[ImpLanExpr]): ImpLanExpr

    Generates an and (&&) expression

    Generates an and (&&) expression

    ops

    parameter sub-expressions, must be of type IntermediateCode.BoolType

    returns

    And expression

  6. def BitwiseOr(ops: Seq[ImpLanExpr]): ImpLanExpr

    Generates an bitor (|) expression

    Generates an bitor (|) expression

    ops

    parameter sub-expressions, must be of type IntermediateCode.LongType

    returns

    Or expression

  7. def GetStruct(struct: ImpLanExpr, fieldName: String, structType: ImpLanType): ImpLanExpr

    Produces an expression for accessing a structure field

    Produces an expression for accessing a structure field

    struct

    Expression which evaluates to a struct

    fieldName

    The accessed field name

    structType

    The type of the struct

    returns

    Expression accessing the struct

  8. def Greater(a: ImpLanExpr, b: ImpLanExpr): ImpLanExpr

    Generates a greater expression

    Generates a greater expression

    a

    First parameter sub-expression, must be of IntermediateCode.LongType

    b

    Second parameter sub-expression, must be of IntermediateCode.LongType

    returns

    Greater expression

  9. def GreaterEqual(a: ImpLanExpr, b: ImpLanExpr): ImpLanExpr

    Generates a greater equal expression

    Generates a greater equal expression

    a

    First parameter sub-expression, must be of IntermediateCode.LongType

    b

    Second parameter sub-expression, must be of IntermediateCode.LongType

    returns

    Greater equal expression

  10. def MkStruct(content: Seq[(String, ImpLanExpr)], targetType: ImpLanType): ImpLanExpr

    Produces an expression building a struct

    Produces an expression building a struct

    content

    Sub expressions with field names

    targetType

    The type of the struct to be generated

    returns

    Expression building a struct

  11. def Negation(a: ImpLanExpr): ImpLanExpr

    Generates a negate expression

    Generates a negate expression

    a

    Sub-expression to be negated

    returns

    Negate expression

  12. def NotEqual(a: ImpLanExpr, b: ImpLanExpr): ImpLanExpr

    Generates a not equal expression

    Generates a not equal expression

    a

    First parameter sub-expression

    b

    Second parameter sub-expression

    returns

    Not equal expression

  13. def Or(ops: Seq[ImpLanExpr]): ImpLanExpr

    Generates an or (||) expression

    Generates an or (||) expression

    ops

    parameter sub-expressions, must be of type IntermediateCode.BoolType

    returns

    Or expression

  14. def Subtraction(op1: ImpLanExpr, op2: ImpLanExpr): ImpLanExpr

    Generates a subtraction expression

    Generates a subtraction expression

    op1

    First parameter sub-expression, must be of IntermediateCode.LongType

    op2

    Second parameter sub-expression, must be of IntermediateCode.LongType

    returns

    Subtraction expression

  15. def Throw(e: ImpLanExpr, forType: ImpLanType): ImpLanExpr

    Generates a throw expression

    Generates a throw expression

    e

    sub expression of the error to be thrown, must be of IntermediateCode.ErrorType

    forType

    Type which should be returned inst

    returns

    Expression throwing an error

  16. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  17. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native() @HotSpotIntrinsicCandidate()
  18. def defaultValueForStreamType(t: core.TesslaAST.Core.Type): Option[ImpLanVal]

    Calculates a static default value for a stream type.

    Calculates a static default value for a stream type. For Events[t] it is the default value of t.

    t

    Type whose default value shall be determined. Must be Events[...]

    returns

    Default value for given type

  19. def defaultValueForType(t: core.TesslaAST.Core.Type): Option[ImpLanVal]

    Calculates a static default value for a non-stream type.

    Calculates a static default value for a non-stream type.

    t

    Type whose default value shall be determined. May not be Events[...]

    returns

    Default value for given type

  20. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  21. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  22. def foldAST[A](stmts: Seq[ImpLanStmt], n: A, f: (A, ImpLanExpr) => A, g: (A, ImpLanStmt) => A): A

    Folds a sequence of statements including all sub-expressions and sub-statements.

    Folds a sequence of statements including all sub-expressions and sub-statements. Sub-statements/sub-expressions are traversed prior their parent expressions

    A

    The result type of the folding operation

    stmts

    The sequence of statements to be folded

    n

    The start value

    f

    Function executed on every expression

    g

    Function executed on every statement

    returns

    The result of the folding

  23. def foldAST[A](exp: ImpLanExpr, n: A, f: (A, ImpLanExpr) => A, g: (A, ImpLanStmt) => A): A

    Folds an IntermediateCode.ImpLanExpr including all sub-expressions and sub-statements.

    Folds an IntermediateCode.ImpLanExpr including all sub-expressions and sub-statements. Sub-statements/sub-expressions are traversed prior their parent expressions

    A

    The result type of the folding operation

    exp

    The sequence of statements to be folded

    n

    The start value

    f

    Function executed on every expression

    g

    Function executed on every statement

    returns

    The result of the folding

  24. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  25. def getVariableSeq(stmts: Seq[ImpLanStmt], baseSeq: Seq[(String, (ImpLanType, Option[ImpLanExpr], DeclarationType))] = Seq(), global: Boolean): Seq[(String, (ImpLanType, Option[ImpLanExpr], DeclarationType))]

    Builds a sequence containing type/default/lazyness/global-definition information for all variables defined in stmts.

    Builds a sequence containing type/default/lazyness/global-definition information for all variables defined in stmts. If unsound information (e.g. multiple declarations) are found an error is thrown. The order is the one of the corresponding assignments.

    stmts

    The sequence of statements to be examined

    baseSeq

    The base sequence to be extended

    global

    Include global definitions in sub-expressions (e.g. functions)

    returns

    Map containing variable information.

  26. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  27. implicit def intermediateCodeDSLConversion(stmts: Seq[ImpLanStmt]): IntermediateCodeUtils
  28. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  29. def mapAST(exp: ImpLanExpr, f: (ImpLanExpr) => ImpLanExpr, g: (ImpLanStmt) => Option[ImpLanStmt]): ImpLanExpr

    Maps f on all subexpressions and g on all sub-statements of an IntermediateCode.ImpLanExpr

    Maps f on all subexpressions and g on all sub-statements of an IntermediateCode.ImpLanExpr

    exp

    The expression to be mapped

    f

    Function to map expressions

    g

    Function to map statements

    returns

    Mapped expression

  30. def mapAST(stmts: Seq[ImpLanStmt], f: (ImpLanExpr) => ImpLanExpr, g: (ImpLanStmt) => Option[ImpLanStmt]): Seq[ImpLanStmt]

    Maps f on all subexpressions and g on all sub-statements of a sequence of statements

    Maps f on all subexpressions and g on all sub-statements of a sequence of statements

    stmts

    The sequence of statements to be mapped

    f

    Function to map expressions

    g

    Function to map statements

    returns

    Mapped sequence of statements

  31. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  32. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  33. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  34. implicit def stmtConversion(dsl: IntermediateCodeUtils): Seq[ImpLanStmt]
  35. implicit def stringToVariable(str: String): Variable
  36. def structComparison(s1: String, s2: String): Boolean

    Sorting function for structs taking care of the right sorting of tuple fild names

    Sorting function for structs taking care of the right sorting of tuple fild names

    s1

    First param for comparison

    s2

    Second param for comparison

    returns

    true if s1 <= s2 with respect to the special sorting rules

  37. def structIsTuple(structType: StructType): Boolean

    Figures out if a struct is a tuple.

    Figures out if a struct is a tuple. i.e. has field names _1,_2 ...

    structType

    The struct to be examined

    returns

    Whether given struct is tuple

  38. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  39. def toString(): String
    Definition Classes
    AnyRef → Any
  40. implicit def typeConversion(t: core.TesslaAST.Core.Type): ImpLanType

    Converts TeSSLa type to corresponding IntermediateCode.ImpLanType

    Converts TeSSLa type to corresponding IntermediateCode.ImpLanType

    t

    Type to be converted. If type is Events[t] the result is equal to calling the function with t.

    returns

    The converted type

  41. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  42. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  43. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  44. case object FinalDeclaration extends DeclarationType with Product with Serializable

    Variable can be assigned and evaluated at declaration and is never changed again

  45. case object FinalLazyDeclaration extends DeclarationType with Product with Serializable

    Variable can be assigned at declaration and is never changed again, the evaluation has to be lazy

  46. case object VariableDeclaration extends DeclarationType with Product with Serializable

    The variable is reassigned in the generated code

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable]) @Deprecated
    Deprecated

Inherited from AnyRef

Inherited from Any

Ungrouped