All Packages Class Hierarchy This Package Previous Next Index
Class ProtocolLayer.IPRouterAction
Abstract.AgentAction
|
+----BaseLayer.BAgentAction
|
+----KQMLLayer.KQMLAgentAction
|
+----RouterLayer.Router.RouterAction
|
+----ProtocolLayer.IPRouterAction
- public class IPRouterAction
- extends RouterAction
IPRouter server action class. Add on Router server action, diverse internet protocols -
SMTP and FTP are supported.
- See Also:
- RouterAction
-
IPRouterAction()
- Default constructor.
-
IPRouterAction(String, String, String, String, String, int, int, int, int, int, int)
- Constructor using
-
createReceiverThread(String, int)
- Override AgentAction createRecvThread method
Create client receiver thread using name of the agent
Override this method if your connection type is different.
-
createServerThread(String, int)
- Override AgentAction createServerThread method
Create server thread using name of the agent
Override this method if your connection type is different.
-
main(String[])
-
IPRouterAction
public IPRouterAction()
- Default constructor. You should use setAddressFilePath, setMessageBoxPath, setPasswordFilePath
methods afterwards.
IPRouterAction
public IPRouterAction(String id,
String addressFilePath,
String messageBoxPath,
String passwordFilePath,
String registryFilePath,
int durationTime,
int offLineTrialTimes,
int offLineCheckPeriod,
int reserveTrialTimes,
int reserveCheckPeriod,
int sleepPeriod)
- Constructor using
- Parameters:
- id - Router name
- addressFilePath - Address file path. Address file contains the addresses of Router and
RouterRegistrar at the minimum. Add on those, you can specify the addresses of other agents
where the Router want to initiate the conneciton
- messageBoxPath - Message incoming file directory path
- passwordFilePath - Password file path
- registryFilePath - Registry file path
- duration - Maximum idle time
- offLineTrialTimes - Maximum trial times to voluntarily reconnect to stand alone agent
- offLineCheckPeriod - Off line agent time check period in minutes
- reserveTrialTimes - Maximum trial times to send reserved message
- reserveCheckPeriod - Reseved message sending time check period in minutes
- sleepPeriod - Sleep period in minutes
createServerThread
public ServerThread createServerThread(String id,
int priority)
- Override AgentAction createServerThread method
Create server thread using name of the agent
Override this method if your connection type is different.
- Parameters:
- id - ServerThread name
- priority - Server thread priority
- Returns:
- ServerThread, generated. Null if fails
- Overrides:
- createServerThread in class RouterAction
createReceiverThread
public ReceiverThread createReceiverThread(String serverid,
int priority)
- Override AgentAction createRecvThread method
Create client receiver thread using name of the agent
Override this method if your connection type is different.
Before you invoke this method, the Router name(the same as RouterAction thread name)
should be specified.
- Parameters:
- serverid - Server agent name. This name is not my name. The name of the other
agent you want to connect
- priority - Receiver thread priority
- Returns:
- ReceiverThread, generated
- Overrides:
- createReceiverThread in class RouterAction
main
public static void main(String args[])
All Packages Class Hierarchy This Package Previous Next Index