Merge "Improve JavaAttribute performance"
authorTony Tkacik <ttkacik@cisco.com>
Thu, 5 Feb 2015 09:55:03 +0000 (09:55 +0000)
committerGerrit Code Review <gerrit@opendaylight.org>
Thu, 5 Feb 2015 09:55:04 +0000 (09:55 +0000)
opendaylight/config/yang-jmx-generator/src/main/java/org/opendaylight/controller/config/yangjmxgenerator/attribute/JavaAttribute.java

index f6ce92d5069be1adbd02050176652790def8af95..6a90439bb2af4b0b3da9287ff6b850bfbf5a9f65 100644 (file)
@@ -201,7 +201,7 @@ public class JavaAttribute extends AbstractAttribute implements TypedAttribute {
             itemTypes[i++] = innerCompositeType;
         }
 
-        String[] descriptions = Arrays.copyOf(itemNames, itemNames.length);
+        String[] descriptions = itemNames.clone();
         descriptions[0] = DESCRIPTION_OF_VALUE_ATTRIBUTE_FOR_UNION;
 
         try {