From a6e4cbb93c629905489de971e84e4914d5a25e2c Mon Sep 17 00:00:00 2001 From: Benjamin Culkin Date: Tue, 21 May 2024 17:02:38 -0400 Subject: Small tweaks --- .../src/main/java/net/wotonomy/foundation/NSArray.java | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) (limited to 'projects/net.wotonomy.foundation/src/main/java/net') diff --git a/projects/net.wotonomy.foundation/src/main/java/net/wotonomy/foundation/NSArray.java b/projects/net.wotonomy.foundation/src/main/java/net/wotonomy/foundation/NSArray.java index e79c206..175c3a1 100644 --- a/projects/net.wotonomy.foundation/src/main/java/net/wotonomy/foundation/NSArray.java +++ b/projects/net.wotonomy.foundation/src/main/java/net/wotonomy/foundation/NSArray.java @@ -41,11 +41,13 @@ import java.util.ListIterator; * @author $Author: cgruber $ * @version $Revision: 929 $ */ -public class NSArray implements List, Serializable { +public class NSArray implements List, Serializable { + private static final long serialVersionUID = 3640615326084287961L; + /** * Actual list that backs this instance. */ - List list; + List list; /** * Return value when array index is not found. @@ -62,7 +64,7 @@ public class NSArray implements List, Serializable { * an internal representation that is returned by a method of return type * NSArray. */ - public static NSArray arrayBackedByList(List aList) { + public static NSArray arrayBackedByList(List aList) { return new NSArray(aList, null); } @@ -80,7 +82,7 @@ public class NSArray implements List, Serializable { * @param ignored This parameter is entirely ignored, and is only there to * distinguish the API. */ - NSArray(List aList, Object ignored) // differentiates + NSArray(List aList, Object ignored) // differentiates { list = aList; } @@ -89,14 +91,14 @@ public class NSArray implements List, Serializable { * Constructor with a size hint, used by NSMutableArray. */ NSArray(int aSize) { - list = new ArrayList(aSize); + list = new ArrayList<>(aSize); } /** * Default constructor returns an empty array. */ public NSArray() { - list = new ArrayList(); + list = new ArrayList<>(); } /** @@ -120,7 +122,7 @@ public class NSArray implements List, Serializable { /** * Produces an array containing the objects in the specified collection. */ - public NSArray(Collection aCollection) { + public NSArray(Collection aCollection) { this(); Iterator i = aCollection.iterator(); while (i.hasNext()) -- cgit v1.2.3