org.gnu.jcifs
Class CifsPrintJobInfo

java.lang.Object
  |
  +--org.gnu.jcifs.CifsPrintJobInfo

public final class CifsPrintJobInfo
extends java.lang.Object

A CifsPrintJobInfo contains informations about a print job. (Corresponds to the structure PSJINFO_2).

Since:
1.0

Field Summary
(package private)  java.lang.String fComment
           
(package private)  java.lang.String fDocument
           
(package private)  int fJobId
           
(package private)  int fPosition
           
(package private)  int fPriority
           
(package private)  long fSize
           
(package private)  int fStatus
           
(package private)  long fSubmitted
           
(package private)  java.lang.String fUserName
           
static int PRJ_COMPLETE
          Print job is complete
static int PRJ_DESTCRTCHG
          The printer is waiting for a cartridge change
static int PRJ_DESTENCHG
          The printer is waiting for a pen change
static int PRJ_DESTFORMCHG
          The printer is waiting for a form change
static int PRJ_DESTNOPAPER
          The print destination is out of paper
static int PRJ_DESTOFFLINE
          The print destination is offline
static int PRJ_DESTPAUSED
          The print destination is paused
static int PRJ_ERROR
          Print job is spooling
static int PRJ_INTERV
          An error occurred
static int PRJ_NOTIFY
          An alert is raised
static int PRJ_PRINTING
          An alert indicates the job was deleted
static int PRJ_QS_PAUSED
          Print job is paused
static int PRJ_QS_PRINTING
          Print job is printing, Print Job Status is valid
static int PRJ_QS_QUEUED
          Print job is queued
static int PRJ_QS_SPOOLING
          Print job is spooling
 
Constructor Summary
(package private) CifsPrintJobInfo()
           
 
Method Summary
 boolean equals(java.lang.Object obj)
          Compares if the two object are the same (same Job ID)
 java.lang.String getComment()
          Returns the comment about the print job
 java.lang.String getDocument()
          Returns the name of the document
 int getJobId()
          JobId uniquely specifies a print job within a printer queue.
 int getPosition()
          Position specifies the position of the print job within the print queue.
 int getPrintJobQueueStatus()
          Returns the status of the print queue.
 int getPrintJobStatus()
          Returns the status of the print job.
 int getPriority()
          Priority specifies the print job priority.
 long getSize()
          Returns the size of the print job in terms of number of bytes.
 long getSubmittedTime()
          Return the time when the user submitted the job.
 java.lang.String getUserName()
          The user name specifies the name of the user who submitted the print job
 
Methods inherited from class java.lang.Object
, clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PRJ_QS_QUEUED

public static final int PRJ_QS_QUEUED
Print job is queued

PRJ_QS_PAUSED

public static final int PRJ_QS_PAUSED
Print job is paused

PRJ_QS_SPOOLING

public static final int PRJ_QS_SPOOLING
Print job is spooling

PRJ_QS_PRINTING

public static final int PRJ_QS_PRINTING
Print job is printing, Print Job Status is valid

PRJ_COMPLETE

public static final int PRJ_COMPLETE
Print job is complete

PRJ_INTERV

public static final int PRJ_INTERV
An error occurred

PRJ_ERROR

public static final int PRJ_ERROR
Print job is spooling

PRJ_DESTOFFLINE

public static final int PRJ_DESTOFFLINE
The print destination is offline

PRJ_DESTPAUSED

public static final int PRJ_DESTPAUSED
The print destination is paused

PRJ_NOTIFY

public static final int PRJ_NOTIFY
An alert is raised

PRJ_DESTNOPAPER

public static final int PRJ_DESTNOPAPER
The print destination is out of paper

PRJ_DESTFORMCHG

public static final int PRJ_DESTFORMCHG
The printer is waiting for a form change

PRJ_DESTCRTCHG

public static final int PRJ_DESTCRTCHG
The printer is waiting for a cartridge change

PRJ_DESTENCHG

public static final int PRJ_DESTENCHG
The printer is waiting for a pen change

PRJ_PRINTING

public static final int PRJ_PRINTING
An alert indicates the job was deleted

fJobId

int fJobId

fPriority

int fPriority

fUserName

java.lang.String fUserName

fPosition

int fPosition

fStatus

int fStatus

fSubmitted

long fSubmitted

fSize

long fSize

fComment

java.lang.String fComment

fDocument

java.lang.String fDocument
Constructor Detail

CifsPrintJobInfo

CifsPrintJobInfo()
Method Detail

getJobId

public int getJobId()
JobId uniquely specifies a print job within a printer queue. The JobID is unique on a server. A combination of the server name and JobId is sufficient to uniquely identify a particular print job.
Returns:
jobId

getPriority

public int getPriority()
Priority specifies the print job priority. This varies from a value of 1 (lowest priority) to 99 (highest priority. Higher priority jobs print first. When 2 jobs have the same priority, the older job prints first.
Returns:
priority value

getUserName

public java.lang.String getUserName()
The user name specifies the name of the user who submitted the print job
Returns:
user name

getPosition

public int getPosition()
Position specifies the position of the print job within the print queue. If the value is 1, this print job prints next.
Returns:
position

getPrintJobQueueStatus

public int getPrintJobQueueStatus()
Returns the status of the print queue. If the status is PRJ_QS_PRINTING, the call getPrintJobStatus() returns detailed status informations.
Returns:
status (see PRJ_QS_*)

getPrintJobStatus

public int getPrintJobStatus()
Returns the status of the print job.
Returns:
status (see PRJ_*)

getSubmittedTime

public long getSubmittedTime()
Return the time when the user submitted the job. This is stored as the number of seconds elapsed since 00:00:00 Jan 1st, 1970
Returns:
time in seconds

getSize

public long getSize()
Returns the size of the print job in terms of number of bytes.
Returns:
size in bytes

getComment

public java.lang.String getComment()
Returns the comment about the print job
Returns:
comment text

getDocument

public java.lang.String getDocument()
Returns the name of the document
Returns:
document name

equals

public boolean equals(java.lang.Object obj)
Compares if the two object are the same (same Job ID)
Overrides:
equals in class java.lang.Object
Parameters:
obj - the object to test
Returns:
true of obj is the same CifsPrintJobInfo object