equal
deleted
inserted
replaced
120 DocFlavor psInFormat = DocFlavor.INPUT_STREAM.POSTSCRIPT; |
120 DocFlavor psInFormat = DocFlavor.INPUT_STREAM.POSTSCRIPT; |
121 Doc myDoc = new SimpleDoc(psStream, psInFormat, null); |
121 Doc myDoc = new SimpleDoc(psStream, psInFormat, null); |
122 PrintRequestAttributeSet aset = |
122 PrintRequestAttributeSet aset = |
123 new HashPrintRequestAttributeSet(); |
123 new HashPrintRequestAttributeSet(); |
124 aset.add(new Copies(5)); |
124 aset.add(new Copies(5)); |
125 aset.add(MediaSize.A4); |
125 aset.add(MediaSizeName.ISO_A4); |
126 aset.add(Sides.DUPLEX); |
126 aset.add(Sides.DUPLEX); |
127 PrintService[] services = |
127 PrintService[] services = |
128 PrintServiceLookup.lookupPrintServices(psInFormat, aset); |
128 PrintServiceLookup.lookupPrintServices(psInFormat, aset); |
129 if (services.length > 0) { |
129 if (services.length > 0) { |
130 DocPrintJob job = services[0].createPrintJob(); |
130 DocPrintJob job = services[0].createPrintJob(); |