站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > JBoss RULES 4.0.0.11754MR2 API 英文版文档

Node (Drools 4.0.0.11754MR2 API) - JBoss RULES 4.0.0.11754MR2 API 英文版文档


org.drools.ruleflow.core.impl
Class Node

java.lang.Object
  extended by org.drools.ruleflow.core.impl.Node
All Implemented Interfaces:
Serializable, INode
Direct Known Subclasses:
EndNode, Join, RuleSetNode, Split, StartNode

public abstract class Node
extends Object
implements INode, Serializable

Default implementation of a node.

Author:
Kris Verlaenen
See Also:
Serialized Form

Field Summary
protected static Node[] EMPTY_NODE_ARRAY
           
 
Constructor Summary
Node()
           
 
Method Summary
protected  void addIncomingConnection(IConnection connection)
           
protected  void addOutgoingConnection(IConnection connection)
           
 long getId()
          Returns the id of the node
 List getIncomingConnections()
          Returns the incoming connections
 String getName()
          Returns the name of the node
 List getOutgoingConnections()
          Returns the outgoing connections
protected  void removeIncomingConnection(IConnection connection)
           
protected  void removeOutgoingConnection(IConnection connection)
           
 void setId(long id)
          Method for setting the id of the node
 void setName(String name)
          Method for setting the name of the node
protected  void validateAddIncomingConnection(IConnection connection)
          This method validates whether the given connection can be added.
protected  void validateAddOutgoingConnection(IConnection connection)
          This method validates whether the given connection can be added.
protected  void validateRemoveIncomingConnection(IConnection connection)
          This method validates whether the given connection can be removed
protected  void validateRemoveOutgoingConnection(IConnection connection)
          This method validates whether the given connection can be removed
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

EMPTY_NODE_ARRAY

protected static final Node[] EMPTY_NODE_ARRAY
Constructor Detail

Node

public Node()
Method Detail

getId

public long getId()
Description copied from interface: INode
Returns the id of the node

Specified by:
getId in interface INode
Returns:
the id of the node

setId

public void setId(long id)
Description copied from interface: INode
Method for setting the id of the node

Specified by:
setId in interface INode
Parameters:
id - the id of the node

getName

public String getName()
Description copied from interface: INode
Returns the name of the node

Specified by:
getName in interface INode
Returns:
the name of the node

setName

public void setName(String name)
Description copied from interface: INode
Method for setting the name of the node

Specified by:
setName in interface INode
Parameters:
name - the name of the node

getIncomingConnections

public List getIncomingConnections()
Description copied from interface: INode
Returns the incoming connections

Specified by:
getIncomingConnections in interface INode
Returns:
the incoming connections

getOutgoingConnections

public List getOutgoingConnections()
Description copied from interface: INode
Returns the outgoing connections

Specified by:
getOutgoingConnections in interface INode
Returns:
the outgoing connections

addIncomingConnection

protected void addIncomingConnection(IConnection connection)

validateAddIncomingConnection

protected void validateAddIncomingConnection(IConnection connection)
This method validates whether the given connection can be added. If the connection cannot be added, an IllegalArgumentException is thrown.

Parameters:
connection - the incoming connection to be added
Throws:
IllegalArgumentException - is thrown if the connection is null, or if a connection is added twice. If subclasses want to change the rules for adding incoming connections the validateAddIncomingConnection(IConnection connection) should be overridden.

addOutgoingConnection

protected void addOutgoingConnection(IConnection connection)

validateAddOutgoingConnection

protected void validateAddOutgoingConnection(IConnection connection)
This method validates whether the given connection can be added. If the connection cannot be added, an IllegalArgumentException is thrown.

Parameters:
connection - the outgoin connection to be added
Throws:
IllegalArgumentException - is thrown if the connection is null, or if a connection is added twice. If subclasses want to change the rules for adding outgoing connections the validateAddIncomingConnection(IConnection connection) should be overridden.

removeIncomingConnection

protected void removeIncomingConnection(IConnection connection)

validateRemoveIncomingConnection

protected void validateRemoveIncomingConnection(IConnection connection)
This method validates whether the given connection can be removed

Parameters:
connection - the incoming connection
Throws:
IllegalArgumentException - is thrown if connectin is null, or unknown. If subclasses want to change the rules for removing incoming connections the validateRemoveIncomingConnection(IConnection connection) should be overridden.

removeOutgoingConnection

protected void removeOutgoingConnection(IConnection connection)

validateRemoveOutgoingConnection

protected void validateRemoveOutgoingConnection(IConnection connection)
This method validates whether the given connection can be removed

Parameters:
connection - the outgoing connection
Throws:
IllegalArgumentException - is thrown if connectin is null, or unknown. If subclasses want to change the rules for removing outgoing connections the validateRemoveOutgoingConnection(IConnection connection) should be overridden.


Copyright © 2001-2007 JBoss Inc.. All Rights Reserved.