Klasse UnaryExpression

Alle implementierten Schnittstellen:
OperatorIds, TypeConstants, TypeIds

public class UnaryExpression extends OperatorExpression
  • Felddetails

    • expression

      public Expression expression
    • optimizedBooleanConstant

      public Constant optimizedBooleanConstant
  • Konstruktordetails

    • UnaryExpression

      public UnaryExpression(Expression expression, int operator)
  • Methodendetails

    • analyseCode

      public FlowInfo analyseCode(BlockScope currentScope, FlowContext flowContext, FlowInfo flowInfo)
      Setzt außer Kraft:
      analyseCode in Klasse Expression
    • updateFlowOnBooleanResult

      protected void updateFlowOnBooleanResult(FlowInfo flowInfo, boolean result)
      Beschreibung aus Klasse kopiert: Expression
      Back-propagation of flow info: before analysing a branch where a given condition is known to hold true/false respectively, ask the condition to contribute its information to the given flowInfo.
      Setzt außer Kraft:
      updateFlowOnBooleanResult in Klasse Expression
      Parameter:
      flowInfo - the info to be used for analysing the branch
      result - condition result that would cause entering the branch
    • optimizedBooleanConstant

      public Constant optimizedBooleanConstant()
      Beschreibung aus Klasse kopiert: Expression
      Constant usable for bytecode pattern optimizations, but cannot be inlined since it is not strictly equivalent to the definition of constant expressions. In particular, some side-effects may be required to occur (only the end value is known).
      Setzt außer Kraft:
      optimizedBooleanConstant in Klasse Expression
      Gibt zurück:
      Constant known to be of boolean type
    • generateCode

      public void generateCode(BlockScope currentScope, CodeStream codeStream, boolean valueRequired)
      Code generation for an unary operation
      Setzt außer Kraft:
      generateCode in Klasse Expression
      Parameter:
      currentScope - org.eclipse.jdt.internal.compiler.lookup.BlockScope
      codeStream - org.eclipse.jdt.internal.compiler.codegen.CodeStream
      valueRequired - boolean
    • generateOptimizedBoolean

      public void generateOptimizedBoolean(BlockScope currentScope, CodeStream codeStream, BranchLabel trueLabel, BranchLabel falseLabel, boolean valueRequired)
      Boolean operator code generation Optimized operations are: Ungültige Eingabe: "&"Ungültige Eingabe: "&", ||, Ungültige Eingabe: "<", Ungültige Eingabe: "<"=, >, >=, Ungültige Eingabe: "&", |, ^
      Setzt außer Kraft:
      generateOptimizedBoolean in Klasse Expression
      Parameter:
      currentScope -
      codeStream -
      trueLabel -
      falseLabel -
      valueRequired -
    • printExpressionNoParenthesis

      public StringBuffer printExpressionNoParenthesis(int indent, StringBuffer output)
      Angegeben von:
      printExpressionNoParenthesis in Klasse OperatorExpression
    • collectPatternVariablesToScope

      public void collectPatternVariablesToScope(LocalVariableBinding[] variables, BlockScope scope)
      Setzt außer Kraft:
      collectPatternVariablesToScope in Klasse Expression
    • resolveType

      public TypeBinding resolveType(BlockScope scope)
      Beschreibung aus Klasse kopiert: Expression
      Resolve the type of this expression in the context of a blockScope
      Setzt außer Kraft:
      resolveType in Klasse Expression
      Parameter:
      scope -
      Gibt zurück:
      Return the actual type of this expression after resolution
    • containsPatternVariable

      public boolean containsPatternVariable()
      Setzt außer Kraft:
      containsPatternVariable in Klasse Statement
    • getPatternVariable

      public LocalDeclaration getPatternVariable()
      Setzt außer Kraft:
      getPatternVariable in Klasse Expression
    • traverse

      public void traverse(ASTVisitor visitor, BlockScope blockScope)
      Beschreibung aus Klasse kopiert: Expression
      Traverse an expression in the context of a blockScope
      Setzt außer Kraft:
      traverse in Klasse Expression
      Parameter:
      visitor -
      blockScope -