< prev index next >

src/java.desktop/unix/classes/sun/print/IPPPrintService.java

Print this page

        

@@ -1,7 +1,7 @@
 /*
- * Copyright (c) 2003, 2014, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2003, 2018, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
  * under the terms of the GNU General Public License version 2 only, as
  * published by the Free Software Foundation.  Oracle designates this

@@ -579,11 +579,11 @@
                 }
             }
         } else if (category == JobName.class) {
             return new JobName("Java Printing", null);
         } else if (category == JobSheets.class) {
-            JobSheets arr[] = new JobSheets[2];
+            JobSheets[] arr = new JobSheets[2];
             arr[0] = JobSheets.NONE;
             arr[1] = JobSheets.STANDARD;
             return arr;
 
         } else if (category == Media.class) {

@@ -1756,15 +1756,15 @@
 
     private void opGetAttributes() {
         try {
             debug_println(debugPrefix+"opGetAttributes myURI "+myURI+" myURL "+myURL);
 
-            AttributeClass attClNoUri[] = {
+            AttributeClass[] attClNoUri = {
                 AttributeClass.ATTRIBUTES_CHARSET,
                 AttributeClass.ATTRIBUTES_NATURAL_LANGUAGE};
 
-            AttributeClass attCl[] = {
+            AttributeClass[] attCl = {
                 AttributeClass.ATTRIBUTES_CHARSET,
                 AttributeClass.ATTRIBUTES_NATURAL_LANGUAGE,
                 new AttributeClass("printer-uri",
                                    AttributeClass.TAG_URI,
                                    ""+myURI)};

@@ -1882,11 +1882,11 @@
 
         if (inputStream == null) {
             return null;
         }
 
-        byte response[] = new byte[MAX_ATTRIBUTE_LENGTH];
+        byte[] response = new byte[MAX_ATTRIBUTE_LENGTH];
         try {
 
             DataInputStream ois = new DataInputStream(inputStream);
 
             // read status and ID

@@ -1929,11 +1929,11 @@
                         if ((len != 0) && (attribStr != null)) {
                             //last byte is the total # of values
                             outObj.write(counter);
                             outObj.flush();
                             outObj.close();
-                            byte outArray[] = outObj.toByteArray();
+                            byte[] outArray = outObj.toByteArray();
 
                             // if key exists, new HashMap
                             if (responseMap.containsKey(attribStr)) {
                                 respList.add(responseMap);
                                 responseMap = new HashMap<>();

@@ -1993,11 +1993,11 @@
                             responseMap.containsKey(attribStr)) {
                             respList.add(responseMap);
                             responseMap = new HashMap<>();
                         }
 
-                        byte outArray[] = outObj.toByteArray();
+                        byte[] outArray = outObj.toByteArray();
 
                         AttributeClass ac =
                             new AttributeClass(attribStr,
                                                valTagByte,
                                                outArray);
< prev index next >