1 32 package org.jruby.ast; 33 34 import java.math.BigInteger ; 35 import java.util.List ; 36 37 import org.jruby.ast.types.ILiteralNode; 38 import org.jruby.ast.visitor.NodeVisitor; 39 import org.jruby.evaluator.Instruction; 40 import org.jruby.lexer.yacc.ISourcePosition; 41 42 46 public class BignumNode extends Node implements ILiteralNode { 47 static final long serialVersionUID = -8646636291868912747L; 48 49 private BigInteger value; 50 51 public BignumNode(ISourcePosition position, BigInteger value) { 52 super(position, NodeTypes.BIGNUMNODE); 53 this.value = value; 54 } 55 56 public Instruction accept(NodeVisitor iVisitor) { 57 return iVisitor.visitBignumNode(this); 58 } 59 60 64 public BigInteger getValue() { 65 return value; 66 } 67 68 public List childNodes() { 69 return EMPTY_LIST; 70 } 71 72 public void setValue(BigInteger value) { 73 this.value = value; 74 } 75 76 } 77 | Popular Tags |