public class RemoteServiceHelper extends Object
| Modifier and Type | Field and Description |
|---|---|
static long |
defaultTimeout |
static Object[] |
EMPTY_PARAMS |
| Constructor and Description |
|---|
RemoteServiceHelper() |
| Modifier and Type | Method and Description |
|---|---|
static void |
asyncExec(IRemoteService remoteService,
String method,
Object[] parameters,
IRemoteCallListener listener)
Invoke given method asynchronously, and call listener upon successful completion.
|
static void |
asyncExec(IRemoteService remoteService,
String method,
Object[] parameters,
long timeout,
IRemoteCallListener listener)
Invoke given method asynchronously, and call listener upon successful completion.
|
static org.eclipse.equinox.concurrent.future.IFuture |
futureExec(IRemoteService remoteService,
String method,
Object[] parameters)
Invoke given method asynchronously, return an IFuture immediately that can be subsequently queried for
completion.
|
static org.eclipse.equinox.concurrent.future.IFuture |
futureExec(IRemoteService remoteService,
String method,
Object[] parameters,
long timeout)
Invoke given method asynchronously, return an IFuture immediately that can be subsequently queried for
completion.
|
static long |
getDefaultTimeout() |
static void |
setDefaultTimeout(long timeout) |
static Object |
syncExec(IRemoteService remoteService,
String method,
Object[] parameters)
Invoke given method synchronously, blocking the calling thread until a result is received or
timeout.
|
static Object |
syncExec(IRemoteService remoteService,
String method,
Object[] parameters,
long timeout)
Invoke given method synchronously, blocking the calling thread until a result is received or
timeout.
|
public static long defaultTimeout
public static Object[] EMPTY_PARAMS
public static long getDefaultTimeout()
public static void setDefaultTimeout(long timeout)
public static void asyncExec(IRemoteService remoteService, String method, Object[] parameters, IRemoteCallListener listener)
remoteService - the IRemoteService to invoke. Must not be null.method - the method to invoke. Must not be null.parameters - the parameters associated with the method to invoke. May be null (no parameters).listener - the listener to call back when remote call initiated and completed. Must not be null.public static void asyncExec(IRemoteService remoteService, String method, Object[] parameters, long timeout, IRemoteCallListener listener)
remoteService - the IRemoteService to invoke. Must not be null.method - the method to invoke. Must not be null.parameters - the parameters associated with the method to invoke. May be null (no parameters).timeout - the timeout (in ms) for the remote call.listener - the listener to call back when remote call initiated and completed. Must not be null.public static org.eclipse.equinox.concurrent.future.IFuture futureExec(IRemoteService remoteService, String method, Object[] parameters, long timeout)
remoteService - the IRemoteService to invoke. Must not be null.method - the method to invoke. Must not be null.parameters - the parameters associated with the method to invoke. May be null (no parameters).timeout - the timeout (in ms) for the remote call.public static org.eclipse.equinox.concurrent.future.IFuture futureExec(IRemoteService remoteService, String method, Object[] parameters)
remoteService - the IRemoteService to invoke. Must not be null.method - the method to invoke. Must not be null.parameters - the parameters associated with the method to invoke. May be null (no parameters).public static Object syncExec(IRemoteService remoteService, String method, Object[] parameters, long timeout) throws ECFException
remoteService - the IRemoteService to invoke. Must not be null.method - the method to invoke. Must not be null.parameters - the parameters associated with the method to invoke. May be null (no parameters).timeout - the timeout (in ms) for the remote call.ECFException - if some problem with executionpublic static Object syncExec(IRemoteService remoteService, String method, Object[] parameters) throws ECFException
remoteService - the IRemoteService to invoke. Must not be null.method - the method to invoke. Must not be null.parameters - the parameters associated with the method to invoke. May be null (no parameters).ECFException - if some problem with executionCopyright © 2004–2020 Eclipse Foundation. All rights reserved.