pub enum PerpetualEventType {
Show 14 variants
Added,
FundingEvent {
rate: D64,
payment_per_unit: D256,
},
FeeScheduleUpdated(FeeSchedule),
FundingSumScalingExpUpdated(u8),
InitialMarginFractionUpdated(UD64),
LastPriceUpdated(UD64),
MaintenanceMarginFractionUpdated(UD64),
MarkPriceUpdated(UD64),
MakerFeeUpdated(UD64),
OpenInterestUpdated(UD128),
OracleConfigurationUpdated {
is_used: bool,
feed_id: B256,
},
OraclePriceUpdated(UD64),
Paused(bool),
TakerFeeUpdated(UD64),
}Expand description
Type of perpetual event with corresponding details.
Variants§
Added
Perpetual contract being added
FundingEvent
Funding event occured and rate updated.
FeeScheduleUpdated(FeeSchedule)
Fee schedule of the contract updated, taking effect on its next fill.
Emitted when the contract’s own schedule is rewritten, when it is
repointed at another schedule (FeeSchedule::key changed), and when
the exchange-wide schedule it points at is rewritten.
FundingSumScalingExpUpdated(u8)
Funding sum scaling exponent updated. The exponent e defines the
divider 10^e applied when interpreting on-chain funding sums and
per-unit funding payments for premium PnL calculations.
InitialMarginFractionUpdated(UD64)
Initial margin requirement updated.
LastPriceUpdated(UD64)
Last price updated.
MaintenanceMarginFractionUpdated(UD64)
Maintenance margin requirement updated.
MarkPriceUpdated(UD64)
Mark price updated.
MakerFeeUpdated(UD64)
Base (fee tier 0) maker fee updated.
Deprecated: only replayed from pre-v1.1.7.4 history, where fees were a
single per-contract pair. Current contracts report every fee change as
PerpetualEventType::FeeScheduleUpdated.
OpenInterestUpdated(UD128)
Open interest updated.
OracleConfigurationUpdated
Oracle configuration updated.
OraclePriceUpdated(UD64)
Oracle price updated.
Paused(bool)
Perpetual contract paused/unpaused.
TakerFeeUpdated(UD64)
Base (fee tier 0) taker fee updated.
Deprecated, see PerpetualEventType::MakerFeeUpdated.
Trait Implementations§
Source§impl Clone for PerpetualEventType
impl Clone for PerpetualEventType
Source§fn clone(&self) -> PerpetualEventType
fn clone(&self) -> PerpetualEventType
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for PerpetualEventType
Auto Trait Implementations§
impl Freeze for PerpetualEventType
impl RefUnwindSafe for PerpetualEventType
impl Send for PerpetualEventType
impl Sync for PerpetualEventType
impl Unpin for PerpetualEventType
impl UnsafeUnpin for PerpetualEventType
impl UnwindSafe for PerpetualEventType
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> 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