Package software.amazon.smithy.cli
Interface CliPrinter
-
- All Superinterfaces:
java.lang.Appendable
,java.io.Flushable
public interface CliPrinter extends java.lang.Appendable, java.io.Flushable
Handles text output of the CLI.
-
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description CliPrinter
append(char c)
default CliPrinter
append(java.lang.CharSequence csq)
CliPrinter
append(java.lang.CharSequence csq, int start, int end)
default void
flush()
Flushes any buffers in the printer.static CliPrinter
fromOutputStream(java.io.OutputStream stream)
Create a new CliPrinter from an OutputStream.default CliPrinter
println(java.lang.String text)
Prints text to the writer and appends a new line.
-
-
-
Method Detail
-
append
CliPrinter append(char c)
- Specified by:
append
in interfacejava.lang.Appendable
-
append
default CliPrinter append(java.lang.CharSequence csq)
- Specified by:
append
in interfacejava.lang.Appendable
-
append
CliPrinter append(java.lang.CharSequence csq, int start, int end)
- Specified by:
append
in interfacejava.lang.Appendable
-
println
default CliPrinter println(java.lang.String text)
Prints text to the writer and appends a new line.- Parameters:
text
- Text to print.
-
flush
default void flush()
Flushes any buffers in the printer.- Specified by:
flush
in interfacejava.io.Flushable
-
fromOutputStream
static CliPrinter fromOutputStream(java.io.OutputStream stream)
Create a new CliPrinter from an OutputStream.- Parameters:
stream
- OutputStream to write to.- Returns:
- Returns the created CliPrinter.
-
-