Klasse VariableNode

java.lang.Object
de.svws_nrw.transpiler.typescript.VariableNode

public class VariableNode extends Object
This class is used to store the information of transpiled java method parameters.
  • Konstruktordetails

  • Methodendetails

    • isStatic

      public boolean isStatic()
      Returns whether this variable declaration is a static class attribute
      Gibt zurück:
      true if this variable declaration is a static class attribute and false otherwise
    • isFinal

      public boolean isFinal()
      Returns whether this variable declaration is marked final
      Gibt zurück:
      true if this variable declaration is marked final and false otherwise
    • transpileType

      public String transpileType()
      Returns the transpiled code for the type of this node.
      Gibt zurück:
      the transpiled code for the type of this node
    • getTypeNode

      public TypeNode getTypeNode()
      Returns the type node of this variable node.
      Gibt zurück:
      the type node
    • getTypeCheck

      public String getTypeCheck(String identifier)
      Returns transpiled code to check whether the specified identifier matches the type of this variable.
      Parameter:
      identifier - the identifier to be checked
      Gibt zurück:
      the type check code
    • getTypeCast

      public String getTypeCast(String identifier)
      Returns transpiled code for casting the specified identifier to the type of this variable. Casting is only used for Java object types.
      Parameter:
      identifier - the identifier
      Gibt zurück:
      the transpiled code
    • getName

      public String getName()
      Gibt den Namen der Variable zurück.
      Gibt zurück:
      der Name der Variable
    • transpile

      public String transpile()
      Returns the transpiled code of this node.
      Gibt zurück:
      the transpiled code