|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.lang.Thread
base.LCDController
public class LCDController
This class comtains the functionality to send data to an optionally connected LCD. This is done via
lcdproc and the related classes of com.vwp.jLCD of the Java XTools. This class consisnts of several
service methods and an onw thread. The thread displays some interesting statistic information after
a timeout. This timeout elapses only when no other, usage-relevant data are displayed via the other
service methods meanwhile.
Within the display two text lines are created, the first line is a scrolling widget that is able to
hold texts that are larger than the display, the second one is a fixed widget where thexts should
be set only that fit into the display, elsewhere the right part will be skipped.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class java.lang.Thread |
|---|
Thread.State, Thread.UncaughtExceptionHandler |
| Field Summary |
|---|
| Fields inherited from class java.lang.Thread |
|---|
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY |
| Constructor Summary | |
|---|---|
LCDController(String title)
The standard constructor for an object of type LCDController establishes the connection to the lcdproc server and starts the internal thread that checks for the user input timeout |
|
| Method Summary | |
|---|---|
String |
getText(int num)
Fetches a line of text that is currently set as standard text. |
void |
ping()
This method has to be called for every user interaction that does not change the data displayed within the LCD so that it is able to restart the timeout counter without changing anything within the display or - when a timeout is active - to display the last data that have been active before the current timeout ocurred |
void |
resetErrorText()
Removes the currently displayed error texts and switch back to the formerly shown standard information |
void |
resetMessageText()
Removes the currently displayed message texts and switch back to the formerly shown standard information |
void |
resetSaverTexts()
Removes the currently displayed saver texts and switch back to the formerly shown standard information |
void |
run()
|
void |
setErrorText(String text)
Sets two error texts to be displayed left-aligned and with a bigger priority than the standard texts; this method does not overwrite the standard texts, with a call to resetErrorText() the error text is removed and the previously used standard texts are displayed again |
void |
setMessageText(String text)
Sets two message texts to be displayed left-aligned and with a bigger priority than the standard texts; this method does not overwrite the standard texts, with a call to resetMessageText() the message texts are removed and the previously used standard texts are displayed again |
void |
setTexts(String t1,
String t2)
Sets two standard texts to be displayed left-aligned |
void |
setTexts(String t1,
String t2,
boolean center)
Sets two standard texts to be displayed |
| Methods inherited from class java.lang.Thread |
|---|
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public LCDController(String title)
title - the name for the lcdproc scoller widget in first line of the LCD| Method Detail |
|---|
public void run()
run in interface Runnablerun in class Threadpublic void ping()
public void setTexts(String t1,
String t2)
t1 - the text for the first line within the displayt2 - the text for the second line within the display
public void setTexts(String t1,
String t2,
boolean center)
t1 - the text for the first line within the displayt2 - the text for the second line within the displaycenter - when this value is set to false the texts are displayed left-aligned, when it
is true they are centeredpublic String getText(int num)
num - the line for which the text has to be fetched
public void setErrorText(String text)
t1 - the error text for the first line within the displayt2 - the error text for the second line within the displaypublic void resetErrorText()
public void setMessageText(String text)
t1 - the message text for the first line within the displayt2 - the message text for the second line within the displaypublic void resetMessageText()
public void resetSaverTexts()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||