IndexPriceKline::getResponseClassnameByCondition()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 1
c 0
b 0
f 0
nc 1
nop 1
dl 0
loc 3
rs 10
1
<?php
2
3
namespace Carpenstar\ByBitAPI\Derivatives\MarketData\IndexPriceKline;
4
5
use Carpenstar\ByBitAPI\Core\Endpoints\PublicEndpoint;
6
use Carpenstar\ByBitAPI\Core\Enums\EnumHttpMethods;
7
use Carpenstar\ByBitAPI\Derivatives\MarketData\IndexPriceKline\Request\IndexPriceKlineRequest;
8
use Carpenstar\ByBitAPI\Derivatives\MarketData\IndexPriceKline\Response\IndexPriceKlineResponse;
9
10
/**
11
 * Get index price kline data
12
 * https://bybit-exchange.github.io/docs/derivatives/public/index-kline
13
 */
14
class IndexPriceKline extends PublicEndpoint
15
{
16
    public function getEndpointRequestMethod(): string
17
    {
18
        return EnumHttpMethods::GET;
19
    }
20
21
    protected function getEndpointUrl(): string
22
    {
23
        return "/derivatives/v3/public/index-price-kline";
24
    }
25
26
    protected function getRequestClassname(): string
27
    {
28
        return IndexPriceKlineRequest::class;
29
    }
30
31
    protected function getResponseClassnameByCondition(array &$apiData = null): string
32
    {
33
        return IndexPriceKlineResponse::class;
34
    }
35
}
36