pub struct AccessRuleView {Show 14 fields
pub id: AccessRuleId,
pub organization_id: OrganizationId,
pub name: String,
pub description: Option<String>,
pub enabled: bool,
pub conditions: Vec<AccessCondition>,
pub single_active_lease: bool,
pub default_lease_duration_seconds: Option<i32>,
pub max_lease_duration_seconds: Option<i32>,
pub allows_extensions: bool,
pub max_extension_duration_seconds: Option<i32>,
pub collections: Vec<CollectionId>,
pub creation_date: DateTime<Utc>,
pub revision_date: DateTime<Utc>,
}Expand description
A decrypted view of an access rule, as returned by the server.
Fields§
§id: AccessRuleIdThe rule’s unique identifier.
organization_id: OrganizationIdThe organization this rule belongs to.
name: StringThe rule’s display name, shown wherever rules are listed and managed.
description: Option<String>Optional free-text describing the rule’s intent.
enabled: boolWhen false, the rule is inactive and does not gate access for the collections it governs.
conditions: Vec<AccessCondition>The condition tree that decides how access is granted under this rule.
single_active_lease: boolWhen true, the rule enforces a per-cipher singleton (at most one active lease per cipher across all users).
default_lease_duration_seconds: Option<i32>Default lease duration in seconds, used to pre-fill a request opened under this rule. None means the backend default applies.
max_lease_duration_seconds: Option<i32>Hard ceiling on the duration of any single lease granted under this rule, in seconds. None means no per-rule cap.
allows_extensions: boolWhen true, a member holding an active lease under this rule may extend it once.
max_extension_duration_seconds: Option<i32>The longest a single extension may run, in seconds. Set when allows_extensions is true.
collections: Vec<CollectionId>The complete set of collections this rule governs.
creation_date: DateTime<Utc>When the rule was created (UTC).
revision_date: DateTime<Utc>When the rule was last modified (UTC).
Trait Implementations§
Source§impl Clone for AccessRuleView
impl Clone for AccessRuleView
Source§fn clone(&self) -> AccessRuleView
fn clone(&self) -> AccessRuleView
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for AccessRuleView
impl Debug for AccessRuleView
Source§impl<'de> Deserialize<'de> for AccessRuleView
impl<'de> Deserialize<'de> for AccessRuleView
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<AccessRuleView> for JsValuewhere
AccessRuleView: Serialize,
impl From<AccessRuleView> for JsValuewhere
AccessRuleView: Serialize,
Source§fn from(value: AccessRuleView) -> Self
fn from(value: AccessRuleView) -> Self
Source§impl FromWasmAbi for AccessRuleViewwhere
Self: DeserializeOwned,
impl FromWasmAbi for AccessRuleViewwhere
Self: DeserializeOwned,
Source§impl IntoWasmAbi for &AccessRuleViewwhere
AccessRuleView: Serialize,
impl IntoWasmAbi for &AccessRuleViewwhere
AccessRuleView: Serialize,
Source§impl IntoWasmAbi for AccessRuleViewwhere
AccessRuleView: Serialize,
impl IntoWasmAbi for AccessRuleViewwhere
AccessRuleView: Serialize,
Source§impl OptionFromWasmAbi for AccessRuleViewwhere
Self: DeserializeOwned,
impl OptionFromWasmAbi for AccessRuleViewwhere
Self: DeserializeOwned,
Source§impl OptionIntoWasmAbi for AccessRuleViewwhere
AccessRuleView: Serialize,
impl OptionIntoWasmAbi for AccessRuleViewwhere
AccessRuleView: Serialize,
Source§impl PartialEq for AccessRuleView
impl PartialEq for AccessRuleView
Source§impl RefFromWasmAbi for AccessRuleViewwhere
Self: DeserializeOwned,
impl RefFromWasmAbi for AccessRuleViewwhere
Self: DeserializeOwned,
Source§type Abi = <JsType as RefFromWasmAbi>::Abi
type Abi = <JsType as RefFromWasmAbi>::Abi
Self are recovered from.Source§type Anchor = SelfOwner<AccessRuleView>
type Anchor = SelfOwner<AccessRuleView>
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 AccessRuleView
impl Serialize for AccessRuleView
Source§impl TryFrom<AccessRuleResponseModel> for AccessRuleView
impl TryFrom<AccessRuleResponseModel> for AccessRuleView
Source§impl Tsify for AccessRuleView
impl Tsify for AccessRuleView
const DECL: &'static str = "/**\n * A decrypted view of an access rule, as returned by the server.\n */\nexport interface AccessRuleView {\n /**\n * The rule\\\'s unique identifier.\n */\n id: AccessRuleId;\n /**\n * The organization this rule belongs to.\n */\n organizationId: OrganizationId;\n /**\n * The rule\\\'s display name, shown wherever rules are listed and managed.\n */\n name: string;\n /**\n * Optional free-text describing the rule\\\'s intent.\n */\n description: string | undefined;\n /**\n * When false, the rule is inactive and does not gate access for the collections it governs.\n */\n enabled: boolean;\n /**\n * The condition tree that decides how access is granted under this rule.\n */\n conditions: AccessCondition[];\n /**\n * When true, the rule enforces a per-cipher singleton (at most one active lease per cipher\n * across all users).\n */\n singleActiveLease: boolean;\n /**\n * Default lease duration in seconds, used to pre-fill a request opened under this rule. None\n * means the backend default applies.\n */\n defaultLeaseDurationSeconds: number | undefined;\n /**\n * Hard ceiling on the duration of any single lease granted under this rule, in seconds. None\n * means no per-rule cap.\n */\n maxLeaseDurationSeconds: number | undefined;\n /**\n * When true, a member holding an active lease under this rule may extend it once.\n */\n allowsExtensions: boolean;\n /**\n * The longest a single extension may run, in seconds. Set when `allows_extensions` is true.\n */\n maxExtensionDurationSeconds: number | undefined;\n /**\n * The complete set of collections this rule governs.\n */\n collections: CollectionId[];\n /**\n * When the rule was created (UTC).\n */\n creationDate: DateTime<Utc>;\n /**\n * When the rule was last modified (UTC).\n */\n revisionDate: DateTime<Utc>;\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 AccessRuleViewwhere
Self: DeserializeOwned,
impl VectorFromWasmAbi for AccessRuleViewwhere
Self: DeserializeOwned,
type Abi = <JsType as VectorFromWasmAbi>::Abi
unsafe fn vector_from_abi(js: Self::Abi) -> Box<[Self]>
Source§impl VectorIntoWasmAbi for AccessRuleViewwhere
AccessRuleView: Serialize,
impl VectorIntoWasmAbi for AccessRuleViewwhere
AccessRuleView: Serialize,
type Abi = <JsType as VectorIntoWasmAbi>::Abi
fn vector_into_abi(vector: Box<[Self]>) -> Self::Abi
Source§impl WasmDescribe for AccessRuleView
impl WasmDescribe for AccessRuleView
impl StructuralPartialEq for AccessRuleView
Auto Trait Implementations§
impl Freeze for AccessRuleView
impl RefUnwindSafe for AccessRuleView
impl Send for AccessRuleView
impl Sync for AccessRuleView
impl Unpin for AccessRuleView
impl UnsafeUnpin for AccessRuleView
impl UnwindSafe for AccessRuleView
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.