1 | <?php declare(strict_types=1); |
||
15 | final class ApiSettings |
||
16 | { |
||
17 | const NAMESPACE = 'ApiClients\\Client\\WeatherUnderground\\Resource'; |
||
18 | |||
19 | const TRANSPORT_OPTIONS = [ |
||
20 | FoundationOptions::HYDRATOR_OPTIONS => [ |
||
21 | HydratorOptions::NAMESPACE => self::NAMESPACE, |
||
22 | HydratorOptions::NAMESPACE_DIR => __DIR__ . DIRECTORY_SEPARATOR . 'Resource' . DIRECTORY_SEPARATOR, |
||
23 | ], |
||
24 | FoundationOptions::TRANSPORT_OPTIONS => [ |
||
25 | TransportOptions::HOST => 'api.wunderground.com', |
||
26 | TransportOptions::MIDDLEWARE => [ |
||
27 | JsonDecodeMiddleware::class, |
||
28 | JsonEncodeMiddleware::class, |
||
29 | UserAgentMiddleware::class, |
||
30 | ], |
||
31 | TransportOptions::DEFAULT_REQUEST_OPTIONS => [ |
||
32 | UserAgentMiddleware::class => [ |
||
33 | UserAgentMiddlewareOptions::STRATEGY => UserAgentStrategies::PACKAGE_VERSION, |
||
34 | UserAgentMiddlewareOptions::PACKAGE => 'api-clients/weather-underground', |
||
35 | ], |
||
36 | ], |
||
37 | ], |
||
38 | ]; |
||
39 | |||
40 | public static function getOptions( |
||
50 | } |
||
51 |