Class HtmlAnsiOutputStream
java.lang.Object
java.io.OutputStream
java.io.FilterOutputStream
org.fusesource.jansi.AnsiOutputStream
org.fusesource.jansi.HtmlAnsiOutputStream
- All Implemented Interfaces:
Closeable, Flushable, AutoCloseable
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final String[]private static final byte[]private static final byte[]private static final byte[]private static final byte[]private booleanFields inherited from class AnsiOutputStream
ATTRIBUTE_BLINK_FAST, ATTRIBUTE_BLINK_OFF, ATTRIBUTE_BLINK_SLOW, ATTRIBUTE_CONCEAL_OFF, ATTRIBUTE_CONCEAL_ON, ATTRIBUTE_INTENSITY_BOLD, ATTRIBUTE_INTENSITY_FAINT, ATTRIBUTE_INTENSITY_NORMAL, ATTRIBUTE_ITALIC, ATTRIBUTE_NEGATIVE_Off, ATTRIBUTE_NEGATIVE_OFF, ATTRIBUTE_NEGATIVE_ON, ATTRIBUTE_UNDERLINE, ATTRIBUTE_UNDERLINE_DOUBLE, ATTRIBUTE_UNDERLINE_OFF, BLACK, BLUE, CYAN, ERASE_LINE, ERASE_LINE_TO_BEGINING, ERASE_LINE_TO_END, ERASE_SCREEN, ERASE_SCREEN_TO_BEGINING, ERASE_SCREEN_TO_END, GREEN, MAGENTA, RED, RESET_CODE, REST_CODE, state, WHITE, YELLOWFields inherited from class FilterOutputStream
out -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()private voidprotected voidprocessSGR 0corresponding toReset / Normalprotected voidprocessSetAttribute(int attribute) processSGRother than0(reset),30-39(foreground),40-49(background),90-97(foreground high intensity) or100-107(background high intensity)protected voidprocessSetBackgroundColor(int color, boolean bright) processSGR 40-47orSGR 100-107corresponding toSet background coloreither in normal mode or high intensity.protected voidprocessSetForegroundColor(int color, boolean bright) processSGR 30-37orSGR 90-97corresponding toSet text color (foreground)either in normal mode or high intensity.voidwrite(int data) private voidprivate voidvoidwriteLine(byte[] buf, int offset, int len) Methods inherited from class AnsiOutputStream
processChangeIconName, processChangeIconNameAndWindowTitle, processChangeWindowTitle, processCharsetSelect, processCursorDown, processCursorDownLine, processCursorLeft, processCursorRight, processCursorTo, processCursorToColumn, processCursorUp, processCursorUpLine, processDefaultBackgroundColor, processDefaultTextColor, processDeleteLine, processEraseLine, processEraseScreen, processInsertLine, processRestoreCursorPosition, processSaveCursorPosition, processScrollDown, processScrollUp, processSetBackgroundColor, processSetBackgroundColorExt, processSetBackgroundColorExt, processSetForegroundColor, processSetForegroundColorExt, processSetForegroundColorExt, processUnknownExtension, processUnknownOperatingSystemCommandMethods inherited from class FilterOutputStream
flush, write, writeMethods inherited from class OutputStream
nullOutputStream
-
Field Details
-
concealOn
private boolean concealOn -
ANSI_COLOR_MAP
-
BYTES_QUOT
private static final byte[] BYTES_QUOT -
BYTES_AMP
private static final byte[] BYTES_AMP -
BYTES_LT
private static final byte[] BYTES_LT -
BYTES_GT
private static final byte[] BYTES_GT -
closingAttributes
-
-
Constructor Details
-
HtmlAnsiOutputStream
-
-
Method Details
-
close
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Overrides:
closein classAnsiOutputStream- Throws:
IOException
-
write
- Throws:
IOException
-
writeAttribute
- Throws:
IOException
-
closeAttributes
- Throws:
IOException
-
write
Description copied from class:AnsiOutputStream- Overrides:
writein classAnsiOutputStream- Throws:
IOException
-
writeLine
- Throws:
IOException
-
processSetAttribute
Description copied from class:AnsiOutputStreamprocessSGRother than0(reset),30-39(foreground),40-49(background),90-97(foreground high intensity) or100-107(background high intensity)- Overrides:
processSetAttributein classAnsiOutputStream- Parameters:
attribute- attribute- Throws:
IOException- IOException- See Also:
-
processAttributeRest
Description copied from class:AnsiOutputStreamprocessSGR 0corresponding toReset / Normal- Overrides:
processAttributeRestin classAnsiOutputStream- Throws:
IOException- IOException
-
processSetForegroundColor
Description copied from class:AnsiOutputStreamprocessSGR 30-37orSGR 90-97corresponding toSet text color (foreground)either in normal mode or high intensity.- Overrides:
processSetForegroundColorin classAnsiOutputStream- Parameters:
color- the text colorbright- is high intensity?- Throws:
IOException- IOException
-
processSetBackgroundColor
Description copied from class:AnsiOutputStreamprocessSGR 40-47orSGR 100-107corresponding toSet background coloreither in normal mode or high intensity.- Overrides:
processSetBackgroundColorin classAnsiOutputStream- Parameters:
color- the background colorbright- is high intensity?- Throws:
IOException- IOException
-