pub struct BotCapabilities { /* private fields */ }Expand description
Set of capabilities that a bot supports
Implementations§
Source§impl BotCapabilities
impl BotCapabilities
pub fn new() -> Self
pub fn with_capability(self, capability: BotCapability) -> Self
pub fn add_capability(&mut self, capability: BotCapability)
pub fn has_capability(&self, capability: &BotCapability) -> bool
pub fn supports_realtime(&self) -> bool
pub fn supports_attachments(&self) -> bool
pub fn supports_function_calling(&self) -> bool
pub fn iter(&self) -> impl Iterator<Item = &BotCapability>
Trait Implementations§
Source§impl Clone for BotCapabilities
impl Clone for BotCapabilities
Source§fn clone(&self) -> BotCapabilities
fn clone(&self) -> BotCapabilities
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for BotCapabilities
impl Debug for BotCapabilities
Source§impl Default for BotCapabilities
impl Default for BotCapabilities
Source§fn default() -> BotCapabilities
fn default() -> BotCapabilities
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for BotCapabilities
impl<'de> Deserialize<'de> for BotCapabilities
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for BotCapabilities
impl RefUnwindSafe for BotCapabilities
impl Send for BotCapabilities
impl Sync for BotCapabilities
impl Unpin for BotCapabilities
impl UnwindSafe for BotCapabilities
Blanket Implementations§
§impl<T> ActionTrait for T
impl<T> ActionTrait for T
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,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
§impl<T> NoneValue for Twhere
T: Default,
impl<T> NoneValue for Twhere
T: Default,
type NoneType = T
§fn null_value() -> T
fn null_value() -> T
The none-equivalent value.