From 736a280771cac7b6002aa66432b5b83ffdee0963 Mon Sep 17 00:00:00 2001 From: Harvey Harrison Date: Tue, 2 Jul 2013 21:41:57 -0700 Subject: j3dcore: annotate targets array in Targets, remove two methods that had incorrect types Signed-off-by: Harvey Harrison --- src/classes/share/javax/media/j3d/Targets.java | 26 +++++--------------------- 1 file changed, 5 insertions(+), 21 deletions(-) diff --git a/src/classes/share/javax/media/j3d/Targets.java b/src/classes/share/javax/media/j3d/Targets.java index adfff46..d151756 100644 --- a/src/classes/share/javax/media/j3d/Targets.java +++ b/src/classes/share/javax/media/j3d/Targets.java @@ -40,23 +40,15 @@ class Targets { static final int BLN_TARGETS = 5; // For boundingLeaf nodes. static final int GRP_TARGETS = 6; // For group nodes. - ArrayList[] targetList = new ArrayList[MAX_NODELIST]; + ArrayList[] targetList = new ArrayList[MAX_NODELIST]; void addNode(NnuId node, int targetType) { if(targetList[targetType] == null) - targetList[targetType] = new ArrayList(1); + targetList[targetType] = new ArrayList(1); targetList[targetType].add(node); } - void addNodeArray(NnuId[] nodeArr, int targetType) { - if(targetList[targetType] == null) - targetList[targetType] = new ArrayList(1); - - targetList[targetType].add(nodeArr); - } - - void removeNode(int index, int targetType) { if(targetList[targetType] != null) { targetList[targetType].remove(index); @@ -64,9 +56,9 @@ class Targets { } - void addNodes(ArrayList nodeList, int targetType) { + void addNodes(ArrayList nodeList, int targetType) { if(targetList[targetType] == null) - targetList[targetType] = new ArrayList(1); + targetList[targetType] = new ArrayList(1); targetList[targetType].addAll(nodeList); } @@ -93,7 +85,7 @@ class Targets { cachedTargets.targetArr[i] = nArr; // System.err.println("Before sort : "); // NnuIdManager.printIds(cachedTargets.targetArr[i]); - NnuIdManager.sort((NnuId[])cachedTargets.targetArr[i]); + NnuIdManager.sort(cachedTargets.targetArr[i]); // System.err.println("After sort : "); // NnuIdManager.printIds(cachedTargets.targetArr[i]); } else { @@ -191,14 +183,6 @@ class Targets { return empty; } - void addCachedTargets(CachedTargets cachedTargets) { - for(int i=0; i