-----------------------------------------------------------------------

	"@(#)README 3.4 99/03/23 SMI"

	Copyright (c) 03/23/99, by Sun Microsystems, Inc.
	All rights reserved.

-----------------------------------------------------------------------

			Advanced M-Let Example
			======================


-----------------------------------------------------------------------
1. Example overview
-----------------------------------------------------------------------
This example shows how to use the m-let service to add m-beans to an 
agent through a connection to a given URL.

The current directory contains the following source files:
   * Client.java:
	- Implements a simple manager.	
	- Sets up communication using the RMI adaptor client
	  to connect to the agent.
	- Gets a handle on an m-bean from the remote agent.
	- Instantiates and registers the m-let service in a remote
	  agent.
	- Uses the m-let service to add m-beans to the agent. The m-let
	  service uses a URL which refers to a text file containing MLET 
	  tags that define the m-beans to be added.

   * Master.java:
	- Implements a simple m-bean.
        - Uses the m-bean specific method initCmf to register an 
	  m-bean with the framework.
	- Instantiates and registers the Sub m-bean from
          within the initCmf method using a handle on the agent
	  in two different ways.
	- Contains a read-only m-bean property.

   * Sub.java:
	- Implements a simple m-bean.
	- Contains a read-only m-bean property.


-----------------------------------------------------------------------
2. Building and running the example
-----------------------------------------------------------------------
To build the advanced m-let example, copy the example source files to
your working directory and type the following commands:

   cd <WORKING_DIR>

   javac -d . Master.java

   mogen Master

   javac -d . *.java

   # Build the JAR file:

   jar cf Master.jar Master.class Sub.class


To run the version of the example you have just built, type the 
following commands:

   # Make sure that no agents are already running 
   # and start the Java DMK base agent:

   jaw start

   # Start the manager:

   java Client <URL>

   # Example using a Solaris platform:
        
   java Client file:/opt/SUNWconn/jaw/examples/mo/Mlet2/Master.html

   # Example using a Windows platform:
        
   java Client "file:/c:/Program Files/SUNWconn/jaw/examples/mo/Mlet2/Master.html"
