pub struct SubaccountInviteOwnedView(/* private fields */);Expand description
Self-contained, 'static owned view of a SubaccountInvite message.
Wraps ::buffa::OwnedView<SubaccountInviteView<'static>>: the decoded view and the ::buffa::bytes::Bytes buffer it borrows from travel together, so the handle is 'static and Send + Sync — suitable for async handlers, spawned tasks, and anywhere a 'static bound is required.
Field accessors return borrows tied to &self. Use Self::view to get the full SubaccountInviteView when you need struct patterns, iteration helpers, or to pass the view to lifetime-parameterised code.
Implementations§
Source§impl SubaccountInviteOwnedView
impl SubaccountInviteOwnedView
Sourcepub fn decode(bytes: Bytes) -> Result<Self, DecodeError>
pub fn decode(bytes: Bytes) -> Result<Self, DecodeError>
Decode an owned view from a ::buffa::bytes::Bytes buffer.
The view borrows directly from the buffer’s data; the buffer is retained inside the returned handle.
§Errors
Returns ::buffa::DecodeError if the buffer contains invalid
protobuf data.
Sourcepub fn decode_with_options(
bytes: Bytes,
opts: &DecodeOptions,
) -> Result<Self, DecodeError>
pub fn decode_with_options( bytes: Bytes, opts: &DecodeOptions, ) -> Result<Self, DecodeError>
Decode with custom ::buffa::DecodeOptions (recursion limit,
max message size).
§Errors
Returns ::buffa::DecodeError if the buffer is invalid or
exceeds the configured limits.
Sourcepub fn from_owned(msg: &SubaccountInvite) -> Result<Self, DecodeError>
pub fn from_owned(msg: &SubaccountInvite) -> Result<Self, DecodeError>
Build from an owned message via an encode → decode round-trip.
§Errors
Returns ::buffa::DecodeError if the re-encoded bytes are
somehow invalid (should not happen for well-formed messages).
Sourcepub fn view(&self) -> &SubaccountInviteView<'_>
pub fn view(&self) -> &SubaccountInviteView<'_>
Borrow the full SubaccountInviteView with its lifetime tied to &self.
Sourcepub fn to_owned_message(&self) -> Result<SubaccountInvite, DecodeError>
pub fn to_owned_message(&self) -> Result<SubaccountInvite, DecodeError>
Convert to the owned message type.
§Errors
Returns an error if re-materializing preserved unknown fields fails (e.g. the unknown-field limit is exceeded).
Sourcepub fn into_bytes(self) -> Bytes
pub fn into_bytes(self) -> Bytes
Consume the handle, returning the underlying bytes buffer.
Sourcepub fn subaccount_id(&self) -> u64
pub fn subaccount_id(&self) -> u64
Target sub-account (opaque ID).
Field 2: subaccount_id
Sourcepub fn grantee_account_id(&self) -> u64
pub fn grantee_account_id(&self) -> u64
Grantee root account ID the invite is for (opaque ID).
Field 3: grantee_account_id
Sourcepub fn inviter_account_id(&self) -> u64
pub fn inviter_account_id(&self) -> u64
Inviter root account ID (opaque ID).
Field 4: inviter_account_id
Sourcepub fn role(&self) -> EnumValue<SubaccountRole>
pub fn role(&self) -> EnumValue<SubaccountRole>
Requested role for the grantee.
Field 5: role
Sourcepub fn status(&self) -> EnumValue<SubaccountInviteStatus>
pub fn status(&self) -> EnumValue<SubaccountInviteStatus>
Current invitation status.
Field 6: status
Sourcepub fn created_at(&self) -> &MessageFieldView<TimestampView<'_>>
pub fn created_at(&self) -> &MessageFieldView<TimestampView<'_>>
Time when the invitation was created.
Field 7: created_at
Sourcepub fn responded_at(&self) -> &MessageFieldView<TimestampView<'_>>
pub fn responded_at(&self) -> &MessageFieldView<TimestampView<'_>>
Time when the invitation was accepted, declined, or cancelled. Empty while pending.
Field 8: responded_at
Sourcepub fn grantee_username(&self) -> &str
pub fn grantee_username(&self) -> &str
Optional usernames for better UX in invite lists.
Field 9: grantee_username
Sourcepub fn inviter_username(&self) -> &str
pub fn inviter_username(&self) -> &str
Username of the account that sent the invitation, when available.
Field 10: inviter_username
Sourcepub fn subaccount_label(&self) -> &str
pub fn subaccount_label(&self) -> &str
Optional label for the target sub-account, for display in invite lists.
Field 11: subaccount_label
Sourcepub fn inviter_root_smart_account_address(&self) -> &str
pub fn inviter_root_smart_account_address(&self) -> &str
Inviter (root account) primary Smart Account address, when available. Useful for displaying a stable identity when no username is set.
Field 12: inviter_root_smart_account_address
Sourcepub fn grantee_root_smart_account_address(&self) -> &str
pub fn grantee_root_smart_account_address(&self) -> &str
Grantee (root account) primary Smart Account address, when available. Useful for displaying a stable identity when no username is set.
Field 13: grantee_root_smart_account_address
Sourcepub fn require_member_mfa(&self) -> bool
pub fn require_member_mfa(&self) -> bool
Current delegated-member MFA requirement on the target sub-account. If true, accepting the invite requires MFA enrollment and fresh step-up.
Field 14: require_member_mfa
Trait Implementations§
Source§impl AsRef<OwnedView<SubaccountInviteView<'static>>> for SubaccountInviteOwnedView
impl AsRef<OwnedView<SubaccountInviteView<'static>>> for SubaccountInviteOwnedView
Source§fn as_ref(&self) -> &OwnedView<SubaccountInviteView<'static>>
fn as_ref(&self) -> &OwnedView<SubaccountInviteView<'static>>
Source§impl Clone for SubaccountInviteOwnedView
impl Clone for SubaccountInviteOwnedView
Source§fn clone(&self) -> SubaccountInviteOwnedView
fn clone(&self) -> SubaccountInviteOwnedView
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more