pub struct LeaseSchema {
pub lease_token: Option<EventPair>,
pub lease_name: Option<String>,
pub dependencies: Option<Vec<LeaseDependency>>,
pub should_return_pending_lease: Option<bool>,
/* private fields */
}Expand description
Passed to Topology.Lease.
Fields§
§lease_token: Option<EventPair>The half of an eventpair to be held by the Power Broker. The other
half of the pair should be retained by the client. See LeaseToken
below for more usage details.
lease_name: Option<String>Human-readable name for logging and debug purposes.
dependencies: Option<Vec<LeaseDependency>>List of dependencies for this lease.
should_return_pending_lease: Option<bool>(Optional) By default, Topology.Lease will wait until the lease is
SATISFIED before returning. If should_return_pending_lease is true,
it will instead return as soon as the lease has been granted by Power
Broker but it may still be PENDING. Clients can listen for
LEASE_SIGNAL_SATISFIED to know when the lease has been SATISFIED.
Trait Implementations§
Source§impl Debug for LeaseSchema
impl Debug for LeaseSchema
Source§impl Decode<LeaseSchema, DefaultFuchsiaResourceDialect> for LeaseSchema
impl Decode<LeaseSchema, DefaultFuchsiaResourceDialect> for LeaseSchema
Source§impl Default for LeaseSchema
impl Default for LeaseSchema
Source§fn default() -> LeaseSchema
fn default() -> LeaseSchema
Returns the “default value” for a type. Read more
Source§impl Encode<LeaseSchema, DefaultFuchsiaResourceDialect> for &mut LeaseSchema
impl Encode<LeaseSchema, DefaultFuchsiaResourceDialect> for &mut LeaseSchema
Source§impl PartialEq for LeaseSchema
impl PartialEq for LeaseSchema
Source§impl ResourceTypeMarker for LeaseSchema
impl ResourceTypeMarker for LeaseSchema
Source§type Borrowed<'a> = &'a mut LeaseSchema
type Borrowed<'a> = &'a mut LeaseSchema
The Rust type to use for encoding. This is a particular
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>
Cheaply converts from
&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 LeaseSchema
impl TypeMarker for LeaseSchema
Source§type Owned = LeaseSchema
type Owned = LeaseSchema
The owned Rust type which this FIDL type decodes into.
Source§fn inline_align(_context: Context) -> usize
fn inline_align(_context: Context) -> usize
Returns the minimum required alignment of the inline portion of the
encoded object. It must be a (nonzero) power of two.
Source§fn inline_size(_context: Context) -> usize
fn inline_size(_context: Context) -> usize
Returns the size of the inline portion of the encoded object, including
padding for alignment. Must be a multiple of
inline_align.Source§fn encode_is_copy() -> bool
fn encode_is_copy() -> bool
Returns true if the memory layout of
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 moreSource§fn decode_is_copy() -> bool
fn decode_is_copy() -> bool
Returns true if the memory layout of
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.impl Standalone<DefaultFuchsiaResourceDialect> for LeaseSchema
impl StructuralPartialEq for LeaseSchema
Auto Trait Implementations§
impl Freeze for LeaseSchema
impl RefUnwindSafe for LeaseSchema
impl Send for LeaseSchema
impl Sync for LeaseSchema
impl Unpin for LeaseSchema
impl UnsafeUnpin for LeaseSchema
impl UnwindSafe for LeaseSchema
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