> getHeaders() {
53 | return headers;
54 | }
55 |
56 | public T getData() {
57 | return data;
58 | }
59 | }
60 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/Configuration.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client;
15 |
16 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-11-08T07:58:56.667Z")
17 | public class Configuration {
18 | private static ApiClient defaultApiClient = new ApiClient();
19 |
20 | /**
21 | * Get the default API client, which would be used when creating API
22 | * instances without providing an API client.
23 | *
24 | * @return Default API client
25 | */
26 | public static ApiClient getDefaultApiClient() {
27 | return defaultApiClient;
28 | }
29 |
30 | /**
31 | * Set the default API client, which would be used when creating API
32 | * instances without providing an API client.
33 | *
34 | * @param apiClient API client
35 | */
36 | public static void setDefaultApiClient(ApiClient apiClient) {
37 | defaultApiClient = apiClient;
38 | }
39 | }
40 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/GzipRequestInterceptor.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client;
15 |
16 | import com.squareup.okhttp.*;
17 | import okio.Buffer;
18 | import okio.BufferedSink;
19 | import okio.GzipSink;
20 | import okio.Okio;
21 |
22 | import java.io.IOException;
23 |
24 | /**
25 | * Encodes request bodies using gzip.
26 | *
27 | * Taken from https://github.com/square/okhttp/issues/350
28 | */
29 | class GzipRequestInterceptor implements Interceptor {
30 | @Override public Response intercept(Chain chain) throws IOException {
31 | Request originalRequest = chain.request();
32 | if (originalRequest.body() == null || originalRequest.header("Content-Encoding") != null) {
33 | return chain.proceed(originalRequest);
34 | }
35 |
36 | Request compressedRequest = originalRequest.newBuilder()
37 | .header("Content-Encoding", "gzip")
38 | .method(originalRequest.method(), forceContentLength(gzip(originalRequest.body())))
39 | .build();
40 | return chain.proceed(compressedRequest);
41 | }
42 |
43 | private RequestBody forceContentLength(final RequestBody requestBody) throws IOException {
44 | final Buffer buffer = new Buffer();
45 | requestBody.writeTo(buffer);
46 | return new RequestBody() {
47 | @Override
48 | public MediaType contentType() {
49 | return requestBody.contentType();
50 | }
51 |
52 | @Override
53 | public long contentLength() {
54 | return buffer.size();
55 | }
56 |
57 | @Override
58 | public void writeTo(BufferedSink sink) throws IOException {
59 | sink.write(buffer.snapshot());
60 | }
61 | };
62 | }
63 |
64 | private RequestBody gzip(final RequestBody body) {
65 | return new RequestBody() {
66 | @Override public MediaType contentType() {
67 | return body.contentType();
68 | }
69 |
70 | @Override public long contentLength() {
71 | return -1; // We don't know the compressed length in advance!
72 | }
73 |
74 | @Override public void writeTo(BufferedSink sink) throws IOException {
75 | BufferedSink gzipSink = Okio.buffer(new GzipSink(sink));
76 | body.writeTo(gzipSink);
77 | gzipSink.close();
78 | }
79 | };
80 | }
81 | }
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/Pair.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client;
15 |
16 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-11-08T07:58:56.667Z")
17 | public class Pair {
18 | private String name = "";
19 | private String value = "";
20 |
21 | public Pair (String name, String value) {
22 | setName(name);
23 | setValue(value);
24 | }
25 |
26 | private void setName(String name) {
27 | if (!isValidString(name)) return;
28 |
29 | this.name = name;
30 | }
31 |
32 | private void setValue(String value) {
33 | if (!isValidString(value)) return;
34 |
35 | this.value = value;
36 | }
37 |
38 | public String getName() {
39 | return this.name;
40 | }
41 |
42 | public String getValue() {
43 | return this.value;
44 | }
45 |
46 | private boolean isValidString(String arg) {
47 | if (arg == null) return false;
48 | if (arg.trim().isEmpty()) return false;
49 |
50 | return true;
51 | }
52 | }
53 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/ProgressRequestBody.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client;
15 |
16 | import com.squareup.okhttp.MediaType;
17 | import com.squareup.okhttp.RequestBody;
18 |
19 | import java.io.IOException;
20 |
21 | import okio.Buffer;
22 | import okio.BufferedSink;
23 | import okio.ForwardingSink;
24 | import okio.Okio;
25 | import okio.Sink;
26 |
27 | public class ProgressRequestBody extends RequestBody {
28 |
29 | public interface ProgressRequestListener {
30 | void onRequestProgress(long bytesWritten, long contentLength, boolean done);
31 | }
32 |
33 | private final RequestBody requestBody;
34 |
35 | private final ProgressRequestListener progressListener;
36 |
37 | public ProgressRequestBody(RequestBody requestBody, ProgressRequestListener progressListener) {
38 | this.requestBody = requestBody;
39 | this.progressListener = progressListener;
40 | }
41 |
42 | @Override
43 | public MediaType contentType() {
44 | return requestBody.contentType();
45 | }
46 |
47 | @Override
48 | public long contentLength() throws IOException {
49 | return requestBody.contentLength();
50 | }
51 |
52 | @Override
53 | public void writeTo(BufferedSink sink) throws IOException {
54 | BufferedSink bufferedSink = Okio.buffer(sink(sink));
55 | requestBody.writeTo(bufferedSink);
56 | bufferedSink.flush();
57 | }
58 |
59 | private Sink sink(Sink sink) {
60 | return new ForwardingSink(sink) {
61 |
62 | long bytesWritten = 0L;
63 | long contentLength = 0L;
64 |
65 | @Override
66 | public void write(Buffer source, long byteCount) throws IOException {
67 | super.write(source, byteCount);
68 | if (contentLength == 0) {
69 | contentLength = contentLength();
70 | }
71 |
72 | bytesWritten += byteCount;
73 | progressListener.onRequestProgress(bytesWritten, contentLength, bytesWritten == contentLength);
74 | }
75 | };
76 | }
77 | }
78 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/ProgressResponseBody.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client;
15 |
16 | import com.squareup.okhttp.MediaType;
17 | import com.squareup.okhttp.ResponseBody;
18 |
19 | import java.io.IOException;
20 |
21 | import okio.Buffer;
22 | import okio.BufferedSource;
23 | import okio.ForwardingSource;
24 | import okio.Okio;
25 | import okio.Source;
26 |
27 | public class ProgressResponseBody extends ResponseBody {
28 |
29 | public interface ProgressListener {
30 | void update(long bytesRead, long contentLength, boolean done);
31 | }
32 |
33 | private final ResponseBody responseBody;
34 | private final ProgressListener progressListener;
35 | private BufferedSource bufferedSource;
36 |
37 | public ProgressResponseBody(ResponseBody responseBody, ProgressListener progressListener) {
38 | this.responseBody = responseBody;
39 | this.progressListener = progressListener;
40 | }
41 |
42 | @Override
43 | public MediaType contentType() {
44 | return responseBody.contentType();
45 | }
46 |
47 | @Override
48 | public long contentLength() throws IOException {
49 | return responseBody.contentLength();
50 | }
51 |
52 | @Override
53 | public BufferedSource source() throws IOException {
54 | if (bufferedSource == null) {
55 | bufferedSource = Okio.buffer(source(responseBody.source()));
56 | }
57 | return bufferedSource;
58 | }
59 |
60 | private Source source(Source source) {
61 | return new ForwardingSource(source) {
62 | long totalBytesRead = 0L;
63 |
64 | @Override
65 | public long read(Buffer sink, long byteCount) throws IOException {
66 | long bytesRead = super.read(sink, byteCount);
67 | // read() returns the number of bytes read, or -1 if this source is exhausted.
68 | totalBytesRead += bytesRead != -1 ? bytesRead : 0;
69 | progressListener.update(totalBytesRead, responseBody.contentLength(), bytesRead == -1);
70 | return bytesRead;
71 | }
72 | };
73 | }
74 | }
75 |
76 |
77 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/StringUtil.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client;
15 |
16 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-11-08T07:58:56.667Z")
17 | public class StringUtil {
18 | /**
19 | * Check if the given array contains the given value (with case-insensitive comparison).
20 | *
21 | * @param array The array
22 | * @param value The value to search
23 | * @return true if the array contains the value
24 | */
25 | public static boolean containsIgnoreCase(String[] array, String value) {
26 | for (String str : array) {
27 | if (value == null && str == null) return true;
28 | if (value != null && value.equalsIgnoreCase(str)) return true;
29 | }
30 | return false;
31 | }
32 |
33 | /**
34 | * Join an array of strings with the given separator.
35 | *
36 | * Note: This might be replaced by utility method from commons-lang or guava someday
37 | * if one of those libraries is added as dependency.
38 | *
39 | *
40 | * @param array The array of strings
41 | * @param separator The separator
42 | * @return the resulting string
43 | */
44 | public static String join(String[] array, String separator) {
45 | int len = array.length;
46 | if (len == 0) return "";
47 |
48 | StringBuilder out = new StringBuilder();
49 | out.append(array[0]);
50 | for (int i = 1; i < len; i++) {
51 | out.append(separator).append(array[i]);
52 | }
53 | return out.toString();
54 | }
55 | }
56 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/auth/ApiKeyAuth.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.auth;
15 |
16 | import io.swagger.client.Pair;
17 |
18 | import java.util.Map;
19 | import java.util.List;
20 |
21 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-11-08T07:58:56.667Z")
22 | public class ApiKeyAuth implements Authentication {
23 | private final String location;
24 | private final String paramName;
25 |
26 | private String apiKey;
27 | private String apiKeyPrefix;
28 |
29 | public ApiKeyAuth(String location, String paramName) {
30 | this.location = location;
31 | this.paramName = paramName;
32 | }
33 |
34 | public String getLocation() {
35 | return location;
36 | }
37 |
38 | public String getParamName() {
39 | return paramName;
40 | }
41 |
42 | public String getApiKey() {
43 | return apiKey;
44 | }
45 |
46 | public void setApiKey(String apiKey) {
47 | this.apiKey = apiKey;
48 | }
49 |
50 | public String getApiKeyPrefix() {
51 | return apiKeyPrefix;
52 | }
53 |
54 | public void setApiKeyPrefix(String apiKeyPrefix) {
55 | this.apiKeyPrefix = apiKeyPrefix;
56 | }
57 |
58 | @Override
59 | public void applyToParams(List queryParams, Map headerParams) {
60 | if (apiKey == null) {
61 | return;
62 | }
63 | String value;
64 | if (apiKeyPrefix != null) {
65 | value = apiKeyPrefix + " " + apiKey;
66 | } else {
67 | value = apiKey;
68 | }
69 | if ("query".equals(location)) {
70 | queryParams.add(new Pair(paramName, value));
71 | } else if ("header".equals(location)) {
72 | headerParams.put(paramName, value);
73 | }
74 | }
75 | }
76 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/auth/Authentication.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.auth;
15 |
16 | import io.swagger.client.Pair;
17 |
18 | import java.util.Map;
19 | import java.util.List;
20 |
21 | public interface Authentication {
22 | /**
23 | * Apply authentication settings to header and query params.
24 | *
25 | * @param queryParams List of query parameters
26 | * @param headerParams Map of header parameters
27 | */
28 | void applyToParams(List queryParams, Map headerParams);
29 | }
30 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/auth/HttpBasicAuth.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.auth;
15 |
16 | import io.swagger.client.Pair;
17 |
18 | import com.squareup.okhttp.Credentials;
19 |
20 | import java.util.Map;
21 | import java.util.List;
22 |
23 | import java.io.UnsupportedEncodingException;
24 |
25 | public class HttpBasicAuth implements Authentication {
26 | private String username;
27 | private String password;
28 |
29 | public String getUsername() {
30 | return username;
31 | }
32 |
33 | public void setUsername(String username) {
34 | this.username = username;
35 | }
36 |
37 | public String getPassword() {
38 | return password;
39 | }
40 |
41 | public void setPassword(String password) {
42 | this.password = password;
43 | }
44 |
45 | @Override
46 | public void applyToParams(List queryParams, Map headerParams) {
47 | if (username == null && password == null) {
48 | return;
49 | }
50 | headerParams.put("Authorization", Credentials.basic(
51 | username == null ? "" : username,
52 | password == null ? "" : password));
53 | }
54 | }
55 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/auth/OAuth.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.auth;
15 |
16 | import io.swagger.client.Pair;
17 |
18 | import java.util.Map;
19 | import java.util.List;
20 |
21 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-11-08T07:58:56.667Z")
22 | public class OAuth implements Authentication {
23 | private String accessToken;
24 |
25 | public String getAccessToken() {
26 | return accessToken;
27 | }
28 |
29 | public void setAccessToken(String accessToken) {
30 | this.accessToken = accessToken;
31 | }
32 |
33 | @Override
34 | public void applyToParams(List queryParams, Map headerParams) {
35 | if (accessToken != null) {
36 | headerParams.put("Authorization", "Bearer " + accessToken);
37 | }
38 | }
39 | }
40 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/auth/OAuthFlow.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.auth;
15 |
16 | public enum OAuthFlow {
17 | accessCode, implicit, password, application
18 | }
19 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/model/Alerts.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.model;
15 |
16 | import java.util.Objects;
17 | import java.util.Arrays;
18 | import com.google.gson.TypeAdapter;
19 | import com.google.gson.annotations.JsonAdapter;
20 | import com.google.gson.annotations.SerializedName;
21 | import com.google.gson.stream.JsonReader;
22 | import com.google.gson.stream.JsonWriter;
23 | import io.swagger.annotations.ApiModel;
24 | import io.swagger.annotations.ApiModelProperty;
25 | import io.swagger.client.model.AlertsAlert;
26 | import java.io.IOException;
27 | import java.util.ArrayList;
28 | import java.util.List;
29 |
30 | /**
31 | * Alerts
32 | */
33 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-11-08T07:58:56.667Z")
34 | public class Alerts {
35 | @SerializedName("alert")
36 | private List alert = null;
37 |
38 | public Alerts alert(List alert) {
39 | this.alert = alert;
40 | return this;
41 | }
42 |
43 | public Alerts addAlertItem(AlertsAlert alertItem) {
44 | if (this.alert == null) {
45 | this.alert = new ArrayList();
46 | }
47 | this.alert.add(alertItem);
48 | return this;
49 | }
50 |
51 | /**
52 | * Get alert
53 | * @return alert
54 | **/
55 | @ApiModelProperty(value = "")
56 | public List getAlert() {
57 | return alert;
58 | }
59 |
60 | public void setAlert(List alert) {
61 | this.alert = alert;
62 | }
63 |
64 |
65 | @Override
66 | public boolean equals(java.lang.Object o) {
67 | if (this == o) {
68 | return true;
69 | }
70 | if (o == null || getClass() != o.getClass()) {
71 | return false;
72 | }
73 | Alerts alerts = (Alerts) o;
74 | return Objects.equals(this.alert, alerts.alert);
75 | }
76 |
77 | @Override
78 | public int hashCode() {
79 | return Objects.hash(alert);
80 | }
81 |
82 |
83 | @Override
84 | public String toString() {
85 | StringBuilder sb = new StringBuilder();
86 | sb.append("class Alerts {\n");
87 |
88 | sb.append(" alert: ").append(toIndentedString(alert)).append("\n");
89 | sb.append("}");
90 | return sb.toString();
91 | }
92 |
93 | /**
94 | * Convert the given object to string with each line indented by 4 spaces
95 | * (except the first line).
96 | */
97 | private String toIndentedString(java.lang.Object o) {
98 | if (o == null) {
99 | return "null";
100 | }
101 | return o.toString().replace("\n", "\n ");
102 | }
103 |
104 | }
105 |
106 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/model/ArrayOfSearch.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.model;
15 |
16 | import java.util.Objects;
17 | import java.util.Arrays;
18 | import io.swagger.client.model.Search;
19 | import java.util.ArrayList;
20 | import java.util.List;
21 |
22 | /**
23 | * ArrayOfSearch
24 | */
25 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-11-08T07:58:56.667Z")
26 | public class ArrayOfSearch extends ArrayList {
27 |
28 | @Override
29 | public boolean equals(java.lang.Object o) {
30 | if (this == o) {
31 | return true;
32 | }
33 | if (o == null || getClass() != o.getClass()) {
34 | return false;
35 | }
36 | return super.equals(o);
37 | }
38 |
39 | @Override
40 | public int hashCode() {
41 | return Objects.hash(super.hashCode());
42 | }
43 |
44 |
45 | @Override
46 | public String toString() {
47 | StringBuilder sb = new StringBuilder();
48 | sb.append("class ArrayOfSearch {\n");
49 | sb.append(" ").append(toIndentedString(super.toString())).append("\n");
50 | sb.append("}");
51 | return sb.toString();
52 | }
53 |
54 | /**
55 | * Convert the given object to string with each line indented by 4 spaces
56 | * (except the first line).
57 | */
58 | private String toIndentedString(java.lang.Object o) {
59 | if (o == null) {
60 | return "null";
61 | }
62 | return o.toString().replace("\n", "\n ");
63 | }
64 |
65 | }
66 |
67 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/model/Astronomy.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.model;
15 |
16 | import java.util.Objects;
17 | import java.util.Arrays;
18 | import com.google.gson.TypeAdapter;
19 | import com.google.gson.annotations.JsonAdapter;
20 | import com.google.gson.annotations.SerializedName;
21 | import com.google.gson.stream.JsonReader;
22 | import com.google.gson.stream.JsonWriter;
23 | import io.swagger.annotations.ApiModel;
24 | import io.swagger.annotations.ApiModelProperty;
25 | import io.swagger.client.model.AstronomyAstro;
26 | import java.io.IOException;
27 |
28 | /**
29 | * Astronomy
30 | */
31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-11-08T07:58:56.667Z")
32 | public class Astronomy {
33 | @SerializedName("astro")
34 | private AstronomyAstro astro = null;
35 |
36 | public Astronomy astro(AstronomyAstro astro) {
37 | this.astro = astro;
38 | return this;
39 | }
40 |
41 | /**
42 | * Get astro
43 | * @return astro
44 | **/
45 | @ApiModelProperty(value = "")
46 | public AstronomyAstro getAstro() {
47 | return astro;
48 | }
49 |
50 | public void setAstro(AstronomyAstro astro) {
51 | this.astro = astro;
52 | }
53 |
54 |
55 | @Override
56 | public boolean equals(java.lang.Object o) {
57 | if (this == o) {
58 | return true;
59 | }
60 | if (o == null || getClass() != o.getClass()) {
61 | return false;
62 | }
63 | Astronomy astronomy = (Astronomy) o;
64 | return Objects.equals(this.astro, astronomy.astro);
65 | }
66 |
67 | @Override
68 | public int hashCode() {
69 | return Objects.hash(astro);
70 | }
71 |
72 |
73 | @Override
74 | public String toString() {
75 | StringBuilder sb = new StringBuilder();
76 | sb.append("class Astronomy {\n");
77 |
78 | sb.append(" astro: ").append(toIndentedString(astro)).append("\n");
79 | sb.append("}");
80 | return sb.toString();
81 | }
82 |
83 | /**
84 | * Convert the given object to string with each line indented by 4 spaces
85 | * (except the first line).
86 | */
87 | private String toIndentedString(java.lang.Object o) {
88 | if (o == null) {
89 | return "null";
90 | }
91 | return o.toString().replace("\n", "\n ");
92 | }
93 |
94 | }
95 |
96 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/model/AstronomyAstro.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.model;
15 |
16 | import java.util.Objects;
17 | import java.util.Arrays;
18 | import com.google.gson.TypeAdapter;
19 | import com.google.gson.annotations.JsonAdapter;
20 | import com.google.gson.annotations.SerializedName;
21 | import com.google.gson.stream.JsonReader;
22 | import com.google.gson.stream.JsonWriter;
23 | import io.swagger.annotations.ApiModel;
24 | import io.swagger.annotations.ApiModelProperty;
25 | import java.io.IOException;
26 |
27 | /**
28 | * AstronomyAstro
29 | */
30 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-11-08T07:58:56.667Z")
31 | public class AstronomyAstro {
32 | @SerializedName("sunrise")
33 | private String sunrise = null;
34 |
35 | @SerializedName("sunset")
36 | private String sunset = null;
37 |
38 | @SerializedName("moonrise")
39 | private String moonrise = null;
40 |
41 | @SerializedName("moonset")
42 | private String moonset = null;
43 |
44 | @SerializedName("moon_phase")
45 | private String moonPhase = null;
46 |
47 | @SerializedName("moon_illumination")
48 | private String moonIllumination = null;
49 |
50 | public AstronomyAstro sunrise(String sunrise) {
51 | this.sunrise = sunrise;
52 | return this;
53 | }
54 |
55 | /**
56 | * Get sunrise
57 | * @return sunrise
58 | **/
59 | @ApiModelProperty(example = "05:10 AM", value = "")
60 | public String getSunrise() {
61 | return sunrise;
62 | }
63 |
64 | public void setSunrise(String sunrise) {
65 | this.sunrise = sunrise;
66 | }
67 |
68 | public AstronomyAstro sunset(String sunset) {
69 | this.sunset = sunset;
70 | return this;
71 | }
72 |
73 | /**
74 | * Get sunset
75 | * @return sunset
76 | **/
77 | @ApiModelProperty(example = "09:03 PM", value = "")
78 | public String getSunset() {
79 | return sunset;
80 | }
81 |
82 | public void setSunset(String sunset) {
83 | this.sunset = sunset;
84 | }
85 |
86 | public AstronomyAstro moonrise(String moonrise) {
87 | this.moonrise = moonrise;
88 | return this;
89 | }
90 |
91 | /**
92 | * Get moonrise
93 | * @return moonrise
94 | **/
95 | @ApiModelProperty(example = "12:29 AM", value = "")
96 | public String getMoonrise() {
97 | return moonrise;
98 | }
99 |
100 | public void setMoonrise(String moonrise) {
101 | this.moonrise = moonrise;
102 | }
103 |
104 | public AstronomyAstro moonset(String moonset) {
105 | this.moonset = moonset;
106 | return this;
107 | }
108 |
109 | /**
110 | * Get moonset
111 | * @return moonset
112 | **/
113 | @ApiModelProperty(example = "04:01 PM", value = "")
114 | public String getMoonset() {
115 | return moonset;
116 | }
117 |
118 | public void setMoonset(String moonset) {
119 | this.moonset = moonset;
120 | }
121 |
122 | public AstronomyAstro moonPhase(String moonPhase) {
123 | this.moonPhase = moonPhase;
124 | return this;
125 | }
126 |
127 | /**
128 | * Get moonPhase
129 | * @return moonPhase
130 | **/
131 | @ApiModelProperty(example = "Third Quarter", value = "")
132 | public String getMoonPhase() {
133 | return moonPhase;
134 | }
135 |
136 | public void setMoonPhase(String moonPhase) {
137 | this.moonPhase = moonPhase;
138 | }
139 |
140 | public AstronomyAstro moonIllumination(String moonIllumination) {
141 | this.moonIllumination = moonIllumination;
142 | return this;
143 | }
144 |
145 | /**
146 | * Get moonIllumination
147 | * @return moonIllumination
148 | **/
149 | @ApiModelProperty(example = "42", value = "")
150 | public String getMoonIllumination() {
151 | return moonIllumination;
152 | }
153 |
154 | public void setMoonIllumination(String moonIllumination) {
155 | this.moonIllumination = moonIllumination;
156 | }
157 |
158 |
159 | @Override
160 | public boolean equals(java.lang.Object o) {
161 | if (this == o) {
162 | return true;
163 | }
164 | if (o == null || getClass() != o.getClass()) {
165 | return false;
166 | }
167 | AstronomyAstro astronomyAstro = (AstronomyAstro) o;
168 | return Objects.equals(this.sunrise, astronomyAstro.sunrise) &&
169 | Objects.equals(this.sunset, astronomyAstro.sunset) &&
170 | Objects.equals(this.moonrise, astronomyAstro.moonrise) &&
171 | Objects.equals(this.moonset, astronomyAstro.moonset) &&
172 | Objects.equals(this.moonPhase, astronomyAstro.moonPhase) &&
173 | Objects.equals(this.moonIllumination, astronomyAstro.moonIllumination);
174 | }
175 |
176 | @Override
177 | public int hashCode() {
178 | return Objects.hash(sunrise, sunset, moonrise, moonset, moonPhase, moonIllumination);
179 | }
180 |
181 |
182 | @Override
183 | public String toString() {
184 | StringBuilder sb = new StringBuilder();
185 | sb.append("class AstronomyAstro {\n");
186 |
187 | sb.append(" sunrise: ").append(toIndentedString(sunrise)).append("\n");
188 | sb.append(" sunset: ").append(toIndentedString(sunset)).append("\n");
189 | sb.append(" moonrise: ").append(toIndentedString(moonrise)).append("\n");
190 | sb.append(" moonset: ").append(toIndentedString(moonset)).append("\n");
191 | sb.append(" moonPhase: ").append(toIndentedString(moonPhase)).append("\n");
192 | sb.append(" moonIllumination: ").append(toIndentedString(moonIllumination)).append("\n");
193 | sb.append("}");
194 | return sb.toString();
195 | }
196 |
197 | /**
198 | * Convert the given object to string with each line indented by 4 spaces
199 | * (except the first line).
200 | */
201 | private String toIndentedString(java.lang.Object o) {
202 | if (o == null) {
203 | return "null";
204 | }
205 | return o.toString().replace("\n", "\n ");
206 | }
207 |
208 | }
209 |
210 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/model/CurrentCondition.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.model;
15 |
16 | import java.util.Objects;
17 | import java.util.Arrays;
18 | import com.google.gson.TypeAdapter;
19 | import com.google.gson.annotations.JsonAdapter;
20 | import com.google.gson.annotations.SerializedName;
21 | import com.google.gson.stream.JsonReader;
22 | import com.google.gson.stream.JsonWriter;
23 | import io.swagger.annotations.ApiModel;
24 | import io.swagger.annotations.ApiModelProperty;
25 | import java.io.IOException;
26 |
27 | /**
28 | * CurrentCondition
29 | */
30 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-11-08T07:58:56.667Z")
31 | public class CurrentCondition {
32 | @SerializedName("text")
33 | private String text = null;
34 |
35 | @SerializedName("icon")
36 | private String icon = null;
37 |
38 | @SerializedName("code")
39 | private Integer code = null;
40 |
41 | public CurrentCondition text(String text) {
42 | this.text = text;
43 | return this;
44 | }
45 |
46 | /**
47 | * Get text
48 | * @return text
49 | **/
50 | @ApiModelProperty(example = "Partly cloudy", value = "")
51 | public String getText() {
52 | return text;
53 | }
54 |
55 | public void setText(String text) {
56 | this.text = text;
57 | }
58 |
59 | public CurrentCondition icon(String icon) {
60 | this.icon = icon;
61 | return this;
62 | }
63 |
64 | /**
65 | * Get icon
66 | * @return icon
67 | **/
68 | @ApiModelProperty(example = "//cdn.weatherapi.com/weather/64x64/day/116.png", value = "")
69 | public String getIcon() {
70 | return icon;
71 | }
72 |
73 | public void setIcon(String icon) {
74 | this.icon = icon;
75 | }
76 |
77 | public CurrentCondition code(Integer code) {
78 | this.code = code;
79 | return this;
80 | }
81 |
82 | /**
83 | * Get code
84 | * @return code
85 | **/
86 | @ApiModelProperty(example = "1003", value = "")
87 | public Integer getCode() {
88 | return code;
89 | }
90 |
91 | public void setCode(Integer code) {
92 | this.code = code;
93 | }
94 |
95 |
96 | @Override
97 | public boolean equals(java.lang.Object o) {
98 | if (this == o) {
99 | return true;
100 | }
101 | if (o == null || getClass() != o.getClass()) {
102 | return false;
103 | }
104 | CurrentCondition currentCondition = (CurrentCondition) o;
105 | return Objects.equals(this.text, currentCondition.text) &&
106 | Objects.equals(this.icon, currentCondition.icon) &&
107 | Objects.equals(this.code, currentCondition.code);
108 | }
109 |
110 | @Override
111 | public int hashCode() {
112 | return Objects.hash(text, icon, code);
113 | }
114 |
115 |
116 | @Override
117 | public String toString() {
118 | StringBuilder sb = new StringBuilder();
119 | sb.append("class CurrentCondition {\n");
120 |
121 | sb.append(" text: ").append(toIndentedString(text)).append("\n");
122 | sb.append(" icon: ").append(toIndentedString(icon)).append("\n");
123 | sb.append(" code: ").append(toIndentedString(code)).append("\n");
124 | sb.append("}");
125 | return sb.toString();
126 | }
127 |
128 | /**
129 | * Convert the given object to string with each line indented by 4 spaces
130 | * (except the first line).
131 | */
132 | private String toIndentedString(java.lang.Object o) {
133 | if (o == null) {
134 | return "null";
135 | }
136 | return o.toString().replace("\n", "\n ");
137 | }
138 |
139 | }
140 |
141 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/model/Error400.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.model;
15 |
16 | import java.util.Objects;
17 | import java.util.Arrays;
18 | import com.google.gson.TypeAdapter;
19 | import com.google.gson.annotations.JsonAdapter;
20 | import com.google.gson.annotations.SerializedName;
21 | import com.google.gson.stream.JsonReader;
22 | import com.google.gson.stream.JsonWriter;
23 | import io.swagger.annotations.ApiModel;
24 | import io.swagger.annotations.ApiModelProperty;
25 | import java.io.IOException;
26 |
27 | /**
28 | * Error400
29 | */
30 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-11-08T07:58:56.667Z")
31 | public class Error400 {
32 | @SerializedName("code")
33 | private Integer code = null;
34 |
35 | @SerializedName("message")
36 | private String message = null;
37 |
38 | public Error400 code(Integer code) {
39 | this.code = code;
40 | return this;
41 | }
42 |
43 | /**
44 | * Get code
45 | * @return code
46 | **/
47 | @ApiModelProperty(example = "1003", value = "")
48 | public Integer getCode() {
49 | return code;
50 | }
51 |
52 | public void setCode(Integer code) {
53 | this.code = code;
54 | }
55 |
56 | public Error400 message(String message) {
57 | this.message = message;
58 | return this;
59 | }
60 |
61 | /**
62 | * Get message
63 | * @return message
64 | **/
65 | @ApiModelProperty(example = "Parameter 'q' not provided.", value = "")
66 | public String getMessage() {
67 | return message;
68 | }
69 |
70 | public void setMessage(String message) {
71 | this.message = message;
72 | }
73 |
74 |
75 | @Override
76 | public boolean equals(java.lang.Object o) {
77 | if (this == o) {
78 | return true;
79 | }
80 | if (o == null || getClass() != o.getClass()) {
81 | return false;
82 | }
83 | Error400 error400 = (Error400) o;
84 | return Objects.equals(this.code, error400.code) &&
85 | Objects.equals(this.message, error400.message);
86 | }
87 |
88 | @Override
89 | public int hashCode() {
90 | return Objects.hash(code, message);
91 | }
92 |
93 |
94 | @Override
95 | public String toString() {
96 | StringBuilder sb = new StringBuilder();
97 | sb.append("class Error400 {\n");
98 |
99 | sb.append(" code: ").append(toIndentedString(code)).append("\n");
100 | sb.append(" message: ").append(toIndentedString(message)).append("\n");
101 | sb.append("}");
102 | return sb.toString();
103 | }
104 |
105 | /**
106 | * Convert the given object to string with each line indented by 4 spaces
107 | * (except the first line).
108 | */
109 | private String toIndentedString(java.lang.Object o) {
110 | if (o == null) {
111 | return "null";
112 | }
113 | return o.toString().replace("\n", "\n ");
114 | }
115 |
116 | }
117 |
118 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/model/Error401.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.model;
15 |
16 | import java.util.Objects;
17 | import java.util.Arrays;
18 | import com.google.gson.TypeAdapter;
19 | import com.google.gson.annotations.JsonAdapter;
20 | import com.google.gson.annotations.SerializedName;
21 | import com.google.gson.stream.JsonReader;
22 | import com.google.gson.stream.JsonWriter;
23 | import io.swagger.annotations.ApiModel;
24 | import io.swagger.annotations.ApiModelProperty;
25 | import java.io.IOException;
26 |
27 | /**
28 | * Error401
29 | */
30 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-11-08T07:58:56.667Z")
31 | public class Error401 {
32 | @SerializedName("code")
33 | private Integer code = null;
34 |
35 | @SerializedName("message")
36 | private String message = null;
37 |
38 | public Error401 code(Integer code) {
39 | this.code = code;
40 | return this;
41 | }
42 |
43 | /**
44 | * Get code
45 | * @return code
46 | **/
47 | @ApiModelProperty(example = "1002", value = "")
48 | public Integer getCode() {
49 | return code;
50 | }
51 |
52 | public void setCode(Integer code) {
53 | this.code = code;
54 | }
55 |
56 | public Error401 message(String message) {
57 | this.message = message;
58 | return this;
59 | }
60 |
61 | /**
62 | * Get message
63 | * @return message
64 | **/
65 | @ApiModelProperty(example = "API key not provided", value = "")
66 | public String getMessage() {
67 | return message;
68 | }
69 |
70 | public void setMessage(String message) {
71 | this.message = message;
72 | }
73 |
74 |
75 | @Override
76 | public boolean equals(java.lang.Object o) {
77 | if (this == o) {
78 | return true;
79 | }
80 | if (o == null || getClass() != o.getClass()) {
81 | return false;
82 | }
83 | Error401 error401 = (Error401) o;
84 | return Objects.equals(this.code, error401.code) &&
85 | Objects.equals(this.message, error401.message);
86 | }
87 |
88 | @Override
89 | public int hashCode() {
90 | return Objects.hash(code, message);
91 | }
92 |
93 |
94 | @Override
95 | public String toString() {
96 | StringBuilder sb = new StringBuilder();
97 | sb.append("class Error401 {\n");
98 |
99 | sb.append(" code: ").append(toIndentedString(code)).append("\n");
100 | sb.append(" message: ").append(toIndentedString(message)).append("\n");
101 | sb.append("}");
102 | return sb.toString();
103 | }
104 |
105 | /**
106 | * Convert the given object to string with each line indented by 4 spaces
107 | * (except the first line).
108 | */
109 | private String toIndentedString(java.lang.Object o) {
110 | if (o == null) {
111 | return "null";
112 | }
113 | return o.toString().replace("\n", "\n ");
114 | }
115 |
116 | }
117 |
118 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/model/Error403.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.model;
15 |
16 | import java.util.Objects;
17 | import java.util.Arrays;
18 | import com.google.gson.TypeAdapter;
19 | import com.google.gson.annotations.JsonAdapter;
20 | import com.google.gson.annotations.SerializedName;
21 | import com.google.gson.stream.JsonReader;
22 | import com.google.gson.stream.JsonWriter;
23 | import io.swagger.annotations.ApiModel;
24 | import io.swagger.annotations.ApiModelProperty;
25 | import java.io.IOException;
26 |
27 | /**
28 | * Error403
29 | */
30 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-11-08T07:58:56.667Z")
31 | public class Error403 {
32 | @SerializedName("code")
33 | private Integer code = null;
34 |
35 | @SerializedName("message")
36 | private String message = null;
37 |
38 | public Error403 code(Integer code) {
39 | this.code = code;
40 | return this;
41 | }
42 |
43 | /**
44 | * Get code
45 | * @return code
46 | **/
47 | @ApiModelProperty(example = "2007", value = "")
48 | public Integer getCode() {
49 | return code;
50 | }
51 |
52 | public void setCode(Integer code) {
53 | this.code = code;
54 | }
55 |
56 | public Error403 message(String message) {
57 | this.message = message;
58 | return this;
59 | }
60 |
61 | /**
62 | * Get message
63 | * @return message
64 | **/
65 | @ApiModelProperty(example = "API key has exceeded calls per month quota.", value = "")
66 | public String getMessage() {
67 | return message;
68 | }
69 |
70 | public void setMessage(String message) {
71 | this.message = message;
72 | }
73 |
74 |
75 | @Override
76 | public boolean equals(java.lang.Object o) {
77 | if (this == o) {
78 | return true;
79 | }
80 | if (o == null || getClass() != o.getClass()) {
81 | return false;
82 | }
83 | Error403 error403 = (Error403) o;
84 | return Objects.equals(this.code, error403.code) &&
85 | Objects.equals(this.message, error403.message);
86 | }
87 |
88 | @Override
89 | public int hashCode() {
90 | return Objects.hash(code, message);
91 | }
92 |
93 |
94 | @Override
95 | public String toString() {
96 | StringBuilder sb = new StringBuilder();
97 | sb.append("class Error403 {\n");
98 |
99 | sb.append(" code: ").append(toIndentedString(code)).append("\n");
100 | sb.append(" message: ").append(toIndentedString(message)).append("\n");
101 | sb.append("}");
102 | return sb.toString();
103 | }
104 |
105 | /**
106 | * Convert the given object to string with each line indented by 4 spaces
107 | * (except the first line).
108 | */
109 | private String toIndentedString(java.lang.Object o) {
110 | if (o == null) {
111 | return "null";
112 | }
113 | return o.toString().replace("\n", "\n ");
114 | }
115 |
116 | }
117 |
118 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/model/Forecast.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.model;
15 |
16 | import java.util.Objects;
17 | import java.util.Arrays;
18 | import com.google.gson.TypeAdapter;
19 | import com.google.gson.annotations.JsonAdapter;
20 | import com.google.gson.annotations.SerializedName;
21 | import com.google.gson.stream.JsonReader;
22 | import com.google.gson.stream.JsonWriter;
23 | import io.swagger.annotations.ApiModel;
24 | import io.swagger.annotations.ApiModelProperty;
25 | import io.swagger.client.model.ForecastForecastday;
26 | import java.io.IOException;
27 | import java.util.ArrayList;
28 | import java.util.List;
29 |
30 | /**
31 | * Forecast
32 | */
33 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-11-08T07:58:56.667Z")
34 | public class Forecast {
35 | @SerializedName("forecastday")
36 | private List forecastday = null;
37 |
38 | public Forecast forecastday(List forecastday) {
39 | this.forecastday = forecastday;
40 | return this;
41 | }
42 |
43 | public Forecast addForecastdayItem(ForecastForecastday forecastdayItem) {
44 | if (this.forecastday == null) {
45 | this.forecastday = new ArrayList();
46 | }
47 | this.forecastday.add(forecastdayItem);
48 | return this;
49 | }
50 |
51 | /**
52 | * Get forecastday
53 | * @return forecastday
54 | **/
55 | @ApiModelProperty(value = "")
56 | public List getForecastday() {
57 | return forecastday;
58 | }
59 |
60 | public void setForecastday(List forecastday) {
61 | this.forecastday = forecastday;
62 | }
63 |
64 |
65 | @Override
66 | public boolean equals(java.lang.Object o) {
67 | if (this == o) {
68 | return true;
69 | }
70 | if (o == null || getClass() != o.getClass()) {
71 | return false;
72 | }
73 | Forecast forecast = (Forecast) o;
74 | return Objects.equals(this.forecastday, forecast.forecastday);
75 | }
76 |
77 | @Override
78 | public int hashCode() {
79 | return Objects.hash(forecastday);
80 | }
81 |
82 |
83 | @Override
84 | public String toString() {
85 | StringBuilder sb = new StringBuilder();
86 | sb.append("class Forecast {\n");
87 |
88 | sb.append(" forecastday: ").append(toIndentedString(forecastday)).append("\n");
89 | sb.append("}");
90 | return sb.toString();
91 | }
92 |
93 | /**
94 | * Convert the given object to string with each line indented by 4 spaces
95 | * (except the first line).
96 | */
97 | private String toIndentedString(java.lang.Object o) {
98 | if (o == null) {
99 | return "null";
100 | }
101 | return o.toString().replace("\n", "\n ");
102 | }
103 |
104 | }
105 |
106 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/model/ForecastAstro.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.model;
15 |
16 | import java.util.Objects;
17 | import java.util.Arrays;
18 | import com.google.gson.TypeAdapter;
19 | import com.google.gson.annotations.JsonAdapter;
20 | import com.google.gson.annotations.SerializedName;
21 | import com.google.gson.stream.JsonReader;
22 | import com.google.gson.stream.JsonWriter;
23 | import io.swagger.annotations.ApiModel;
24 | import io.swagger.annotations.ApiModelProperty;
25 | import java.io.IOException;
26 |
27 | /**
28 | * ForecastAstro
29 | */
30 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-11-08T07:58:56.667Z")
31 | public class ForecastAstro {
32 | @SerializedName("sunrise")
33 | private String sunrise = null;
34 |
35 | @SerializedName("sunset")
36 | private String sunset = null;
37 |
38 | @SerializedName("moonrise")
39 | private String moonrise = null;
40 |
41 | @SerializedName("moonset")
42 | private String moonset = null;
43 |
44 | @SerializedName("moon_phase")
45 | private String moonPhase = null;
46 |
47 | @SerializedName("moon_illumination")
48 | private String moonIllumination = null;
49 |
50 | public ForecastAstro sunrise(String sunrise) {
51 | this.sunrise = sunrise;
52 | return this;
53 | }
54 |
55 | /**
56 | * Get sunrise
57 | * @return sunrise
58 | **/
59 | @ApiModelProperty(example = "05:44 AM", value = "")
60 | public String getSunrise() {
61 | return sunrise;
62 | }
63 |
64 | public void setSunrise(String sunrise) {
65 | this.sunrise = sunrise;
66 | }
67 |
68 | public ForecastAstro sunset(String sunset) {
69 | this.sunset = sunset;
70 | return this;
71 | }
72 |
73 | /**
74 | * Get sunset
75 | * @return sunset
76 | **/
77 | @ApiModelProperty(example = "08:20 PM", value = "")
78 | public String getSunset() {
79 | return sunset;
80 | }
81 |
82 | public void setSunset(String sunset) {
83 | this.sunset = sunset;
84 | }
85 |
86 | public ForecastAstro moonrise(String moonrise) {
87 | this.moonrise = moonrise;
88 | return this;
89 | }
90 |
91 | /**
92 | * Get moonrise
93 | * @return moonrise
94 | **/
95 | @ApiModelProperty(example = "12:58 AM", value = "")
96 | public String getMoonrise() {
97 | return moonrise;
98 | }
99 |
100 | public void setMoonrise(String moonrise) {
101 | this.moonrise = moonrise;
102 | }
103 |
104 | public ForecastAstro moonset(String moonset) {
105 | this.moonset = moonset;
106 | return this;
107 | }
108 |
109 | /**
110 | * Get moonset
111 | * @return moonset
112 | **/
113 | @ApiModelProperty(example = "03:35 PM", value = "")
114 | public String getMoonset() {
115 | return moonset;
116 | }
117 |
118 | public void setMoonset(String moonset) {
119 | this.moonset = moonset;
120 | }
121 |
122 | public ForecastAstro moonPhase(String moonPhase) {
123 | this.moonPhase = moonPhase;
124 | return this;
125 | }
126 |
127 | /**
128 | * Get moonPhase
129 | * @return moonPhase
130 | **/
131 | @ApiModelProperty(example = "Last Quarter", value = "")
132 | public String getMoonPhase() {
133 | return moonPhase;
134 | }
135 |
136 | public void setMoonPhase(String moonPhase) {
137 | this.moonPhase = moonPhase;
138 | }
139 |
140 | public ForecastAstro moonIllumination(String moonIllumination) {
141 | this.moonIllumination = moonIllumination;
142 | return this;
143 | }
144 |
145 | /**
146 | * Get moonIllumination
147 | * @return moonIllumination
148 | **/
149 | @ApiModelProperty(example = "36", value = "")
150 | public String getMoonIllumination() {
151 | return moonIllumination;
152 | }
153 |
154 | public void setMoonIllumination(String moonIllumination) {
155 | this.moonIllumination = moonIllumination;
156 | }
157 |
158 |
159 | @Override
160 | public boolean equals(java.lang.Object o) {
161 | if (this == o) {
162 | return true;
163 | }
164 | if (o == null || getClass() != o.getClass()) {
165 | return false;
166 | }
167 | ForecastAstro forecastAstro = (ForecastAstro) o;
168 | return Objects.equals(this.sunrise, forecastAstro.sunrise) &&
169 | Objects.equals(this.sunset, forecastAstro.sunset) &&
170 | Objects.equals(this.moonrise, forecastAstro.moonrise) &&
171 | Objects.equals(this.moonset, forecastAstro.moonset) &&
172 | Objects.equals(this.moonPhase, forecastAstro.moonPhase) &&
173 | Objects.equals(this.moonIllumination, forecastAstro.moonIllumination);
174 | }
175 |
176 | @Override
177 | public int hashCode() {
178 | return Objects.hash(sunrise, sunset, moonrise, moonset, moonPhase, moonIllumination);
179 | }
180 |
181 |
182 | @Override
183 | public String toString() {
184 | StringBuilder sb = new StringBuilder();
185 | sb.append("class ForecastAstro {\n");
186 |
187 | sb.append(" sunrise: ").append(toIndentedString(sunrise)).append("\n");
188 | sb.append(" sunset: ").append(toIndentedString(sunset)).append("\n");
189 | sb.append(" moonrise: ").append(toIndentedString(moonrise)).append("\n");
190 | sb.append(" moonset: ").append(toIndentedString(moonset)).append("\n");
191 | sb.append(" moonPhase: ").append(toIndentedString(moonPhase)).append("\n");
192 | sb.append(" moonIllumination: ").append(toIndentedString(moonIllumination)).append("\n");
193 | sb.append("}");
194 | return sb.toString();
195 | }
196 |
197 | /**
198 | * Convert the given object to string with each line indented by 4 spaces
199 | * (except the first line).
200 | */
201 | private String toIndentedString(java.lang.Object o) {
202 | if (o == null) {
203 | return "null";
204 | }
205 | return o.toString().replace("\n", "\n ");
206 | }
207 |
208 | }
209 |
210 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/model/ForecastCondition.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.model;
15 |
16 | import java.util.Objects;
17 | import java.util.Arrays;
18 | import com.google.gson.TypeAdapter;
19 | import com.google.gson.annotations.JsonAdapter;
20 | import com.google.gson.annotations.SerializedName;
21 | import com.google.gson.stream.JsonReader;
22 | import com.google.gson.stream.JsonWriter;
23 | import io.swagger.annotations.ApiModel;
24 | import io.swagger.annotations.ApiModelProperty;
25 | import java.io.IOException;
26 |
27 | /**
28 | * ForecastCondition
29 | */
30 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-11-08T07:58:56.667Z")
31 | public class ForecastCondition {
32 | @SerializedName("text")
33 | private String text = null;
34 |
35 | @SerializedName("icon")
36 | private String icon = null;
37 |
38 | @SerializedName("code")
39 | private Integer code = null;
40 |
41 | public ForecastCondition text(String text) {
42 | this.text = text;
43 | return this;
44 | }
45 |
46 | /**
47 | * Get text
48 | * @return text
49 | **/
50 | @ApiModelProperty(example = "Clear", value = "")
51 | public String getText() {
52 | return text;
53 | }
54 |
55 | public void setText(String text) {
56 | this.text = text;
57 | }
58 |
59 | public ForecastCondition icon(String icon) {
60 | this.icon = icon;
61 | return this;
62 | }
63 |
64 | /**
65 | * Get icon
66 | * @return icon
67 | **/
68 | @ApiModelProperty(example = "//cdn.weatherapi.com/weather/64x64/night/113.png", value = "")
69 | public String getIcon() {
70 | return icon;
71 | }
72 |
73 | public void setIcon(String icon) {
74 | this.icon = icon;
75 | }
76 |
77 | public ForecastCondition code(Integer code) {
78 | this.code = code;
79 | return this;
80 | }
81 |
82 | /**
83 | * Get code
84 | * @return code
85 | **/
86 | @ApiModelProperty(example = "1000", value = "")
87 | public Integer getCode() {
88 | return code;
89 | }
90 |
91 | public void setCode(Integer code) {
92 | this.code = code;
93 | }
94 |
95 |
96 | @Override
97 | public boolean equals(java.lang.Object o) {
98 | if (this == o) {
99 | return true;
100 | }
101 | if (o == null || getClass() != o.getClass()) {
102 | return false;
103 | }
104 | ForecastCondition forecastCondition = (ForecastCondition) o;
105 | return Objects.equals(this.text, forecastCondition.text) &&
106 | Objects.equals(this.icon, forecastCondition.icon) &&
107 | Objects.equals(this.code, forecastCondition.code);
108 | }
109 |
110 | @Override
111 | public int hashCode() {
112 | return Objects.hash(text, icon, code);
113 | }
114 |
115 |
116 | @Override
117 | public String toString() {
118 | StringBuilder sb = new StringBuilder();
119 | sb.append("class ForecastCondition {\n");
120 |
121 | sb.append(" text: ").append(toIndentedString(text)).append("\n");
122 | sb.append(" icon: ").append(toIndentedString(icon)).append("\n");
123 | sb.append(" code: ").append(toIndentedString(code)).append("\n");
124 | sb.append("}");
125 | return sb.toString();
126 | }
127 |
128 | /**
129 | * Convert the given object to string with each line indented by 4 spaces
130 | * (except the first line).
131 | */
132 | private String toIndentedString(java.lang.Object o) {
133 | if (o == null) {
134 | return "null";
135 | }
136 | return o.toString().replace("\n", "\n ");
137 | }
138 |
139 | }
140 |
141 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/model/ForecastDayCondition.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.model;
15 |
16 | import java.util.Objects;
17 | import java.util.Arrays;
18 | import com.google.gson.TypeAdapter;
19 | import com.google.gson.annotations.JsonAdapter;
20 | import com.google.gson.annotations.SerializedName;
21 | import com.google.gson.stream.JsonReader;
22 | import com.google.gson.stream.JsonWriter;
23 | import io.swagger.annotations.ApiModel;
24 | import io.swagger.annotations.ApiModelProperty;
25 | import java.io.IOException;
26 |
27 | /**
28 | * ForecastDayCondition
29 | */
30 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-11-08T07:58:56.667Z")
31 | public class ForecastDayCondition {
32 | @SerializedName("text")
33 | private String text = null;
34 |
35 | @SerializedName("icon")
36 | private String icon = null;
37 |
38 | @SerializedName("code")
39 | private Integer code = null;
40 |
41 | public ForecastDayCondition text(String text) {
42 | this.text = text;
43 | return this;
44 | }
45 |
46 | /**
47 | * Get text
48 | * @return text
49 | **/
50 | @ApiModelProperty(example = "Sunny", value = "")
51 | public String getText() {
52 | return text;
53 | }
54 |
55 | public void setText(String text) {
56 | this.text = text;
57 | }
58 |
59 | public ForecastDayCondition icon(String icon) {
60 | this.icon = icon;
61 | return this;
62 | }
63 |
64 | /**
65 | * Get icon
66 | * @return icon
67 | **/
68 | @ApiModelProperty(example = "//cdn.weatherapi.com/weather/64x64/day/113.png", value = "")
69 | public String getIcon() {
70 | return icon;
71 | }
72 |
73 | public void setIcon(String icon) {
74 | this.icon = icon;
75 | }
76 |
77 | public ForecastDayCondition code(Integer code) {
78 | this.code = code;
79 | return this;
80 | }
81 |
82 | /**
83 | * Get code
84 | * @return code
85 | **/
86 | @ApiModelProperty(example = "1000", value = "")
87 | public Integer getCode() {
88 | return code;
89 | }
90 |
91 | public void setCode(Integer code) {
92 | this.code = code;
93 | }
94 |
95 |
96 | @Override
97 | public boolean equals(java.lang.Object o) {
98 | if (this == o) {
99 | return true;
100 | }
101 | if (o == null || getClass() != o.getClass()) {
102 | return false;
103 | }
104 | ForecastDayCondition forecastDayCondition = (ForecastDayCondition) o;
105 | return Objects.equals(this.text, forecastDayCondition.text) &&
106 | Objects.equals(this.icon, forecastDayCondition.icon) &&
107 | Objects.equals(this.code, forecastDayCondition.code);
108 | }
109 |
110 | @Override
111 | public int hashCode() {
112 | return Objects.hash(text, icon, code);
113 | }
114 |
115 |
116 | @Override
117 | public String toString() {
118 | StringBuilder sb = new StringBuilder();
119 | sb.append("class ForecastDayCondition {\n");
120 |
121 | sb.append(" text: ").append(toIndentedString(text)).append("\n");
122 | sb.append(" icon: ").append(toIndentedString(icon)).append("\n");
123 | sb.append(" code: ").append(toIndentedString(code)).append("\n");
124 | sb.append("}");
125 | return sb.toString();
126 | }
127 |
128 | /**
129 | * Convert the given object to string with each line indented by 4 spaces
130 | * (except the first line).
131 | */
132 | private String toIndentedString(java.lang.Object o) {
133 | if (o == null) {
134 | return "null";
135 | }
136 | return o.toString().replace("\n", "\n ");
137 | }
138 |
139 | }
140 |
141 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/model/ForecastForecastday.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.model;
15 |
16 | import java.util.Objects;
17 | import java.util.Arrays;
18 | import com.google.gson.TypeAdapter;
19 | import com.google.gson.annotations.JsonAdapter;
20 | import com.google.gson.annotations.SerializedName;
21 | import com.google.gson.stream.JsonReader;
22 | import com.google.gson.stream.JsonWriter;
23 | import io.swagger.annotations.ApiModel;
24 | import io.swagger.annotations.ApiModelProperty;
25 | import io.swagger.client.model.ForecastAstro;
26 | import io.swagger.client.model.ForecastDay;
27 | import io.swagger.client.model.ForecastHour;
28 | import java.io.IOException;
29 | import java.util.ArrayList;
30 | import java.util.List;
31 | import org.threeten.bp.LocalDate;
32 |
33 | /**
34 | * ForecastForecastday
35 | */
36 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-11-08T07:58:56.667Z")
37 | public class ForecastForecastday {
38 | @SerializedName("date")
39 | private LocalDate date = null;
40 |
41 | @SerializedName("date_epoch")
42 | private Integer dateEpoch = null;
43 |
44 | @SerializedName("day")
45 | private ForecastDay day = null;
46 |
47 | @SerializedName("astro")
48 | private ForecastAstro astro = null;
49 |
50 | @SerializedName("hour")
51 | private List hour = null;
52 |
53 | public ForecastForecastday date(LocalDate date) {
54 | this.date = date;
55 | return this;
56 | }
57 |
58 | /**
59 | * Get date
60 | * @return date
61 | **/
62 | @ApiModelProperty(example = "2022-07-22T00:00:00.000Z", value = "")
63 | public LocalDate getDate() {
64 | return date;
65 | }
66 |
67 | public void setDate(LocalDate date) {
68 | this.date = date;
69 | }
70 |
71 | public ForecastForecastday dateEpoch(Integer dateEpoch) {
72 | this.dateEpoch = dateEpoch;
73 | return this;
74 | }
75 |
76 | /**
77 | * Get dateEpoch
78 | * @return dateEpoch
79 | **/
80 | @ApiModelProperty(example = "1658448000", value = "")
81 | public Integer getDateEpoch() {
82 | return dateEpoch;
83 | }
84 |
85 | public void setDateEpoch(Integer dateEpoch) {
86 | this.dateEpoch = dateEpoch;
87 | }
88 |
89 | public ForecastForecastday day(ForecastDay day) {
90 | this.day = day;
91 | return this;
92 | }
93 |
94 | /**
95 | * Get day
96 | * @return day
97 | **/
98 | @ApiModelProperty(value = "")
99 | public ForecastDay getDay() {
100 | return day;
101 | }
102 |
103 | public void setDay(ForecastDay day) {
104 | this.day = day;
105 | }
106 |
107 | public ForecastForecastday astro(ForecastAstro astro) {
108 | this.astro = astro;
109 | return this;
110 | }
111 |
112 | /**
113 | * Get astro
114 | * @return astro
115 | **/
116 | @ApiModelProperty(value = "")
117 | public ForecastAstro getAstro() {
118 | return astro;
119 | }
120 |
121 | public void setAstro(ForecastAstro astro) {
122 | this.astro = astro;
123 | }
124 |
125 | public ForecastForecastday hour(List hour) {
126 | this.hour = hour;
127 | return this;
128 | }
129 |
130 | public ForecastForecastday addHourItem(ForecastHour hourItem) {
131 | if (this.hour == null) {
132 | this.hour = new ArrayList();
133 | }
134 | this.hour.add(hourItem);
135 | return this;
136 | }
137 |
138 | /**
139 | * Get hour
140 | * @return hour
141 | **/
142 | @ApiModelProperty(value = "")
143 | public List getHour() {
144 | return hour;
145 | }
146 |
147 | public void setHour(List hour) {
148 | this.hour = hour;
149 | }
150 |
151 |
152 | @Override
153 | public boolean equals(java.lang.Object o) {
154 | if (this == o) {
155 | return true;
156 | }
157 | if (o == null || getClass() != o.getClass()) {
158 | return false;
159 | }
160 | ForecastForecastday forecastForecastday = (ForecastForecastday) o;
161 | return Objects.equals(this.date, forecastForecastday.date) &&
162 | Objects.equals(this.dateEpoch, forecastForecastday.dateEpoch) &&
163 | Objects.equals(this.day, forecastForecastday.day) &&
164 | Objects.equals(this.astro, forecastForecastday.astro) &&
165 | Objects.equals(this.hour, forecastForecastday.hour);
166 | }
167 |
168 | @Override
169 | public int hashCode() {
170 | return Objects.hash(date, dateEpoch, day, astro, hour);
171 | }
172 |
173 |
174 | @Override
175 | public String toString() {
176 | StringBuilder sb = new StringBuilder();
177 | sb.append("class ForecastForecastday {\n");
178 |
179 | sb.append(" date: ").append(toIndentedString(date)).append("\n");
180 | sb.append(" dateEpoch: ").append(toIndentedString(dateEpoch)).append("\n");
181 | sb.append(" day: ").append(toIndentedString(day)).append("\n");
182 | sb.append(" astro: ").append(toIndentedString(astro)).append("\n");
183 | sb.append(" hour: ").append(toIndentedString(hour)).append("\n");
184 | sb.append("}");
185 | return sb.toString();
186 | }
187 |
188 | /**
189 | * Convert the given object to string with each line indented by 4 spaces
190 | * (except the first line).
191 | */
192 | private String toIndentedString(java.lang.Object o) {
193 | if (o == null) {
194 | return "null";
195 | }
196 | return o.toString().replace("\n", "\n ");
197 | }
198 |
199 | }
200 |
201 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/model/InlineResponse200.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Astronomy - Time zone - Location data - Search or Autocomplete API - NEW: Historical weather - NEW: Future Weather (Upto 300 days ahead) - Weather Alerts - Air Quality Data # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! We have [code libraries](https://www.weatherapi.com/docs/code-libraries.aspx) for different programming languages like PHP, .net, JAVA, etc. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR_API_KEY
4 | *
5 | * OpenAPI spec version: 1.0.0-oas3
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 | package io.swagger.client.model;
14 |
15 | import java.util.Objects;
16 | import java.util.Arrays;
17 | import com.google.gson.TypeAdapter;
18 | import com.google.gson.annotations.JsonAdapter;
19 | import com.google.gson.annotations.SerializedName;
20 | import com.google.gson.stream.JsonReader;
21 | import com.google.gson.stream.JsonWriter;
22 | import io.swagger.client.model.Current;
23 | import io.swagger.client.model.Location;
24 | import io.swagger.v3.oas.annotations.media.Schema;
25 | import java.io.IOException;
26 | /**
27 | * InlineResponse200
28 | */
29 |
30 | @javax.annotation.Generated(value = "io.swagger.codegen.v3.generators.java.JavaClientCodegen", date = "2022-07-22T21:39:34.951Z[GMT]")
31 | public class InlineResponse200 {
32 | @SerializedName("location")
33 | private Location location = null;
34 |
35 | @SerializedName("current")
36 | private Current current = null;
37 |
38 | public InlineResponse200 location(Location location) {
39 | this.location = location;
40 | return this;
41 | }
42 |
43 | /**
44 | * Get location
45 | * @return location
46 | **/
47 | @Schema(description = "")
48 | public Location getLocation() {
49 | return location;
50 | }
51 |
52 | public void setLocation(Location location) {
53 | this.location = location;
54 | }
55 |
56 | public InlineResponse200 current(Current current) {
57 | this.current = current;
58 | return this;
59 | }
60 |
61 | /**
62 | * Get current
63 | * @return current
64 | **/
65 | @Schema(description = "")
66 | public Current getCurrent() {
67 | return current;
68 | }
69 |
70 | public void setCurrent(Current current) {
71 | this.current = current;
72 | }
73 |
74 |
75 | @Override
76 | public boolean equals(java.lang.Object o) {
77 | if (this == o) {
78 | return true;
79 | }
80 | if (o == null || getClass() != o.getClass()) {
81 | return false;
82 | }
83 | InlineResponse200 inlineResponse200 = (InlineResponse200) o;
84 | return Objects.equals(this.location, inlineResponse200.location) &&
85 | Objects.equals(this.current, inlineResponse200.current);
86 | }
87 |
88 | @Override
89 | public int hashCode() {
90 | return Objects.hash(location, current);
91 | }
92 |
93 |
94 | @Override
95 | public String toString() {
96 | StringBuilder sb = new StringBuilder();
97 | sb.append("class InlineResponse200 {\n");
98 |
99 | sb.append(" location: ").append(toIndentedString(location)).append("\n");
100 | sb.append(" current: ").append(toIndentedString(current)).append("\n");
101 | sb.append("}");
102 | return sb.toString();
103 | }
104 |
105 | /**
106 | * Convert the given object to string with each line indented by 4 spaces
107 | * (except the first line).
108 | */
109 | private String toIndentedString(java.lang.Object o) {
110 | if (o == null) {
111 | return "null";
112 | }
113 | return o.toString().replace("\n", "\n ");
114 | }
115 |
116 | }
117 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/model/InlineResponse2001.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Astronomy - Time zone - Location data - Search or Autocomplete API - NEW: Historical weather - NEW: Future Weather (Upto 300 days ahead) - Weather Alerts - Air Quality Data # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! We have [code libraries](https://www.weatherapi.com/docs/code-libraries.aspx) for different programming languages like PHP, .net, JAVA, etc. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR_API_KEY
4 | *
5 | * OpenAPI spec version: 1.0.0-oas3
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 | package io.swagger.client.model;
14 |
15 | import java.util.Objects;
16 | import java.util.Arrays;
17 | import com.google.gson.TypeAdapter;
18 | import com.google.gson.annotations.JsonAdapter;
19 | import com.google.gson.annotations.SerializedName;
20 | import com.google.gson.stream.JsonReader;
21 | import com.google.gson.stream.JsonWriter;
22 | import io.swagger.client.model.Alerts;
23 | import io.swagger.client.model.Current;
24 | import io.swagger.client.model.Forecast;
25 | import io.swagger.client.model.Location;
26 | import io.swagger.v3.oas.annotations.media.Schema;
27 | import java.io.IOException;
28 | /**
29 | * InlineResponse2001
30 | */
31 |
32 | @javax.annotation.Generated(value = "io.swagger.codegen.v3.generators.java.JavaClientCodegen", date = "2022-07-22T21:39:34.951Z[GMT]")
33 | public class InlineResponse2001 {
34 | @SerializedName("location")
35 | private Location location = null;
36 |
37 | @SerializedName("current")
38 | private Current current = null;
39 |
40 | @SerializedName("forecast")
41 | private Forecast forecast = null;
42 |
43 | @SerializedName("alerts")
44 | private Alerts alerts = null;
45 |
46 | public InlineResponse2001 location(Location location) {
47 | this.location = location;
48 | return this;
49 | }
50 |
51 | /**
52 | * Get location
53 | * @return location
54 | **/
55 | @Schema(description = "")
56 | public Location getLocation() {
57 | return location;
58 | }
59 |
60 | public void setLocation(Location location) {
61 | this.location = location;
62 | }
63 |
64 | public InlineResponse2001 current(Current current) {
65 | this.current = current;
66 | return this;
67 | }
68 |
69 | /**
70 | * Get current
71 | * @return current
72 | **/
73 | @Schema(description = "")
74 | public Current getCurrent() {
75 | return current;
76 | }
77 |
78 | public void setCurrent(Current current) {
79 | this.current = current;
80 | }
81 |
82 | public InlineResponse2001 forecast(Forecast forecast) {
83 | this.forecast = forecast;
84 | return this;
85 | }
86 |
87 | /**
88 | * Get forecast
89 | * @return forecast
90 | **/
91 | @Schema(description = "")
92 | public Forecast getForecast() {
93 | return forecast;
94 | }
95 |
96 | public void setForecast(Forecast forecast) {
97 | this.forecast = forecast;
98 | }
99 |
100 | public InlineResponse2001 alerts(Alerts alerts) {
101 | this.alerts = alerts;
102 | return this;
103 | }
104 |
105 | /**
106 | * Get alerts
107 | * @return alerts
108 | **/
109 | @Schema(description = "")
110 | public Alerts getAlerts() {
111 | return alerts;
112 | }
113 |
114 | public void setAlerts(Alerts alerts) {
115 | this.alerts = alerts;
116 | }
117 |
118 |
119 | @Override
120 | public boolean equals(java.lang.Object o) {
121 | if (this == o) {
122 | return true;
123 | }
124 | if (o == null || getClass() != o.getClass()) {
125 | return false;
126 | }
127 | InlineResponse2001 inlineResponse2001 = (InlineResponse2001) o;
128 | return Objects.equals(this.location, inlineResponse2001.location) &&
129 | Objects.equals(this.current, inlineResponse2001.current) &&
130 | Objects.equals(this.forecast, inlineResponse2001.forecast) &&
131 | Objects.equals(this.alerts, inlineResponse2001.alerts);
132 | }
133 |
134 | @Override
135 | public int hashCode() {
136 | return Objects.hash(location, current, forecast, alerts);
137 | }
138 |
139 |
140 | @Override
141 | public String toString() {
142 | StringBuilder sb = new StringBuilder();
143 | sb.append("class InlineResponse2001 {\n");
144 |
145 | sb.append(" location: ").append(toIndentedString(location)).append("\n");
146 | sb.append(" current: ").append(toIndentedString(current)).append("\n");
147 | sb.append(" forecast: ").append(toIndentedString(forecast)).append("\n");
148 | sb.append(" alerts: ").append(toIndentedString(alerts)).append("\n");
149 | sb.append("}");
150 | return sb.toString();
151 | }
152 |
153 | /**
154 | * Convert the given object to string with each line indented by 4 spaces
155 | * (except the first line).
156 | */
157 | private String toIndentedString(java.lang.Object o) {
158 | if (o == null) {
159 | return "null";
160 | }
161 | return o.toString().replace("\n", "\n ");
162 | }
163 |
164 | }
165 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/model/InlineResponse2002.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Astronomy - Time zone - Location data - Search or Autocomplete API - NEW: Historical weather - NEW: Future Weather (Upto 300 days ahead) - Weather Alerts - Air Quality Data # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! We have [code libraries](https://www.weatherapi.com/docs/code-libraries.aspx) for different programming languages like PHP, .net, JAVA, etc. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR_API_KEY
4 | *
5 | * OpenAPI spec version: 1.0.0-oas3
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 | package io.swagger.client.model;
14 |
15 | import java.util.Objects;
16 | import java.util.Arrays;
17 | import com.google.gson.TypeAdapter;
18 | import com.google.gson.annotations.JsonAdapter;
19 | import com.google.gson.annotations.SerializedName;
20 | import com.google.gson.stream.JsonReader;
21 | import com.google.gson.stream.JsonWriter;
22 | import io.swagger.client.model.Forecast;
23 | import io.swagger.client.model.Location;
24 | import io.swagger.v3.oas.annotations.media.Schema;
25 | import java.io.IOException;
26 | /**
27 | * InlineResponse2002
28 | */
29 |
30 | @javax.annotation.Generated(value = "io.swagger.codegen.v3.generators.java.JavaClientCodegen", date = "2022-07-22T21:39:34.951Z[GMT]")
31 | public class InlineResponse2002 {
32 | @SerializedName("location")
33 | private Location location = null;
34 |
35 | @SerializedName("forecast")
36 | private Forecast forecast = null;
37 |
38 | public InlineResponse2002 location(Location location) {
39 | this.location = location;
40 | return this;
41 | }
42 |
43 | /**
44 | * Get location
45 | * @return location
46 | **/
47 | @Schema(description = "")
48 | public Location getLocation() {
49 | return location;
50 | }
51 |
52 | public void setLocation(Location location) {
53 | this.location = location;
54 | }
55 |
56 | public InlineResponse2002 forecast(Forecast forecast) {
57 | this.forecast = forecast;
58 | return this;
59 | }
60 |
61 | /**
62 | * Get forecast
63 | * @return forecast
64 | **/
65 | @Schema(description = "")
66 | public Forecast getForecast() {
67 | return forecast;
68 | }
69 |
70 | public void setForecast(Forecast forecast) {
71 | this.forecast = forecast;
72 | }
73 |
74 |
75 | @Override
76 | public boolean equals(java.lang.Object o) {
77 | if (this == o) {
78 | return true;
79 | }
80 | if (o == null || getClass() != o.getClass()) {
81 | return false;
82 | }
83 | InlineResponse2002 inlineResponse2002 = (InlineResponse2002) o;
84 | return Objects.equals(this.location, inlineResponse2002.location) &&
85 | Objects.equals(this.forecast, inlineResponse2002.forecast);
86 | }
87 |
88 | @Override
89 | public int hashCode() {
90 | return Objects.hash(location, forecast);
91 | }
92 |
93 |
94 | @Override
95 | public String toString() {
96 | StringBuilder sb = new StringBuilder();
97 | sb.append("class InlineResponse2002 {\n");
98 |
99 | sb.append(" location: ").append(toIndentedString(location)).append("\n");
100 | sb.append(" forecast: ").append(toIndentedString(forecast)).append("\n");
101 | sb.append("}");
102 | return sb.toString();
103 | }
104 |
105 | /**
106 | * Convert the given object to string with each line indented by 4 spaces
107 | * (except the first line).
108 | */
109 | private String toIndentedString(java.lang.Object o) {
110 | if (o == null) {
111 | return "null";
112 | }
113 | return o.toString().replace("\n", "\n ");
114 | }
115 |
116 | }
117 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/model/InlineResponse2003.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Astronomy - Time zone - Location data - Search or Autocomplete API - NEW: Historical weather - NEW: Future Weather (Upto 300 days ahead) - Weather Alerts - Air Quality Data # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! We have [code libraries](https://www.weatherapi.com/docs/code-libraries.aspx) for different programming languages like PHP, .net, JAVA, etc. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR_API_KEY
4 | *
5 | * OpenAPI spec version: 1.0.0-oas3
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 | package io.swagger.client.model;
14 |
15 | import java.util.Objects;
16 | import java.util.Arrays;
17 | import com.google.gson.TypeAdapter;
18 | import com.google.gson.annotations.JsonAdapter;
19 | import com.google.gson.annotations.SerializedName;
20 | import com.google.gson.stream.JsonReader;
21 | import com.google.gson.stream.JsonWriter;
22 | import io.swagger.client.model.Astronomy;
23 | import io.swagger.client.model.Location;
24 | import io.swagger.v3.oas.annotations.media.Schema;
25 | import java.io.IOException;
26 | /**
27 | * InlineResponse2003
28 | */
29 |
30 | @javax.annotation.Generated(value = "io.swagger.codegen.v3.generators.java.JavaClientCodegen", date = "2022-07-22T21:39:34.951Z[GMT]")
31 | public class InlineResponse2003 {
32 | @SerializedName("location")
33 | private Location location = null;
34 |
35 | @SerializedName("astronomy")
36 | private Astronomy astronomy = null;
37 |
38 | public InlineResponse2003 location(Location location) {
39 | this.location = location;
40 | return this;
41 | }
42 |
43 | /**
44 | * Get location
45 | * @return location
46 | **/
47 | @Schema(description = "")
48 | public Location getLocation() {
49 | return location;
50 | }
51 |
52 | public void setLocation(Location location) {
53 | this.location = location;
54 | }
55 |
56 | public InlineResponse2003 astronomy(Astronomy astronomy) {
57 | this.astronomy = astronomy;
58 | return this;
59 | }
60 |
61 | /**
62 | * Get astronomy
63 | * @return astronomy
64 | **/
65 | @Schema(description = "")
66 | public Astronomy getAstronomy() {
67 | return astronomy;
68 | }
69 |
70 | public void setAstronomy(Astronomy astronomy) {
71 | this.astronomy = astronomy;
72 | }
73 |
74 |
75 | @Override
76 | public boolean equals(java.lang.Object o) {
77 | if (this == o) {
78 | return true;
79 | }
80 | if (o == null || getClass() != o.getClass()) {
81 | return false;
82 | }
83 | InlineResponse2003 inlineResponse2003 = (InlineResponse2003) o;
84 | return Objects.equals(this.location, inlineResponse2003.location) &&
85 | Objects.equals(this.astronomy, inlineResponse2003.astronomy);
86 | }
87 |
88 | @Override
89 | public int hashCode() {
90 | return Objects.hash(location, astronomy);
91 | }
92 |
93 |
94 | @Override
95 | public String toString() {
96 | StringBuilder sb = new StringBuilder();
97 | sb.append("class InlineResponse2003 {\n");
98 |
99 | sb.append(" location: ").append(toIndentedString(location)).append("\n");
100 | sb.append(" astronomy: ").append(toIndentedString(astronomy)).append("\n");
101 | sb.append("}");
102 | return sb.toString();
103 | }
104 |
105 | /**
106 | * Convert the given object to string with each line indented by 4 spaces
107 | * (except the first line).
108 | */
109 | private String toIndentedString(java.lang.Object o) {
110 | if (o == null) {
111 | return "null";
112 | }
113 | return o.toString().replace("\n", "\n ");
114 | }
115 |
116 | }
117 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/model/Location.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.model;
15 |
16 | import java.util.Objects;
17 | import java.util.Arrays;
18 | import com.google.gson.TypeAdapter;
19 | import com.google.gson.annotations.JsonAdapter;
20 | import com.google.gson.annotations.SerializedName;
21 | import com.google.gson.stream.JsonReader;
22 | import com.google.gson.stream.JsonWriter;
23 | import io.swagger.annotations.ApiModel;
24 | import io.swagger.annotations.ApiModelProperty;
25 | import java.io.IOException;
26 | import java.math.BigDecimal;
27 |
28 | /**
29 | * Location
30 | */
31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-11-08T07:58:56.667Z")
32 | public class Location {
33 | @SerializedName("name")
34 | private String name = null;
35 |
36 | @SerializedName("region")
37 | private String region = null;
38 |
39 | @SerializedName("country")
40 | private String country = null;
41 |
42 | @SerializedName("lat")
43 | private BigDecimal lat = null;
44 |
45 | @SerializedName("lon")
46 | private BigDecimal lon = null;
47 |
48 | @SerializedName("tz_id")
49 | private String tzId = null;
50 |
51 | @SerializedName("localtime_epoch")
52 | private Integer localtimeEpoch = null;
53 |
54 | @SerializedName("localtime")
55 | private String localtime = null;
56 |
57 | public Location name(String name) {
58 | this.name = name;
59 | return this;
60 | }
61 |
62 | /**
63 | * Get name
64 | * @return name
65 | **/
66 | @ApiModelProperty(example = "New York", value = "")
67 | public String getName() {
68 | return name;
69 | }
70 |
71 | public void setName(String name) {
72 | this.name = name;
73 | }
74 |
75 | public Location region(String region) {
76 | this.region = region;
77 | return this;
78 | }
79 |
80 | /**
81 | * Get region
82 | * @return region
83 | **/
84 | @ApiModelProperty(example = "New York", value = "")
85 | public String getRegion() {
86 | return region;
87 | }
88 |
89 | public void setRegion(String region) {
90 | this.region = region;
91 | }
92 |
93 | public Location country(String country) {
94 | this.country = country;
95 | return this;
96 | }
97 |
98 | /**
99 | * Get country
100 | * @return country
101 | **/
102 | @ApiModelProperty(example = "United States of America", value = "")
103 | public String getCountry() {
104 | return country;
105 | }
106 |
107 | public void setCountry(String country) {
108 | this.country = country;
109 | }
110 |
111 | public Location lat(BigDecimal lat) {
112 | this.lat = lat;
113 | return this;
114 | }
115 |
116 | /**
117 | * Get lat
118 | * @return lat
119 | **/
120 | @ApiModelProperty(example = "40.71", value = "")
121 | public BigDecimal getLat() {
122 | return lat;
123 | }
124 |
125 | public void setLat(BigDecimal lat) {
126 | this.lat = lat;
127 | }
128 |
129 | public Location lon(BigDecimal lon) {
130 | this.lon = lon;
131 | return this;
132 | }
133 |
134 | /**
135 | * Get lon
136 | * @return lon
137 | **/
138 | @ApiModelProperty(example = "-74.01", value = "")
139 | public BigDecimal getLon() {
140 | return lon;
141 | }
142 |
143 | public void setLon(BigDecimal lon) {
144 | this.lon = lon;
145 | }
146 |
147 | public Location tzId(String tzId) {
148 | this.tzId = tzId;
149 | return this;
150 | }
151 |
152 | /**
153 | * Get tzId
154 | * @return tzId
155 | **/
156 | @ApiModelProperty(example = "America/New_York", value = "")
157 | public String getTzId() {
158 | return tzId;
159 | }
160 |
161 | public void setTzId(String tzId) {
162 | this.tzId = tzId;
163 | }
164 |
165 | public Location localtimeEpoch(Integer localtimeEpoch) {
166 | this.localtimeEpoch = localtimeEpoch;
167 | return this;
168 | }
169 |
170 | /**
171 | * Get localtimeEpoch
172 | * @return localtimeEpoch
173 | **/
174 | @ApiModelProperty(example = "1658522976", value = "")
175 | public Integer getLocaltimeEpoch() {
176 | return localtimeEpoch;
177 | }
178 |
179 | public void setLocaltimeEpoch(Integer localtimeEpoch) {
180 | this.localtimeEpoch = localtimeEpoch;
181 | }
182 |
183 | public Location localtime(String localtime) {
184 | this.localtime = localtime;
185 | return this;
186 | }
187 |
188 | /**
189 | * Get localtime
190 | * @return localtime
191 | **/
192 | @ApiModelProperty(example = "2022-07-22 16:49", value = "")
193 | public String getLocaltime() {
194 | return localtime;
195 | }
196 |
197 | public void setLocaltime(String localtime) {
198 | this.localtime = localtime;
199 | }
200 |
201 |
202 | @Override
203 | public boolean equals(java.lang.Object o) {
204 | if (this == o) {
205 | return true;
206 | }
207 | if (o == null || getClass() != o.getClass()) {
208 | return false;
209 | }
210 | Location location = (Location) o;
211 | return Objects.equals(this.name, location.name) &&
212 | Objects.equals(this.region, location.region) &&
213 | Objects.equals(this.country, location.country) &&
214 | Objects.equals(this.lat, location.lat) &&
215 | Objects.equals(this.lon, location.lon) &&
216 | Objects.equals(this.tzId, location.tzId) &&
217 | Objects.equals(this.localtimeEpoch, location.localtimeEpoch) &&
218 | Objects.equals(this.localtime, location.localtime);
219 | }
220 |
221 | @Override
222 | public int hashCode() {
223 | return Objects.hash(name, region, country, lat, lon, tzId, localtimeEpoch, localtime);
224 | }
225 |
226 |
227 | @Override
228 | public String toString() {
229 | StringBuilder sb = new StringBuilder();
230 | sb.append("class Location {\n");
231 |
232 | sb.append(" name: ").append(toIndentedString(name)).append("\n");
233 | sb.append(" region: ").append(toIndentedString(region)).append("\n");
234 | sb.append(" country: ").append(toIndentedString(country)).append("\n");
235 | sb.append(" lat: ").append(toIndentedString(lat)).append("\n");
236 | sb.append(" lon: ").append(toIndentedString(lon)).append("\n");
237 | sb.append(" tzId: ").append(toIndentedString(tzId)).append("\n");
238 | sb.append(" localtimeEpoch: ").append(toIndentedString(localtimeEpoch)).append("\n");
239 | sb.append(" localtime: ").append(toIndentedString(localtime)).append("\n");
240 | sb.append("}");
241 | return sb.toString();
242 | }
243 |
244 | /**
245 | * Convert the given object to string with each line indented by 4 spaces
246 | * (except the first line).
247 | */
248 | private String toIndentedString(java.lang.Object o) {
249 | if (o == null) {
250 | return "null";
251 | }
252 | return o.toString().replace("\n", "\n ");
253 | }
254 |
255 | }
256 |
257 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/model/Marine.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.model;
15 |
16 | import java.util.Objects;
17 | import java.util.Arrays;
18 | import com.google.gson.TypeAdapter;
19 | import com.google.gson.annotations.JsonAdapter;
20 | import com.google.gson.annotations.SerializedName;
21 | import com.google.gson.stream.JsonReader;
22 | import com.google.gson.stream.JsonWriter;
23 | import io.swagger.annotations.ApiModel;
24 | import io.swagger.annotations.ApiModelProperty;
25 | import io.swagger.client.model.MarineForecastday;
26 | import java.io.IOException;
27 | import java.util.ArrayList;
28 | import java.util.List;
29 |
30 | /**
31 | * Marine
32 | */
33 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-11-08T07:58:56.667Z")
34 | public class Marine {
35 | @SerializedName("forecastday")
36 | private List forecastday = null;
37 |
38 | public Marine forecastday(List forecastday) {
39 | this.forecastday = forecastday;
40 | return this;
41 | }
42 |
43 | public Marine addForecastdayItem(MarineForecastday forecastdayItem) {
44 | if (this.forecastday == null) {
45 | this.forecastday = new ArrayList();
46 | }
47 | this.forecastday.add(forecastdayItem);
48 | return this;
49 | }
50 |
51 | /**
52 | * Get forecastday
53 | * @return forecastday
54 | **/
55 | @ApiModelProperty(value = "")
56 | public List getForecastday() {
57 | return forecastday;
58 | }
59 |
60 | public void setForecastday(List forecastday) {
61 | this.forecastday = forecastday;
62 | }
63 |
64 |
65 | @Override
66 | public boolean equals(java.lang.Object o) {
67 | if (this == o) {
68 | return true;
69 | }
70 | if (o == null || getClass() != o.getClass()) {
71 | return false;
72 | }
73 | Marine marine = (Marine) o;
74 | return Objects.equals(this.forecastday, marine.forecastday);
75 | }
76 |
77 | @Override
78 | public int hashCode() {
79 | return Objects.hash(forecastday);
80 | }
81 |
82 |
83 | @Override
84 | public String toString() {
85 | StringBuilder sb = new StringBuilder();
86 | sb.append("class Marine {\n");
87 |
88 | sb.append(" forecastday: ").append(toIndentedString(forecastday)).append("\n");
89 | sb.append("}");
90 | return sb.toString();
91 | }
92 |
93 | /**
94 | * Convert the given object to string with each line indented by 4 spaces
95 | * (except the first line).
96 | */
97 | private String toIndentedString(java.lang.Object o) {
98 | if (o == null) {
99 | return "null";
100 | }
101 | return o.toString().replace("\n", "\n ");
102 | }
103 |
104 | }
105 |
106 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/model/MarineForecastday.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.model;
15 |
16 | import java.util.Objects;
17 | import java.util.Arrays;
18 | import com.google.gson.TypeAdapter;
19 | import com.google.gson.annotations.JsonAdapter;
20 | import com.google.gson.annotations.SerializedName;
21 | import com.google.gson.stream.JsonReader;
22 | import com.google.gson.stream.JsonWriter;
23 | import io.swagger.annotations.ApiModel;
24 | import io.swagger.annotations.ApiModelProperty;
25 | import io.swagger.client.model.ForecastAstro;
26 | import io.swagger.client.model.ForecastDay;
27 | import io.swagger.client.model.MarineHour;
28 | import java.io.IOException;
29 | import java.util.ArrayList;
30 | import java.util.List;
31 | import org.threeten.bp.LocalDate;
32 |
33 | /**
34 | * MarineForecastday
35 | */
36 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-11-08T07:58:56.667Z")
37 | public class MarineForecastday {
38 | @SerializedName("date")
39 | private LocalDate date = null;
40 |
41 | @SerializedName("date_epoch")
42 | private Integer dateEpoch = null;
43 |
44 | @SerializedName("day")
45 | private ForecastDay day = null;
46 |
47 | @SerializedName("astro")
48 | private ForecastAstro astro = null;
49 |
50 | @SerializedName("hour")
51 | private List hour = null;
52 |
53 | public MarineForecastday date(LocalDate date) {
54 | this.date = date;
55 | return this;
56 | }
57 |
58 | /**
59 | * Get date
60 | * @return date
61 | **/
62 | @ApiModelProperty(example = "2022-07-22T00:00:00.000Z", value = "")
63 | public LocalDate getDate() {
64 | return date;
65 | }
66 |
67 | public void setDate(LocalDate date) {
68 | this.date = date;
69 | }
70 |
71 | public MarineForecastday dateEpoch(Integer dateEpoch) {
72 | this.dateEpoch = dateEpoch;
73 | return this;
74 | }
75 |
76 | /**
77 | * Get dateEpoch
78 | * @return dateEpoch
79 | **/
80 | @ApiModelProperty(example = "1658448000", value = "")
81 | public Integer getDateEpoch() {
82 | return dateEpoch;
83 | }
84 |
85 | public void setDateEpoch(Integer dateEpoch) {
86 | this.dateEpoch = dateEpoch;
87 | }
88 |
89 | public MarineForecastday day(ForecastDay day) {
90 | this.day = day;
91 | return this;
92 | }
93 |
94 | /**
95 | * Get day
96 | * @return day
97 | **/
98 | @ApiModelProperty(value = "")
99 | public ForecastDay getDay() {
100 | return day;
101 | }
102 |
103 | public void setDay(ForecastDay day) {
104 | this.day = day;
105 | }
106 |
107 | public MarineForecastday astro(ForecastAstro astro) {
108 | this.astro = astro;
109 | return this;
110 | }
111 |
112 | /**
113 | * Get astro
114 | * @return astro
115 | **/
116 | @ApiModelProperty(value = "")
117 | public ForecastAstro getAstro() {
118 | return astro;
119 | }
120 |
121 | public void setAstro(ForecastAstro astro) {
122 | this.astro = astro;
123 | }
124 |
125 | public MarineForecastday hour(List hour) {
126 | this.hour = hour;
127 | return this;
128 | }
129 |
130 | public MarineForecastday addHourItem(MarineHour hourItem) {
131 | if (this.hour == null) {
132 | this.hour = new ArrayList();
133 | }
134 | this.hour.add(hourItem);
135 | return this;
136 | }
137 |
138 | /**
139 | * Get hour
140 | * @return hour
141 | **/
142 | @ApiModelProperty(value = "")
143 | public List getHour() {
144 | return hour;
145 | }
146 |
147 | public void setHour(List hour) {
148 | this.hour = hour;
149 | }
150 |
151 |
152 | @Override
153 | public boolean equals(java.lang.Object o) {
154 | if (this == o) {
155 | return true;
156 | }
157 | if (o == null || getClass() != o.getClass()) {
158 | return false;
159 | }
160 | MarineForecastday marineForecastday = (MarineForecastday) o;
161 | return Objects.equals(this.date, marineForecastday.date) &&
162 | Objects.equals(this.dateEpoch, marineForecastday.dateEpoch) &&
163 | Objects.equals(this.day, marineForecastday.day) &&
164 | Objects.equals(this.astro, marineForecastday.astro) &&
165 | Objects.equals(this.hour, marineForecastday.hour);
166 | }
167 |
168 | @Override
169 | public int hashCode() {
170 | return Objects.hash(date, dateEpoch, day, astro, hour);
171 | }
172 |
173 |
174 | @Override
175 | public String toString() {
176 | StringBuilder sb = new StringBuilder();
177 | sb.append("class MarineForecastday {\n");
178 |
179 | sb.append(" date: ").append(toIndentedString(date)).append("\n");
180 | sb.append(" dateEpoch: ").append(toIndentedString(dateEpoch)).append("\n");
181 | sb.append(" day: ").append(toIndentedString(day)).append("\n");
182 | sb.append(" astro: ").append(toIndentedString(astro)).append("\n");
183 | sb.append(" hour: ").append(toIndentedString(hour)).append("\n");
184 | sb.append("}");
185 | return sb.toString();
186 | }
187 |
188 | /**
189 | * Convert the given object to string with each line indented by 4 spaces
190 | * (except the first line).
191 | */
192 | private String toIndentedString(java.lang.Object o) {
193 | if (o == null) {
194 | return "null";
195 | }
196 | return o.toString().replace("\n", "\n ");
197 | }
198 |
199 | }
200 |
201 |
--------------------------------------------------------------------------------
/src/main/java/io/swagger/client/model/Search.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.model;
15 |
16 | import java.util.Objects;
17 | import java.util.Arrays;
18 | import com.google.gson.TypeAdapter;
19 | import com.google.gson.annotations.JsonAdapter;
20 | import com.google.gson.annotations.SerializedName;
21 | import com.google.gson.stream.JsonReader;
22 | import com.google.gson.stream.JsonWriter;
23 | import io.swagger.annotations.ApiModel;
24 | import io.swagger.annotations.ApiModelProperty;
25 | import java.io.IOException;
26 | import java.math.BigDecimal;
27 |
28 | /**
29 | * Search
30 | */
31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-11-08T07:58:56.667Z")
32 | public class Search {
33 | @SerializedName("id")
34 | private Integer id = null;
35 |
36 | @SerializedName("name")
37 | private String name = null;
38 |
39 | @SerializedName("region")
40 | private String region = null;
41 |
42 | @SerializedName("country")
43 | private String country = null;
44 |
45 | @SerializedName("lat")
46 | private BigDecimal lat = null;
47 |
48 | @SerializedName("lon")
49 | private BigDecimal lon = null;
50 |
51 | @SerializedName("url")
52 | private String url = null;
53 |
54 | public Search id(Integer id) {
55 | this.id = id;
56 | return this;
57 | }
58 |
59 | /**
60 | * Get id
61 | * @return id
62 | **/
63 | @ApiModelProperty(example = "2796590", value = "")
64 | public Integer getId() {
65 | return id;
66 | }
67 |
68 | public void setId(Integer id) {
69 | this.id = id;
70 | }
71 |
72 | public Search name(String name) {
73 | this.name = name;
74 | return this;
75 | }
76 |
77 | /**
78 | * Get name
79 | * @return name
80 | **/
81 | @ApiModelProperty(example = "Holborn", value = "")
82 | public String getName() {
83 | return name;
84 | }
85 |
86 | public void setName(String name) {
87 | this.name = name;
88 | }
89 |
90 | public Search region(String region) {
91 | this.region = region;
92 | return this;
93 | }
94 |
95 | /**
96 | * Get region
97 | * @return region
98 | **/
99 | @ApiModelProperty(example = "Camden Greater London", value = "")
100 | public String getRegion() {
101 | return region;
102 | }
103 |
104 | public void setRegion(String region) {
105 | this.region = region;
106 | }
107 |
108 | public Search country(String country) {
109 | this.country = country;
110 | return this;
111 | }
112 |
113 | /**
114 | * Get country
115 | * @return country
116 | **/
117 | @ApiModelProperty(example = "United Kingdom", value = "")
118 | public String getCountry() {
119 | return country;
120 | }
121 |
122 | public void setCountry(String country) {
123 | this.country = country;
124 | }
125 |
126 | public Search lat(BigDecimal lat) {
127 | this.lat = lat;
128 | return this;
129 | }
130 |
131 | /**
132 | * Get lat
133 | * @return lat
134 | **/
135 | @ApiModelProperty(example = "51.52", value = "")
136 | public BigDecimal getLat() {
137 | return lat;
138 | }
139 |
140 | public void setLat(BigDecimal lat) {
141 | this.lat = lat;
142 | }
143 |
144 | public Search lon(BigDecimal lon) {
145 | this.lon = lon;
146 | return this;
147 | }
148 |
149 | /**
150 | * Get lon
151 | * @return lon
152 | **/
153 | @ApiModelProperty(example = "-0.12", value = "")
154 | public BigDecimal getLon() {
155 | return lon;
156 | }
157 |
158 | public void setLon(BigDecimal lon) {
159 | this.lon = lon;
160 | }
161 |
162 | public Search url(String url) {
163 | this.url = url;
164 | return this;
165 | }
166 |
167 | /**
168 | * Get url
169 | * @return url
170 | **/
171 | @ApiModelProperty(example = "holborn-camden-greater-london-united-kingdom", value = "")
172 | public String getUrl() {
173 | return url;
174 | }
175 |
176 | public void setUrl(String url) {
177 | this.url = url;
178 | }
179 |
180 |
181 | @Override
182 | public boolean equals(java.lang.Object o) {
183 | if (this == o) {
184 | return true;
185 | }
186 | if (o == null || getClass() != o.getClass()) {
187 | return false;
188 | }
189 | Search search = (Search) o;
190 | return Objects.equals(this.id, search.id) &&
191 | Objects.equals(this.name, search.name) &&
192 | Objects.equals(this.region, search.region) &&
193 | Objects.equals(this.country, search.country) &&
194 | Objects.equals(this.lat, search.lat) &&
195 | Objects.equals(this.lon, search.lon) &&
196 | Objects.equals(this.url, search.url);
197 | }
198 |
199 | @Override
200 | public int hashCode() {
201 | return Objects.hash(id, name, region, country, lat, lon, url);
202 | }
203 |
204 |
205 | @Override
206 | public String toString() {
207 | StringBuilder sb = new StringBuilder();
208 | sb.append("class Search {\n");
209 |
210 | sb.append(" id: ").append(toIndentedString(id)).append("\n");
211 | sb.append(" name: ").append(toIndentedString(name)).append("\n");
212 | sb.append(" region: ").append(toIndentedString(region)).append("\n");
213 | sb.append(" country: ").append(toIndentedString(country)).append("\n");
214 | sb.append(" lat: ").append(toIndentedString(lat)).append("\n");
215 | sb.append(" lon: ").append(toIndentedString(lon)).append("\n");
216 | sb.append(" url: ").append(toIndentedString(url)).append("\n");
217 | sb.append("}");
218 | return sb.toString();
219 | }
220 |
221 | /**
222 | * Convert the given object to string with each line indented by 4 spaces
223 | * (except the first line).
224 | */
225 | private String toIndentedString(java.lang.Object o) {
226 | if (o == null) {
227 | return "null";
228 | }
229 | return o.toString().replace("\n", "\n ");
230 | }
231 |
232 | }
233 |
234 |
--------------------------------------------------------------------------------
/src/test/java/io/swagger/client/api/ApIsApiTest.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Astronomy - Time zone - Location data - Search or Autocomplete API - NEW: Historical weather - NEW: Future Weather (Upto 300 days ahead) - Weather Alerts - Air Quality Data # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! We have [code libraries](https://www.weatherapi.com/docs/code-libraries.aspx) for different programming languages like PHP, .net, JAVA, etc. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR_API_KEY
4 | *
5 | * OpenAPI spec version: 1.0.0-oas3
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 | package io.swagger.client.api;
14 |
15 | import io.swagger.client.model.ArrayOfSearch;
16 | import io.swagger.client.model.Error400;
17 | import io.swagger.client.model.Error401;
18 | import io.swagger.client.model.Error403;
19 | import io.swagger.client.model.InlineResponse200;
20 | import io.swagger.client.model.InlineResponse2001;
21 | import io.swagger.client.model.InlineResponse2002;
22 | import io.swagger.client.model.InlineResponse2003;
23 | import io.swagger.client.model.Ip;
24 | import org.threeten.bp.LocalDate;
25 | import io.swagger.client.model.Location;
26 | import org.junit.Test;
27 | import org.junit.Ignore;
28 |
29 |
30 | import java.util.ArrayList;
31 | import java.util.HashMap;
32 | import java.util.List;
33 | import java.util.Map;
34 |
35 |
36 | /**
37 | * API tests for ApIsApi
38 | */
39 | @Ignore
40 | public class ApIsApiTest {
41 |
42 | private final ApIsApi api = new ApIsApi();
43 |
44 | /**
45 | * Astronomy API
46 | *
47 | * Return Location and Astronomy Object
48 | *
49 | * @throws Exception
50 | * if the Api call fails
51 | */
52 | @Test
53 | public void astronomyTest() throws Exception {
54 | String q = null;
55 | LocalDate dt = null;
56 | InlineResponse2003 response = api.astronomy(q, dt);
57 |
58 | // TODO: test validations
59 | }
60 | /**
61 | * Forecast API
62 | *
63 | * Forecast weather API method returns upto next 10 day weather forecast and weather alert as json. The data is returned as a Forecast Object. Forecast object contains astronomy data, day weather forecast and hourly interval weather information for a given city.
64 | *
65 | * @throws Exception
66 | * if the Api call fails
67 | */
68 | @Test
69 | public void forecastWeatherTest() throws Exception {
70 | String q = null;
71 | Integer days = null;
72 | LocalDate dt = null;
73 | Integer unixdt = null;
74 | Integer hour = null;
75 | String lang = null;
76 | InlineResponse2001 response = api.forecastWeather(q, days, dt, unixdt, hour, lang);
77 |
78 | // TODO: test validations
79 | }
80 | /**
81 | * Future API
82 | *
83 | * Future weather API method returns weather in a 3 hourly interval in future for a date between 14 days and 300 days from today in the future.
84 | *
85 | * @throws Exception
86 | * if the Api call fails
87 | */
88 | @Test
89 | public void futureWeatherTest() throws Exception {
90 | String q = null;
91 | LocalDate dt = null;
92 | String lang = null;
93 | InlineResponse2002 response = api.futureWeather(q, dt, lang);
94 |
95 | // TODO: test validations
96 | }
97 | /**
98 | * History API
99 | *
100 | * History weather API method returns historical weather for a date on or after 1st Jan, 2010 as json. The data is returned as a Forecast Object.
101 | *
102 | * @throws Exception
103 | * if the Api call fails
104 | */
105 | @Test
106 | public void historyWeatherTest() throws Exception {
107 | String q = null;
108 | LocalDate dt = null;
109 | Integer unixdt = null;
110 | LocalDate endDt = null;
111 | Integer unixendDt = null;
112 | Integer hour = null;
113 | String lang = null;
114 | InlineResponse2002 response = api.historyWeather(q, dt, unixdt, endDt, unixendDt, hour, lang);
115 |
116 | // TODO: test validations
117 | }
118 | /**
119 | * IP Lookup API
120 | *
121 | * IP Lookup API method allows a user to get up to date information for an IP address.
122 | *
123 | * @throws Exception
124 | * if the Api call fails
125 | */
126 | @Test
127 | public void ipLookupTest() throws Exception {
128 | String q = null;
129 | Ip response = api.ipLookup(q);
130 |
131 | // TODO: test validations
132 | }
133 | /**
134 | * Realtime API
135 | *
136 | * Current weather or realtime weather API method allows a user to get up to date current weather information in json and xml. The data is returned as a Current Object.<br /><br />Current object contains current or realtime weather information for a given city.
137 | *
138 | * @throws Exception
139 | * if the Api call fails
140 | */
141 | @Test
142 | public void realtimeWeatherTest() throws Exception {
143 | String q = null;
144 | String lang = null;
145 | InlineResponse200 response = api.realtimeWeather(q, lang);
146 |
147 | // TODO: test validations
148 | }
149 | /**
150 | * Search/Autocomplete API
151 | *
152 | * WeatherAPI.com Search or Autocomplete API returns matching cities and towns as an array of Location object.
153 | *
154 | * @throws Exception
155 | * if the Api call fails
156 | */
157 | @Test
158 | public void searchAutocompleteWeatherTest() throws Exception {
159 | String q = null;
160 | ArrayOfSearch response = api.searchAutocompleteWeather(q);
161 |
162 | // TODO: test validations
163 | }
164 | /**
165 | * Time Zone API
166 | *
167 | * Return Location Object
168 | *
169 | * @throws Exception
170 | * if the Api call fails
171 | */
172 | @Test
173 | public void timeZoneTest() throws Exception {
174 | String q = null;
175 | Location response = api.timeZone(q);
176 |
177 | // TODO: test validations
178 | }
179 | }
180 |
--------------------------------------------------------------------------------
/src/test/java/io/swagger/client/api/ApisApiTest.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Weather API
3 | * # Introduction WeatherAPI.com provides access to weather and geo data via a JSON/XML restful API. It allows developers to create desktop, web and mobile applications using this data very easy. We provide following data through our API: - Real-time weather - 14 day weather forecast - Historical Weather - Marine Weather and Tide Data - Future Weather (Upto 365 days ahead) - Daily and hourly intervals - 15 min interval (Enterprise only) - Astronomy - Time zone - Location data - Sports - Search or Autocomplete API - Weather Alerts - Air Quality Data - Bulk Request # Getting Started You need to [signup](https://www.weatherapi.com/signup.aspx) and then you can find your API key under [your account](https://www.weatherapi.com/login.aspx), and start using API right away! Try our weather API by using interactive [API Explorer](https://www.weatherapi.com/api-explorer.aspx). We also have SDK for popular framework/languages available on [Github](https://github.com/weatherapicom/) for quick integrations. If you find any features missing or have any suggestions, please [contact us](https://www.weatherapi.com/contact.aspx). # Authentication API access to the data is protected by an API key. If at anytime, you find the API key has become vulnerable, please regenerate the key using Regenerate button next to the API key. Authentication to the WeatherAPI.com API is provided by passing your API key as request parameter through an API . ## key parameter key=YOUR API KEY
4 | *
5 | * OpenAPI spec version: 1.0.2
6 | *
7 | *
8 | * NOTE: This class is auto generated by the swagger code generator program.
9 | * https://github.com/swagger-api/swagger-codegen.git
10 | * Do not edit the class manually.
11 | */
12 |
13 |
14 | package io.swagger.client.api;
15 |
16 | import io.swagger.client.model.ArrayOfSearch;
17 | import io.swagger.client.model.Error400;
18 | import io.swagger.client.model.Error401;
19 | import io.swagger.client.model.Error403;
20 | import io.swagger.client.model.Ip;
21 | import org.threeten.bp.LocalDate;
22 | import io.swagger.client.model.Location;
23 | import org.junit.Test;
24 | import org.junit.Ignore;
25 |
26 |
27 | import java.util.ArrayList;
28 | import java.util.HashMap;
29 | import java.util.List;
30 | import java.util.Map;
31 |
32 | /**
33 | * API tests for ApisApi
34 | */
35 | @Ignore
36 | public class ApisApiTest {
37 |
38 | private final ApisApi api = new ApisApi();
39 |
40 |
41 | /**
42 | * Astronomy API
43 | *
44 | * Return Location and Astronomy Object
45 | *
46 | * @throws Exception
47 | * if the Api call fails
48 | */
49 | @Test
50 | public void astronomyTest() throws Exception {
51 | String q = null;
52 | LocalDate dt = null;
53 | Object response = api.astronomy(q, dt);
54 |
55 | // TODO: test validations
56 | }
57 |
58 | /**
59 | * Forecast API
60 | *
61 | * Forecast weather API method returns, depending upon your price plan level, upto next 14 day weather forecast and weather alert as json or xml. The data is returned as a Forecast Object.<br /><br />Forecast object contains astronomy data, day weather forecast and hourly interval weather information for a given city.
62 | *
63 | * @throws Exception
64 | * if the Api call fails
65 | */
66 | @Test
67 | public void forecastWeatherTest() throws Exception {
68 | String q = null;
69 | Integer days = null;
70 | LocalDate dt = null;
71 | Integer unixdt = null;
72 | Integer hour = null;
73 | String lang = null;
74 | String alerts = null;
75 | String aqi = null;
76 | Integer tp = null;
77 | Object response = api.forecastWeather(q, days, dt, unixdt, hour, lang, alerts, aqi, tp);
78 |
79 | // TODO: test validations
80 | }
81 |
82 | /**
83 | * Future API
84 | *
85 | * Future weather API method returns weather in a 3 hourly interval in future for a date between 14 days and 365 days from today in the future.
86 | *
87 | * @throws Exception
88 | * if the Api call fails
89 | */
90 | @Test
91 | public void futureWeatherTest() throws Exception {
92 | String q = null;
93 | LocalDate dt = null;
94 | String lang = null;
95 | Object response = api.futureWeather(q, dt, lang);
96 |
97 | // TODO: test validations
98 | }
99 |
100 | /**
101 | * History API
102 | *
103 | * History weather API method returns historical weather for a date on or after 1st Jan, 2010 as json. The data is returned as a Forecast Object.
104 | *
105 | * @throws Exception
106 | * if the Api call fails
107 | */
108 | @Test
109 | public void historyWeatherTest() throws Exception {
110 | String q = null;
111 | LocalDate dt = null;
112 | Integer unixdt = null;
113 | LocalDate endDt = null;
114 | Integer unixendDt = null;
115 | Integer hour = null;
116 | String lang = null;
117 | Object response = api.historyWeather(q, dt, unixdt, endDt, unixendDt, hour, lang);
118 |
119 | // TODO: test validations
120 | }
121 |
122 | /**
123 | * IP Lookup API
124 | *
125 | * IP Lookup API method allows a user to get up to date information for an IP address.
126 | *
127 | * @throws Exception
128 | * if the Api call fails
129 | */
130 | @Test
131 | public void ipLookupTest() throws Exception {
132 | String q = null;
133 | Ip response = api.ipLookup(q);
134 |
135 | // TODO: test validations
136 | }
137 |
138 | /**
139 | * Marine Weather API
140 | *
141 | * Marine weather API method returns upto next 7 day (depending upon your price plan level) marine and sailing weather forecast and tide data (depending upon your price plan level) as json or xml. The data is returned as a Marine Object.<br /><br />Marine object, depending upon your price plan level, contains astronomy data, day weather forecast and hourly interval weather information and tide data for a given sea/ocean point.
142 | *
143 | * @throws Exception
144 | * if the Api call fails
145 | */
146 | @Test
147 | public void marineWeatherTest() throws Exception {
148 | String q = null;
149 | Integer days = null;
150 | LocalDate dt = null;
151 | Integer unixdt = null;
152 | Integer hour = null;
153 | String lang = null;
154 | Object response = api.marineWeather(q, days, dt, unixdt, hour, lang);
155 |
156 | // TODO: test validations
157 | }
158 |
159 | /**
160 | * Realtime API
161 | *
162 | * Current weather or realtime weather API method allows a user to get up to date current weather information in json and xml. The data is returned as a Current Object.<br /><br />Current object contains current or realtime weather information for a given city.
163 | *
164 | * @throws Exception
165 | * if the Api call fails
166 | */
167 | @Test
168 | public void realtimeWeatherTest() throws Exception {
169 | String q = null;
170 | String lang = null;
171 | Object response = api.realtimeWeather(q, lang);
172 |
173 | // TODO: test validations
174 | }
175 |
176 | /**
177 | * Search/Autocomplete API
178 | *
179 | * WeatherAPI.com Search or Autocomplete API returns matching cities and towns as an array of Location object.
180 | *
181 | * @throws Exception
182 | * if the Api call fails
183 | */
184 | @Test
185 | public void searchAutocompleteWeatherTest() throws Exception {
186 | String q = null;
187 | ArrayOfSearch response = api.searchAutocompleteWeather(q);
188 |
189 | // TODO: test validations
190 | }
191 |
192 | /**
193 | * Time Zone API
194 | *
195 | * Return Location Object
196 | *
197 | * @throws Exception
198 | * if the Api call fails
199 | */
200 | @Test
201 | public void timeZoneTest() throws Exception {
202 | String q = null;
203 | Location response = api.timeZone(q);
204 |
205 | // TODO: test validations
206 | }
207 |
208 | }
209 |
--------------------------------------------------------------------------------