#[non_exhaustive]pub struct PromoteAction {
pub data_store: String,
pub search_link_promotion: Option<SearchLinkPromotion>,
/* private fields */
}Available on crate feature
control-service only.Expand description
Promote certain links based on some trigger queries.
Example: Promote shoe store link when searching for shoe keyword.
The link can be outside of associated data store.
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.data_store: StringRequired. Data store with which this promotion is attached to.
search_link_promotion: Option<SearchLinkPromotion>Required. Promotion attached to this action.
Implementations§
Source§impl PromoteAction
impl PromoteAction
pub fn new() -> Self
Sourcepub fn set_data_store<T: Into<String>>(self, v: T) -> Self
pub fn set_data_store<T: Into<String>>(self, v: T) -> Self
Sourcepub fn set_search_link_promotion<T>(self, v: T) -> Selfwhere
T: Into<SearchLinkPromotion>,
pub fn set_search_link_promotion<T>(self, v: T) -> Selfwhere
T: Into<SearchLinkPromotion>,
Sets the value of search_link_promotion.
§Example
ⓘ
use google_cloud_discoveryengine_v1::model::SearchLinkPromotion;
let x = PromoteAction::new().set_search_link_promotion(SearchLinkPromotion::default()/* use setters */);Sourcepub fn set_or_clear_search_link_promotion<T>(self, v: Option<T>) -> Selfwhere
T: Into<SearchLinkPromotion>,
pub fn set_or_clear_search_link_promotion<T>(self, v: Option<T>) -> Selfwhere
T: Into<SearchLinkPromotion>,
Sets or clears the value of search_link_promotion.
§Example
ⓘ
use google_cloud_discoveryengine_v1::model::SearchLinkPromotion;
let x = PromoteAction::new().set_or_clear_search_link_promotion(Some(SearchLinkPromotion::default()/* use setters */));
let x = PromoteAction::new().set_or_clear_search_link_promotion(None::<SearchLinkPromotion>);Trait Implementations§
Source§impl Clone for PromoteAction
impl Clone for PromoteAction
Source§fn clone(&self) -> PromoteAction
fn clone(&self) -> PromoteAction
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 PromoteAction
impl Debug for PromoteAction
Source§impl Default for PromoteAction
impl Default for PromoteAction
Source§fn default() -> PromoteAction
fn default() -> PromoteAction
Returns the “default value” for a type. Read more
Source§impl Message for PromoteAction
impl Message for PromoteAction
Source§impl PartialEq for PromoteAction
impl PartialEq for PromoteAction
impl StructuralPartialEq for PromoteAction
Auto Trait Implementations§
impl Freeze for PromoteAction
impl RefUnwindSafe for PromoteAction
impl Send for PromoteAction
impl Sync for PromoteAction
impl Unpin for PromoteAction
impl UnwindSafe for PromoteAction
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