Search in sources :

Example 1 with WfVertex

use of org.cristalise.kernel.lifecycle.instance.WfVertex in project kernel by cristal-ise.

the class CompositeActivityDef method intantiateVertices.

/**
 * Loops through the vertices of children graph model and calls their instantiate method
 *
 * @param ca the parent CompositeActivity instance which will be set as a Parent
 * @return the instantiated array of WfVertex instances
 */
public WfVertex[] intantiateVertices(CompositeActivity ca) throws ObjectNotFoundException, InvalidDataException {
    GraphableVertex[] vertexDefs = getLayoutableChildren();
    WfVertex[] wfVertices = new WfVertex[vertexDefs.length];
    for (int i = 0; i < vertexDefs.length; i++) {
        WfVertexDef vertDef = (WfVertexDef) vertexDefs[i];
        wfVertices[i] = vertDef.instantiate();
        wfVertices[i].setParent(ca);
    }
    return wfVertices;
}
Also used : WfVertex(org.cristalise.kernel.lifecycle.instance.WfVertex) GraphableVertex(org.cristalise.kernel.graph.model.GraphableVertex) GraphPoint(org.cristalise.kernel.graph.model.GraphPoint)

Aggregations

GraphPoint (org.cristalise.kernel.graph.model.GraphPoint)1 GraphableVertex (org.cristalise.kernel.graph.model.GraphableVertex)1 WfVertex (org.cristalise.kernel.lifecycle.instance.WfVertex)1