#[non_exhaustive]pub enum OptionalPackage {
Agents,
Skills,
}Expand description
A standard-library package that exists only when the embedder provides it.
Each one is backed by a provider trait the harness implements. An embedder that does not enable a package gets none of it: the package cannot be imported, discovery and the capability catalog do not list it, and its host functions are not installed.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Implementations§
Source§impl OptionalPackage
impl OptionalPackage
pub const ALL: &'static [OptionalPackage]
pub const fn module_name(self) -> &'static str
pub fn from_module_name(name: &str) -> Option<Self>
Trait Implementations§
Source§impl Clone for OptionalPackage
impl Clone for OptionalPackage
impl Copy for OptionalPackage
Source§impl Debug for OptionalPackage
impl Debug for OptionalPackage
impl Eq for OptionalPackage
Source§impl Hash for OptionalPackage
impl Hash for OptionalPackage
Source§impl Ord for OptionalPackage
impl Ord for OptionalPackage
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more
Source§impl PartialEq for OptionalPackage
impl PartialEq for OptionalPackage
Source§impl PartialOrd for OptionalPackage
impl PartialOrd for OptionalPackage
impl StructuralPartialEq for OptionalPackage
Auto Trait Implementations§
impl Freeze for OptionalPackage
impl RefUnwindSafe for OptionalPackage
impl Send for OptionalPackage
impl Sync for OptionalPackage
impl Unpin for OptionalPackage
impl UnsafeUnpin for OptionalPackage
impl UnwindSafe for OptionalPackage
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.