#[non_exhaustive]pub struct Button {
pub label: String,
pub hyperlink: String,
pub description: String,
pub new_tab: bool,
pub properties: Option<Properties>,
/* private fields */
}Expand description
Button config for a chart.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.label: String§hyperlink: String§description: String§new_tab: boolOptional. Whether to open the link in a new tab.
properties: Option<Properties>Implementations§
Source§impl Button
impl Button
Sourcepub fn set_hyperlink<T: Into<String>>(self, v: T) -> Self
pub fn set_hyperlink<T: Into<String>>(self, v: T) -> Self
Sourcepub fn set_description<T: Into<String>>(self, v: T) -> Self
pub fn set_description<T: Into<String>>(self, v: T) -> Self
Sourcepub fn set_new_tab<T: Into<bool>>(self, v: T) -> Self
pub fn set_new_tab<T: Into<bool>>(self, v: T) -> Self
Sourcepub fn set_properties<T>(self, v: T) -> Selfwhere
T: Into<Properties>,
pub fn set_properties<T>(self, v: T) -> Selfwhere
T: Into<Properties>,
Sets the value of properties.
§Example
ⓘ
use google_cloud_chronicle_v1::model::button::Properties;
let x = Button::new().set_properties(Properties::default()/* use setters */);Sourcepub fn set_or_clear_properties<T>(self, v: Option<T>) -> Selfwhere
T: Into<Properties>,
pub fn set_or_clear_properties<T>(self, v: Option<T>) -> Selfwhere
T: Into<Properties>,
Sets or clears the value of properties.
§Example
ⓘ
use google_cloud_chronicle_v1::model::button::Properties;
let x = Button::new().set_or_clear_properties(Some(Properties::default()/* use setters */));
let x = Button::new().set_or_clear_properties(None::<Properties>);Trait Implementations§
impl StructuralPartialEq for Button
Auto Trait Implementations§
impl Freeze for Button
impl RefUnwindSafe for Button
impl Send for Button
impl Sync for Button
impl Unpin for Button
impl UnsafeUnpin for Button
impl UnwindSafe for Button
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