    All Examples  This Package

# Class examples.workspace.monitor.MonitorDemo

    java.lang.Object
       |
       +----examples.workspace.monitor.MonitorDemo

public class MonitorDemo
extends Object
implements ActionDef

This example demonstrates how to use the various types of workspace monitors. SetMonitors and DestroyMonitors are used for a variety of purposes, such as sending an event when a workspace value is removed, mirroring a workspace value in another workspace, restricting a workspace value to a given range, or altering a workspace value from what the user specified. The XXXMonitor class, also called here, shows how a Master Monitor is used, and the RangeMonitor shows how you can check the range of a Workspace value before it is set, and throw a MonitorException if it is out of range.

### To set up this example:

1. Set up your development shell as described in Setting up your environment.

2. Compile this example by executing the following command in your development shell:

   $ javac -d %CLIENT_CLASSES% MonitorDemo.java

3. Start WebLogic Server in a separate shell.

4. Run this example by executing the following command in your development shell:

   $ java examples.workspace.monitor.MonitorDemo t3://hostname:port

   Where hostname:port is the host name and port number of your WebLogic Server.

   Author:
     Copyright (c) 1997-2000 by BEA Systems, Inc. All Rights Reserved.

   ##

   MonitorDemo()

   ##

   action(EventMessageDef)
   main(String[])
     Starts the Monitor process.
   registerInit(ParamSet)
   setServices(T3ServicesDef)

   ##

   MonitorDemo

        public MonitorDemo()

   ##

   main

        public static void main(String argv[]) throws Exception

     Starts the Monitor process. Supply the WebLogic Server URL as an argument.

   setServices

        public void setServices(T3ServicesDef services)

   registerInit

        public void registerInit(ParamSet ps)

   action

        public void action(EventMessageDef message)

       All Examples  This Package