1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
/// Module implementations for PocketOption client
///
/// This module provides specialized handlers for different aspects of the
/// PocketOption trading platform:
///
/// # Modules
///
/// ## keep_alive
/// Contains modules for maintaining the WebSocket connection alive:
/// - `InitModule`: Handles initial authentication and setup
/// - `KeepAliveModule`: Sends periodic ping messages to prevent disconnection
///
/// ## balance
/// Manages account balance tracking and updates from the server.
///
/// ## server_time
/// Lightweight module for synchronizing local time with server time.
/// Automatically processes incoming price data to maintain accurate time sync.
///
/// ## subscriptions
/// Full-featured subscription management system:
/// - Symbol subscription/unsubscription
/// - Multiple aggregation strategies (Direct, Duration, Chunk)
/// - Real-time candle generation and emission
/// - Subscription statistics tracking
/// - Handles PocketOption's 4-subscription limit
///
/// # Architecture
///
/// Modules are designed using two patterns:
///
/// ## LightweightModule
/// For simple background processing without command-response mechanisms.
/// Examples: server_time, keep_alive
///
/// ## ApiModule
/// For full-featured modules with command-response patterns and public APIs.
/// Examples: subscriptions
///
/// Both patterns allow for clean separation of concerns and easy testing.
// pub use subscriptions::{
// CandleConfig, MAX_SUBSCRIPTIONS, SubscriptionCommand, SubscriptionHandle, SubscriptionModule,
// SubscriptionResponse,
// };