pub struct IndicatorParamValue {
pub type: Option<i32>,
pub int_value: Option<i64>,
pub float_value: Option<f32>,
pub string_value: Option<String>,
pub bool_value: Option<bool>,
pub color_value: Option<String>,
pub shape_value: Option<i32>,
pub line_value: Option<i32>,
}Expand description
指标参数值(类型 + 对应 value 字段)
Fields§
§type: Option<i32>值类型
int_value: Option<i64>type=INT 时使用
float_value: Option<f32>type=FLOAT 时使用
string_value: Option<String>type=STRING 时使用
bool_value: Option<bool>type=BOOL 时使用
color_value: Option<String>type=COLOR 时使用,格式为 #RRGGBBAA 或 #RRGGBB
shape_value: Option<i32>type=SHAPE 时使用
line_value: Option<i32>type=LINE 时使用
Implementations§
Source§impl IndicatorParamValue
impl IndicatorParamValue
Sourcepub fn type(&self) -> IndicatorParamValueType
pub fn type(&self) -> IndicatorParamValueType
Returns the enum value of type, or the default if the field is unset or set to an invalid enum value.
Sourcepub fn set_type(&mut self, value: IndicatorParamValueType)
pub fn set_type(&mut self, value: IndicatorParamValueType)
Sets type to the provided enum value.
Sourcepub fn int_value(&self) -> i64
pub fn int_value(&self) -> i64
Returns the value of int_value, or the default value if int_value is unset.
Sourcepub fn float_value(&self) -> f32
pub fn float_value(&self) -> f32
Returns the value of float_value, or the default value if float_value is unset.
Sourcepub fn string_value(&self) -> &str
pub fn string_value(&self) -> &str
Returns the value of string_value, or the default value if string_value is unset.
Sourcepub fn bool_value(&self) -> bool
pub fn bool_value(&self) -> bool
Returns the value of bool_value, or the default value if bool_value is unset.
Sourcepub fn color_value(&self) -> &str
pub fn color_value(&self) -> &str
Returns the value of color_value, or the default value if color_value is unset.
Sourcepub fn shape_value(&self) -> IndicatorShape
pub fn shape_value(&self) -> IndicatorShape
Returns the enum value of shape_value, or the default if the field is unset or set to an invalid enum value.
Sourcepub fn set_shape_value(&mut self, value: IndicatorShape)
pub fn set_shape_value(&mut self, value: IndicatorShape)
Sets shape_value to the provided enum value.
Sourcepub fn line_value(&self) -> IndicatorLineType
pub fn line_value(&self) -> IndicatorLineType
Returns the enum value of line_value, or the default if the field is unset or set to an invalid enum value.
Sourcepub fn set_line_value(&mut self, value: IndicatorLineType)
pub fn set_line_value(&mut self, value: IndicatorLineType)
Sets line_value to the provided enum value.
Trait Implementations§
Source§impl Clone for IndicatorParamValue
impl Clone for IndicatorParamValue
Source§fn clone(&self) -> IndicatorParamValue
fn clone(&self) -> IndicatorParamValue
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for IndicatorParamValue
impl Debug for IndicatorParamValue
Source§impl Default for IndicatorParamValue
impl Default for IndicatorParamValue
Source§impl<'de> Deserialize<'de> for IndicatorParamValuewhere
IndicatorParamValue: Default,
impl<'de> Deserialize<'de> for IndicatorParamValuewhere
IndicatorParamValue: Default,
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl Message for IndicatorParamValue
impl Message for IndicatorParamValue
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 IndicatorParamValue
impl PartialEq for IndicatorParamValue
Source§fn eq(&self, other: &IndicatorParamValue) -> bool
fn eq(&self, other: &IndicatorParamValue) -> bool
self and other values to be equal, and is used by ==.