pub struct CryptoBarsParams {
pub symbols: Option<String>,
pub timeframe: Option<String>,
pub start: Option<String>,
pub end: Option<String>,
pub limit: Option<u32>,
}Expand description
Parameters for crypto bars request.
Fields§
§symbols: Option<String>Comma-separated list of symbols.
timeframe: Option<String>Timeframe (e.g., “1Min”, “1Hour”, “1Day”).
start: Option<String>Start time (RFC3339).
end: Option<String>End time (RFC3339).
limit: Option<u32>Maximum number of bars.
Implementations§
Source§impl CryptoBarsParams
impl CryptoBarsParams
Sourcepub fn new(symbols: &str) -> CryptoBarsParams
pub fn new(symbols: &str) -> CryptoBarsParams
Create new parameters with symbols.
Sourcepub fn timeframe(self, timeframe: &str) -> CryptoBarsParams
pub fn timeframe(self, timeframe: &str) -> CryptoBarsParams
Set timeframe.
Sourcepub fn time_range(self, start: &str, end: &str) -> CryptoBarsParams
pub fn time_range(self, start: &str, end: &str) -> CryptoBarsParams
Set time range.
Sourcepub fn limit(self, limit: u32) -> CryptoBarsParams
pub fn limit(self, limit: u32) -> CryptoBarsParams
Set limit.
Trait Implementations§
Source§impl Clone for CryptoBarsParams
impl Clone for CryptoBarsParams
Source§fn clone(&self) -> CryptoBarsParams
fn clone(&self) -> CryptoBarsParams
Returns a duplicate 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 CryptoBarsParams
impl Debug for CryptoBarsParams
Source§impl Default for CryptoBarsParams
impl Default for CryptoBarsParams
Source§fn default() -> CryptoBarsParams
fn default() -> CryptoBarsParams
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for CryptoBarsParams
impl<'de> Deserialize<'de> for CryptoBarsParams
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<CryptoBarsParams, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<CryptoBarsParams, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for CryptoBarsParams
impl Serialize for CryptoBarsParams
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations§
impl Freeze for CryptoBarsParams
impl RefUnwindSafe for CryptoBarsParams
impl Send for CryptoBarsParams
impl Sync for CryptoBarsParams
impl Unpin for CryptoBarsParams
impl UnwindSafe for CryptoBarsParams
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