class LevelDependency
Defined at line 288 of file fidling/gen/sdk/fidl/fuchsia.power.broker/fuchsia.power.broker/cpp/fidl/fuchsia.power.broker/cpp/wire_types.h
Describes a dependency from one power element's level on another power
element's level.
For example if element `PowerElement_A` has a level `PowerLevel_A3` which
depends on an element `PowerElement_B` being at `PowerLevel_B2` then we would
fill out the struct to convey the meaning:
- `dependent_level` = `PowerLevel_A3`
- `requires_token` = `PowerElement_B`
- `requires_level_by_preference` = `[PowerLevel_B2]`
(Note the values above are only *symbolic*, eg. `dependent_level` requires
an integer value, not a string.)
The dependent Element's identity is not specified in this struct and must
be specified as a separate argument in a request or be inferred, perhaps
because a channel is scoped to the dependent element.
Public Methods
bool IsEmpty ()
Returns whether no field is set.
bool HasUnknownData ()
Returns whether the table references unknown fields.
void LevelDependency ()
Defined at line 290 of file fidling/gen/sdk/fidl/fuchsia.power.broker/fuchsia.power.broker/cpp/fidl/fuchsia.power.broker/cpp/wire_types.h
void LevelDependency (const LevelDependency & other)
Defined at line 291 of file fidling/gen/sdk/fidl/fuchsia.power.broker/fuchsia.power.broker/cpp/fidl/fuchsia.power.broker/cpp/wire_types.h
void _CloseHandles ()
::fidl::WireTableBuilder< ::fuchsia_power_broker::wire::LevelDependency> Builder (::fidl::AnyArena & arena)
Return a builder that by defaults allocates of an arena.
::fidl::WireTableExternalBuilder< ::fuchsia_power_broker::wire::LevelDependency> ExternalBuilder (::fidl::ObjectView< ::fidl::WireTableFrame< ::fuchsia_power_broker::wire::LevelDependency>> frame)
Return a builder that relies on explicitly allocating |fidl::ObjectView|s.
uint8_t & dependent_level ()
The power element level that this `LevelDependency` struct declaration
supports. This is level that has a dependency on
`requires_level_by_preference`.
bool has_dependent_level ()
bool has_requires_level_by_preference ()
LevelDependency & operator= (const LevelDependency & other)
Defined at line 292 of file fidling/gen/sdk/fidl/fuchsia.power.broker/fuchsia.power.broker/cpp/fidl/fuchsia.power.broker/cpp/wire_types.h
void LevelDependency (LevelDependency && other)
Defined at line 293 of file fidling/gen/sdk/fidl/fuchsia.power.broker/fuchsia.power.broker/cpp/fidl/fuchsia.power.broker/cpp/wire_types.h
LevelDependency & operator= (LevelDependency && other)
Defined at line 294 of file fidling/gen/sdk/fidl/fuchsia.power.broker/fuchsia.power.broker/cpp/fidl/fuchsia.power.broker/cpp/wire_types.h
::zx::event & requires_token ()
Must supply a token registered via the RegisterDependencyToken call of
the required element's ElementControl protocol.
bool has_requires_token ()
::fidl::VectorView<uint8_t> & requires_level_by_preference ()
A list of levels in decreasing preferential order that power broker
should attempt to make required for this dependency to be satisfied.
The first level in list that is a valid level will become the required
level.
Platform clients can use this list to keep backwards compatibility with
dependencies by providing multiple levels that the dependency may have
implemented in older API levels.
bool & remove_with_required_element ()
If true, this dependency will be automatically removed if/when the
required element is removed.
bool has_remove_with_required_element ()
LevelDependency & set_dependent_level (uint8_t elem)
LevelDependency & clear_dependent_level ()
LevelDependency & set_requires_token (::zx::event elem)
LevelDependency & clear_requires_token ()
LevelDependency & set_requires_level_by_preference (::fidl::ObjectView< ::fidl::VectorView<uint8_t>> elem)
LevelDependency & set_requires_level_by_preference (std::nullptr_t )
LevelDependency & clear_requires_level_by_preference ()
LevelDependency & set_remove_with_required_element (bool elem)
LevelDependency & clear_remove_with_required_element ()
void LevelDependency (::fidl::AnyArena & allocator)
void LevelDependency (::fidl::ObjectView< ::fidl::WireTableFrame< ::fuchsia_power_broker::wire::LevelDependency>> && frame)
This constructor allows a user controlled allocation (not using a Arena).
It should only be used when performance is key.
As soon as the frame is given to the table, it must not be used directly or for another table.
void Allocate (::fidl::AnyArena & allocator)
void Init (::fidl::ObjectView< ::fidl::WireTableFrame< ::fuchsia_power_broker::wire::LevelDependency>> && frame_ptr)
void ~LevelDependency ()
Defined at line 296 of file fidling/gen/sdk/fidl/fuchsia.power.broker/fuchsia.power.broker/cpp/fidl/fuchsia.power.broker/cpp/wire_types.h
Friends
class WireTableBaseBuilder
class WireTableBaseBuilder