@Override public ProtocolSignedDelta signDelta(ByteStringMessage<ProtocolWaveletDelta> delta) { // TODO: support extended address paths. For now, there will be exactly // one signature, and we don't support federated groups. Preconditions.checkState(delta.getMessage().getAddressPathCount() == 0); ProtocolSignedDelta.Builder signedDelta = ProtocolSignedDelta.newBuilder(); signedDelta.setDelta(delta.getByteString()); signedDelta.addAllSignature(waveSigner.sign(delta)); return signedDelta.build(); }
when(localSigner.sign(Matchers.<ByteStringMessage<ProtocolWaveletDelta>>any())) .thenReturn(ImmutableList.<ProtocolSignature>of());
when(localSigner.sign(Matchers.<ByteStringMessage<ProtocolWaveletDelta>>any())) .thenReturn(ImmutableList.<ProtocolSignature>of());