@@ -56,7 +56,7 @@ |
||
56 | 56 | } catch (Exception $exception) { |
57 | 57 | echo "Something went wrong during retrieving druid data\n"; |
58 | 58 | echo $exception->getMessage() . "\n"; |
59 | - echo $exception->getTraceAsString(). "\n"; |
|
59 | + echo $exception->getTraceAsString() . "\n"; |
|
60 | 60 | if ($exception instanceof \GuzzleHttp\Exception\ClientException) { |
61 | 61 | echo $exception->getResponse()->getBody() . "\n"; |
62 | 62 | } |
@@ -142,7 +142,7 @@ |
||
142 | 142 | * |
143 | 143 | * @throws InvalidArgumentException |
144 | 144 | */ |
145 | - public function setGranularity(string|Granularity $granularity): void |
|
145 | + public function setGranularity(string | Granularity $granularity): void |
|
146 | 146 | { |
147 | 147 | $this->granularity = is_string($granularity) ? Granularity::from(strtolower($granularity)) : $granularity; |
148 | 148 | } |
@@ -56,7 +56,7 @@ |
||
56 | 56 | DimensionInterface $dimension, |
57 | 57 | int $threshold, |
58 | 58 | string $metric, |
59 | - string|Granularity $granularity = Granularity::ALL |
|
59 | + string | Granularity $granularity = Granularity::ALL |
|
60 | 60 | ) { |
61 | 61 | $this->dataSource = $dataSource; |
62 | 62 | $this->intervals = $intervals; |
@@ -55,7 +55,7 @@ |
||
55 | 55 | public function __construct( |
56 | 56 | DataSourceInterface $dataSource, |
57 | 57 | IntervalCollection $intervals, |
58 | - string|Granularity $granularity = Granularity::ALL |
|
58 | + string | Granularity $granularity = Granularity::ALL |
|
59 | 59 | ) { |
60 | 60 | $this->dataSource = $dataSource; |
61 | 61 | $this->intervals = $intervals; |
@@ -150,7 +150,7 @@ discard block |
||
150 | 150 | * |
151 | 151 | * @param string|ScanQueryResultFormat $resultFormat |
152 | 152 | */ |
153 | - public function setResultFormat(string|ScanQueryResultFormat $resultFormat): void |
|
153 | + public function setResultFormat(string | ScanQueryResultFormat $resultFormat): void |
|
154 | 154 | { |
155 | 155 | $this->resultFormat = is_string($resultFormat) ? ScanQueryResultFormat::from(strtolower($resultFormat)) : $resultFormat; |
156 | 156 | } |
@@ -229,7 +229,7 @@ discard block |
||
229 | 229 | * |
230 | 230 | * @param string|OrderByDirection $order |
231 | 231 | */ |
232 | - public function setOrder(string|OrderByDirection $order): void |
|
232 | + public function setOrder(string | OrderByDirection $order): void |
|
233 | 233 | { |
234 | 234 | $this->order = is_string($order) ? OrderByDirection::make($order) : $order; |
235 | 235 | } |
@@ -39,7 +39,7 @@ discard block |
||
39 | 39 | |
40 | 40 | public function __construct( |
41 | 41 | DataSourceInterface $dataSource, |
42 | - string|Granularity $granularity, |
|
42 | + string | Granularity $granularity, |
|
43 | 43 | IntervalCollection $intervals, |
44 | 44 | SearchFilterInterface $searchFilter |
45 | 45 | ) { |
@@ -123,7 +123,7 @@ discard block |
||
123 | 123 | /** |
124 | 124 | * @param string|SortingOrder $sort |
125 | 125 | */ |
126 | - public function setSort(string|SortingOrder $sort): void |
|
126 | + public function setSort(string | SortingOrder $sort): void |
|
127 | 127 | { |
128 | 128 | $this->sort = is_string($sort) ? SortingOrder::from(strtolower($sort)) : $sort; |
129 | 129 | } |
@@ -23,8 +23,8 @@ |
||
23 | 23 | */ |
24 | 24 | public function __construct( |
25 | 25 | string $dimension, |
26 | - string|OrderByDirection $direction = OrderByDirection::ASC, |
|
27 | - string|SortingOrder $dimensionOrder = SortingOrder::LEXICOGRAPHIC |
|
26 | + string | OrderByDirection $direction = OrderByDirection::ASC, |
|
27 | + string | SortingOrder $dimensionOrder = SortingOrder::LEXICOGRAPHIC |
|
28 | 28 | ) { |
29 | 29 | $this->dimension = $dimension; |
30 | 30 | $this->direction = is_string($direction) ? OrderByDirection::make($direction) : $direction; |
@@ -12,12 +12,12 @@ discard block |
||
12 | 12 | /** |
13 | 13 | * @var string|array<int|string,string> |
14 | 14 | */ |
15 | - protected string|array $registeredLookupFunctionOrMap; |
|
15 | + protected string | array $registeredLookupFunctionOrMap; |
|
16 | 16 | |
17 | 17 | /** |
18 | 18 | * @var bool|string |
19 | 19 | */ |
20 | - protected string|bool $keepMissingValue; |
|
20 | + protected string | bool $keepMissingValue; |
|
21 | 21 | |
22 | 22 | protected bool $isOneToOne; |
23 | 23 | |
@@ -39,9 +39,9 @@ discard block |
||
39 | 39 | */ |
40 | 40 | public function __construct( |
41 | 41 | string $dimension, |
42 | - array|string $registeredLookupFunctionOrMap, |
|
42 | + array | string $registeredLookupFunctionOrMap, |
|
43 | 43 | string $outputName = '', |
44 | - bool|string $keepMissingValue = false, |
|
44 | + bool | string $keepMissingValue = false, |
|
45 | 45 | bool $isOneToOne = false |
46 | 46 | ) { |
47 | 47 | $this->dimension = $dimension; |
@@ -22,9 +22,9 @@ |
||
22 | 22 | * @param PostAggregationCollection $fields |
23 | 23 | * @param string|DataType $type |
24 | 24 | */ |
25 | - public function __construct(string $outputName, PostAggregationCollection $fields, string|DataType $type = DataType::LONG) |
|
25 | + public function __construct(string $outputName, PostAggregationCollection $fields, string | DataType $type = DataType::LONG) |
|
26 | 26 | { |
27 | - $type = is_string($type)? DataType::from(strtolower($type)) : $type; |
|
27 | + $type = is_string($type) ? DataType::from(strtolower($type)) : $type; |
|
28 | 28 | if (!in_array($type, [DataType::LONG, DataType::DOUBLE])) { |
29 | 29 | throw new InvalidArgumentException( |
30 | 30 | 'Supported types are "long" and "double". Value given: ' . $type->value |