pub enum AttributionUpdate {
Add(NewPrincipal),
Update(UpdatedPrincipal),
Remove(u64),
// some variants omitted
}
Expand description
Describes a change affecting attribution of resources to a single principal.
Variants§
Add(NewPrincipal)
Reports a new principal managed by the reporter.
Declaring a Principal means that the declarer/reporter is providing the resources for the Principal to run. Typically, Component Framework Runners will declare the components they run as Principals.
Update(UpdatedPrincipal)
Replaces the attribution information for a Principal.
When this is received, the client is should discard any attribution information received by this channel for the Principal, and replace it with this information.
Remove(u64)
Removes a Principal.
Declares that a Principal is no longer active on the system. All attribution information for this Principal can be removed after this message. Any remaining resources will still be attributed according to the default attribution rules.
Implementations§
Source§impl AttributionUpdate
impl AttributionUpdate
pub fn ordinal(&self) -> u64
pub fn unknown_variant_for_testing() -> Self
pub fn is_unknown(&self) -> bool
Trait Implementations§
Source§impl Debug for AttributionUpdate
impl Debug for AttributionUpdate
Source§impl Decode<AttributionUpdate, DefaultFuchsiaResourceDialect> for AttributionUpdate
impl Decode<AttributionUpdate, DefaultFuchsiaResourceDialect> for AttributionUpdate
Source§impl Encode<AttributionUpdate, DefaultFuchsiaResourceDialect> for &mut AttributionUpdate
impl Encode<AttributionUpdate, DefaultFuchsiaResourceDialect> for &mut AttributionUpdate
Source§impl PartialEq for AttributionUpdate
impl PartialEq for AttributionUpdate
Source§impl ResourceTypeMarker for AttributionUpdate
impl ResourceTypeMarker for AttributionUpdate
Source§type Borrowed<'a> = &'a mut AttributionUpdate
type Borrowed<'a> = &'a mut AttributionUpdate
Encode<Self>
type cheaply obtainable from &mut Self::Owned
. There are three cases: Read moreSource§fn take_or_borrow<'a>(
value: &'a mut <Self as TypeMarker>::Owned,
) -> Self::Borrowed<'a>
fn take_or_borrow<'a>( value: &'a mut <Self as TypeMarker>::Owned, ) -> Self::Borrowed<'a>
&mut Self::Owned
to Self::Borrowed
. For
HandleBased
types this is “take” (it returns an owned handle and
replaces value
with Handle::invalid
), and for all other types it is
“borrow” (just converts from one reference to another).Source§impl TypeMarker for AttributionUpdate
impl TypeMarker for AttributionUpdate
Source§type Owned = AttributionUpdate
type Owned = AttributionUpdate
Source§fn inline_align(_context: Context) -> usize
fn inline_align(_context: Context) -> usize
Source§fn inline_size(_context: Context) -> usize
fn inline_size(_context: Context) -> usize
inline_align
.§fn encode_is_copy() -> bool
fn encode_is_copy() -> bool
Self::Owned
matches the FIDL wire
format and encoding requires no validation. When true, we can optimize
encoding arrays and vectors of Self::Owned
to a single memcpy. Read more§fn decode_is_copy() -> bool
fn decode_is_copy() -> bool
Self::Owned
matches the FIDL wire
format and decoding requires no validation. When true, we can optimize
decoding arrays and vectors of Self::Owned
to a single memcpy.