Class DbgTimer.TabbingOutputStream
- java.lang.Object
-
- java.io.OutputStream
-
- ghidra.app.plugin.assembler.sleigh.util.DbgTimer.TabbingOutputStream
-
- All Implemented Interfaces:
java.io.Closeable
,java.io.Flushable
,java.lang.AutoCloseable
- Enclosing class:
- DbgTimer
public static class DbgTimer.TabbingOutputStream extends java.io.OutputStream
A (rather slow) output stream that indents every line of its output
-
-
Field Summary
Fields Modifier and Type Field Description protected java.io.OutputStream
out
protected int
state
protected static int
STATE_LINE
protected static int
STATE_NOLINE
protected java.util.Stack<java.lang.Long>
timeStack
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
void
flush()
protected void
setTimeStack(java.util.Stack<java.lang.Long> timeStack)
Workaround: Set the time stack referenceprotected void
startln()
Start a new (indented) line of outputvoid
write(int b)
Parses each line and prepends the indentation as they are printed
-
-
-
Field Detail
-
STATE_NOLINE
protected static final int STATE_NOLINE
- See Also:
- Constant Field Values
-
STATE_LINE
protected static final int STATE_LINE
- See Also:
- Constant Field Values
-
out
protected java.io.OutputStream out
-
state
protected int state
-
timeStack
protected java.util.Stack<java.lang.Long> timeStack
-
-
Method Detail
-
startln
protected void startln() throws java.io.IOException
Start a new (indented) line of output- Throws:
java.io.IOException
-
setTimeStack
protected void setTimeStack(java.util.Stack<java.lang.Long> timeStack)
Workaround: Set the time stack reference- Parameters:
timeStack
- the stack
-
write
public void write(int b) throws java.io.IOException
Parses each line and prepends the indentation as they are printed- Specified by:
write
in classjava.io.OutputStream
- Throws:
java.io.IOException
-
close
public void close() throws java.io.IOException
- Specified by:
close
in interfacejava.lang.AutoCloseable
- Specified by:
close
in interfacejava.io.Closeable
- Overrides:
close
in classjava.io.OutputStream
- Throws:
java.io.IOException
-
flush
public void flush() throws java.io.IOException
- Specified by:
flush
in interfacejava.io.Flushable
- Overrides:
flush
in classjava.io.OutputStream
- Throws:
java.io.IOException
-
-