001/*
002 * Copyright (c) 2012-2018 Institut National des Sciences Appliquées de Lyon (INSA Lyon) and others
003 *
004 * This program and the accompanying materials are made available under the
005 * terms of the Eclipse Public License 2.0 which is available at
006 * http://www.eclipse.org/legal/epl-2.0.
007 *
008 * SPDX-License-Identifier: EPL-2.0
009 */
010
011package org.eclipse.golo.compiler.parser;
012
013public class ASTLiteral extends GoloASTNode {
014
015  private Object literalValue;
016
017  public ASTLiteral(int i) {
018    super(i);
019  }
020
021  public ASTLiteral(GoloParser p, int i) {
022    super(p, i);
023  }
024
025  public Object getLiteralValue() {
026    return literalValue;
027  }
028
029  public void setLiteralValue(Object literalValue) {
030    this.literalValue = literalValue;
031  }
032
033  @Override
034  public String toString() {
035    return String.format("ASTLiteral{literalValue=%s}", literalValue);
036  }
037
038  @Override
039  public Object jjtAccept(GoloParserVisitor visitor, Object data) {
040    return visitor.visit(this, data);
041  }
042}