@Override public ConcatResponseProto concat(RpcController controller, ConcatRequestProto req) throws ServiceException { try { List<String> srcs = req.getSrcsList(); server.concat(req.getTrg(), srcs.toArray(new String[srcs.size()])); } catch (IOException e) { throw new ServiceException(e); } return VOID_CONCAT_RESPONSE; }
@Override public void concat(String trg, String[] srcs) throws IOException, UnresolvedLinkException { ConcatRequestProto req = ConcatRequestProto.newBuilder(). setTrg(trg). addAllSrcs(Arrays.asList(srcs)).build(); try { rpcProxy.concat(null, req); } catch (ServiceException e) { throw ProtobufHelper.getRemoteException(e); } }
@Override public void concat(String trg, String[] srcs) throws IOException { ConcatRequestProto req = ConcatRequestProto.newBuilder(). setTrg(trg). addAllSrcs(Arrays.asList(srcs)).build(); try { rpcProxy.concat(null, req); } catch (ServiceException e) { throw ProtobufHelper.getRemoteException(e); } }