Dynamic RMI Action

VERSION 3 Published

Created on: 20-Jul-2007 15:49 by flux - Last Modified:  26-Feb-2008 16:11 by Guest

This article will explain what the dynamic RMI action is and how to use it.

The dynamic RMI action is very similar to the dynamic java action, the only difference being that it executes a remote object not a local one. Like the dynamic java action the dynamic RMI action does not require you to implement any specific Flux interfaces. You will however need to specify the signature of the method that receives the callback. You will also need to specify the location of the remote object; this includes the host, bind name, and port. This remote object is called when the dynamic RMI action executes.

You first need to specify a host, port, and bind name. Once that is done you will need to specify a listener signature. If you created a simple java class like the one below you would use main (String [] args) as the listener signature.

public class HelloWorld {
    public static void main(String[] args) {
        System.out.println("Hello World");
    }
}

The host, port ,and bind name can be set in code using the following options.

rmiAction.setPort(1099);
rmiAction.setHost("somehost.mycompany.com");
rmiAction.setBindName("MyRemoteObject");

The argument property is used to pass arguments to your listener signature. The argument count property specifies the number of arguments that are passed into your method. This count is dynamically generated by the listener signature. For example, if your listener signature method takes a string you could add the string you wanted to pass in as the argument.
Average User Rating
(0 ratings)




There are no comments on this document