#[repr(C)]pub struct OhlcvMsg {
pub hd: RecordHeader,
pub open: i64,
pub high: i64,
pub low: i64,
pub close: i64,
pub volume: u64,
}
Expand description
Fields§
§hd: RecordHeader
The common header.
open: i64
The open price for the bar.
high: i64
The high price for the bar.
low: i64
The low price for the bar.
close: i64
The close price for the bar.
volume: u64
The total volume traded during the aggregation period.
Implementations§
Trait Implementations§
source§impl<'de> Deserialize<'de> for OhlcvMsg
impl<'de> Deserialize<'de> for OhlcvMsg
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
source§impl<'a> From<&'a OhlcvMsg> for RecordRefEnum<'a>
impl<'a> From<&'a OhlcvMsg> for RecordRefEnum<'a>
source§impl From<OhlcvMsg> for RecordEnum
impl From<OhlcvMsg> for RecordEnum
source§impl PartialEq for OhlcvMsg
impl PartialEq for OhlcvMsg
source§impl PartialOrd for OhlcvMsg
impl PartialOrd for OhlcvMsg
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresource§impl PyClassImpl for OhlcvMsg
impl PyClassImpl for OhlcvMsg
source§const IS_BASETYPE: bool = false
const IS_BASETYPE: bool = false
#[pyclass(subclass)]
source§const IS_SUBCLASS: bool = false
const IS_SUBCLASS: bool = false
#[pyclass(extends=…)]
source§const IS_MAPPING: bool = false
const IS_MAPPING: bool = false
#[pyclass(mapping)]
source§const IS_SEQUENCE: bool = false
const IS_SEQUENCE: bool = false
#[pyclass(sequence)]
§type ThreadChecker = SendablePyClass<OhlcvMsg>
type ThreadChecker = SendablePyClass<OhlcvMsg>
This handles following two situations: Read more
§type PyClassMutability = <<PyAny as PyClassBaseType>::PyClassMutability as PyClassMutability>::MutableChild
type PyClassMutability = <<PyAny as PyClassBaseType>::PyClassMutability as PyClassMutability>::MutableChild
Immutable or mutable
§type BaseNativeType = PyAny
type BaseNativeType = PyAny
The closest native ancestor. This is
PyAny
by default, and when you declare
#[pyclass(extends=PyDict)]
, it’s PyDict
.fn items_iter() -> PyClassItemsIter
fn dict_offset() -> Option<Py_ssize_t>
fn lazy_type_object() -> &'static LazyTypeObject<Self>
fn weaklist_offset() -> Option<isize>
source§impl PyClassNewTextSignature<OhlcvMsg> for PyClassImplCollector<OhlcvMsg>
Available on crate feature python
only.
impl PyClassNewTextSignature<OhlcvMsg> for PyClassImplCollector<OhlcvMsg>
Available on crate feature
python
only.fn new_text_signature(self) -> Option<&'static str>
source§impl PyMethods<OhlcvMsg> for PyClassImplCollector<OhlcvMsg>
Available on crate feature python
only.
impl PyMethods<OhlcvMsg> for PyClassImplCollector<OhlcvMsg>
Available on crate feature
python
only.fn py_methods(self) -> &'static PyClassItems
source§impl PyTypeInfo for OhlcvMsg
impl PyTypeInfo for OhlcvMsg
§type AsRefTarget = PyCell<OhlcvMsg>
type AsRefTarget = PyCell<OhlcvMsg>
Utility type to make Py::as_ref work.
source§fn type_object_raw(py: Python<'_>) -> *mut PyTypeObject
fn type_object_raw(py: Python<'_>) -> *mut PyTypeObject
Returns the PyTypeObject instance for this type.
source§fn type_object(py: Python<'_>) -> &PyType
fn type_object(py: Python<'_>) -> &PyType
Returns the safe abstraction over the type object.
source§fn is_type_of(object: &PyAny) -> bool
fn is_type_of(object: &PyAny) -> bool
Checks if
object
is an instance of this type or a subclass of this type.source§fn is_exact_type_of(object: &PyAny) -> bool
fn is_exact_type_of(object: &PyAny) -> bool
Checks if
object
is an instance of this type.source§impl Record for OhlcvMsg
impl Record for OhlcvMsg
source§fn header(&self) -> &RecordHeader
fn header(&self) -> &RecordHeader
Returns a reference to the
RecordHeader
that comes at the beginning of all
record types.source§fn record_size(&self) -> usize
fn record_size(&self) -> usize
Returns the size of the record in bytes.
source§fn rtype(&self) -> Result<RType>
fn rtype(&self) -> Result<RType>
Tries to convert the raw record type into an enum which is useful for exhaustive
pattern matching. Read more
source§fn publisher(&self) -> Result<Publisher>
fn publisher(&self) -> Result<Publisher>
Tries to convert the raw
publisher_id
into an enum which is useful for
exhaustive pattern matching. Read moresource§fn raw_index_ts(&self) -> u64
fn raw_index_ts(&self) -> u64
Returns the raw primary timestamp for the record. Read more
source§fn index_ts(&self) -> Option<OffsetDateTime>
fn index_ts(&self) -> Option<OffsetDateTime>
Returns the primary timestamp for the record. Returns
None
if the primary
timestamp contains the sentinel value for a null timestamp. Read moresource§fn index_date(&self) -> Option<Date>
fn index_date(&self) -> Option<Date>
Returns the primary date for the record; the date component of the primary
timestamp (
index_ts()
). Returns None
if the primary timestamp contains the
sentinel value for a null timestamp.source§impl RecordMut for OhlcvMsg
impl RecordMut for OhlcvMsg
source§fn header_mut(&mut self) -> &mut RecordHeader
fn header_mut(&mut self) -> &mut RecordHeader
Returns a mutable reference to the
RecordHeader
that comes at the beginning of
all record types.impl Copy for OhlcvMsg
impl Eq for OhlcvMsg
impl StructuralPartialEq for OhlcvMsg
Auto Trait Implementations§
impl Freeze for OhlcvMsg
impl RefUnwindSafe for OhlcvMsg
impl Send for OhlcvMsg
impl Sync for OhlcvMsg
impl Unpin for OhlcvMsg
impl UnwindSafe for OhlcvMsg
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