Skip to main content

Transaction

Enum Transaction 

Source
#[non_exhaustive]
pub enum Transaction {
Show 39 variants CreateTransaction(CreateTransaction), CloseTransaction(CloseTransaction), ReopenTransaction(ReopenTransaction), ClientConfigureTransaction(ClientConfigureTransaction), ClientConfigureRejectTransaction(ClientConfigureRejectTransaction), TransferFundsTransaction(TransferFundsTransaction), TransferFundsRejectTransaction(TransferFundsRejectTransaction), MarketOrderTransaction(MarketOrderTransaction), MarketOrderRejectTransaction(MarketOrderRejectTransaction), FixedPriceOrderTransaction(FixedPriceOrderTransaction), LimitOrderTransaction(LimitOrderTransaction), LimitOrderRejectTransaction(LimitOrderRejectTransaction), StopOrderTransaction(StopOrderTransaction), StopOrderRejectTransaction(StopOrderRejectTransaction), MarketIfTouchedOrderTransaction(MarketIfTouchedOrderTransaction), MarketIfTouchedOrderRejectTransaction(MarketIfTouchedOrderRejectTransaction), TakeProfitOrderTransaction(TakeProfitOrderTransaction), TakeProfitOrderRejectTransaction(TakeProfitOrderRejectTransaction), StopLossOrderTransaction(StopLossOrderTransaction), StopLossOrderRejectTransaction(StopLossOrderRejectTransaction), GuaranteedStopLossOrderTransaction(GuaranteedStopLossOrderTransaction), GuaranteedStopLossOrderRejectTransaction(GuaranteedStopLossOrderRejectTransaction), TrailingStopLossOrderTransaction(TrailingStopLossOrderTransaction), TrailingStopLossOrderRejectTransaction(TrailingStopLossOrderRejectTransaction), OrderFillTransaction(OrderFillTransaction), OrderCancelTransaction(OrderCancelTransaction), OrderCancelRejectTransaction(OrderCancelRejectTransaction), OrderClientExtensionsModifyTransaction(OrderClientExtensionsModifyTransaction), OrderClientExtensionsModifyRejectTransaction(OrderClientExtensionsModifyRejectTransaction), TradeClientExtensionsModifyTransaction(TradeClientExtensionsModifyTransaction), TradeClientExtensionsModifyRejectTransaction(TradeClientExtensionsModifyRejectTransaction), MarginCallEnterTransaction(MarginCallEnterTransaction), MarginCallExtendTransaction(MarginCallExtendTransaction), MarginCallExitTransaction(MarginCallExitTransaction), DelayedTradeClosureTransaction(DelayedTradeClosureTransaction), DailyFinancingTransaction(DailyFinancingTransaction), DividendAdjustmentTransaction(DividendAdjustmentTransaction), ResetResettablePLTransaction(ResetResettablePLTransaction), Unknown { kind: String, raw: Value, },
}
Expand description

Documented Transaction variants identified by OANDA’s type field.

Variants (Non-exhaustive)§

This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
§

CreateTransaction(CreateTransaction)

CREATE provider variant.

§

CloseTransaction(CloseTransaction)

CLOSE provider variant.

§

ReopenTransaction(ReopenTransaction)

REOPEN provider variant.

§

ClientConfigureTransaction(ClientConfigureTransaction)

CLIENT_CONFIGURE provider variant.

§

ClientConfigureRejectTransaction(ClientConfigureRejectTransaction)

CLIENT_CONFIGURE_REJECT provider variant.

§

TransferFundsTransaction(TransferFundsTransaction)

TRANSFER_FUNDS provider variant.

§

TransferFundsRejectTransaction(TransferFundsRejectTransaction)

TRANSFER_FUNDS_REJECT provider variant.

§

MarketOrderTransaction(MarketOrderTransaction)

MARKET_ORDER provider variant.

§

MarketOrderRejectTransaction(MarketOrderRejectTransaction)

MARKET_ORDER_REJECT provider variant.

§

FixedPriceOrderTransaction(FixedPriceOrderTransaction)

FIXED_PRICE_ORDER provider variant.

§

LimitOrderTransaction(LimitOrderTransaction)

LIMIT_ORDER provider variant.

§

LimitOrderRejectTransaction(LimitOrderRejectTransaction)

LIMIT_ORDER_REJECT provider variant.

§

StopOrderTransaction(StopOrderTransaction)

STOP_ORDER provider variant.

§

StopOrderRejectTransaction(StopOrderRejectTransaction)

STOP_ORDER_REJECT provider variant.

§

MarketIfTouchedOrderTransaction(MarketIfTouchedOrderTransaction)

MARKET_IF_TOUCHED_ORDER provider variant.

§

MarketIfTouchedOrderRejectTransaction(MarketIfTouchedOrderRejectTransaction)

MARKET_IF_TOUCHED_ORDER_REJECT provider variant.

§

TakeProfitOrderTransaction(TakeProfitOrderTransaction)

TAKE_PROFIT_ORDER provider variant.

§

TakeProfitOrderRejectTransaction(TakeProfitOrderRejectTransaction)

TAKE_PROFIT_ORDER_REJECT provider variant.

§

StopLossOrderTransaction(StopLossOrderTransaction)

STOP_LOSS_ORDER provider variant.

§

StopLossOrderRejectTransaction(StopLossOrderRejectTransaction)

STOP_LOSS_ORDER_REJECT provider variant.

§

GuaranteedStopLossOrderTransaction(GuaranteedStopLossOrderTransaction)

GUARANTEED_STOP_LOSS_ORDER provider variant.

§

GuaranteedStopLossOrderRejectTransaction(GuaranteedStopLossOrderRejectTransaction)

GUARANTEED_STOP_LOSS_ORDER_REJECT provider variant.

§

TrailingStopLossOrderTransaction(TrailingStopLossOrderTransaction)

TRAILING_STOP_LOSS_ORDER provider variant.

§

TrailingStopLossOrderRejectTransaction(TrailingStopLossOrderRejectTransaction)

TRAILING_STOP_LOSS_ORDER_REJECT provider variant.

§

OrderFillTransaction(OrderFillTransaction)

ORDER_FILL provider variant.

§

OrderCancelTransaction(OrderCancelTransaction)

ORDER_CANCEL provider variant.

§

OrderCancelRejectTransaction(OrderCancelRejectTransaction)

ORDER_CANCEL_REJECT provider variant.

§

OrderClientExtensionsModifyTransaction(OrderClientExtensionsModifyTransaction)

ORDER_CLIENT_EXTENSIONS_MODIFY provider variant.

§

OrderClientExtensionsModifyRejectTransaction(OrderClientExtensionsModifyRejectTransaction)

ORDER_CLIENT_EXTENSIONS_MODIFY_REJECT provider variant.

§

TradeClientExtensionsModifyTransaction(TradeClientExtensionsModifyTransaction)

TRADE_CLIENT_EXTENSIONS_MODIFY provider variant.

§

TradeClientExtensionsModifyRejectTransaction(TradeClientExtensionsModifyRejectTransaction)

TRADE_CLIENT_EXTENSIONS_MODIFY_REJECT provider variant.

§

MarginCallEnterTransaction(MarginCallEnterTransaction)

MARGIN_CALL_ENTER provider variant.

§

MarginCallExtendTransaction(MarginCallExtendTransaction)

MARGIN_CALL_EXTEND provider variant.

§

MarginCallExitTransaction(MarginCallExitTransaction)

MARGIN_CALL_EXIT provider variant.

§

DelayedTradeClosureTransaction(DelayedTradeClosureTransaction)

DELAYED_TRADE_CLOSURE provider variant.

§

DailyFinancingTransaction(DailyFinancingTransaction)

DAILY_FINANCING provider variant.

§

DividendAdjustmentTransaction(DividendAdjustmentTransaction)

DIVIDEND_ADJUSTMENT provider variant.

§

ResetResettablePLTransaction(ResetResettablePLTransaction)

RESET_RESETTABLE_PL provider variant.

§

Unknown

Future provider variant with its bounded raw value.

Fields

§kind: String

Provider discriminator.

§raw: Value

Bounded provider object.

Trait Implementations§

Source§

impl Clone for Transaction

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Transaction

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'de> Deserialize<'de> for Transaction

Source§

fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>

Deserialize this value from the given Serde deserializer. Read more
Source§

impl PartialEq for Transaction

Source§

fn eq(&self, other: &Self) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl Serialize for Transaction

Source§

fn serialize<S: Serializer>(&self, serializer: S) -> Result<S::Ok, S::Error>

Serialize this value into the given Serde serializer. Read more
Source§

impl StructuralPartialEq for Transaction

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self> ⓘ

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self> ⓘ

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> PolicyExt for T
where T: ?Sized,

Source§

fn and<P, B, E>(self, other: P) -> And<T, P>
where T: Sized + Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow only if self and other return Action::Follow. Read more
Source§

fn or<P, B, E>(self, other: P) -> Or<T, P>
where T: Sized + Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow if either self or other returns Action::Follow. Read more
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> ⓘ
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self> ⓘ

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more