5use InvalidArgumentException;
20 if ($cookies->has(
$name)) {
21 return $cookies->get(
$name);
37 ->renderIntoCookieHeader($request)
50 if (! is_callable($modify)) {
51 throw new InvalidArgumentException(
'$modify must be callable.');
55 $cookie = $modify($cookies->has(
$name)
56 ? $cookies->get(
$name)
62 ->renderIntoCookieHeader($request)
76 ->renderIntoCookieHeader($request)
An exception for terminatinating execution or to throw for unit testing.
static create($name, $value=null)
Create a Cookie.
static fromRequest(RequestInterface $request)
Create Cookies from a Request.
static modify(RequestInterface $request, $name, $modify)
Representation of an outgoing, client-side request.