Struct aws_sdk_pricing::types::Filter
source · #[non_exhaustive]pub struct Filter {
pub type: FilterType,
pub field: String,
pub value: String,
}
Expand description
The constraints that you want all returned products to match.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.type: FilterType
The type of filter that you want to use.
Valid values are: TERM_MATCH
. TERM_MATCH
returns only products that match both the given filter field and the given value.
field: String
The product metadata field that you want to filter on. You can filter by just the service code to see all products for a specific service, filter by just the attribute name to see a specific attribute for multiple services, or use both a service code and an attribute name to retrieve only products that match both fields.
Valid values include: ServiceCode
, and all attribute names
For example, you can filter by the AmazonEC2
service code and the volumeType
attribute name to get the prices for only Amazon EC2 volumes.
value: String
The service code or attribute value that you want to filter by. If you're filtering by service code this is the actual service code, such as AmazonEC2
. If you're filtering by attribute name, this is the attribute value that you want the returned products to match, such as a Provisioned IOPS
volume.
Implementations§
source§impl Filter
impl Filter
sourcepub fn type(&self) -> &FilterType
pub fn type(&self) -> &FilterType
The type of filter that you want to use.
Valid values are: TERM_MATCH
. TERM_MATCH
returns only products that match both the given filter field and the given value.
sourcepub fn field(&self) -> &str
pub fn field(&self) -> &str
The product metadata field that you want to filter on. You can filter by just the service code to see all products for a specific service, filter by just the attribute name to see a specific attribute for multiple services, or use both a service code and an attribute name to retrieve only products that match both fields.
Valid values include: ServiceCode
, and all attribute names
For example, you can filter by the AmazonEC2
service code and the volumeType
attribute name to get the prices for only Amazon EC2 volumes.
sourcepub fn value(&self) -> &str
pub fn value(&self) -> &str
The service code or attribute value that you want to filter by. If you're filtering by service code this is the actual service code, such as AmazonEC2
. If you're filtering by attribute name, this is the attribute value that you want the returned products to match, such as a Provisioned IOPS
volume.
Trait Implementations§
source§impl PartialEq for Filter
impl PartialEq for Filter
impl StructuralPartialEq for Filter
Auto Trait Implementations§
impl Freeze for Filter
impl RefUnwindSafe for Filter
impl Send for Filter
impl Sync for Filter
impl Unpin for Filter
impl UnwindSafe for Filter
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