Skip to content
Snippets Groups Projects
Commit 40488db2 authored by codecraft's avatar codecraft :crocodile:
Browse files

Add basic cookie utility prototypes

parent 94752493
No related branches found
No related tags found
1 merge request!1Initial feature merge
struct CookieBuilder {}
mod cookie_builder;
...@@ -20,21 +20,21 @@ pub enum SameSite { ...@@ -20,21 +20,21 @@ pub enum SameSite {
pub struct Cookie<'a> { pub struct Cookie<'a> {
/// Storage for the cookie string. Only used if this structure was derived /// Storage for the cookie string. Only used if this structure was derived
/// from a string that was subsequently parsed. /// from a string that was subsequently parsed.
cookie_string: &'a str, pub(crate) cookie_string: Option<&'a str>,
name: &'a str, pub(crate) name: &'a str,
value: &'a str, pub(crate) value: &'a str,
// expires: Option<Tm>, // expires: Option<Tm>,
max_age: Option<Duration>, pub(crate) max_age: Option<Duration>,
/// The cookie's domain, if any. /// The cookie's domain, if any.
domain: Option<&'a str>, pub(crate) domain: Option<&'a str>,
/// The cookie's path domain, if any. /// The cookie's path domain, if any.
path: Option<&'a str>, pub(crate) path: Option<&'a str>,
/// Whether this cookie was marked Secure. /// Whether this cookie was marked Secure.
secure: Option<bool>, pub(crate) secure: Option<bool>,
/// Whether this cookie was marked HttpOnly. /// Whether this cookie was marked HttpOnly.
http_only: Option<bool>, pub(crate) http_only: Option<bool>,
/// The draft `SameSite` attribute. /// The draft `SameSite` attribute.
same_site: Option<SameSite>, pub(crate) same_site: Option<SameSite>,
} }
pub struct Response<'a> { pub struct Response<'a> {
......
mod cookie; mod cookie_management;
mod datatypes; mod datatypes;
mod response; mod response;
mod status; mod status;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment