Struct QuotingParams
pub struct QuotingParams {
pub layers: u32,
pub spread_min_ppm: u32,
pub spread_buffer_ppm: u32,
pub skew_factor_ppm: u32,
pub order_size_pct_ppm: u32,
pub order_expiration_seconds: u32,
pub activation_threshold_quote_quantums: Vec<u8>,
}Expand description
QuotingParams stores vault quoting parameters.
Fields§
§layers: u32The number of layers of orders a vault places. For example if
layers=2, a vault places 2 asks and 2 bids.
spread_min_ppm: u32The minimum base spread when a vault quotes around reservation price.
spread_buffer_ppm: u32The buffer amount to add to min_price_change_ppm to arrive at spread
according to formula:
spread = max(spread_min_ppm, min_price_change_ppm + spread_buffer_ppm).
skew_factor_ppm: u32The factor that determines how aggressive a vault skews its orders.
order_size_pct_ppm: u32The percentage of vault equity that each order is sized at.
order_expiration_seconds: u32The duration that a vault’s orders are valid for.
activation_threshold_quote_quantums: Vec<u8>The number of quote quantums in quote asset that a vault with no perpetual positions must have to activate, i.e. if a vault has no perpetual positions and has strictly less than this amount of quote asset, it will not activate.
Trait Implementations§
§impl Clone for QuotingParams
impl Clone for QuotingParams
§fn clone(&self) -> QuotingParams
fn clone(&self) -> QuotingParams
1.0.0§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more§impl Debug for QuotingParams
impl Debug for QuotingParams
§impl Default for QuotingParams
impl Default for QuotingParams
§fn default() -> QuotingParams
fn default() -> QuotingParams
§impl Message for QuotingParams
impl Message for QuotingParams
§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 Name for QuotingParams
impl Name for QuotingParams
§const NAME: &'static str = "QuotingParams"
const NAME: &'static str = "QuotingParams"
Message.
This name is the same as it appears in the source .proto file, e.g. FooBar.§const PACKAGE: &'static str = "dydxprotocol.vault"
const PACKAGE: &'static str = "dydxprotocol.vault"
., e.g. google.protobuf.§fn full_name() -> String
fn full_name() -> String
Message.
It’s prefixed with the package name and names of any parent messages,
e.g. google.rpc.BadRequest.FieldViolation.
By default, this is the package name followed by the message name.
Fully-qualified names must be unique within a domain of Type URLs.§impl PartialEq for QuotingParams
impl PartialEq for QuotingParams
impl StructuralPartialEq for QuotingParams
Auto Trait Implementations§
impl Freeze for QuotingParams
impl RefUnwindSafe for QuotingParams
impl Send for QuotingParams
impl Sync for QuotingParams
impl Unpin for QuotingParams
impl UnwindSafe for QuotingParams
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
clone_to_uninit)§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request§impl<L> LayerExt<L> for L
impl<L> LayerExt<L> for L
§fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
Layered].