public class RenderAppendable extends Object implements Appendable, ScreenContext
| Modifier and Type | Field and Description |
|---|---|
private ScreenContext |
context
.
|
private LinkedList<Style.Composite> |
stack
.
|
| Constructor and Description |
|---|
RenderAppendable(ScreenContext context) |
| Modifier and Type | Method and Description |
|---|---|
RenderAppendable |
append(char c) |
RenderAppendable |
append(CharSequence csq) |
RenderAppendable |
append(CharSequence csq,
int start,
int end) |
void |
enterStyle(Style.Composite style) |
void |
flush() |
private Boolean |
foo(Boolean last,
Boolean merged) |
private Color |
foo(Color last,
Color merged,
Color def) |
Class<Chunk> |
getConsumedType() |
int |
getHeight()
Returns the screen height in chars.
|
private Style.Composite |
getMerged()
Compute the current merged style.
|
int |
getWidth()
Returns the screen width in chars.
|
Style.Composite |
leaveStyle() |
private void |
safeAppend(Chunk chunk) |
void |
styleOff() |
void |
styleOn() |
void |
write(Chunk chunk)
Write a chunk to the screen.
|
private final ScreenContext context
private LinkedList<Style.Composite> stack
public RenderAppendable(ScreenContext context)
private void safeAppend(Chunk chunk)
public void write(Chunk chunk) throws IOException
ScreenContextwrite in interface ScreenContextchunk - the chunkIOException - any io exceptionpublic Class<Chunk> getConsumedType()
public int getWidth()
ScreenContextgetWidth in interface ScreenContextpublic int getHeight()
ScreenContextgetHeight in interface ScreenContextpublic void flush() throws IOException
flush in interface FlushableIOExceptionpublic RenderAppendable append(CharSequence csq)
append in interface Appendablepublic void enterStyle(Style.Composite style)
public Style.Composite leaveStyle()
private Style.Composite getMerged()
public void styleOff()
public void styleOn()
public RenderAppendable append(CharSequence csq, int start, int end)
append in interface Appendablepublic RenderAppendable append(char c)
append in interface AppendableCopyright © 2014 eXo Platform SAS. All Rights Reserved.