Class LiteralExpression

java.lang.Object
org.openstreetmap.josm.gui.mappaint.mapcss.LiteralExpression
All Implemented Interfaces:
Expression

public class LiteralExpression extends Object implements Expression
Simple literal value, that does not depend on other expressions.
Since:
5705
  • Field Details

  • Constructor Details

    • LiteralExpression

      public LiteralExpression(Object literal)
      Constructs a new LiteralExpression.
      Parameters:
      literal - literal
  • Method Details

    • getLiteral

      public final Object getLiteral()
      Returns the literal.
      Returns:
      the literal
      Since:
      14484
    • evaluate

      public Object evaluate(Environment env)
      Description copied from interface: Expression
      Evaluate this expression.
      Specified by:
      evaluate in interface Expression
      Parameters:
      env - The environment
      Returns:
      the result of the evaluation, can be a List, String or any primitive type or wrapper classes of a primitive type.
    • toString

      public String toString()
      Overrides:
      toString in class Object