Class MapExpression

All Implemented Interfaces:
GroovydocHolder<AnnotatedNode>, NodeMetaDataHandler
Direct Known Subclasses:

public class MapExpression
extends Expression
Represents a map expression [1 : 2, "a" : "b", x : y] which creates a mutable Map
  • Constructor Details

    • MapExpression

      public MapExpression()
    • MapExpression

      public MapExpression​(java.util.List<MapEntryExpression> mapEntryExpressions)
  • Method Details

    • addMapEntryExpression

      public void addMapEntryExpression​(MapEntryExpression expression)
    • getMapEntryExpressions

      public java.util.List<MapEntryExpression> getMapEntryExpressions()
    • visit

      public void visit​(GroovyCodeVisitor visitor)
      visit in class ASTNode
    • isDynamic

      public boolean isDynamic()
    • transformExpression

      public Expression transformExpression​(ExpressionTransformer transformer)
      Description copied from class: Expression
      Return a copy of the expression calling the transformer on any nested expressions
      Specified by:
      transformExpression in class Expression
    • toString

      public java.lang.String toString()
      toString in class java.lang.Object
    • getText

      public java.lang.String getText()
      getText in class ASTNode
    • addMapEntryExpression

      public void addMapEntryExpression​(Expression keyExpression, Expression valueExpression)