pub struct CipherAccessStateView {
pub cipher_id: CipherId,
pub active_lease: Option<AccessLeaseView>,
pub pending_request: Option<AccessRequestView>,
pub approved_request: Option<AccessRequestView>,
pub extensions_allowed: bool,
pub max_extension_duration_seconds: Option<i32>,
}Expand description
A single-snapshot read of the caller’s access state for one cipher, powering the cipher-view banner and the vault-row badge.
At most one of active_lease, pending_request,
and approved_request is meaningfully “next”: an active lease
authorizes access, a pending request awaits a decision, and an approved request awaits
activation by the caller.
Fields§
§cipher_id: CipherIdThe cipher this state was resolved for.
active_lease: Option<AccessLeaseView>The caller’s active lease over this cipher, if any.
pending_request: Option<AccessRequestView>The caller’s request awaiting a decision on this cipher, if any.
approved_request: Option<AccessRequestView>The caller’s approved-but-not-yet-activated request on this cipher, if any. Lapsed approvals are never surfaced here.
extensions_allowed: boolWhether the active lease can still be extended.
max_extension_duration_seconds: Option<i32>The longest a single extension of the active lease may run, in seconds; None when there is no cap or no active lease.
Trait Implementations§
Source§impl Clone for CipherAccessStateView
impl Clone for CipherAccessStateView
Source§fn clone(&self) -> CipherAccessStateView
fn clone(&self) -> CipherAccessStateView
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for CipherAccessStateView
impl Debug for CipherAccessStateView
Source§impl<'de> Deserialize<'de> for CipherAccessStateView
impl<'de> Deserialize<'de> for CipherAccessStateView
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl From<CipherAccessStateView> for JsValuewhere
CipherAccessStateView: Serialize,
impl From<CipherAccessStateView> for JsValuewhere
CipherAccessStateView: Serialize,
Source§fn from(value: CipherAccessStateView) -> Self
fn from(value: CipherAccessStateView) -> Self
Source§impl FromWasmAbi for CipherAccessStateViewwhere
Self: DeserializeOwned,
impl FromWasmAbi for CipherAccessStateViewwhere
Self: DeserializeOwned,
Source§impl IntoWasmAbi for &CipherAccessStateViewwhere
CipherAccessStateView: Serialize,
impl IntoWasmAbi for &CipherAccessStateViewwhere
CipherAccessStateView: Serialize,
Source§impl IntoWasmAbi for CipherAccessStateViewwhere
CipherAccessStateView: Serialize,
impl IntoWasmAbi for CipherAccessStateViewwhere
CipherAccessStateView: Serialize,
Source§impl OptionFromWasmAbi for CipherAccessStateViewwhere
Self: DeserializeOwned,
impl OptionFromWasmAbi for CipherAccessStateViewwhere
Self: DeserializeOwned,
Source§impl OptionIntoWasmAbi for CipherAccessStateViewwhere
CipherAccessStateView: Serialize,
impl OptionIntoWasmAbi for CipherAccessStateViewwhere
CipherAccessStateView: Serialize,
Source§impl PartialEq for CipherAccessStateView
impl PartialEq for CipherAccessStateView
Source§impl RefFromWasmAbi for CipherAccessStateViewwhere
Self: DeserializeOwned,
impl RefFromWasmAbi for CipherAccessStateViewwhere
Self: DeserializeOwned,
Source§type Abi = <JsType as RefFromWasmAbi>::Abi
type Abi = <JsType as RefFromWasmAbi>::Abi
Self are recovered from.Source§type Anchor = SelfOwner<CipherAccessStateView>
type Anchor = SelfOwner<CipherAccessStateView>
Self for the duration of the
invocation of the function that has an &Self parameter. This is
required to ensure that the lifetimes don’t persist beyond one function
call, and so that they remain anonymous.Source§impl Serialize for CipherAccessStateView
impl Serialize for CipherAccessStateView
Source§impl TryFrom<CipherAccessStateResponseModel> for CipherAccessStateView
impl TryFrom<CipherAccessStateResponseModel> for CipherAccessStateView
Source§impl Tsify for CipherAccessStateView
impl Tsify for CipherAccessStateView
const DECL: &'static str = "/**\n * A single-snapshot read of the caller\\\'s access state for one cipher, powering the cipher-view\n * banner and the vault-row badge.\n *\n * At most one of [`active_lease`](Self::active_lease), [`pending_request`](Self::pending_request),\n * and [`approved_request`](Self::approved_request) is meaningfully \\\"next\\\": an active lease\n * authorizes access, a pending request awaits a decision, and an approved request awaits\n * activation by the caller.\n */\nexport interface CipherAccessStateView {\n /**\n * The cipher this state was resolved for.\n */\n cipherId: CipherId;\n /**\n * The caller\\\'s active lease over this cipher, if any.\n */\n activeLease: AccessLeaseView | undefined;\n /**\n * The caller\\\'s request awaiting a decision on this cipher, if any.\n */\n pendingRequest: AccessRequestView | undefined;\n /**\n * The caller\\\'s approved-but-not-yet-activated request on this cipher, if any. Lapsed\n * approvals are never surfaced here.\n */\n approvedRequest: AccessRequestView | undefined;\n /**\n * Whether the active lease can still be extended.\n */\n extensionsAllowed: boolean;\n /**\n * The longest a single extension of the active lease may run, in seconds; None when there is\n * no cap or no active lease.\n */\n maxExtensionDurationSeconds: number | undefined;\n}"
const SERIALIZATION_CONFIG: SerializationConfig
type JsType = JsType
fn into_js(&self) -> Result<Self::JsType, Error>where
Self: Serialize,
fn from_js<T>(js: T) -> Result<Self, Error>
Source§impl VectorFromWasmAbi for CipherAccessStateViewwhere
Self: DeserializeOwned,
impl VectorFromWasmAbi for CipherAccessStateViewwhere
Self: DeserializeOwned,
type Abi = <JsType as VectorFromWasmAbi>::Abi
unsafe fn vector_from_abi(js: Self::Abi) -> Box<[Self]>
Source§impl VectorIntoWasmAbi for CipherAccessStateViewwhere
CipherAccessStateView: Serialize,
impl VectorIntoWasmAbi for CipherAccessStateViewwhere
CipherAccessStateView: Serialize,
type Abi = <JsType as VectorIntoWasmAbi>::Abi
fn vector_into_abi(vector: Box<[Self]>) -> Self::Abi
Source§impl WasmDescribe for CipherAccessStateView
impl WasmDescribe for CipherAccessStateView
impl StructuralPartialEq for CipherAccessStateView
Auto Trait Implementations§
impl Freeze for CipherAccessStateView
impl RefUnwindSafe for CipherAccessStateView
impl Send for CipherAccessStateView
impl Sync for CipherAccessStateView
impl Unpin for CipherAccessStateView
impl UnsafeUnpin for CipherAccessStateView
impl UnwindSafe for CipherAccessStateView
Blanket Implementations§
§impl<T> AnySync for T
impl<T> AnySync for T
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> CompatExt for T
impl<T> CompatExt for T
§impl<T, UT> HandleAlloc<UT> for T
impl<T, UT> HandleAlloc<UT> for T
§fn new_handle(value: Arc<T>) -> Handle
fn new_handle(value: Arc<T>) -> Handle
§unsafe fn clone_handle(handle: Handle) -> Handle
unsafe fn clone_handle(handle: Handle) -> Handle
§unsafe fn consume_handle(handle: Handle) -> Arc<T>
unsafe fn consume_handle(handle: Handle) -> Arc<T>
Arc<> Read more§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ReturnWasmAbi for Twhere
T: IntoWasmAbi,
impl<T> ReturnWasmAbi for Twhere
T: IntoWasmAbi,
Source§type Abi = <T as IntoWasmAbi>::Abi
type Abi = <T as IntoWasmAbi>::Abi
IntoWasmAbi::AbiSource§fn return_abi(self) -> <T as ReturnWasmAbi>::Abi
fn return_abi(self) -> <T as ReturnWasmAbi>::Abi
IntoWasmAbi::into_abi, except that it may throw and never
return in the case of Err.