net.sf.lpr.spi
Class AbstractQueueDepth
java.lang.Object
net.sf.lpr.spi.AbstractQueueDepth
- All Implemented Interfaces:
- LPR
- Direct Known Subclasses:
- LPRQueueDepthLong, LPRQueueDepthShort
public abstract class AbstractQueueDepth
- extends java.lang.Object
- implements LPR
Abstract class for sharing the basic code of querying the print queue for its depth. The differentiation comes for the two query
commands is the code that is sent to the server.
- Author:
- myersgw
Constructor Summary |
protected |
AbstractQueueDepth(java.lang.String serverName,
java.lang.String queue,
java.io.Writer response)
|
Method Summary |
protected abstract DaemonCommand |
getSendQueueState(java.io.PrintStream print,
java.io.InputStream serverIn,
java.lang.String queue,
java.io.Writer response)
|
void |
print()
call this method to actually make the request to the LPD server. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AbstractQueueDepth
protected AbstractQueueDepth(java.lang.String serverName,
java.lang.String queue,
java.io.Writer response)
- Parameters:
serverName
- the name of the server that should be queried.queue
- the name of the queue on the server that is to be queried.response
- Writer
that the LPD server's response will be written to.
getSendQueueState
protected abstract DaemonCommand getSendQueueState(java.io.PrintStream print,
java.io.InputStream serverIn,
java.lang.String queue,
java.io.Writer response)
print
public void print()
throws IORuntimeException
- call this method to actually make the request to the LPD server.
- Specified by:
print
in interface LPR
- Throws:
IORuntimeException