Author: koen.aers(a)jboss.com
Date: 2008-07-29 09:48:00 -0400 (Tue, 29 Jul 2008)
New Revision: 9392
Added:
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/Container.java
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/DefaultConnection.java
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/DefaultContainer.java
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/DefaultFlow.java
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/DefaultNode.java
Removed:
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/AbstractConnection.java
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/AbstractFlow.java
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/AbstractNode.java
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/AbstractNodeContainer.java
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/NodeContainer.java
Modified:
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/Flow.java
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/Node.java
Log:
rename Abstract* -> Default*
Deleted:
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/AbstractConnection.java
===================================================================
---
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/AbstractConnection.java 2008-07-29
13:41:00 UTC (rev 9391)
+++
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/AbstractConnection.java 2008-07-29
13:48:00 UTC (rev 9392)
@@ -1,31 +0,0 @@
-package org.jboss.tools.flow.common.core;
-
-import java.util.HashMap;
-
-public abstract class AbstractConnection implements Connection {
-
- private HashMap<String, Object> metaData = new HashMap<String, Object>();
- private Node from, to;
-
- public AbstractConnection(Node from, Node to) {
- this.from = from;
- this.to = to;
- }
-
- public Object getMetaData(String key) {
- return metaData.get(key);
- }
-
- public void setMetaData(String key, Object value) {
- metaData.put(key, value);
- }
-
- public Node getFrom() {
- return from;
- }
-
- public Node getTo() {
- return to;
- }
-
-}
Deleted:
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/AbstractFlow.java
===================================================================
---
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/AbstractFlow.java 2008-07-29
13:41:00 UTC (rev 9391)
+++
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/AbstractFlow.java 2008-07-29
13:48:00 UTC (rev 9392)
@@ -1,88 +0,0 @@
-package org.jboss.tools.flow.common.core;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-
-public class AbstractFlow implements Flow {
-
- private String name;
- private HashMap<String, Object> metaData = new HashMap<String, Object>();
- private ArrayList<Node> nodes = new ArrayList<Node>();
-
- public String getName() {
- return name;
- }
-
- public void setName(String name) {
- this.name = name;
- }
-
- public Object getMetaData(String key) {
- return metaData.get(key);
- }
-
- public void setMetaData(String key, Object value) {
- metaData.put(key, value);
- }
-
- public List<Node> getNodes() {
- return nodes;
- }
-
- public void addNode(Node node) {
- nodes.add(node);
- node.setNodeContainer(this);
- }
-
- public void removeNode(Node node) {
- node.setNodeContainer(null);
- nodes.remove(node);
- }
-
- public String getId() {
- // TODO Auto-generated method stub
- return null;
- }
-
- public String getPackageName() {
- // TODO Auto-generated method stub
- return null;
- }
-
- public String getType() {
- // TODO Auto-generated method stub
- return null;
- }
-
- public String getVersion() {
- // TODO Auto-generated method stub
- return null;
- }
-
- public void setId(String id) {
- // TODO Auto-generated method stub
-
- }
-
- public void setPackageName(String packageName) {
- // TODO Auto-generated method stub
-
- }
-
- public void setType(String type) {
- // TODO Auto-generated method stub
-
- }
-
- public void setVersion(String version) {
- // TODO Auto-generated method stub
-
- }
-
- public Node getNode(long id) {
- // TODO Auto-generated method stub
- return null;
- }
-
-}
Deleted:
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/AbstractNode.java
===================================================================
---
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/AbstractNode.java 2008-07-29
13:41:00 UTC (rev 9391)
+++
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/AbstractNode.java 2008-07-29
13:48:00 UTC (rev 9392)
@@ -1,87 +0,0 @@
-package org.jboss.tools.flow.common.core;
-
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-public class AbstractNode implements Node {
-
- private long id;
- private String name;
- private NodeContainer container;
-
- private HashMap<String, Object> metaData = new HashMap<String, Object>();
-
- public long getId() {
- return id;
- }
-
- public void setId(long l) {
- id = l;
- }
-
- public String getName() {
- return name;
- }
-
- public void setName(String name) {
- this.name = name;
- }
-
- public void setMetaData(String key, Object value) {
- metaData.put(key, value);
- }
-
- public Object getMetaData(String key) {
- return metaData.get(key);
- }
-
- public NodeContainer getNodeContainer() {
- return container;
- }
-
- public void setNodeContainer(NodeContainer container) {
- this.container = container;
- }
-
- public void addIncomingConnection(String type, Connection connection) {
- // TODO Auto-generated method stub
-
- }
-
- public void addOutgoingConnection(String type, Connection connection) {
- // TODO Auto-generated method stub
-
- }
-
- public Map<String, List<Connection>> getIncomingConnections() {
- // TODO Auto-generated method stub
- return null;
- }
-
- public List<Connection> getIncomingConnections(String type) {
- // TODO Auto-generated method stub
- return null;
- }
-
- public Map<String, List<Connection>> getOutgoingConnections() {
- // TODO Auto-generated method stub
- return null;
- }
-
- public List<Connection> getOutgoingConnections(String type) {
- // TODO Auto-generated method stub
- return null;
- }
-
- public void removeIncomingConnection(String type, Connection connection) {
- // TODO Auto-generated method stub
-
- }
-
- public void removeOutgoingConnection(String type, Connection connection) {
- // TODO Auto-generated method stub
-
- }
-
-}
Deleted:
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/AbstractNodeContainer.java
===================================================================
---
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/AbstractNodeContainer.java 2008-07-29
13:41:00 UTC (rev 9391)
+++
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/AbstractNodeContainer.java 2008-07-29
13:48:00 UTC (rev 9392)
@@ -1,52 +0,0 @@
-package org.jboss.tools.flow.common.core;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-
-public abstract class AbstractNodeContainer extends AbstractNode implements NodeContainer
{
-
- private String name;
- private HashMap<String, Object> metaData = new HashMap<String, Object>();
- private ArrayList<Node> nodes = new ArrayList<Node>();
-
- public String getName() {
- return name;
- }
-
- public void setName(String name) {
- this.name = name;
- }
-
- public Object getMetaData(String key) {
- return metaData.get(key);
- }
-
- public void setMetaData(String key, Object value) {
- metaData.put(key, value);
- }
-
- public List<Node> getNodes() {
- return nodes;
- }
-
- public void addNode(Node node) {
- nodes.add(node);
- node.setNodeContainer(this);
- }
-
- public void removeNode(Node node) {
- node.setNodeContainer(null);
- nodes.remove(node);
- }
-
- public Node getNode(long id) {
- for (Node node : nodes) {
- if (node.getId() == id) {
- return node;
- }
- }
- return null;
- }
-
-}
Copied:
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/Container.java
(from rev 9373,
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/NodeContainer.java)
===================================================================
---
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/Container.java
(rev 0)
+++
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/Container.java 2008-07-29
13:48:00 UTC (rev 9392)
@@ -0,0 +1,47 @@
+package org.jboss.tools.flow.common.core;
+
+import java.util.List;
+
+/**
+ * A container of nodes.
+ *
+ * @author <a href="mailto:kris_verlaenen@hotmail.com">Kris
Verlaenen</a>
+ */
+public interface Container {
+
+ /**
+ * Returns the nodes of this node container.
+ *
+ * @return the nodes of this node container
+ */
+ List<Node> getNodes();
+
+ /**
+ * Returns the node with the given id
+ *
+ * @param id
+ * the node id
+ * @return the node with the given id
+ * @throws IllegalArgumentException
+ * if an unknown id is passed
+ */
+ Node getNode(long id);
+
+ /**
+ * Method for adding a node to this node container.
+ * Note that the node will get an id unique for this node container.
+ *
+ * @param node the node to be added
+ * @throws IllegalArgumentException if <code>node</code> is null
+ */
+ void addNode(Node node);
+
+ /**
+ * Method for removing a node from this node container
+ *
+ * @param node the node to be removed
+ * @throws IllegalArgumentException if <code>node</code> is null or
unknown
+ */
+ void removeNode(Node node);
+
+}
Property changes on:
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/Container.java
___________________________________________________________________
Name: svn:mergeinfo
+
Copied:
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/DefaultConnection.java
(from rev 9373,
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/AbstractConnection.java)
===================================================================
---
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/DefaultConnection.java
(rev 0)
+++
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/DefaultConnection.java 2008-07-29
13:48:00 UTC (rev 9392)
@@ -0,0 +1,39 @@
+package org.jboss.tools.flow.common.core;
+
+import java.util.HashMap;
+
+public abstract class DefaultConnection implements Connection {
+
+ private HashMap<String, Object> metaData = new HashMap<String, Object>();
+ private Node from, to;
+
+ public DefaultConnection(Node from, Node to) {
+ this.from = from;
+ this.to = to;
+ }
+
+ public Object getMetaData(String key) {
+ return metaData.get(key);
+ }
+
+ public void setMetaData(String key, Object value) {
+ metaData.put(key, value);
+ }
+
+ public Node getFrom() {
+ return from;
+ }
+
+ public Node getTo() {
+ return to;
+ }
+
+ public String getFromType() {
+ return null;
+ }
+
+ public String getToType() {
+ return null;
+ }
+
+}
Property changes on:
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/DefaultConnection.java
___________________________________________________________________
Name: svn:mergeinfo
+
Copied:
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/DefaultContainer.java
(from rev 9389,
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/AbstractNodeContainer.java)
===================================================================
---
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/DefaultContainer.java
(rev 0)
+++
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/DefaultContainer.java 2008-07-29
13:48:00 UTC (rev 9392)
@@ -0,0 +1,52 @@
+package org.jboss.tools.flow.common.core;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+
+public abstract class DefaultContainer extends DefaultNode implements Container {
+
+ private String name;
+ private HashMap<String, Object> metaData = new HashMap<String, Object>();
+ private ArrayList<Node> nodes = new ArrayList<Node>();
+
+ public String getName() {
+ return name;
+ }
+
+ public void setName(String name) {
+ this.name = name;
+ }
+
+ public Object getMetaData(String key) {
+ return metaData.get(key);
+ }
+
+ public void setMetaData(String key, Object value) {
+ metaData.put(key, value);
+ }
+
+ public List<Node> getNodes() {
+ return nodes;
+ }
+
+ public void addNode(Node node) {
+ nodes.add(node);
+ node.setNodeContainer(this);
+ }
+
+ public void removeNode(Node node) {
+ node.setNodeContainer(null);
+ nodes.remove(node);
+ }
+
+ public Node getNode(long id) {
+ for (Node node : nodes) {
+ if (node.getId() == id) {
+ return node;
+ }
+ }
+ return null;
+ }
+
+}
Property changes on:
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/DefaultContainer.java
___________________________________________________________________
Name: svn:mergeinfo
+
Copied:
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/DefaultFlow.java
(from rev 9373,
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/AbstractFlow.java)
===================================================================
---
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/DefaultFlow.java
(rev 0)
+++
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/DefaultFlow.java 2008-07-29
13:48:00 UTC (rev 9392)
@@ -0,0 +1,88 @@
+package org.jboss.tools.flow.common.core;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+
+public class DefaultFlow implements Flow {
+
+ private String name;
+ private HashMap<String, Object> metaData = new HashMap<String, Object>();
+ private ArrayList<Node> nodes = new ArrayList<Node>();
+
+ public String getName() {
+ return name;
+ }
+
+ public void setName(String name) {
+ this.name = name;
+ }
+
+ public Object getMetaData(String key) {
+ return metaData.get(key);
+ }
+
+ public void setMetaData(String key, Object value) {
+ metaData.put(key, value);
+ }
+
+ public List<Node> getNodes() {
+ return nodes;
+ }
+
+ public void addNode(Node node) {
+ nodes.add(node);
+ node.setNodeContainer(this);
+ }
+
+ public void removeNode(Node node) {
+ node.setNodeContainer(null);
+ nodes.remove(node);
+ }
+
+ public String getId() {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ public String getPackageName() {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ public String getType() {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ public String getVersion() {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ public void setId(String id) {
+ // TODO Auto-generated method stub
+
+ }
+
+ public void setPackageName(String packageName) {
+ // TODO Auto-generated method stub
+
+ }
+
+ public void setType(String type) {
+ // TODO Auto-generated method stub
+
+ }
+
+ public void setVersion(String version) {
+ // TODO Auto-generated method stub
+
+ }
+
+ public Node getNode(long id) {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+}
Property changes on:
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/DefaultFlow.java
___________________________________________________________________
Name: svn:mergeinfo
+
Copied:
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/DefaultNode.java
(from rev 9380,
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/AbstractNode.java)
===================================================================
---
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/DefaultNode.java
(rev 0)
+++
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/DefaultNode.java 2008-07-29
13:48:00 UTC (rev 9392)
@@ -0,0 +1,87 @@
+package org.jboss.tools.flow.common.core;
+
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+public class DefaultNode implements Node {
+
+ private long id;
+ private String name;
+ private Container container;
+
+ private HashMap<String, Object> metaData = new HashMap<String, Object>();
+
+ public long getId() {
+ return id;
+ }
+
+ public void setId(long l) {
+ id = l;
+ }
+
+ public String getName() {
+ return name;
+ }
+
+ public void setName(String name) {
+ this.name = name;
+ }
+
+ public void setMetaData(String key, Object value) {
+ metaData.put(key, value);
+ }
+
+ public Object getMetaData(String key) {
+ return metaData.get(key);
+ }
+
+ public Container getNodeContainer() {
+ return container;
+ }
+
+ public void setNodeContainer(Container container) {
+ this.container = container;
+ }
+
+ public void addIncomingConnection(String type, Connection connection) {
+ // TODO Auto-generated method stub
+
+ }
+
+ public void addOutgoingConnection(String type, Connection connection) {
+ // TODO Auto-generated method stub
+
+ }
+
+ public Map<String, List<Connection>> getIncomingConnections() {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ public List<Connection> getIncomingConnections(String type) {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ public Map<String, List<Connection>> getOutgoingConnections() {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ public List<Connection> getOutgoingConnections(String type) {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ public void removeIncomingConnection(String type, Connection connection) {
+ // TODO Auto-generated method stub
+
+ }
+
+ public void removeOutgoingConnection(String type, Connection connection) {
+ // TODO Auto-generated method stub
+
+ }
+
+}
Property changes on:
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/DefaultNode.java
___________________________________________________________________
Name: svn:mergeinfo
+
Modified:
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/Flow.java
===================================================================
---
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/Flow.java 2008-07-29
13:41:00 UTC (rev 9391)
+++
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/Flow.java 2008-07-29
13:48:00 UTC (rev 9392)
@@ -25,7 +25,7 @@
*
* @author <a href="mailto:kris_verlaenen@hotmail.com">Kris
Verlaenen</a>
*/
-public interface Flow extends NodeContainer {
+public interface Flow extends Container {
/**
* Sets the id of this process.
Modified:
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/Node.java
===================================================================
---
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/Node.java 2008-07-29
13:41:00 UTC (rev 9391)
+++
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/Node.java 2008-07-29
13:48:00 UTC (rev 9392)
@@ -80,9 +80,9 @@
List<Connection> getOutgoingConnections(String type);
- NodeContainer getNodeContainer();
+ Container getNodeContainer();
- void setNodeContainer(NodeContainer nodeContainer);
+ void setNodeContainer(Container nodeContainer);
void setMetaData(String name, Object value);
Deleted:
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/NodeContainer.java
===================================================================
---
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/NodeContainer.java 2008-07-29
13:41:00 UTC (rev 9391)
+++
trunk/flow/plugins/org.jboss.tools.flow.common.core/src/org/jboss/tools/flow/common/core/NodeContainer.java 2008-07-29
13:48:00 UTC (rev 9392)
@@ -1,47 +0,0 @@
-package org.jboss.tools.flow.common.core;
-
-import java.util.List;
-
-/**
- * A container of nodes.
- *
- * @author <a href="mailto:kris_verlaenen@hotmail.com">Kris
Verlaenen</a>
- */
-public interface NodeContainer {
-
- /**
- * Returns the nodes of this node container.
- *
- * @return the nodes of this node container
- */
- List<Node> getNodes();
-
- /**
- * Returns the node with the given id
- *
- * @param id
- * the node id
- * @return the node with the given id
- * @throws IllegalArgumentException
- * if an unknown id is passed
- */
- Node getNode(long id);
-
- /**
- * Method for adding a node to this node container.
- * Note that the node will get an id unique for this node container.
- *
- * @param node the node to be added
- * @throws IllegalArgumentException if <code>node</code> is null
- */
- void addNode(Node node);
-
- /**
- * Method for removing a node from this node container
- *
- * @param node the node to be removed
- * @throws IllegalArgumentException if <code>node</code> is null or
unknown
- */
- void removeNode(Node node);
-
-}