Struct google_api_proto::google::cloud::channel::v1::ParameterDefinition
source · pub struct ParameterDefinition {
pub name: String,
pub parameter_type: i32,
pub min_value: Option<Value>,
pub max_value: Option<Value>,
pub allowed_values: Vec<Value>,
pub optional: bool,
}
Expand description
Parameter’s definition. Specifies what parameter is required to use the current Offer to purchase.
Fields§
§name: String
Name of the parameter.
parameter_type: i32
Data type of the parameter. Minimal value, Maximum value and allowed values will use specified data type here.
min_value: Option<Value>
Minimal value of the parameter, if applicable. Inclusive. For example, minimal commitment when purchasing Anthos is 0.01. Applicable to INT64 and DOUBLE parameter types.
max_value: Option<Value>
Maximum value of the parameter, if applicable. Inclusive. For example, maximum seats when purchasing Google Workspace Business Standard. Applicable to INT64 and DOUBLE parameter types.
allowed_values: Vec<Value>
If not empty, parameter values must be drawn from this list. For example, [us-west1, us-west2, …] Applicable to STRING parameter type.
optional: bool
If set to true, parameter is optional to purchase this Offer.
Implementations§
source§impl ParameterDefinition
impl ParameterDefinition
sourcepub fn parameter_type(&self) -> ParameterType
pub fn parameter_type(&self) -> ParameterType
Returns the enum value of parameter_type
, or the default if the field is set to an invalid enum value.
sourcepub fn set_parameter_type(&mut self, value: ParameterType)
pub fn set_parameter_type(&mut self, value: ParameterType)
Sets parameter_type
to the provided enum value.
Trait Implementations§
source§impl Clone for ParameterDefinition
impl Clone for ParameterDefinition
source§fn clone(&self) -> ParameterDefinition
fn clone(&self) -> ParameterDefinition
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for ParameterDefinition
impl Debug for ParameterDefinition
source§impl Default for ParameterDefinition
impl Default for ParameterDefinition
source§impl Message for ParameterDefinition
impl Message for ParameterDefinition
source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
source§fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
source§fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self
. Read moresource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self
.source§impl PartialEq for ParameterDefinition
impl PartialEq for ParameterDefinition
source§fn eq(&self, other: &ParameterDefinition) -> bool
fn eq(&self, other: &ParameterDefinition) -> bool
self
and other
values to be equal, and is used
by ==
.impl StructuralPartialEq for ParameterDefinition
Auto Trait Implementations§
impl Freeze for ParameterDefinition
impl RefUnwindSafe for ParameterDefinition
impl Send for ParameterDefinition
impl Sync for ParameterDefinition
impl Unpin for ParameterDefinition
impl UnwindSafe for ParameterDefinition
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T
in a tonic::Request