Ejemplo n.º 1
0
 @Override
 public RequestFixture body(byte[] bytes, String contentType) {
   requestHeaders.add(HttpHeaderNames.CONTENT_TYPE, contentType);
   requestHeaders.add(HttpHeaderNames.CONTENT_LENGTH, bytes.length);
   requestBody.capacity(bytes.length).writeBytes(bytes);
   return this;
 }
Ejemplo n.º 2
0
 @Override
 public RequestFixture header(CharSequence name, String value) {
   requestHeaders.add(name, value);
   return this;
 }