Examples of QueuedJobCount


Examples of javax.print.attribute.standard.QueuedJobCount

            attributes.add(PrinterIsAcceptingJobs.ACCEPTING_JOBS);
        }
       
        int jobCount = getQueuedJobCount(serviceName);
        if (jobCount >= 0) {
            attributes.add(new QueuedJobCount(jobCount));
        }
        return attributes;
    }
View Full Code Here

Examples of javax.print.attribute.standard.QueuedJobCount

    private QueuedJobCount getQueuedJobCount() {

        int count = getJobStatus(printer, 1);
        if (count != -1) {
            return new QueuedJobCount(count);
        }
        else {
            return new QueuedJobCount(0);
        }
    }
View Full Code Here

Examples of javax.print.attribute.standard.QueuedJobCount

        }
    }

    public static QueuedJobCount getQueuedJobCount(final long handle)
                    throws PrintException {
        return new QueuedJobCount(getQueuedJobs(handle));
    }
View Full Code Here

Examples of javax.print.attribute.standard.QueuedJobCount

            attributes.add(PrinterIsAcceptingJobs.ACCEPTING_JOBS);
        }
       
        int jobCount = getQueuedJobCount(serviceName);
        if (jobCount >= 0) {
            attributes.add(new QueuedJobCount(jobCount));
        }
        return attributes;
    }
View Full Code Here

Examples of javax.print.attribute.standard.QueuedJobCount

            attributes.add(PrinterIsAcceptingJobs.ACCEPTING_JOBS);
        }
       
        int jobCount = getQueuedJobCount(serviceName);
        if (jobCount >= 0) {
            attributes.add(new QueuedJobCount(jobCount));
        }
        return attributes;
    }
View Full Code Here

Examples of javax.print.attribute.standard.QueuedJobCount

                    attrx.add(a);
                }
            }
        } else if (aname.equals("queued-job-count")) {
            for (int i = 0, ii = avalue.size(); i < ii; i++) {
                a = new QueuedJobCount(((Integer) avalue.get(i)).intValue());
                if (a != null) {
                    attrx.add(a);
                }
            }
        } else if (aname.equals("printer-state-reason")
View Full Code Here

Examples of javax.print.attribute.standard.QueuedJobCount

                    attrx.add(a);
                }
            }
        } else if (aname.equals("queued-job-count")) {
            for (int i = 0, ii = avalue.size(); i < ii; i++) {
                a = new QueuedJobCount(((Integer) avalue.get(i)).intValue());
                if (a != null) {
                    attrx.add(a);
                }
            }
        } else if (aname.equals("printer-state-reason")
View Full Code Here

Examples of javax.print.attribute.standard.QueuedJobCount

            attributes.add(PrinterIsAcceptingJobs.ACCEPTING_JOBS);
        }
       
        int jobCount = getQueuedJobCount(serviceName);
        if (jobCount >= 0) {
            attributes.add(new QueuedJobCount(jobCount));
        }
        return attributes;
    }
View Full Code Here

Examples of javax.print.attribute.standard.QueuedJobCount

    private QueuedJobCount getQueuedJobCount() {

        int count = getJobStatus(printer, 1);
        if (count != -1) {
            return new QueuedJobCount(count);
        }
        else {
            return new QueuedJobCount(0);
        }
    }
View Full Code Here

Examples of javax.print.attribute.standard.QueuedJobCount

    private QueuedJobCount getQueuedJobCountSysV() {
        String command = "/usr/bin/lpstat -R " + printer;
        String results[]= UnixPrintServiceLookup.execCmd(command);
        int qlen = (results == null) ? 0 : results.length;

        return new QueuedJobCount(qlen);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.