com.BobCo.FileExplorer
Class BobCoFileExplorerServer
java.lang.Object
|
+--com.BobCo.FileExplorer.BobCoFileExplorerServer
- All Implemented Interfaces:
- BobCoFileExplorerConstants, com.tivoli.twg.libs.CommandReceivedListener, java.lang.Runnable, com.tivoli.twg.engine.TWGTaskServer
- public class BobCoFileExplorerServer
- extends java.lang.Object
- implements com.tivoli.twg.libs.CommandReceivedListener, com.tivoli.twg.engine.TWGTaskServer, BobCoFileExplorerConstants
This class is the main class for the BobCo file explorer task server. It
gets launched by the Director server as appropriate
Fields inherited from interface com.BobCo.FileExplorer.BobCoFileExplorerConstants |
ARCHIVE, clientAddressSuffix, consoleRequestDirectoryContents, consoleRequestLocalFixedDrives, DIRECTORY, getClientDirectoryContents, getClientLocalFixedDrives, HIDDEN, READONLY, RETURN_FIND_FAILED, RETURN_OKAY, RETURN_UNRECOGNIZED_ACT_ID, RETURN_UNRECOGNIZED_COMMAND_CODE, RTMcommandCode, serviceNodeName, SYSTEM |
Method Summary |
boolean |
CommandReceived(com.tivoli.twg.libs.ServiceNode sn,
com.tivoli.twg.libs.Command cmd)
Command received callback. |
void |
run()
Since this task server gets launched in its own JVM by Director's
server, it must have a main() method. |
boolean |
serverActivate(com.tivoli.twg.engine.TWGTask task)
This method is called first so that the server task can perform any
initialization prior to run() getting called. |
void |
serverDeactivate()
The task server has been deactivated and any clean up required should be
done during this method. |
int |
subtaskActivate(com.tivoli.twg.engine.TWGTaskActivation act)
This method is called when a subtask activation has occurred. |
void |
subtaskDeactivate(com.tivoli.twg.engine.TWGTaskActivation act)
This method is called when a subtask deactivation has occurred. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BobCoFileExplorerServer
public BobCoFileExplorerServer()
serverActivate
public boolean serverActivate(com.tivoli.twg.engine.TWGTask task)
- Description copied from interface:
com.tivoli.twg.engine.TWGTaskServer
- This method is called first so that the server task can perform any
initialization prior to run() getting called. If there are any other
threads needed besides the thread that calls run() they should be created
here. Since the thread calling serverActivate() is dedicated to the
activation process, it is expected that control will not be returned from
this call until server task activation has completed.
- Specified by:
serverActivate
in interface com.tivoli.twg.engine.TWGTaskServer
- Following copied from interface:
com.tivoli.twg.engine.TWGTaskServer
- Returns:
- true if server activation completed successfully. or false if it
failed
CommandReceived
public boolean CommandReceived(com.tivoli.twg.libs.ServiceNode sn,
com.tivoli.twg.libs.Command cmd)
- Command received callback. This listener method is called when a
Command is received matching one of the command codes registered for
the given listener
- Specified by:
CommandReceived
in interface com.tivoli.twg.libs.CommandReceivedListener
- Parameters:
sn
- - ServiceNode instance which received Commandcmd
- - Instance of Command received- Returns:
- true if ServiceNode should stay active, false if it should
terminate
subtaskActivate
public int subtaskActivate(com.tivoli.twg.engine.TWGTaskActivation act)
- This method is called when a subtask activation has occurred.
- Specified by:
subtaskActivate
in interface com.tivoli.twg.engine.TWGTaskServer
- Parameters:
act
- the TWGTaskActivation object containing the task activation
information.
subtaskDeactivate
public void subtaskDeactivate(com.tivoli.twg.engine.TWGTaskActivation act)
- This method is called when a subtask deactivation has occurred.
- Specified by:
subtaskDeactivate
in interface com.tivoli.twg.engine.TWGTaskServer
- Parameters:
act
- the TWGTaskActivation object containing the task activation
information. This is the same object that was passed to the
subtaskActivate() method.
serverDeactivate
public void serverDeactivate()
- The task server has been deactivated and any clean up required should be
done during this method. After this method is called, the task server's
JVM will terminate.
- Specified by:
serverDeactivate
in interface com.tivoli.twg.engine.TWGTaskServer
run
public void run()
- Since this task server gets launched in its own JVM by Director's
server, it must have a main() method.
- Specified by:
run
in interface java.lang.Runnable