* Generic remote command implementation that sends the rpc xml to the remote device and waits for response
/**
* Generic remote command implementation that sends the rpc xml to the remote device and waits for response
@@ -33,16+35,18 @@ public class RemoteCommand extends AbstractCommand {
// TODO make this configurable
private static final long DEFAULT_TIMEOUT = 10000;
private static final TimeUnit DEFAULT_TIMEOUT_UNIT = TimeUnit.MILLISECONDS;
// TODO make this configurable
private static final long DEFAULT_TIMEOUT = 10000;
private static final TimeUnit DEFAULT_TIMEOUT_UNIT = TimeUnit.MILLISECONDS;
- private final RpcImplementation rpc;
+ private final DOMRpcService rpcService;
- public RemoteCommand(final QName qName, final InputDefinition args, final OutputDefinition output, final String description, final RpcImplementation rpc) {
+ public RemoteCommand(final QName qName, final InputDefinition args, final OutputDefinition output, final String description, final DOMRpcService rpcService) {
super(qName, args, output, description);
super(qName, args, output, description);
- this.rpc = rpc;
+ this.rpcService = rpcService;
}
@Override
public Output invoke(final Input inputArgs) throws CommandInvocationException {
}
@Override
public Output invoke(final Input inputArgs) throws CommandInvocationException {
- final ListenableFuture<RpcResult<CompositeNode>> invokeRpc = rpc.invokeRpc(getCommandId(), inputArgs.wrap(getCommandId()));
+ final CheckedFuture<DOMRpcResult, DOMRpcException> invokeRpc =