Struct databento::live::Subscription
source · pub struct Subscription {
pub symbols: Symbols,
pub schema: Schema,
pub stype_in: SType,
pub start: Option<OffsetDateTime>,
/* private fields */
}
Available on crate feature
live
only.Expand description
A subscription for real-time or intraday historical data.
Fields§
§symbols: Symbols
The symbols of the instruments to subscribe to.
schema: Schema
The data record schema of data to subscribe to.
stype_in: SType
The symbology type of the symbols in symbols
.
start: Option<OffsetDateTime>
If specified, requests available data since that time (inclusive), based on
ts_event
. When None
, only real-time data is sent.
Setting this field is not supported once the session has been started with
LiveClient::start
.
Implementations§
source§impl Subscription
impl Subscription
sourcepub fn builder() -> SubscriptionBuilder<((), (), (), (), ())>
pub fn builder() -> SubscriptionBuilder<((), (), (), (), ())>
Create a builder for building Subscription
.
On the builder, call .symbols(...)
, .schema(...)
, .stype_in(...)
(optional), .start(...)
(optional), .use_snapshot(...)
(optional) to set the values of the fields.
Finally, call .build()
to create the instance of Subscription
.
Trait Implementations§
source§impl Clone for Subscription
impl Clone for Subscription
source§fn clone(&self) -> Subscription
fn clone(&self) -> Subscription
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for Subscription
impl Debug for Subscription
source§impl PartialEq for Subscription
impl PartialEq for Subscription
source§fn eq(&self, other: &Subscription) -> bool
fn eq(&self, other: &Subscription) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Eq for Subscription
impl StructuralPartialEq for Subscription
Auto Trait Implementations§
impl Freeze for Subscription
impl RefUnwindSafe for Subscription
impl Send for Subscription
impl Sync for Subscription
impl Unpin for Subscription
impl UnwindSafe for Subscription
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.