|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.jayway.restassured.response.Cookies
public class Cookies
Represents the a number of response cookies
| Constructor Summary | |
|---|---|
Cookies(Cookie... cookies)
|
|
Cookies(List<Cookie> cookies)
|
|
| Method Summary | |
|---|---|
static Cookies |
cookies(Cookie cookie,
Cookie... additionalCookies)
An alternative way to create a Cookies object from the constructor. |
boolean |
exist()
|
Cookie |
get(String cookieName)
Get a single cookie with the supplied name. |
List<Cookie> |
getList(String cookieName)
Get all cookies with the supplied name. |
String |
getValue(String cookieName)
Get a single cookie value with the supplied name. |
List<String> |
getValues(String cookieName)
Get all cookie values of the cookie with the supplied name. |
boolean |
hasCookieWithName(String cookieName)
See if a cookie with the given name exists |
Iterator<Cookie> |
iterator()
|
protected List<Cookie> |
list()
|
int |
size()
|
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public Cookies(Cookie... cookies)
public Cookies(List<Cookie> cookies)
| Method Detail |
|---|
public int size()
public boolean exist()
true if one or more cookies are defined, false otherwise.public boolean hasCookieWithName(String cookieName)
cookieName - The name of the cookie to check
true if the cookie existsprotected List<Cookie> list()
public Cookie get(String cookieName)
cookieName then
the first one is returned.
cookieName - The name of the cookie to find
null if no cookie was found.public String getValue(String cookieName)
cookieName then
the first one is returned.
cookieName - The name of the cookie to find
null if no cookie was found.public List<Cookie> getList(String cookieName)
cookieName then
a list with only that cookie is returned.
cookieName - The name of the cookie to find
public List<String> getValues(String cookieName)
cookieName then
a list with only that cookie value is returned.
cookieName - The name of the header to find
public Iterator<Cookie> iterator()
iterator in interface Iterable<Cookie>
public static Cookies cookies(Cookie cookie,
Cookie... additionalCookies)
cookie - The cookie to be includedadditionalCookies - Additional cookies to be included (optional)
public String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||