vutbr.checkers.protocol
Class ProtocolOutput

java.lang.Object
  extended by java.lang.Thread
      extended by vutbr.checkers.protocol.ProtocolOutput
All Implemented Interfaces:
java.lang.Runnable

public class ProtocolOutput
extends java.lang.Thread

Trida ProtocolOutput

Author:
Ondrej Novy

Nested Class Summary
 
Nested classes/interfaces inherited from class java.lang.Thread
java.lang.Thread.State, java.lang.Thread.UncaughtExceptionHandler
 
Field Summary
 
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Constructor Summary
ProtocolOutput(java.io.BufferedWriter bufferedWriter)
          Konstruktor
 
Method Summary
 void run()
          Hlavni smycka odesilani dat ve fronte
 void send(ProtocolLine line)
          Prida pozadavek na odeslani radku do fronty
 void waitEmpty()
          Ceka na vyprazdneni odchozi fronty
 
Methods inherited from class java.lang.Thread
activeCount, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, checkAccess, 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
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ProtocolOutput

public ProtocolOutput(java.io.BufferedWriter bufferedWriter)
Konstruktor

Parameters:
bufferedWriter - Bufferovany vystup
Method Detail

run

public void run()
Hlavni smycka odesilani dat ve fronte

Specified by:
run in interface java.lang.Runnable
Overrides:
run in class java.lang.Thread

send

public void send(ProtocolLine line)
Prida pozadavek na odeslani radku do fronty

Parameters:
line - Radek k odeslani

waitEmpty

public void waitEmpty()
Ceka na vyprazdneni odchozi fronty