@@ -19,8 +19,8 @@ |
||
19 | 19 | * @param IntervalCollection $intervals |
20 | 20 | */ |
21 | 21 | public function __construct( |
22 | - string|Granularity $segmentGranularity, |
|
23 | - string|Granularity $queryGranularity, |
|
22 | + string | Granularity $segmentGranularity, |
|
23 | + string | Granularity $queryGranularity, |
|
24 | 24 | bool $rollup, |
25 | 25 | IntervalCollection $intervals |
26 | 26 | ) { |
@@ -21,7 +21,7 @@ |
||
21 | 21 | * @param bool $rollup |
22 | 22 | * @param IntervalCollection $intervals |
23 | 23 | */ |
24 | - public function __construct(string|Granularity $queryGranularity, bool $rollup, IntervalCollection $intervals) |
|
24 | + public function __construct(string | Granularity $queryGranularity, bool $rollup, IntervalCollection $intervals) |
|
25 | 25 | { |
26 | 26 | $this->queryGranularity = is_string($queryGranularity) ? Granularity::from(strtolower($queryGranularity)) : $queryGranularity; |
27 | 27 | $this->rollup = $rollup; |
@@ -36,7 +36,7 @@ |
||
36 | 36 | * |
37 | 37 | * @return $this |
38 | 38 | */ |
39 | - public function field(string|FlattenFieldType $flattenFieldType, string $name, string $expr = null): self |
|
39 | + public function field(string | FlattenFieldType $flattenFieldType, string $name, string $expr = null): self |
|
40 | 40 | { |
41 | 41 | $type = is_string($flattenFieldType) ? FlattenFieldType::from(strtolower($flattenFieldType)) : $flattenFieldType; |
42 | 42 |
@@ -11,7 +11,7 @@ discard block |
||
11 | 11 | * |
12 | 12 | * @var string[]|string |
13 | 13 | */ |
14 | - protected string|array $paths; |
|
14 | + protected string | array $paths; |
|
15 | 15 | |
16 | 16 | /** |
17 | 17 | * HdfsInputSource constructor. |
@@ -20,7 +20,7 @@ discard block |
||
20 | 20 | * like * are supported in these paths. Empty files located under one of the given paths |
21 | 21 | * will be skipped. |
22 | 22 | */ |
23 | - public function __construct(array|string $paths) |
|
23 | + public function __construct(array | string $paths) |
|
24 | 24 | { |
25 | 25 | $this->paths = $paths; |
26 | 26 | } |
@@ -15,7 +15,7 @@ discard block |
||
15 | 15 | /** |
16 | 16 | * @var null|string|string[] |
17 | 17 | */ |
18 | - protected string|array|null $password; |
|
18 | + protected string | array | null $password; |
|
19 | 19 | |
20 | 20 | /** |
21 | 21 | * HttpInputSource constructor. |
@@ -24,7 +24,7 @@ discard block |
||
24 | 24 | * @param string|null $username |
25 | 25 | * @param string|string[]|null $password |
26 | 26 | */ |
27 | - public function __construct(array $uris, ?string $username = null, array|string $password = null) |
|
27 | + public function __construct(array $uris, ?string $username = null, array | string $password = null) |
|
28 | 28 | { |
29 | 29 | $this->uris = $uris; |
30 | 30 | $this->username = $username; |
@@ -34,7 +34,7 @@ |
||
34 | 34 | * @return $this |
35 | 35 | * @see https://druid.apache.org/docs/latest/misc/math-expr.html |
36 | 36 | */ |
37 | - public function virtualColumn(string $expression, string $as, string|DataType $outputType = DataType::STRING): self |
|
37 | + public function virtualColumn(string $expression, string $as, string | DataType $outputType = DataType::STRING): self |
|
38 | 38 | { |
39 | 39 | $this->virtualColumns[] = new VirtualColumn($expression, $as, $outputType); |
40 | 40 |
@@ -19,7 +19,7 @@ |
||
19 | 19 | * |
20 | 20 | * @return $this |
21 | 21 | */ |
22 | - public function tuningConfig(array|TuningConfig $tuningConfig): self |
|
22 | + public function tuningConfig(array | TuningConfig $tuningConfig): self |
|
23 | 23 | { |
24 | 24 | if (!$tuningConfig instanceof TuningConfig) { |
25 | 25 | $tuningConfig = new TuningConfig($tuningConfig); |
@@ -57,7 +57,7 @@ discard block |
||
57 | 57 | public function sum( |
58 | 58 | string $metric, |
59 | 59 | string $as = '', |
60 | - string|DataType $type = DataType::LONG, |
|
60 | + string | DataType $type = DataType::LONG, |
|
61 | 61 | Closure $filterBuilder = null |
62 | 62 | ): self { |
63 | 63 | $this->aggregations[] = $this->buildFilteredAggregation( |
@@ -236,7 +236,7 @@ discard block |
||
236 | 236 | */ |
237 | 237 | public function cardinality( |
238 | 238 | string $as, |
239 | - array|Closure $dimensionsOrDimensionBuilder, |
|
239 | + array | Closure $dimensionsOrDimensionBuilder, |
|
240 | 240 | bool $byRow = false, |
241 | 241 | bool $round = false |
242 | 242 | ): self { |
@@ -354,7 +354,7 @@ discard block |
||
354 | 354 | public function min( |
355 | 355 | string $metric, |
356 | 356 | string $as = '', |
357 | - string|DataType $type = DataType::LONG, |
|
357 | + string | DataType $type = DataType::LONG, |
|
358 | 358 | Closure $filterBuilder = null |
359 | 359 | ): self { |
360 | 360 | $this->aggregations[] = $this->buildFilteredAggregation( |
@@ -424,7 +424,7 @@ discard block |
||
424 | 424 | public function max( |
425 | 425 | string $metric, |
426 | 426 | string $as = '', |
427 | - string|DataType $type = DataType::LONG, |
|
427 | + string | DataType $type = DataType::LONG, |
|
428 | 428 | Closure $filterBuilder = null |
429 | 429 | ): self { |
430 | 430 | $this->aggregations[] = $this->buildFilteredAggregation( |
@@ -499,7 +499,7 @@ discard block |
||
499 | 499 | public function any( |
500 | 500 | string $metric, |
501 | 501 | string $as = '', |
502 | - string|DataType $type = DataType::LONG, |
|
502 | + string | DataType $type = DataType::LONG, |
|
503 | 503 | int $maxStringBytes = null, |
504 | 504 | Closure $filterBuilder = null |
505 | 505 | ): self { |
@@ -609,7 +609,7 @@ discard block |
||
609 | 609 | public function first( |
610 | 610 | string $metric, |
611 | 611 | string $as = '', |
612 | - string|DataType $type = DataType::LONG, |
|
612 | + string | DataType $type = DataType::LONG, |
|
613 | 613 | Closure $filterBuilder = null |
614 | 614 | ): self { |
615 | 615 | $this->aggregations[] = $this->buildFilteredAggregation( |
@@ -706,7 +706,7 @@ discard block |
||
706 | 706 | public function last( |
707 | 707 | string $metric, |
708 | 708 | string $as = '', |
709 | - string|DataType $type = DataType::LONG, |
|
709 | + string | DataType $type = DataType::LONG, |
|
710 | 710 | Closure $filterBuilder = null |
711 | 711 | ): self { |
712 | 712 | $this->aggregations[] = $this->buildFilteredAggregation( |
@@ -66,8 +66,8 @@ discard block |
||
66 | 66 | */ |
67 | 67 | public function orderBy( |
68 | 68 | string $dimensionOrMetric, |
69 | - string|OrderByDirection $direction = OrderByDirection::ASC, |
|
70 | - string|SortingOrder $sortingOrder = SortingOrder::LEXICOGRAPHIC |
|
69 | + string | OrderByDirection $direction = OrderByDirection::ASC, |
|
70 | + string | SortingOrder $sortingOrder = SortingOrder::LEXICOGRAPHIC |
|
71 | 71 | ): self { |
72 | 72 | $order = new OrderBy($dimensionOrMetric, $direction, $sortingOrder); |
73 | 73 | |
@@ -88,7 +88,7 @@ discard block |
||
88 | 88 | * |
89 | 89 | * @return $this |
90 | 90 | */ |
91 | - public function orderByDirection(string|OrderByDirection $direction = OrderByDirection::DESC): self |
|
91 | + public function orderByDirection(string | OrderByDirection $direction = OrderByDirection::DESC): self |
|
92 | 92 | { |
93 | 93 | $this->direction = is_string($direction) ? OrderByDirection::make($direction) : $direction; |
94 | 94 |