@@ -152,10 +152,7 @@ public static function __set_state(array $properties): self
152152 return new self ($ properties ['rules ' ]);
153153 }
154154
155- /**
156- * @param int|DomainNameProvider|Host|string|Stringable|null $host a type that supports instantiating a Domain from.
157- */
158- public function resolve ($ host ): ResolvedDomainName
155+ public function resolve (DomainNameProvider |Host |Stringable |string |int |null $ host ): ResolvedDomainName
159156 {
160157 try {
161158 return $ this ->getCookieDomain ($ host );
@@ -166,10 +163,7 @@ public function resolve($host): ResolvedDomainName
166163 }
167164 }
168165
169- /**
170- * @param int|DomainNameProvider|Host|string|Stringable|null $host the domain value
171- */
172- public function getCookieDomain ($ host ): ResolvedDomainName
166+ public function getCookieDomain (DomainNameProvider |Host |Stringable |string |int |null $ host ): ResolvedDomainName
173167 {
174168 $ domain = $ this ->validateDomain ($ host );
175169 [$ suffixLength , $ section ] = $ this ->resolveSuffix ($ domain ->withoutRootLabel (), self ::UNKNOWN_DOMAINS );
@@ -181,10 +175,7 @@ public function getCookieDomain($host): ResolvedDomainName
181175 };
182176 }
183177
184- /**
185- * @param int|DomainNameProvider|Host|string|Stringable|null $host a type that supports instantiating a Domain from.
186- */
187- public function getICANNDomain ($ host ): ResolvedDomainName
178+ public function getICANNDomain (DomainNameProvider |Host |Stringable |string |int |null $ host ): ResolvedDomainName
188179 {
189180 $ domain = $ this ->validateDomain ($ host );
190181 [$ suffixLength , $ section ] = $ this ->resolveSuffix ($ domain , self ::ICANN_DOMAINS );
@@ -195,10 +186,7 @@ public function getICANNDomain($host): ResolvedDomainName
195186 return ResolvedDomain::fromICANN ($ domain , $ suffixLength );
196187 }
197188
198- /**
199- * @param int|DomainNameProvider|Host|string|Stringable|null $host a type that supports instantiating a Domain from.
200- */
201- public function getPrivateDomain ($ host ): ResolvedDomainName
189+ public function getPrivateDomain (DomainNameProvider |Host |Stringable |string |int |null $ host ): ResolvedDomainName
202190 {
203191 $ domain = $ this ->validateDomain ($ host );
204192 [$ suffixLength , $ section ] = $ this ->resolveSuffix ($ domain , self ::PRIVATE_DOMAINS );
@@ -215,7 +203,7 @@ public function getPrivateDomain($host): ResolvedDomainName
215203 * @throws SyntaxError If the domain is invalid
216204 * @throws UnableToResolveDomain If the domain can not be resolved
217205 */
218- private function validateDomain (int | DomainNameProvider |Host |string |Stringable |null $ domain ): DomainName
206+ private function validateDomain (DomainNameProvider |Host |Stringable | string |int |null $ domain ): DomainName
219207 {
220208 if ($ domain instanceof DomainNameProvider) {
221209 $ domain = $ domain ->domain ();
0 commit comments