Package com.pi4j.util
Class Console
- java.lang.Object
-
- com.pi4j.util.Console
-
public class Console extends Object
-
-
Field Summary
Fields Modifier and Type Field Description static String
CLEAR_SCREEN_ESCAPE_SEQUENCE
static String
ERASE_LINE_ESCAPE_SEQUENCE
protected boolean
exiting
static String
LINE_SEPARATOR
static char
LINE_SEPARATOR_CHAR
-
Constructor Summary
Constructors Constructor Description Console()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Console
box(int padding, String... lines)
Console
box(String... lines)
Console
clearScreen()
Console
emptyLine()
Console
emptyLine(int number)
Console
eraseLine()
void
exit()
boolean
exiting()
Console
goodbye()
boolean
isRunning()
Console
print(Object data)
Console
print(String data)
Console
print(String format, Object... args)
Console
println()
Console
println(char character, int repeat)
Console
println(Object line)
Console
println(String line)
Console
println(String format, Object... args)
Console
promptForExit()
Console
separatorLine()
Console
separatorLine(char character)
Console
separatorLine(char character, int length)
Console
title(String... title)
void
waitForExit()
-
-
-
Field Detail
-
CLEAR_SCREEN_ESCAPE_SEQUENCE
public static final String CLEAR_SCREEN_ESCAPE_SEQUENCE
- See Also:
- Constant Field Values
-
ERASE_LINE_ESCAPE_SEQUENCE
public static final String ERASE_LINE_ESCAPE_SEQUENCE
- See Also:
- Constant Field Values
-
LINE_SEPARATOR_CHAR
public static final char LINE_SEPARATOR_CHAR
- See Also:
- Constant Field Values
-
LINE_SEPARATOR
public static final String LINE_SEPARATOR
-
exiting
protected boolean exiting
-
-
Method Detail
-
println
public Console println()
-
println
public Console println(char character, int repeat)
-
emptyLine
public Console emptyLine()
-
emptyLine
public Console emptyLine(int number)
-
separatorLine
public Console separatorLine()
-
separatorLine
public Console separatorLine(char character)
-
separatorLine
public Console separatorLine(char character, int length)
-
goodbye
public Console goodbye()
-
clearScreen
public Console clearScreen()
-
eraseLine
public Console eraseLine()
-
promptForExit
public Console promptForExit()
-
waitForExit
public void waitForExit() throws InterruptedException
- Throws:
InterruptedException
-
exiting
public boolean exiting()
-
isRunning
public boolean isRunning()
-
exit
public void exit()
-
-