msv.tahiti.src.com.sun.tahiti.runtime.ll.NamedSymbol Maven / Gradle / Ivy
/*
* @(#)$Id: NamedSymbol.java 923 2001-07-20 20:45:03Z Bear $
*
* Copyright 2001 Sun Microsystems, Inc. All Rights Reserved.
*
* This software is the proprietary information of Sun Microsystems, Inc.
* Use is subject to license terms.
*
*/
package com.sun.tahiti.runtime.ll;
/**
* Non-terminal name symbol for LL grammar.
* immutable.
*
* @author
* Kohsuke KAWAGUCHI
*/
public class NamedSymbol extends NonTerminalSymbol
{
public final String name;
public NamedSymbol( String name ) {
this.name = name;
}
public String toString() {
return "N<"+name+">";
}
public LLParser.Receiver createReceiver( final LLParser.Receiver parent ) {
return new LLParser.ObjectReceiver() {
public void start() throws Exception {}
public void end() throws Exception {}
public void action( Object item ) throws Exception {
((LLParser.FieldReceiver)parent).action( item, NamedSymbol.this );
}
};
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy