com.develop.jawin
Class EventHelper

java.lang.Object
  |
  +--com.develop.jawin.EventHelper

public class EventHelper
extends java.lang.Object

Helper class to add, remove and invoke event listener

Author:
Vitally Shelest

Constructor Summary
EventHelper()
           
 
Method Summary
private static int addEventListener(java.lang.Object owner, java.lang.Object sink)
           
static int addListener(IUnknown owner, IUnknown sink)
          Adds a new listenet
static byte[] invoke(java.lang.Object srcObj, java.lang.Object itf, int memid, java.lang.Object[] params)
          Invokes the listener method.
private static int newEventListener(java.lang.Object proxy, int guidToken)
           
static int newListener(java.lang.Object listener, GUID iid, int guidToken)
          Creates a new listener object
private static int removeEventListener(java.lang.Object owner, java.lang.Object sink)
           
static int removeListener(IUnknown owner, java.lang.Object sink)
          Removes the listener
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Constructor Detail

EventHelper

public EventHelper()
Method Detail

newListener

public static int newListener(java.lang.Object listener,
                              GUID iid,
                              int guidToken)
                       throws COMException
Creates a new listener object
Parameters:
listener - listener class
iid - listener IID
guidToken -  
Returns:
 
Throws:
COMException -  

addListener

public static int addListener(IUnknown owner,
                              IUnknown sink)
                       throws COMException
Adds a new listenet
Parameters:
owner -  
sink -  
Returns:
 
Throws:
COMException -  

removeListener

public static int removeListener(IUnknown owner,
                                 java.lang.Object sink)
                          throws COMException
Removes the listener
Parameters:
owner -  
sink -  
Returns:
 
Throws:
COMException -  

invoke

public static byte[] invoke(java.lang.Object srcObj,
                            java.lang.Object itf,
                            int memid,
                            java.lang.Object[] params)
                     throws COMException
Invokes the listener method. It is called from the native code
Parameters:
srcObj -  
itf -  
memid -  
bytes -  
Returns:
 
Throws:
COMException -  

newEventListener

private static int newEventListener(java.lang.Object proxy,
                                    int guidToken)

addEventListener

private static int addEventListener(java.lang.Object owner,
                                    java.lang.Object sink)

removeEventListener

private static int removeEventListener(java.lang.Object owner,
                                       java.lang.Object sink)


New Jawin designed by Vitally Shelest. This product includes software developed by the DevelopMentor OpenSource Project (http://www.develop.com/OpenSource).