public class IppHandler
extends java.lang.Object
| Constructor and Description |
|---|
IppHandler(java.nio.file.Path recordDir)
Instantiates a new IPP handler.
|
IppHandler(java.net.URI forwardURI)
Instantiates a new IPP handler.
|
| Modifier and Type | Method and Description |
|---|---|
IppResponse |
cancelJob(java.net.URI printerURI,
int jobId)
Cancels a (created) job.
|
IppResponse |
createJob(java.net.URI printerURI)
Creates a new job.
|
IppResponse |
getJobs(java.net.URI printerURI)
Gets all jobs of a printer.
|
IppResponse |
getPrinterAttributes(java.net.URI printerURI)
Sends a get-printer-attributes to CUPS.
|
IppResponse |
printJob(java.net.URI printerURI,
java.nio.file.Path path)
Sends a print job to the printer.
|
IppResponse |
send(IppRequest ippRequest)
Sends an IPP request to a CUPS server.
|
IppResponse |
sendDocument(java.net.URI printerURI,
java.nio.file.Path path,
int jobId,
boolean lastDocument)
Sends one print job of a multiple document to the printer
|
java.lang.String |
toString() |
public IppHandler(java.net.URI forwardURI)
forwardURI - the forward uri where to store the requests/responsespublic IppHandler(java.nio.file.Path recordDir)
recordDir - directory where requests and responses are recordedpublic IppResponse printJob(java.net.URI printerURI, java.nio.file.Path path)
printerURI - printer URIpath - file to be printedpublic IppResponse getJobs(java.net.URI printerURI)
printerURI - printer URIpublic IppResponse createJob(java.net.URI printerURI)
printerURI - printer URIpublic IppResponse sendDocument(java.net.URI printerURI, java.nio.file.Path path, int jobId, boolean lastDocument)
printerURI - printer URIpath - file to be printedjobId - the job idlastDocument - if it is the last documentpublic IppResponse cancelJob(java.net.URI printerURI, int jobId)
printerURI - printer URIjobId - the job idpublic IppResponse getPrinterAttributes(java.net.URI printerURI)
printerURI - printer URIpublic IppResponse send(IppRequest ippRequest)
IppResponse. But in some case (like the
get-printers operation the answer is returned as HTML page.ippRequest - the ipp requestpublic java.lang.String toString()
toString in class java.lang.ObjectCopyright © 2018–2020. All rights reserved.