jay.yydebug

Class yyAnim

public class yyAnim extends Frame implements yyDebug

delegates messages to a yyAnimPanel and optionally intercepts standard i/o. This is not java.io.Serializable.

If the panel is to simulate standard input it must be instantiated before standard input is accessed. Otherwise the reader might be waiting for a different stream.

See Also: java.lang.System#setIn

Field Summary
protected ThreadeventThread
set by the checkbox listener.
static intIN
trap java.lang.System#in.
protected static intnFrames
counts instances to exit on last close.
protected booleanoutputBreak
breakpoint, only(!)
static intOUT
trap java.lang.System#out.
protected yyAnimPanelpanel
input, stack, and comments.
Constructor Summary
yyAnim(String title, int io)
creates and displays the frame.
yyAnim(Class system, String title, int io)
creates and displays the frame.
Method Summary
voidaccept(Object value)
voiddiscard(int state, int token, String name, Object value)
voiderror(String message)
voidlex(int state, int token, String name, Object value)
voidpop(int state)
voidpush(int state, Object value)
voidreduce(int from, int to, int rule, String text, int len)
voidreject()
static voidsetStaggeredLocation(Component c)
try to cascade multiple instances of components.
voidshift(int from, int to, int errorFlag)
voidshift(int from, int to)

Field Detail

eventThread

protected Thread eventThread
set by the checkbox listener.

IN

public static final int IN
trap java.lang.System#in.

nFrames

protected static int nFrames
counts instances to exit on last close.

outputBreak

protected boolean outputBreak
breakpoint, only(!) set in GUI.

OUT

public static final int OUT
trap java.lang.System#out.

panel

protected yyAnimPanel panel
input, stack, and comments.

Constructor Detail

yyAnim

public yyAnim(String title, int io)
creates and displays the frame.

Parameters: io flags to trap standard input, and/or standard and diagnostic output.

yyAnim

public yyAnim(Class system, String title, int io)
creates and displays the frame.

Parameters: system hook to spoof java.lang.System. io flags to trap standard input, and/or standard and diagnostic output.

Method Detail

accept

public void accept(Object value)

discard

public void discard(int state, int token, String name, Object value)

error

public void error(String message)

lex

public void lex(int state, int token, String name, Object value)

pop

public void pop(int state)

push

public void push(int state, Object value)

reduce

public void reduce(int from, int to, int rule, String text, int len)

reject

public void reject()

setStaggeredLocation

public static void setStaggeredLocation(Component c)
try to cascade multiple instances of components.

shift

public void shift(int from, int to, int errorFlag)

shift

public void shift(int from, int to)