| 
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface IPCInterface
| Method Summary | |
|---|---|
 boolean | 
canInvoke(java.lang.String methodName,
          java.lang.Object[] params)
Test for existance of IPC method - params as above  | 
 java.lang.Object | 
invoke(java.lang.String methodName,
       java.lang.Object[] params)
This function will call the given method on the plugin.  | 
| Method Detail | 
|---|
java.lang.Object invoke(java.lang.String methodName,
                        java.lang.Object[] params)
                        throws IPCException
int, boolean need to be wrapped in their
 Objects (int -> Integer).
 
 Results will be returned as Object and can be classcasted.
 
 WARNING: only call Methods that use Java or Azureus Classes the use of custom classes may cause problems.
Examples:
 
 1.
 Plugin has method
 int add (int x, int y);
 
 
 int result = ((Integer)invoke ("add", new Object[] {Integer.valueOf(10),Integer.valueOf(5)}).intValue();
 //result (15)
 
 
 2. Plugin has method
 String randomize (String x);
 
 
 String result = (String)invoke("randomize", new Object[]{"foobar"});
 //result ("bfaoro")
 
methodName - the name of the Methods to be calledparams - Parameters of the Method
IPCException
boolean canInvoke(java.lang.String methodName,
                  java.lang.Object[] params)
methodName - params - 
  | 
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||