de.dhbwstuttgart.syntaxtree.statement

## Class MethodCall

- java.lang.Object
- - de.dhbwstuttgart.syntaxtree.SyntaxTreeNode
  - - de.dhbwstuttgart.syntaxtree.statement.Statement
    - - de.dhbwstuttgart.syntaxtree.statement.ExprStmt
      - - de.dhbwstuttgart.syntaxtree.statement.Expr
        - - de.dhbwstuttgart.syntaxtree.statement.MethodCall

- All Implemented Interfaces:
    IItemWithOffset, Typeable
  Direct Known Subclasses:
    ConstructorCall, ThisCall

      public class MethodCall
      extends Expr

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `private ArgumentList` | `arglist`
    `protected static Logger` | `parserlog`
    `private Receiver` | `receiver` Diese Variable speichert die Expression, welche die Klasse von welcher die Methode aufgerufen wird darstellt.

    - ### Fields inherited from class de.dhbwstuttgart.syntaxtree.statement.Expr

      `usedid`

    - ### Fields inherited from class de.dhbwstuttgart.syntaxtree.statement.ExprStmt

      `inferencelog`

    - ### Fields inherited from class de.dhbwstuttgart.syntaxtree.statement.Statement

      `offset, type`

    - ### Fields inherited from class de.dhbwstuttgart.syntaxtree.SyntaxTreeNode

      `parent`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `MethodCall(int offset, int variableLength)`
    `MethodCall(Receiver receiver, java.lang.String methodName, ArgumentList argumentList, int offset)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `add_Expr(Expr e)`
    `UndConstraint` | `constraintsFromMethodAssumption(MethodAssumption methodAssumption, TypeAssumptions assumptions)` Spezifikation: overloading determines for all possible overloadings and overridings of a method the constraints, where constraints itself forms the constraints from the receiver type, the argument types, the return type and a given type assumption for the method.
    `java.lang.String` | `get_Name()`
    `Receiver` | `get_Receiver()`
    `ArgumentList` | `getArgumentList()`
    `Menge<SyntaxTreeNode>` | `getChildren()`
    `java.lang.String` | `getName()`
    `ConstraintsSet` | `overloading(TypeAssumptions assumptions)` Erstellt die Constraints fÃ¼r den eigentlichen Methodenaufruf.
    `void` | `parserPostProcessing(SyntaxTreeNode parent)` Wird nach dem Parsen aufgerufen.
    `JavaCodeResult` | `printJavaCode(ResultSet resultSet)`
    `void` | `set_ArgumentList(ArgumentList al)`
    `void` | `set_Expr_Menge(Menge<Expr> v)`
    `void` | `set_Name(java.lang.String name)`
    `void` | `set_Receiver(Receiver rec)`
    `void` | `set_UsedId(UsedId u)`
    `java.lang.String` | `toString()` Author: Martin PlÃ¯Â¿Â½micke
    `ConstraintsSet` | `TYPEExpr(TypeAssumptions assumptions)`
    `ConstraintsSet` | `TYPEStmt(TypeAssumptions assumptions)` Spezifikation: TYPEStmt( Ass, stmt ) = let (stmt : rty, ConS) = TYPEExpr( Ass, stmt ) in (stmt : Void, ConS)
    `void` | `wandleRefTypeAttributes2GenericAttributes(Menge<Type> paralist, Menge<GenericTypeVar> genericMethodParameters)`

    - ### Methods inherited from class de.dhbwstuttgart.syntaxtree.statement.Expr

      `get_Name_Menge, get_Type_Menge, get_UsedId, set_Type`

    - ### Methods inherited from class de.dhbwstuttgart.syntaxtree.statement.ExprStmt

      `getTypeLineNumber, getTypeName`

    - ### Methods inherited from class de.dhbwstuttgart.syntaxtree.statement.Statement

      `getDescription, getOffset, getReturnType, getType, getTypeInformation, getVariableLength, setReturnType, setType`

    - ### Methods inherited from class de.dhbwstuttgart.syntaxtree.SyntaxTreeNode

      `addTypeInsertPoints, equals, getGTVDeclarationContext, getMatchingParentNode, getParent, getParentClass, seesType`

    - ### Methods inherited from class java.lang.Object

      `clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Field Detail

    - #### receiver

          private Receiver receiver

      Diese Variable speichert die Expression, welche die Klasse von welcher die Methode aufgerufen wird darstellt.

    - #### arglist

          private ArgumentList arglist

    - #### parserlog

          protected static Logger parserlog

  - ### Constructor Detail

    - #### MethodCall

          public MethodCall(Receiver receiver,
                            java.lang.String methodName,
                            ArgumentList argumentList,
                            int offset)

    - #### MethodCall

          public MethodCall(int offset,
                            int variableLength)

  - ### Method Detail

    - #### set_ArgumentList

          public void set_ArgumentList(ArgumentList al)

    - #### getArgumentList

          public ArgumentList getArgumentList()

    - #### get_Receiver

          public Receiver get_Receiver()

    - #### get_Name

          public java.lang.String get_Name()

      Specified by:
        `get_Name` in class `Expr`

    - #### set_Name

          public void set_Name(java.lang.String name)

    - #### set_Receiver

          public void set_Receiver(Receiver rec)

    - #### set_UsedId

          public void set_UsedId(UsedId u)

      Overrides:
        `set_UsedId` in class `Expr`

    - #### set_Expr_Menge

          public void set_Expr_Menge(Menge<Expr> v)

    - #### add_Expr

          public void add_Expr(Expr e)

    - #### toString

          public java.lang.String toString()

      Author: Martin PlÃ¯Â¿Â½micke
      Overrides:
        `toString` in class `java.lang.Object`
      Returns:

    - #### wandleRefTypeAttributes2GenericAttributes

          public void wandleRefTypeAttributes2GenericAttributes(Menge<Type> paralist,
                                                                Menge<GenericTypeVar> genericMethodParameters)

      Specified by:
        `wandleRefTypeAttributes2GenericAttributes` in class `Statement`

    - #### getName

          public java.lang.String getName()

      Returns:
        der Name der Methode, welcher dieser MethodCall aufruft.

    - #### TYPEExpr

          public ConstraintsSet TYPEExpr(TypeAssumptions assumptions)

      Specified by:
        `TYPEExpr` in class `Expr`

    - #### overloading

          public ConstraintsSet overloading(TypeAssumptions assumptions)

      Erstellt die Constraints fÃ¼r den eigentlichen Methodenaufruf. Sucht in den Assumptions nach passenden Methoden und erstellt ein OderConstraintSet.
      Parameters:
        `assumptions` -
      Returns:

    - #### constraintsFromMethodAssumption

          public UndConstraint constraintsFromMethodAssumption(MethodAssumption methodAssumption,
                                                               TypeAssumptions assumptions)

      Spezifikation: overloading determines for all possible overloadings and overridings of a method the constraints, where constraints itself forms the constraints from the receiver type, the argument types, the return type and a given type assumption for the method. If it is a method from a class, which is not the actual class (this), all type variables are replaced by fresh type variables (fresh), as different instances can occur. sargs determines all type assumptions of a method, where the argument types are supertypes of a minimal type assumption.
      Returns:

    - #### TYPEStmt

          public ConstraintsSet TYPEStmt(TypeAssumptions assumptions)

      Spezifikation: TYPEStmt( Ass, stmt ) = let (stmt : rty, ConS) = TYPEExpr( Ass, stmt ) in (stmt : Void, ConS)
      Overrides:
        `TYPEStmt` in class `Expr`

    - #### printJavaCode

          public JavaCodeResult printJavaCode(ResultSet resultSet)

      Specified by:
        `printJavaCode` in class `Statement`

    - #### getChildren

          public Menge<SyntaxTreeNode> getChildren()

      Specified by:
        `getChildren` in class `SyntaxTreeNode`

    - #### parserPostProcessing

          public void parserPostProcessing(SyntaxTreeNode parent)

      Description copied from class: `SyntaxTreeNode`
      Wird nach dem Parsen aufgerufen. ErfÃ¼llt folgenden Aufgaben: 1. FÃ¼llt fehlende Typangaben mit TPHs auf. 2. VerknÃ¼pft die Knoten des Syntaxbaums. (setzt Parent) 3. Wechselt RefTypes gegebenenfalls mit GenericTypeVars aus. 4. FÃ¼hrt einen Teil des Syntaxckecks durch.
      Overrides:
        `parserPostProcessing` in class `SyntaxTreeNode`