enum Owned {
Write {
account: String,
attributes: Attributes,
universal: Facts,
client_id: Option<ClientId>,
collection: String,
action: WriteAction,
changes: Vec<OwnedChange>,
before: Option<Value>,
after: Option<Value>,
lookups: Vec<OwnedLookup>,
},
Blob {
account: String,
attributes: Attributes,
universal: Facts,
client_id: Option<ClientId>,
mime_type: String,
sniffed: Option<String>,
size: Option<u64>,
},
Grant {
universal: Facts,
client_id: ClientId,
requested_scopes: Vec<String>,
},
Token {
account: String,
attributes: Attributes,
universal: Facts,
client_id: ClientId,
scopes: Vec<String>,
},
Create {
account: String,
attributes: Option<Attributes>,
universal: Facts,
kind: Kind,
asked: Asked,
pool: String,
zone: String,
name: Option<String>,
label: Option<String>,
},
}Expand description
A Subject copied out of the borrows it arrived in. Both directions
name every field, so a field added to Subject does not compile here
until it is copied and compared too.
Variants§
Write
Fields
§
attributes: Attributes§
action: WriteAction§
changes: Vec<OwnedChange>§
lookups: Vec<OwnedLookup>Blob
Fields
§
attributes: AttributesGrant
Token
Fields
§
attributes: AttributesCreate
Implementations§
Source§impl Owned
impl Owned
fn of(subject: &Subject<'_>) -> Self
Sourcefn view<R>(&self, f: impl FnOnce(&Subject<'_>) -> R) -> R
fn view<R>(&self, f: impl FnOnce(&Subject<'_>) -> R) -> R
The subject this was copied from, handed to f.
fn is(&self, subject: &Subject<'_>) -> bool
Sourcefn weight(&self) -> usize
fn weight(&self) -> usize
Roughly how many bytes of text and record body this owns, for
KEEP_BELOW.
The variable part only: a Subject’s fixed fields are a handful of
words each, and what separates one subject from another by orders of
magnitude is the record a write carries.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Owned
impl RefUnwindSafe for Owned
impl Send for Owned
impl Sync for Owned
impl Unpin for Owned
impl UnsafeUnpin for Owned
impl UnwindSafe for Owned
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
§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>
Converts
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>
Converts
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