Passed
Push — master ( fbd7eb...8e7304 )
by Vladislav
12:37 queued 10:39
created

PublicTradeChannel   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 9
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 2
dl 0
loc 9
rs 10
c 1
b 0
f 0
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A getResponseClassname() 0 3 1
1
<?php
2
namespace Carpenstar\ByBitAPI\WebSockets\Channels\Spot\PublicChannels\PublicTrade;
3
4
use Carpenstar\ByBitAPI\WebSockets\Channels\Spot\PublicChannels\PublicTrade\Entities\PublicTradeAbstract;
5
use Carpenstar\ByBitAPI\WebSockets\Objects\WebSockets\WebSocketsSpotPublicChannel;
6
7
/**
8
 * https://bybit-exchange.github.io/docs/spot/ws-public/public-trade
9
 *
10
 * Topic: trade.{symbol}
11
 *
12
 * This topic pushes raw trade information; each trade has a unique buyer and seller.
13
 * Variable "v" acts as a tradeId. This variable is shared across different symbols; however, each ID is unique.
14
 * For example, suppose in the last 5 seconds 3 trades happened in ETHUSDT, BTCUSDT, and BHTBTC.
15
 * Their tradeId (which is "v") will be consecutive: 112, 113, 114.
16
 */
17
class PublicTradeChannel extends WebSocketsSpotPublicChannel
18
{
19
20
    /**
21
     * @return string
22
     */
23
    public function getResponseClassname(): string
24
    {
25
        return PublicTradeAbstract::class;
26
    }
27
28
}