@@ -100,7 +100,7 @@ discard block |
||
| 100 | 100 | * |
| 101 | 101 | * @return $this |
| 102 | 102 | */ |
| 103 | - public function dimension(string $name, string|DataType $type = DataType::STRING): IndexTaskBuilder |
|
| 103 | + public function dimension(string $name, string | DataType $type = DataType::STRING): IndexTaskBuilder |
|
| 104 | 104 | { |
| 105 | 105 | $this->dimensions[] = [ |
| 106 | 106 | 'name' => $name, |
@@ -122,8 +122,8 @@ discard block |
||
| 122 | 122 | */ |
| 123 | 123 | public function multiValueDimension( |
| 124 | 124 | string $name, |
| 125 | - string|DataType $type = DataType::STRING, |
|
| 126 | - string|MultiValueHandling $multiValueHandling = MultiValueHandling::SORTED_ARRAY, |
|
| 125 | + string | DataType $type = DataType::STRING, |
|
| 126 | + string | MultiValueHandling $multiValueHandling = MultiValueHandling::SORTED_ARRAY, |
|
| 127 | 127 | bool $createBitmapIndex = true |
| 128 | 128 | ): IndexTaskBuilder { |
| 129 | 129 | $this->dimensions[] = [ |
@@ -184,7 +184,7 @@ discard block |
||
| 184 | 184 | * |
| 185 | 185 | * @return \Level23\Druid\Tasks\TaskInterface |
| 186 | 186 | */ |
| 187 | - protected function buildTask(array|TaskContext $context): TaskInterface |
|
| 187 | + protected function buildTask(array | TaskContext $context): TaskInterface |
|
| 188 | 188 | { |
| 189 | 189 | if (is_array($context)) { |
| 190 | 190 | $context = new TaskContext($context); |
@@ -74,7 +74,7 @@ discard block |
||
| 74 | 74 | * @return string |
| 75 | 75 | * @throws \Level23\Druid\Exceptions\QueryResponseException|\GuzzleHttp\Exception\GuzzleException |
| 76 | 76 | */ |
| 77 | - public function execute(array|TaskContext $context = []): string |
|
| 77 | + public function execute(array | TaskContext $context = []): string |
|
| 78 | 78 | { |
| 79 | 79 | $task = $this->buildTask($context); |
| 80 | 80 | |
@@ -90,7 +90,7 @@ discard block |
||
| 90 | 90 | * @throws \Level23\Druid\Exceptions\QueryResponseException |
| 91 | 91 | * @throws \JsonException |
| 92 | 92 | */ |
| 93 | - public function toJson(array|TaskContext $context = []): string |
|
| 93 | + public function toJson(array | TaskContext $context = []): string |
|
| 94 | 94 | { |
| 95 | 95 | $task = $this->buildTask($context); |
| 96 | 96 | |
@@ -107,7 +107,7 @@ discard block |
||
| 107 | 107 | * @return array<string,mixed> |
| 108 | 108 | * @throws \Level23\Druid\Exceptions\QueryResponseException |
| 109 | 109 | */ |
| 110 | - public function toArray(array|TaskContext $context = []): array |
|
| 110 | + public function toArray(array | TaskContext $context = []): array |
|
| 111 | 111 | { |
| 112 | 112 | $task = $this->buildTask($context); |
| 113 | 113 | |
@@ -135,5 +135,5 @@ discard block |
||
| 135 | 135 | * @return \Level23\Druid\Tasks\TaskInterface |
| 136 | 136 | * @throws \Level23\Druid\Exceptions\QueryResponseException |
| 137 | 137 | */ |
| 138 | - abstract protected function buildTask(array|TaskContext $context): TaskInterface; |
|
| 138 | + abstract protected function buildTask(array | TaskContext $context): TaskInterface; |
|
| 139 | 139 | } |
| 140 | 140 | \ No newline at end of file |
@@ -52,7 +52,7 @@ |
||
| 52 | 52 | public function __construct( |
| 53 | 53 | string $dataSource, |
| 54 | 54 | IntervalInterface $interval, |
| 55 | - string|Granularity $segmentGranularity = null, |
|
| 55 | + string | Granularity $segmentGranularity = null, |
|
| 56 | 56 | ?TuningConfig $tuningConfig = null, |
| 57 | 57 | ?TaskContext $context = null, |
| 58 | 58 | ?int $targetCompactionSizeBytes = null, |
@@ -45,7 +45,7 @@ |
||
| 45 | 45 | * @throws \Level23\Druid\Exceptions\QueryResponseException |
| 46 | 46 | * @throws \GuzzleHttp\Exception\GuzzleException |
| 47 | 47 | */ |
| 48 | - protected function buildTask(array|TaskContext $context): TaskInterface |
|
| 48 | + protected function buildTask(array | TaskContext $context): TaskInterface |
|
| 49 | 49 | { |
| 50 | 50 | if (is_array($context)) { |
| 51 | 51 | $context = new TaskContext($context); |
@@ -66,7 +66,7 @@ |
||
| 66 | 66 | /** |
| 67 | 67 | * @inheritDoc |
| 68 | 68 | */ |
| 69 | - protected function buildTask(array|TaskContext $context): TaskInterface |
|
| 69 | + protected function buildTask(array | TaskContext $context): TaskInterface |
|
| 70 | 70 | { |
| 71 | 71 | if ($this->interval === null) { |
| 72 | 72 | throw new InvalidArgumentException('You have to specify an interval!'); |
@@ -22,7 +22,7 @@ |
||
| 22 | 22 | * |
| 23 | 23 | * @see https://druid.apache.org/docs/latest/misc/math-expr.html |
| 24 | 24 | */ |
| 25 | - public function __construct(string $expression, string $as, string|DataType $outputType = DataType::FLOAT) |
|
| 25 | + public function __construct(string $expression, string $as, string | DataType $outputType = DataType::FLOAT) |
|
| 26 | 26 | { |
| 27 | 27 | $this->name = $as; |
| 28 | 28 | $this->expression = $expression; |
@@ -29,7 +29,7 @@ |
||
| 29 | 29 | DataSourceInterface $right, |
| 30 | 30 | string $rightPrefix, |
| 31 | 31 | string $condition, |
| 32 | - string|JoinType $joinType |
|
| 32 | + string | JoinType $joinType |
|
| 33 | 33 | ) { |
| 34 | 34 | $this->left = $left; |
| 35 | 35 | $this->right = $right; |
@@ -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; |