]> git.argeo.org Git - gpl/argeo-slc.git/blob - runtime/org.argeo.slc.core/src/main/java/org/argeo/slc/core/execution/generator/RunnableDataNode.java
Improve SystemCall
[gpl/argeo-slc.git] / runtime / org.argeo.slc.core / src / main / java / org / argeo / slc / core / execution / generator / RunnableDataNode.java
1 package org.argeo.slc.core.execution.generator;
2
3 import java.util.List;
4 import java.util.Map;
5
6 /**
7 * Stores information relative to a Runnable.
8 * Allows to structure the information as a tree, each node
9 * storing data as a Map.
10 */
11 public interface RunnableDataNode {
12
13 /**
14 * @return a Map containing the data associated with this node.
15 * Data associated with parent nodes are expected
16 * to be contained in the returned Map
17 */
18 public Map<String, Object> getData();
19
20 /**
21 * @return the name of the bean to create.
22 * Can be null if no bean shall be created for the
23 * <code>RunnableDataNode</code> (e.g. is is a sub-node)
24 */
25 public String getBeanName();
26
27 /**
28 * @return the path of the flow bean to create.
29 * Can be null if the bean to created is not an
30 * <code>ExecutionFlow</code> or if no bean shall be created for the
31 * <code>RunnableDataNode</code> (e.g. is is a sub-node)
32 */
33 public String getPath();
34
35 /**
36 * @return whether the <code>RunnableDataNode</code> has
37 * children or not.
38 * Expected to be equivalent to <code>getChildren().empty()</code>
39 */
40 public boolean isLeaf();
41
42 /**
43 * @return the list of <code>RunnableDataNode</code> children.
44 * Can be empty. Shall not be null.
45 */
46 public List<RunnableDataNode> getChildren();
47
48 /**
49 * @return the <code>RunnableDataNode</code> parent.
50 * Can be null if no parent is defined (top node).
51 */
52 public RunnableDataNode getParent();
53
54 /**
55 * Sets the <code>RunnableDataNode</code> parent
56 * @param parent
57 */
58 public void setParent(RunnableDataNode parent);
59 }