pub struct AlertItem {
pub id: String,
pub indicator_id: String,
pub enabled: bool,
pub frequency: i32,
pub scope: i32,
pub text: String,
pub state: Vec<i32>,
pub value_map: Value,
}Expand description
One price alert
Fields§
§id: StringAlert ID
indicator_id: StringCondition: “1”=price_rise, “2”=price_fall, “3”=pct_rise, “4”=pct_fall
enabled: boolWhether the alert is active
frequency: i32Frequency: 1=daily, 2=every_time, 3=once
scope: i32Scope
text: StringDisplay text, e.g. “价格涨到 600”
state: Vec<i32>Trigger state flags
value_map: ValueTrigger value: {"price":"500"} or {"chg":"5"}
Trait Implementations§
Source§impl<'de> Deserialize<'de> for AlertItem
impl<'de> Deserialize<'de> for AlertItem
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>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for AlertItem
impl RefUnwindSafe for AlertItem
impl Send for AlertItem
impl Sync for AlertItem
impl Unpin for AlertItem
impl UnsafeUnpin for AlertItem
impl UnwindSafe for AlertItem
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§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> 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>
Converts
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>
Converts
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