pub struct SelectMenuBuilder<'a> { /* private fields */ }Expand description
Builder for creating a Select Menu.
Implementations§
Source§impl<'a> SelectMenuBuilder<'a>
impl<'a> SelectMenuBuilder<'a>
Sourcepub fn new(custom_id: impl Into<TitanString<'a>>) -> SelectMenuBuilder<'a>
pub fn new(custom_id: impl Into<TitanString<'a>>) -> SelectMenuBuilder<'a>
Create a new SelectMenuBuilder.
Sourcepub fn option(
self,
label: impl Into<TitanString<'a>>,
value: impl Into<TitanString<'a>>,
) -> SelectMenuBuilder<'a>
pub fn option( self, label: impl Into<TitanString<'a>>, value: impl Into<TitanString<'a>>, ) -> SelectMenuBuilder<'a>
Add an option.
Sourcepub fn placeholder(
self,
placeholder: impl Into<TitanString<'a>>,
) -> SelectMenuBuilder<'a>
pub fn placeholder( self, placeholder: impl Into<TitanString<'a>>, ) -> SelectMenuBuilder<'a>
Set placeholder.
Sourcepub fn min_values(self, min: u8) -> SelectMenuBuilder<'a>
pub fn min_values(self, min: u8) -> SelectMenuBuilder<'a>
Set min values.
Sourcepub fn max_values(self, max: u8) -> SelectMenuBuilder<'a>
pub fn max_values(self, max: u8) -> SelectMenuBuilder<'a>
Set max values.
Sourcepub fn disabled(self, disabled: bool) -> SelectMenuBuilder<'a>
pub fn disabled(self, disabled: bool) -> SelectMenuBuilder<'a>
Set disabled.
Trait Implementations§
Source§impl<'a> Clone for SelectMenuBuilder<'a>
impl<'a> Clone for SelectMenuBuilder<'a>
Source§fn clone(&self) -> SelectMenuBuilder<'a>
fn clone(&self) -> SelectMenuBuilder<'a>
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<'a> Debug for SelectMenuBuilder<'a>
impl<'a> Debug for SelectMenuBuilder<'a>
Source§impl Default for SelectMenuBuilder<'_>
impl Default for SelectMenuBuilder<'_>
Source§fn default() -> SelectMenuBuilder<'_>
fn default() -> SelectMenuBuilder<'_>
Returns the “default value” for a type. Read more
Source§impl<'a> From<SelectMenuBuilder<'a>> for Component<'a>
SelectMenuBuilder automatically converts to Component
impl<'a> From<SelectMenuBuilder<'a>> for Component<'a>
SelectMenuBuilder automatically converts to Component
Source§fn from(builder: SelectMenuBuilder<'a>) -> Component<'a>
fn from(builder: SelectMenuBuilder<'a>) -> Component<'a>
Converts to this type from the input type.
Auto Trait Implementations§
impl<'a> Freeze for SelectMenuBuilder<'a>
impl<'a> RefUnwindSafe for SelectMenuBuilder<'a>
impl<'a> Send for SelectMenuBuilder<'a>
impl<'a> Sync for SelectMenuBuilder<'a>
impl<'a> Unpin for SelectMenuBuilder<'a>
impl<'a> UnwindSafe for SelectMenuBuilder<'a>
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