pub struct Operation {Show 18 fields
pub id: String,
pub parent_operation_id: String,
pub currency: String,
pub payment: Option<MoneyValue>,
pub price: Option<MoneyValue>,
pub state: i32,
pub quantity: i64,
pub quantity_rest: i64,
pub figi: String,
pub instrument_type: String,
pub date: Option<Timestamp>,
pub type: String,
pub operation_type: i32,
pub trades: Vec<OperationTrade>,
pub asset_uid: String,
pub position_uid: String,
pub instrument_uid: String,
pub child_operations: Vec<ChildOperationItem>,
}Expand description
Данные по операции.
Fields§
§id: StringИдентификатор операции.
parent_operation_id: StringИдентификатор родительской операции.
currency: StringВалюта операции.
payment: Option<MoneyValue>Сумма операции.
price: Option<MoneyValue>Цена операции за 1 инструмент. Чтобы получить стоимость лота, нужно умножить на лотность инструмента.
state: i32Статус операции.
quantity: i64Количество единиц инструмента.
quantity_rest: i64Неисполненный остаток по сделке.
figi: StringFIGI-идентификатор инструмента, связанного с операцией.
instrument_type: StringТип инструмента. Возможные значения: bond — облигация; share — акция; currency — валюта; etf — фонд; futures — фьючерс.
date: Option<Timestamp>Дата и время операции в формате часовом поясе UTC.
type: StringТекстовое описание типа операции.
operation_type: i32Тип операции.
trades: Vec<OperationTrade>Массив сделок.
asset_uid: StringИдентификатор актива
position_uid: StringУникальный идентификатор позиции.
instrument_uid: StringУникальный идентификатор инструмента.
child_operations: Vec<ChildOperationItem>Массив дочерних операций.
Implementations§
Source§impl Operation
impl Operation
Sourcepub fn state(&self) -> OperationState
pub fn state(&self) -> OperationState
Returns the enum value of state, or the default if the field is set to an invalid enum value.
Sourcepub fn set_state(&mut self, value: OperationState)
pub fn set_state(&mut self, value: OperationState)
Sets state to the provided enum value.
Sourcepub fn operation_type(&self) -> OperationType
pub fn operation_type(&self) -> OperationType
Returns the enum value of operation_type, or the default if the field is set to an invalid enum value.
Sourcepub fn set_operation_type(&mut self, value: OperationType)
pub fn set_operation_type(&mut self, value: OperationType)
Sets operation_type to the provided enum value.
Trait Implementations§
Source§impl Message for Operation
impl Message for Operation
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.impl StructuralPartialEq for Operation
Auto Trait Implementations§
impl Freeze for Operation
impl RefUnwindSafe for Operation
impl Send for Operation
impl Sync for Operation
impl Unpin for Operation
impl UnwindSafe for Operation
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,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§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