pub struct CacheControl {
pub max_age: Option<u64>,
pub s_maxage: Option<u64>,
pub no_cache: bool,
pub no_store: bool,
pub must_revalidate: bool,
pub public: bool,
pub private: bool,
pub immutable: bool,
}Expand description
Cache-Control ヘッダの解析結果
Fields§
§max_age: Option<u64>有効期間(秒)。max-age=N
s_maxage: Option<u64>共有キャッシュ用有効期間(秒)。s-maxage=N
no_cache: boolキャッシュ利用前にオリジンサーバーへの再検証を要求
no_store: boolメディア・ディスク・メモリへの一切のキャッシュ保存を禁止
must_revalidate: bool期限切れ後のステールキャッシュ使用を厳格に禁止(再検証必須)
public: bool共有キャッシュへの保存許可
private: bool単一ユーザーのブラウザ専用キャッシュ(共有プロキシへの保存禁止)
immutable: bool有効期限内はリソースが絶対に変更されないことを保証
Implementations§
Trait Implementations§
Source§impl Clone for CacheControl
impl Clone for CacheControl
Source§impl Debug for CacheControl
impl Debug for CacheControl
Source§impl Default for CacheControl
impl Default for CacheControl
impl Eq for CacheControl
Source§impl PartialEq for CacheControl
impl PartialEq for CacheControl
impl StructuralPartialEq for CacheControl
Auto Trait Implementations§
impl Freeze for CacheControl
impl RefUnwindSafe for CacheControl
impl Send for CacheControl
impl Sync for CacheControl
impl Unpin for CacheControl
impl UnsafeUnpin for CacheControl
impl UnwindSafe for CacheControl
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.