All Examples This Package
Class examples.time.ServerTimer
java.lang.Object
|
+----examples.time.ServerTimer
- public class ServerTimer
- extends Object
- implements Schedulable, Triggerable
This application connects to a WebLogic Server, and schedules a recurring trigger
that executes on the server. The server dynamically loads an instance of
the ServerTimer class, repeatedly calling its schedule method to
schedule execution of its trigger method. In this example, the timer
starts out at a 0 second delay, but with each event, the delay is increased
by 1 second. When it reaches 10, the trigger is cancelled.
Assuming that the server is running on port 7001 of the local machine,
you would run this example using the following command:
java examples.time.ServerTimer t3://localhost:7001
View the server output logs to see the results of the timer execution.
- Author:
- Copyright (c) 1996-2000 by BEA Systems, Inc. All Rights Reserved.
-
ServerTimer()
-
-
main(String[])
- Main allows this example to be called from the command line.
-
schedule(long)
-
-
trigger()
-
ServerTimer
public ServerTimer()
schedule
public long schedule(long t)
trigger
public void trigger()
main
public static void main(String argv[]) throws Exception
- Main allows this example to be called from the command line.
String argv are the params for the event registration.
All Examples This Package