com.jayway.restassured.response
Interface ResponseBody

All Known Subinterfaces:
Response
All Known Implementing Classes:
RestAssuredResponseImpl

public interface ResponseBody


Method Summary
 byte[] asByteArray()
          Get the body as a byte array.
 String asString()
          Get the body as a string.
 String print()
          Print the response body and return it as string.
 

Method Detail

print

String print()
Print the response body and return it as string. Mainly useful for debug purposes when writing tests.

Returns:
The body as a string.

asString

String asString()
Get the body as a string. You can only do this if you've not used REST Assured response expectations.

Returns:
The body as a string.

asByteArray

byte[] asByteArray()
Get the body as a byte array. You can only do this if you've not used REST Assured response expectations.

Returns:
The body as a array.


Copyright © 2010-2011. All Rights Reserved.