All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class magician.Node.ActiveNode

java.lang.Object
   |
   +----magician.Node.ActiveNode

public class ActiveNode
extends Object
implements ActiveNetsConstants
The main entry point for starting up an Active Node. It contacts the Four11 Information server to obtain configuration information, starts up the PortManager and the Demultiplexer so that they can send and receive Active Network Encapsulation Protocol (ANEP) packets. It also starts up all the processing environments available at the Active Node.

See Also:
PortManager, ActiveNodeManager, Demultiplexer

Variable Index

 o EventMgr
 o Four11ConnID
 o Four11Server
 o NborHostTable
 o NborPortTable
 o ProcEnvs

Constructor Index

 o ActiveNode(String, String, String)
initializes the Active Node

Method Index

 o ()
 o getEventManager()
returns the event manager initialized for this node
 o getNeighbors()
gives the node names of the neighbors of this Active Node
 o GetNetName()
Get this node's virtual net name
 o GetNodeName()
Get this node's virtual name
 o getPhysicalHostName(String)
returns the name of the machine on which a virtual Active Node resides
 o getPortManagerForPort(int)
get the PortManager for a specified UDP port
 o getPortManagers()
get all PortManager for this node
 o getPortsForNode(String)
get the UDP ports a node is listening to
 o send(String, int, byte[])
interface for Node Manager to send packets to the correct port manager
 o SendSmartPacket(int, String, Object)
temporary interface to send Smartpackets from host
 o setType(int)
converts an int into a Type field

Variables

 o Four11Server
 Four11Stub Four11Server
 o Four11ConnID
 int Four11ConnID
 o ProcEnvs
 public static Hashtable ProcEnvs
 o NborHostTable
 static Hashtable NborHostTable
 o NborPortTable
 static Hashtable NborPortTable
 o EventMgr
 static EventManager EventMgr

Constructors

 o ActiveNode
 public ActiveNode(String thisHost,
                   String thisNet,
                   String traceStream)
initializes the Active Node

Parameters:
thisHost - name of this active node
thisNet - name of the network
traceStream - name of logging stream

Methods

 o getNeighbors
 public static UnsynchVector getNeighbors()
gives the node names of the neighbors of this Active Node

Returns:
a Vector consisting of the names of the nodes
 o getPhysicalHostName
 public static String getPhysicalHostName(String nodeName)
returns the name of the machine on which a virtual Active Node resides

Parameters:
nodeName - the name of the Active Node
Returns:
a String object containing the name of the physical host
 o getPortManagerForPort
 public static PortManager getPortManagerForPort(int udpPort)
get the PortManager for a specified UDP port

Parameters:
udpPort - the UDP port
Returns:
the PortManager object associated with the port
 o getPortManagers
 public static UnsynchVector getPortManagers()
get all PortManager for this node

Returns:
a Vector containing the PortManager objects
 o getPortsForNode
 public static String getPortsForNode(String nodeName)
get the UDP ports a node is listening to

Parameters:
nodeName - the name of the Active Node
Returns:
a space separated string containing the port numbers
 o GetNodeName
 public static String GetNodeName()
Get this node's virtual name

Returns:
the node name as a String
 o GetNetName
 public static String GetNetName()
Get this node's virtual net name

Returns:
the net name as a String
 o getEventManager
 public static EventManager getEventManager()
returns the event manager initialized for this node

Returns:
the event manager object
 o send
 public static synchronized boolean send(String node,
                                         int port,
                                         byte packetBytes[])
interface for Node Manager to send packets to the correct port manager

Parameters:
node - the name of the destination to send packet to
port - the port on which to send Smartpacket
packetBytes - the bytes comprising the Smartpacket
Returns:
true if the packet was sent successfully, false otherwise
See Also:
ExecEnvironment, ActiveNode, PortInterface
 o SendSmartPacket
 public static void SendSmartPacket(int EnvID,
                                    String destination,
                                    Object SmartPkt)
temporary interface to send Smartpackets from host

Parameters:
EnvID - the processing environment to use to process
destination - the node to send the Smartpacket to
SmartPkt - the Smartpacket object
 o
 static void ()
 o setType
 public byte[] setType(int typeInt)
converts an int into a Type field

Parameters:
typeInt - an int repsenting the type
Returns:
a two byte field representing the type

All Packages  Class Hierarchy  This Package  Previous  Next  Index
1