Struct aws_sdk_personalize::types::builders::MetricAttributeBuilder
source · #[non_exhaustive]pub struct MetricAttributeBuilder { /* private fields */ }Expand description
A builder for MetricAttribute.
Implementations§
source§impl MetricAttributeBuilder
impl MetricAttributeBuilder
sourcepub fn event_type(self, input: impl Into<String>) -> Self
pub fn event_type(self, input: impl Into<String>) -> Self
The metric's event type.
This field is required.sourcepub fn set_event_type(self, input: Option<String>) -> Self
pub fn set_event_type(self, input: Option<String>) -> Self
The metric's event type.
sourcepub fn get_event_type(&self) -> &Option<String>
pub fn get_event_type(&self) -> &Option<String>
The metric's event type.
sourcepub fn metric_name(self, input: impl Into<String>) -> Self
pub fn metric_name(self, input: impl Into<String>) -> Self
The metric's name. The name helps you identify the metric in Amazon CloudWatch or Amazon S3.
This field is required.sourcepub fn set_metric_name(self, input: Option<String>) -> Self
pub fn set_metric_name(self, input: Option<String>) -> Self
The metric's name. The name helps you identify the metric in Amazon CloudWatch or Amazon S3.
sourcepub fn get_metric_name(&self) -> &Option<String>
pub fn get_metric_name(&self) -> &Option<String>
The metric's name. The name helps you identify the metric in Amazon CloudWatch or Amazon S3.
sourcepub fn expression(self, input: impl Into<String>) -> Self
pub fn expression(self, input: impl Into<String>) -> Self
The attribute's expression. Available functions are SUM() or SAMPLECOUNT(). For SUM() functions, provide the dataset type (either Interactions or Items) and column to sum as a parameter. For example SUM(Items.PRICE).
sourcepub fn set_expression(self, input: Option<String>) -> Self
pub fn set_expression(self, input: Option<String>) -> Self
The attribute's expression. Available functions are SUM() or SAMPLECOUNT(). For SUM() functions, provide the dataset type (either Interactions or Items) and column to sum as a parameter. For example SUM(Items.PRICE).
sourcepub fn get_expression(&self) -> &Option<String>
pub fn get_expression(&self) -> &Option<String>
The attribute's expression. Available functions are SUM() or SAMPLECOUNT(). For SUM() functions, provide the dataset type (either Interactions or Items) and column to sum as a parameter. For example SUM(Items.PRICE).
sourcepub fn build(self) -> Result<MetricAttribute, BuildError>
pub fn build(self) -> Result<MetricAttribute, BuildError>
Consumes the builder and constructs a MetricAttribute.
This method will fail if any of the following fields are not set:
Trait Implementations§
source§impl Clone for MetricAttributeBuilder
impl Clone for MetricAttributeBuilder
source§fn clone(&self) -> MetricAttributeBuilder
fn clone(&self) -> MetricAttributeBuilder
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moresource§impl Debug for MetricAttributeBuilder
impl Debug for MetricAttributeBuilder
source§impl Default for MetricAttributeBuilder
impl Default for MetricAttributeBuilder
source§fn default() -> MetricAttributeBuilder
fn default() -> MetricAttributeBuilder
source§impl PartialEq for MetricAttributeBuilder
impl PartialEq for MetricAttributeBuilder
source§fn eq(&self, other: &MetricAttributeBuilder) -> bool
fn eq(&self, other: &MetricAttributeBuilder) -> bool
self and other values to be equal, and is used
by ==.impl StructuralPartialEq for MetricAttributeBuilder
Auto Trait Implementations§
impl Freeze for MetricAttributeBuilder
impl RefUnwindSafe for MetricAttributeBuilder
impl Send for MetricAttributeBuilder
impl Sync for MetricAttributeBuilder
impl Unpin for MetricAttributeBuilder
impl UnwindSafe for MetricAttributeBuilder
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> 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