summaryrefslogtreecommitdiff
path: root/src/main/java/com/c2kernel/collection/AggregationInstance.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/com/c2kernel/collection/AggregationInstance.java')
-rw-r--r--src/main/java/com/c2kernel/collection/AggregationInstance.java17
1 files changed, 9 insertions, 8 deletions
diff --git a/src/main/java/com/c2kernel/collection/AggregationInstance.java b/src/main/java/com/c2kernel/collection/AggregationInstance.java
index 47e7c41..f46b691 100644
--- a/src/main/java/com/c2kernel/collection/AggregationInstance.java
+++ b/src/main/java/com/c2kernel/collection/AggregationInstance.java
@@ -6,6 +6,7 @@ package com.c2kernel.collection;
*/
import com.c2kernel.graph.model.GraphPoint;
+import com.c2kernel.lookup.ItemPath;
import com.c2kernel.utils.CastorHashMap;
public class AggregationInstance extends Aggregation
@@ -23,23 +24,23 @@ public class AggregationInstance extends Aggregation
@Override
- public AggregationMember addMember(int entityKey, CastorHashMap props, String classProps)
+ public AggregationMember addMember(ItemPath itemPath, CastorHashMap props, String classProps)
throws MembershipException
{
- if( entityKey!=-1 && exists(entityKey))
- throw new MembershipException(entityKey+" already exists in this collection.");
+ if( itemPath != null && exists(itemPath))
+ throw new MembershipException(itemPath+" already exists in this collection.");
else
- return super.addMember(entityKey, props, classProps);
+ return super.addMember(itemPath, props, classProps);
}
@Override
- public AggregationMember addMember(int entityKey, CastorHashMap props, String classProps, GraphPoint location, int w, int h)
+ public AggregationMember addMember(ItemPath itemPath, CastorHashMap props, String classProps, GraphPoint location, int w, int h)
throws MembershipException
{
- if( entityKey!=-1 && exists(entityKey))
- throw new MembershipException(entityKey+" already exists in this collection.");
+ if( itemPath != null && exists(itemPath))
+ throw new MembershipException(itemPath+" already exists in this collection.");
else
- return super.addMember(entityKey, props, classProps, location, w, h);
+ return super.addMember(itemPath, props, classProps, location, w, h);
}
}