Search in sources :

Example 6 with RouterCookie

use of org.webpieces.ctx.api.RouterCookie in project webpieces by deanhiller.

the class RequestStreamWriter method copy.

private Map<String, RouterCookie> copy(Map<String, String> cookies) {
    Map<String, RouterCookie> map = new HashMap<>();
    for (Entry<String, String> entry : cookies.entrySet()) {
        RouterCookie c = copy(entry.getKey(), entry.getValue());
        map.put(c.name, c);
    }
    return map;
}
Also used : HashMap(java.util.HashMap) RouterCookie(org.webpieces.ctx.api.RouterCookie)

Example 7 with RouterCookie

use of org.webpieces.ctx.api.RouterCookie in project webpieces by deanhiller.

the class ResponseCreator method addDeleteCookie.

public void addDeleteCookie(Http2Response response, String badCookieName) {
    RouterCookie cookie = cookieTranslator.createDeleteCookie(badCookieName);
    Http2Header cookieHeader = create(cookie);
    response.addHeader(cookieHeader);
}
Also used : Http2Header(com.webpieces.http2parser.api.dto.lib.Http2Header) RouterCookie(org.webpieces.ctx.api.RouterCookie)

Example 8 with RouterCookie

use of org.webpieces.ctx.api.RouterCookie in project webpieces by deanhiller.

the class RequestStreamWriter method copy.

private RouterCookie copy(String name, String val) {
    RouterCookie rCookie = new RouterCookie();
    rCookie.name = name;
    rCookie.value = val;
    return rCookie;
}
Also used : RouterCookie(org.webpieces.ctx.api.RouterCookie)

Aggregations

RouterCookie (org.webpieces.ctx.api.RouterCookie)8 Http2Header (com.webpieces.http2parser.api.dto.lib.Http2Header)2 HashMap (java.util.HashMap)2 SecureCookie (org.webpieces.router.impl.ctx.SecureCookie)2 DateTime (org.joda.time.DateTime)1 BadCookieException (org.webpieces.router.api.exceptions.BadCookieException)1 CookieTooLargeException (org.webpieces.router.api.exceptions.CookieTooLargeException)1 CookieScopeImpl (org.webpieces.router.impl.ctx.CookieScopeImpl)1 SecretKeyInfo (org.webpieces.util.security.SecretKeyInfo)1