@Test public void nameOnly(){ String cookieHeader = "__test; name=Bob"; CookieField field = new CookieField(cookieHeader); Assert.assertNotNull(field.cookies().get(0)); Assert.assertEquals("__test", field.cookies().get(0).name); Assert.assertNull(field.cookies().get(0).value); Assert.assertEquals("Bob", field.cookies().get(1).value); }
public List<Cookie> cookies() { return cookies; }
CookieField extends HeaderField { public List<Cookie> cookies() { return cookies; } }
CookieField extends HeaderField { public List<Cookie> cookies() { return cookies; } CookieField(String fieldValue);  CookieField(Cookie ... cookies); }
CookieField extends HeaderField { public List<Cookie> cookies() { return cookies; } CookieField(String fieldValue);  CookieField(Cookie ... cookies); @Override T accept(HeaderFieldVisitor<T> visitor); @Override String name(); List<Cookie> cookies(); @Override String value(); }
CookieField extends HeaderField { public List<Cookie> cookies() { return cookies; } CookieField(String fieldValue);  CookieField(Cookie ... cookies); @Override T accept(HeaderFieldVisitor<T> visitor); @Override String name(); List<Cookie> cookies(); @Override String value();  }