summaryrefslogtreecommitdiff
path: root/source/com/c2kernel/lifecycle/CompositeActivityDef.java
diff options
context:
space:
mode:
authorabranson <andrew.branson@cern.ch>2011-08-04 00:42:34 +0200
committerabranson <andrew.branson@cern.ch>2011-08-04 00:42:34 +0200
commit0ec8481c10cd8277d84c7c1a785483a0a739e5a0 (patch)
tree5f6e5d9ae75193e67e6f3b3dfa488960c5cde1d5 /source/com/c2kernel/lifecycle/CompositeActivityDef.java
parent036cbdba66f804743c4c838ed598d6972c4b3e17 (diff)
More code cleanup:
Refactored Entity Proxy Subscription to handle generics better Rewrote RemoteMap to use TreeMap instead of the internal array for order. It now sorts its keys by number if they parse, else as strings. Removed a no-longer-in-progress outcome form class
Diffstat (limited to 'source/com/c2kernel/lifecycle/CompositeActivityDef.java')
-rw-r--r--[-rwxr-xr-x]source/com/c2kernel/lifecycle/CompositeActivityDef.java26
1 files changed, 14 insertions, 12 deletions
diff --git a/source/com/c2kernel/lifecycle/CompositeActivityDef.java b/source/com/c2kernel/lifecycle/CompositeActivityDef.java
index a46cc50..86b6f88 100755..100644
--- a/source/com/c2kernel/lifecycle/CompositeActivityDef.java
+++ b/source/com/c2kernel/lifecycle/CompositeActivityDef.java
@@ -51,7 +51,7 @@ public class CompositeActivityDef extends ActivityDef
/**
* Method addNextDef.
- *
+ *
* @param origin
* @param terminus
* @return NextDef
@@ -64,7 +64,7 @@ public class CompositeActivityDef extends ActivityDef
}
/**
* Method addExistingActivityDef.
- *
+ *
* @param actDef
* @param point
*/
@@ -78,7 +78,7 @@ public class CompositeActivityDef extends ActivityDef
}
/**
* Method newChild.
- *
+ *
* @param Name
* @param Type
* @param location
@@ -149,13 +149,15 @@ public class CompositeActivityDef extends ActivityDef
}
/**
* Method instantiateAct.
- *
+ *
* @return CompositeActivity
*/
+ @Override
public WfVertex instantiate() throws ObjectNotFoundException, InvalidDataException {
return instantiate(getName());
}
-
+
+ @Override
public WfVertex instantiate(String name) throws ObjectNotFoundException, InvalidDataException
{
CompositeActivity cAct = new CompositeActivity();
@@ -186,18 +188,17 @@ public class CompositeActivityDef extends ActivityDef
/**
* Method hasGoodNumberOfActivity.
- *
+ *
* @return boolean
*/
-
+
public boolean hasGoodNumberOfActivity()
{
int endingAct = 0;
GraphableVertex[] graphableVertices = this.getLayoutableChildren();
if (graphableVertices != null)
- for (int i = 0; i < graphableVertices.length; i++)
- {
- WfVertexDef vertex = (WfVertexDef) graphableVertices[i];
+ for (GraphableVertex graphableVertice : graphableVertices) {
+ WfVertexDef vertex = (WfVertexDef) graphableVertice;
if (getChildrenGraphModel().getOutEdges(vertex).length == 0)
endingAct++;
}
@@ -209,17 +210,18 @@ public class CompositeActivityDef extends ActivityDef
/**
* @see com.c2kernel.graph.model.GraphableVertex#getPath()
*/
+ @Override
public String getPath()
{
if (getParent() == null)
return getName();
return super.getPath();
}
-
+
//deprecated
public String[] getCastorNonLayoutableChildren() {
return new String[0];
}
-
+
public void setCastorNonLayoutableChildren(String[] dummy) { }
}