Skip to main content

ComponentCapabilities

Struct ComponentCapabilities 

Source
pub struct ComponentCapabilities {
Show 15 fields pub component: ComponentId, pub contract: Option<&'static str>, pub snapshot_schema: Option<&'static str>, pub precision: &'static [Precision], pub arithmetic: &'static [ArithmeticRequirement], pub runtimes: &'static [RuntimeSupport], pub endpoints: &'static [Endpoint], pub regimes: &'static [RegimeSupport], pub sources: &'static [SourceKind], pub options: &'static [OptionSet], pub nested: &'static [ComponentId], pub attachable_to: &'static [ComponentId], pub unsupported: &'static [Unsupported], pub limits: &'static [Limit], pub summary: Summary,
}
Expand description

Everything one component admits, refuses and limits.

Fields§

§component: ComponentId

Declaring component.

§contract: Option<&'static str>

Public numerical contract version, when the component has one.

§snapshot_schema: Option<&'static str>

Snapshot schema identity, when the component writes snapshots.

§precision: &'static [Precision]

Supported state precisions.

§arithmetic: &'static [ArithmeticRequirement]

Arithmetic properties the runtime must provide.

§runtimes: &'static [RuntimeSupport]

Standing on each runtime.

§endpoints: &'static [Endpoint]

Endpoints and their admitted boundary kinds.

§regimes: &'static [RegimeSupport]

Supported regimes per scope.

§sources: &'static [SourceKind]

Admitted local sources and sinks.

§options: &'static [OptionSet]

Options and their accepted values.

§nested: &'static [ComponentId]

Components that this component contains.

§attachable_to: &'static [ComponentId]

Components that this component attaches to.

§unsupported: &'static [Unsupported]

Capabilities the component does not support.

§limits: &'static [Limit]

Limits of the supported range.

§summary: Summary

Model description.

Implementations§

Source§

impl ComponentCapabilities

Source

pub fn endpoint(&self, id: EndpointId) -> Option<&'static Endpoint>

Returns the declared endpoint with identity id.

Source

pub fn admits(&self, id: EndpointId, kind: BoundaryKind) -> bool

Returns true when endpoint id is declared and admits kind.

Source

pub fn runtime(&self, runtime: RuntimeKind) -> Option<&'static RuntimeSupport>

Returns the declared standing on runtime.

Source

pub fn option(&self, id: &str) -> Option<&'static OptionSet>

Returns the option with id id.

Source

pub fn unsupported_by_id(&self, id: &str) -> Option<&'static Unsupported>

Returns the unsupported entry with id id.

Source

pub fn limit_by_id(&self, id: &str) -> Option<&'static Limit>

Returns the limit with id id.

Trait Implementations§

Source§

impl Clone for ComponentCapabilities

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Copy for ComponentCapabilities

Source§

impl Debug for ComponentCapabilities

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Eq for ComponentCapabilities

Source§

impl PartialEq for ComponentCapabilities

Source§

fn eq(&self, other: &Self) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl StructuralPartialEq for ComponentCapabilities

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> ArchivePointee for T

Source§

type ArchivedMetadata = ()

The archived version of the pointer metadata for this type.
Source§

fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata

Converts some archived metadata to the pointer metadata for itself.
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
where F: FnOnce(&Self) -> bool,

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
Source§

impl<T> LayoutRaw for T

Source§

fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>

Returns the layout of the type.
Source§

impl<T, N1, N2> Niching<NichedOption<T, N1>> for N2
where T: SharedNiching<N1, N2>, N1: Niching<T>, N2: Niching<T>,

Source§

unsafe fn is_niched(niched: *const NichedOption<T, N1>) -> bool

Returns whether the given value has been niched. Read more
Source§

fn resolve_niched(out: Place<NichedOption<T, N1>>)

Writes data to out indicating that a T is niched.
Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
Source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
Source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

impl<T> Pointee for T

Source§

type Metadata = ()

The metadata type for pointers and references to this type.
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.