[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[ecf-dev] remote service tracker
- From: Scott Lewis <slewis@xxxxxxxxxxxxx>
- Date: Sat, 29 Nov 2008 08:44:41 -0800
- Delivered-to: email@example.com
- User-agent: Thunderbird 220.127.116.11 (Windows/20081105)
I've been playing around with writing a RemoteServiceTracker class. The
intention here is to provide a very convenient and familiar means for
clients to get an ECF IRemoteService in the same way that a normal
ServiceTracker.getService() returns an Object (which is casted to an
interface by contract).
A normal service tracker is used like this:
ServiceTracker st = new ServiceTracker(...);
IMyInterface service = (IMyInterface) st.getService();
...use service here...
The idea is that with a RemoteServiceTracker the usage would be similar:
RemoteServiceTracker rst = new RemoteServiceTracker(...);
IRemoteService rservice = rst.getService();
...use rservice here...e.g. IMyInterface intf = (IMyInterface)
rservice.getProxy(), or rservice.callAsynch(...), or others.
I've committed an RemoteServiceTracker to the 'remote_svc_tracker'
branch on the org.eclipse.ecf.remoteservice project. I need to write
some tests and try it out in some other scenarios before deciding
whether to include it...and would like to get other's feedback.
Obviously all of this is intended for ECF 3.0. I've created an
enhancement request: https://bugs.eclipse.org/bugs/show_bug.cgi?id=256975