Re: Help to implement OperationListener interface.



On Oct 30, 11:18 am, mike <mikaelpetter...@xxxxxxxxxxx> wrote:
Ok!

I am calling the interface as my task, operationDel, makes progress or
isCanceled.
Shall the class where I have my call:

myApp.operationDel( file, operationListener);

implement the interface. Seems like I cannot figure out how the
callback is working!
Or am I missing something here?


Either the caller, or any other class can implement this interface.
Whoever implements it needs to be passed to the method call. The
interface methods wil be called by the method call at various points,
and the implementation will receive these callbacks (it is also called
a hook), and can use that to perform any operation. For now, you can
log a message or do a System.out.println() to understand the flow and
the callback mechanism, later you can tie it to more complex solution,
like rendering a progressbar or something similar.

-cheers,
Manish

.



Relevant Pages

  • Re: Help to implement OperationListener interface.
    ... have to implement the interface - you will need to call the interface ... methods as you progress through the operationDel. ... callback to notify the caller of various events, ...
    (comp.lang.java.programmer)
  • Re: Problem with imported callback to C#
    ... Usually it happens when callback declaration is using non-standard ... exposes interface, which enables to set a callback, which is called ... DirectShow graph with mentioned face detector filter and calls its ... int BufferCB; ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: Function pointers (Callback functions) in Java ?
    ... object to a local var called 'callback'. ... > In the above I don't see the Opps interface. ... The code was a very simple example of creating a named inner class ... Its may be worth knowing that you can create anonymous inner classes ...
    (comp.lang.java.programmer)
  • Re: Callback Interface functions NOT being Called
    ... a callback interface interface ICallbackInterface which implements the ... callback functions of the buttons I create in Ribbon interface. ... The ribbon callbacks use IDispatch, always, so you must return ... You need COM_INTERFACE_ENTRY2(IDispatch, ICallbackInterface) ...
    (microsoft.public.office.developer.com.add_ins)
  • Re: Using .NET callback via COM
    ... possible solution is to "redefine" the interface as a managed __interface and ... > I can implement this interface in an unmanaged class and pass this ... The callback occurs successfully. ... > managed class as a member, how do I let my managed class know when the ...
    (microsoft.public.dotnet.framework.interop)