@Test public void wrapMethodDefinition_methodDescriptor() throws Exception { ServerMethodDefinition<String, Integer> methodDef = ServerMethodDefinition.create( method, new ServerCallHandler<String, Integer>() { @Override public Listener<String> startCall( ServerCall<String, Integer> call, Metadata headers) { throw new UnsupportedOperationException(); } }); ServerMethodDefinition<?, ?> wMethodDef = binlogProvider.wrapMethodDefinition(methodDef); validateWrappedMethod(wMethodDef.getMethodDescriptor()); }
@Override public final <ReqT, RespT> ServerMethodDefinition<?, ?> wrapMethodDefinition( ServerMethodDefinition<ReqT, RespT> oMethodDef) { ServerInterceptor binlogInterceptor = getServerInterceptor(oMethodDef.getMethodDescriptor().getFullMethodName()); if (binlogInterceptor == null) { return oMethodDef; } MethodDescriptor<byte[], byte[]> binMethod = BinaryLogProvider.toByteBufferMethod(oMethodDef.getMethodDescriptor()); ServerMethodDefinition<byte[], byte[]> binDef = InternalServerInterceptors.wrapMethod(oMethodDef, binMethod); ServerCallHandler<byte[], byte[]> binlogHandler = InternalServerInterceptors.interceptCallHandlerCreate( binlogInterceptor, binDef.getServerCallHandler()); return ServerMethodDefinition.create(binMethod, binlogHandler); }
BinaryLogProvider extends BinaryLog { @Override public final <ReqT, RespT> ServerMethodDefinition<?, ?> wrapMethodDefinition( ServerMethodDefinition<ReqT, RespT> oMethodDef) { ServerInterceptor binlogInterceptor = getServerInterceptor(oMethodDef.getMethodDescriptor().getFullMethodName()); if (binlogInterceptor == null) { return oMethodDef; } MethodDescriptor<byte[], byte[]> binMethod = BinaryLogProvider.toByteBufferMethod(oMethodDef.getMethodDescriptor()); ServerMethodDefinition<byte[], byte[]> binDef = InternalServerInterceptors.wrapMethod(oMethodDef, binMethod); ServerCallHandler<byte[], byte[]> binlogHandler = InternalServerInterceptors.interceptCallHandlerCreate( binlogInterceptor, binDef.getServerCallHandler()); return ServerMethodDefinition.create(binMethod, binlogHandler); } }
BinaryLogProvider extends BinaryLog { @Override public final <ReqT, RespT> ServerMethodDefinition<?, ?> wrapMethodDefinition( ServerMethodDefinition<ReqT, RespT> oMethodDef) { ServerInterceptor binlogInterceptor = getServerInterceptor(oMethodDef.getMethodDescriptor().getFullMethodName()); if (binlogInterceptor == null) { return oMethodDef; } MethodDescriptor<byte[], byte[]> binMethod = BinaryLogProvider.toByteBufferMethod(oMethodDef.getMethodDescriptor()); ServerMethodDefinition<byte[], byte[]> binDef = InternalServerInterceptors.wrapMethod(oMethodDef, binMethod); ServerCallHandler<byte[], byte[]> binlogHandler = InternalServerInterceptors.interceptCallHandlerCreate( binlogInterceptor, binDef.getServerCallHandler()); return ServerMethodDefinition.create(binMethod, binlogHandler); }  }
BinaryLogProvider extends BinaryLog { @Override public final <ReqT, RespT> ServerMethodDefinition<?, ?> wrapMethodDefinition( ServerMethodDefinition<ReqT, RespT> oMethodDef) { ServerInterceptor binlogInterceptor = getServerInterceptor(oMethodDef.getMethodDescriptor().getFullMethodName()); if (binlogInterceptor == null) { return oMethodDef; } MethodDescriptor<byte[], byte[]> binMethod = BinaryLogProvider.toByteBufferMethod(oMethodDef.getMethodDescriptor()); ServerMethodDefinition<byte[], byte[]> binDef = InternalServerInterceptors.wrapMethod(oMethodDef, binMethod); ServerCallHandler<byte[], byte[]> binlogHandler = InternalServerInterceptors.interceptCallHandlerCreate( binlogInterceptor, binDef.getServerCallHandler()); return ServerMethodDefinition.create(binMethod, binlogHandler); }  @Override final Channel wrapChannel(Channel channel); @Override final ServerMethodDefinition<?, ?> wrapMethodDefinition(
      ServerMethodDefinition<ReqT, RespT> oMethodDef); @Override void close(); }
BinaryLogProvider extends BinaryLog { @Override public final <ReqT, RespT> ServerMethodDefinition<?, ?> wrapMethodDefinition( ServerMethodDefinition<ReqT, RespT> oMethodDef) { ServerInterceptor binlogInterceptor = getServerInterceptor(oMethodDef.getMethodDescriptor().getFullMethodName()); if (binlogInterceptor == null) { return oMethodDef; } MethodDescriptor<byte[], byte[]> binMethod = BinaryLogProvider.toByteBufferMethod(oMethodDef.getMethodDescriptor()); ServerMethodDefinition<byte[], byte[]> binDef = InternalServerInterceptors.wrapMethod(oMethodDef, binMethod); ServerCallHandler<byte[], byte[]> binlogHandler = InternalServerInterceptors.interceptCallHandlerCreate( binlogInterceptor, binDef.getServerCallHandler()); return ServerMethodDefinition.create(binMethod, binlogHandler); }  @Override final Channel wrapChannel(Channel channel); @Override final ServerMethodDefinition<?, ?> wrapMethodDefinition(
      ServerMethodDefinition<ReqT, RespT> oMethodDef); @Override void close(); @VisibleForTesting
  static final Marshaller<byte[]> BYTEARRAY_MARSHALLER; }