#[non_exhaustive]pub struct ImageResponseCardBuilder { /* private fields */ }Expand description
A builder for ImageResponseCard.
Implementations§
source§impl ImageResponseCardBuilder
impl ImageResponseCardBuilder
sourcepub fn title(self, input: impl Into<String>) -> Self
pub fn title(self, input: impl Into<String>) -> Self
The title to display on the response card. The format of the title is determined by the platform displaying the response card.
This field is required.sourcepub fn set_title(self, input: Option<String>) -> Self
pub fn set_title(self, input: Option<String>) -> Self
The title to display on the response card. The format of the title is determined by the platform displaying the response card.
sourcepub fn get_title(&self) -> &Option<String>
pub fn get_title(&self) -> &Option<String>
The title to display on the response card. The format of the title is determined by the platform displaying the response card.
sourcepub fn subtitle(self, input: impl Into<String>) -> Self
pub fn subtitle(self, input: impl Into<String>) -> Self
The subtitle to display on the response card. The format of the subtitle is determined by the platform displaying the response card.
sourcepub fn set_subtitle(self, input: Option<String>) -> Self
pub fn set_subtitle(self, input: Option<String>) -> Self
The subtitle to display on the response card. The format of the subtitle is determined by the platform displaying the response card.
sourcepub fn get_subtitle(&self) -> &Option<String>
pub fn get_subtitle(&self) -> &Option<String>
The subtitle to display on the response card. The format of the subtitle is determined by the platform displaying the response card.
sourcepub fn image_url(self, input: impl Into<String>) -> Self
pub fn image_url(self, input: impl Into<String>) -> Self
The URL of an image to display on the response card. The image URL must be publicly available so that the platform displaying the response card has access to the image.
sourcepub fn set_image_url(self, input: Option<String>) -> Self
pub fn set_image_url(self, input: Option<String>) -> Self
The URL of an image to display on the response card. The image URL must be publicly available so that the platform displaying the response card has access to the image.
sourcepub fn get_image_url(&self) -> &Option<String>
pub fn get_image_url(&self) -> &Option<String>
The URL of an image to display on the response card. The image URL must be publicly available so that the platform displaying the response card has access to the image.
Appends an item to buttons.
To override the contents of this collection use set_buttons.
A list of buttons that should be displayed on the response card. The arrangement of the buttons is determined by the platform that displays the button.
A list of buttons that should be displayed on the response card. The arrangement of the buttons is determined by the platform that displays the button.
A list of buttons that should be displayed on the response card. The arrangement of the buttons is determined by the platform that displays the button.
sourcepub fn build(self) -> Result<ImageResponseCard, BuildError>
pub fn build(self) -> Result<ImageResponseCard, BuildError>
Consumes the builder and constructs a ImageResponseCard.
This method will fail if any of the following fields are not set:
Trait Implementations§
source§impl Clone for ImageResponseCardBuilder
impl Clone for ImageResponseCardBuilder
source§fn clone(&self) -> ImageResponseCardBuilder
fn clone(&self) -> ImageResponseCardBuilder
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moresource§impl Debug for ImageResponseCardBuilder
impl Debug for ImageResponseCardBuilder
source§impl Default for ImageResponseCardBuilder
impl Default for ImageResponseCardBuilder
source§fn default() -> ImageResponseCardBuilder
fn default() -> ImageResponseCardBuilder
source§impl PartialEq for ImageResponseCardBuilder
impl PartialEq for ImageResponseCardBuilder
impl StructuralPartialEq for ImageResponseCardBuilder
Auto Trait Implementations§
impl Freeze for ImageResponseCardBuilder
impl RefUnwindSafe for ImageResponseCardBuilder
impl Send for ImageResponseCardBuilder
impl Sync for ImageResponseCardBuilder
impl Unpin for ImageResponseCardBuilder
impl UnwindSafe for ImageResponseCardBuilder
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit)source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
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 moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
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