diff options
Diffstat (limited to 'src/main/java/com/c2kernel/collection/Parent2ChildCollection.java')
| -rw-r--r-- | src/main/java/com/c2kernel/collection/Parent2ChildCollection.java | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/main/java/com/c2kernel/collection/Parent2ChildCollection.java b/src/main/java/com/c2kernel/collection/Parent2ChildCollection.java index 814cca8..26aa451 100644 --- a/src/main/java/com/c2kernel/collection/Parent2ChildCollection.java +++ b/src/main/java/com/c2kernel/collection/Parent2ChildCollection.java @@ -3,6 +3,7 @@ package com.c2kernel.collection; import java.util.Iterator;
import com.c2kernel.common.ObjectNotFoundException;
+import com.c2kernel.lookup.ItemPath;
import com.c2kernel.persistency.ClusterStorage;
import com.c2kernel.utils.CastorHashMap;
@@ -88,10 +89,10 @@ abstract public class Parent2ChildCollection<E extends CollectionMember> impleme mMembers = newMembers;
}
- public boolean contains(int sysKey) {
+ public boolean contains(ItemPath itemPath) {
for (Object name : mMembers.list) {
CollectionMember element = (CollectionMember)name;
- if (element.getSystemKey() == sysKey)
+ if (element.getItemPath().equals(itemPath))
return true;
}
return false;
@@ -102,7 +103,7 @@ abstract public class Parent2ChildCollection<E extends CollectionMember> impleme for (int i=0; i<size(); i++)
{
CollectionMember element = mMembers.list.get(i);
- if (element.getSystemKey() == -1)
+ if (element.getItemPath() == null)
return false;
}
return true;
@@ -124,7 +125,7 @@ abstract public class Parent2ChildCollection<E extends CollectionMember> impleme }
@Override
- public abstract E addMember(int entityKey, CastorHashMap props, String classProps) throws MembershipException;
+ public abstract E addMember(ItemPath itemPath, CastorHashMap props, String classProps) throws MembershipException;
public boolean equals(Parent2ChildCollection<?> other) {
boolean same = mName.equals(other.getName()) && mURLInfo.equals(other.getURLInfo()) && size() == other.size();
|
