Table of Contents

Namespace WhalesSecret.TradeScriptLib.API.TradingV1.ConnectionStrategy

Classes

BlockUntilReconnectedOrTimeout

Strategy that affects exchange API functions to behave in the following way.

When there is an active connection to the exchange, then all exchange API requests are processed normally.

When the exchange connection is lost and a new exchange API request is sent, NotConnectedException is thrown to the callee script task only if PreRequestTimeout elapses and a new exchange connection was not established in the allotted time. If a new connection was established before PreRequestTimeout elapsed, then the API request will be sent at that point.

FailInstantlyIfNotConnected

Connection strategy that affects exchange API functions to behave in the following way.

When there is an active connection to the exchange, then all exchange API requests are processed normally.

When the exchange connection is lost and a new exchange API request is sent, the API request fails instantly with NotConnectedException being thrown.

Interfaces

IConnectionStrategy

Connection strategy that modifies trade API functions behavior.