pub struct CryptoAccountContext {
pub acc_id: u64,
pub intra_acc_id: Option<u64>,
pub broker_id: Option<u32>,
pub customer_id: Option<u64>,
pub cipher: Vec<u8>,
}Fields§
§acc_id: u64§intra_acc_id: Option<u64>§broker_id: Option<u32>§customer_id: Option<u64>§cipher: Vec<u8>Implementations§
Source§impl CryptoAccountContext
impl CryptoAccountContext
Sourcepub fn build_asset_msg_header(&self, _op: &str) -> MsgHeader
pub fn build_asset_msg_header(&self, _op: &str) -> MsgHeader
Build the odr_sys_cmn::MsgHeader used by crypto asset reads.
C++ NNProto_Trd_AccCrypto.cpp:197-215 sends
asset_pl::AccountInfoReq through M_SendProto_SetReqMsgHeader;
NNProtoCenter_Inner_Macro_Send.h:16-24 always sets cipher bytes
even when the cipher length is zero.
v1.4.110 P0-1: delegate to crate::msg_header::build_real.
_op 参数保留作 caller-side 语义标注 (test fixture / log key 可能用),
当前实现忽略 (与 v1.4.110 之前 self.req_id(op) 的 _op 行为一致).
Sourcepub fn build_crypto_msg_header(&self, _op: &str) -> CryptoMsgHeader
pub fn build_crypto_msg_header(&self, _op: &str) -> CryptoMsgHeader
Build the trade_cmn::CryptoMsgHeader used by crypto order paths.
C++ NNProto_Trd_OrderOpCrypto.cpp:40-48,94-102 sets req_id and
account_id, but only writes cipher when GetAccCipher returned a
non-empty buffer. Keep that distinction because backend crypto order
services use this lighter header rather than odr_sys_cmn::MsgHeader.
v1.4.110 P0-1: delegate to crate::msg_header::build_crypto.
pub fn require_intra_acc_id(&self, op: &str) -> Result<u64>
pub fn require_broker_id(&self, op: &str) -> Result<u32>
pub fn require_customer_id(&self, op: &str) -> Result<u64>
Trait Implementations§
Source§impl Clone for CryptoAccountContext
impl Clone for CryptoAccountContext
Source§fn clone(&self) -> CryptoAccountContext
fn clone(&self) -> CryptoAccountContext
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for CryptoAccountContext
impl Debug for CryptoAccountContext
Source§impl PartialEq for CryptoAccountContext
impl PartialEq for CryptoAccountContext
impl Eq for CryptoAccountContext
impl StructuralPartialEq for CryptoAccountContext
Auto Trait Implementations§
impl Freeze for CryptoAccountContext
impl RefUnwindSafe for CryptoAccountContext
impl Send for CryptoAccountContext
impl Sync for CryptoAccountContext
impl Unpin for CryptoAccountContext
impl UnsafeUnpin for CryptoAccountContext
impl UnwindSafe for CryptoAccountContext
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.