pub struct State {
pub timestamp: i64,
pub node_info: NodeInfo,
pub pid: u32,
pub system_state: SystemState,
pub counter: Counter,
pub moment_counter: MomentCounter,
pub custom: Option<Value>,
}Fields§
§timestamp: i64时间戳,单位毫秒
node_info: NodeInfo节点信息
pid: u32§system_state: SystemState系统状态
counter: Counter计数器
moment_counter: MomentCounter瞬时计数器
custom: Option<Value>其他自定义数据
Implementations§
Source§impl State
impl State
pub fn reset_counter(&mut self)
Trait Implementations§
Source§impl<'de> Deserialize<'de> for State
impl<'de> Deserialize<'de> for State
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 State
impl RefUnwindSafe for State
impl Send for State
impl Sync for State
impl Unpin for State
impl UnsafeUnpin for State
impl UnwindSafe for State
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