blob: 1c420c08f3b6ab2c4df07905c957db9bfacac04b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
|
/*************************************************
*
* = PACKAGE
* JACE.ServiceConfigurator
*
* = FILENAME
* ServiceObject.java
*
*@author Prashant Jain
*
*************************************************/
package JACE.ServiceConfigurator;
import java.io.*;
import JACE.ASX.*;
import JACE.Reactor.*;
public class ServiceObject implements EventHandler
{
/**
* Initialize object when dynamic loading occurs. Overwrite this
* method to do anything useful.
*@return -1 (default implementation)
*/
public int init (String [] args)
{
return -1;
}
/**
* Terminate the object. Note that an object can not be explicitly
* unloaded. Overwrite this method to do anything useful.
*@return -1 (default implementation)
*/
public int fini ()
{
return -1;
}
/**
* Get information on an active object. Overwrite this method to do
* anything useful.
*@return null (default implementation)
*/
public String info ()
{
return null;
}
/**
* Called when timer expires. Overwrite this method to do
* anything useful.
*@param tv Time Value for which timer was set
*@param obj An arbitrary object that was passed to the Timer Queue
* (Asynchronous Completion Token)
*@return -1
*/
public int handleTimeout (TimeValue tv, Object obj)
{
return -1;
}
/**
* Request that this service suspend activity. Overwrite this
* method to do anything useful.
*/
public int suspend ()
{
return -1;
}
/**
* Request that this service resume activity. Overwrite this
* method to do anything useful.
*/
public int resume ()
{
return -1;
}
}
|