diff --git a/build.gradle b/build.gradle index ac831a7..b182eb2 100644 --- a/build.gradle +++ b/build.gradle @@ -27,7 +27,7 @@ apply plugin: 'java' apply plugin: 'com.diffplug.spotless' group 'io.tiledb' -version = '0.4.1-SNAPSHOT' +version = '0.4.2' repositories { mavenCentral() diff --git a/src/main/java/io/tiledb/cloud/rest_api/JSON.java b/src/main/java/io/tiledb/cloud/rest_api/JSON.java index 00ce2cd..a18f608 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/JSON.java +++ b/src/main/java/io/tiledb/cloud/rest_api/JSON.java @@ -159,7 +159,6 @@ import io.tiledb.cloud.rest_api.model.UDFSubarrayRange; import io.tiledb.cloud.rest_api.model.User; import io.tiledb.cloud.rest_api.model.Writer; -import io.tiledb.cloud.rest_api.v1.model.*; import io.tiledb.cloud.rest_api.model.Error; import okio.ByteString; diff --git a/src/main/java/io/tiledb/cloud/rest_api/api/ArrayApi.java b/src/main/java/io/tiledb/cloud/rest_api/api/ArrayApi.java index 3ab795f..9b366c6 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/api/ArrayApi.java +++ b/src/main/java/io/tiledb/cloud/rest_api/api/ArrayApi.java @@ -49,10 +49,6 @@ import java.util.List; import java.util.Map; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.api - */ -@Deprecated public class ArrayApi { private ApiClient localVarApiClient; private int localHostIndex; diff --git a/src/main/java/io/tiledb/cloud/rest_api/api/ArrayTasksApi.java b/src/main/java/io/tiledb/cloud/rest_api/api/ArrayTasksApi.java index 9131623..7eab19f 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/api/ArrayTasksApi.java +++ b/src/main/java/io/tiledb/cloud/rest_api/api/ArrayTasksApi.java @@ -30,10 +30,6 @@ import java.util.List; import java.util.Map; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.api - */ -@Deprecated public class ArrayTasksApi { private ApiClient localVarApiClient; private int localHostIndex; diff --git a/src/main/java/io/tiledb/cloud/rest_api/api/FavoritesApi.java b/src/main/java/io/tiledb/cloud/rest_api/api/FavoritesApi.java index 8cd7de4..93d56f5 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/api/FavoritesApi.java +++ b/src/main/java/io/tiledb/cloud/rest_api/api/FavoritesApi.java @@ -38,10 +38,6 @@ import java.util.List; import java.util.Map; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.api - */ -@Deprecated public class FavoritesApi { private ApiClient localVarApiClient; private int localHostIndex; diff --git a/src/main/java/io/tiledb/cloud/rest_api/api/FilesApi.java b/src/main/java/io/tiledb/cloud/rest_api/api/FilesApi.java index 6f53588..e799b94 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/api/FilesApi.java +++ b/src/main/java/io/tiledb/cloud/rest_api/api/FilesApi.java @@ -36,10 +36,6 @@ import java.util.List; import java.util.Map; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.api - */ -@Deprecated public class FilesApi { private ApiClient localVarApiClient; private int localHostIndex; diff --git a/src/main/java/io/tiledb/cloud/rest_api/api/GroupsApi.java b/src/main/java/io/tiledb/cloud/rest_api/api/GroupsApi.java index aa81825..e817d9d 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/api/GroupsApi.java +++ b/src/main/java/io/tiledb/cloud/rest_api/api/GroupsApi.java @@ -42,10 +42,6 @@ import java.util.List; import java.util.Map; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.api - */ -@Deprecated public class GroupsApi { private ApiClient localVarApiClient; private int localHostIndex; diff --git a/src/main/java/io/tiledb/cloud/rest_api/api/InvitationApi.java b/src/main/java/io/tiledb/cloud/rest_api/api/InvitationApi.java index 0787cb1..d081e80 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/api/InvitationApi.java +++ b/src/main/java/io/tiledb/cloud/rest_api/api/InvitationApi.java @@ -33,10 +33,6 @@ import java.util.List; import java.util.Map; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.api - */ -@Deprecated public class InvitationApi { private ApiClient localVarApiClient; private int localHostIndex; diff --git a/src/main/java/io/tiledb/cloud/rest_api/api/NotebookApi.java b/src/main/java/io/tiledb/cloud/rest_api/api/NotebookApi.java index 058ec54..5be5110 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/api/NotebookApi.java +++ b/src/main/java/io/tiledb/cloud/rest_api/api/NotebookApi.java @@ -37,10 +37,6 @@ import java.util.List; import java.util.Map; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.api - */ -@Deprecated public class NotebookApi { private ApiClient localVarApiClient; private int localHostIndex; diff --git a/src/main/java/io/tiledb/cloud/rest_api/api/NotebooksApi.java b/src/main/java/io/tiledb/cloud/rest_api/api/NotebooksApi.java index 96a279e..70fc1dc 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/api/NotebooksApi.java +++ b/src/main/java/io/tiledb/cloud/rest_api/api/NotebooksApi.java @@ -30,10 +30,6 @@ import java.util.List; import java.util.Map; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.api - */ -@Deprecated public class NotebooksApi { private ApiClient localVarApiClient; private int localHostIndex; diff --git a/src/main/java/io/tiledb/cloud/rest_api/api/OrganizationApi.java b/src/main/java/io/tiledb/cloud/rest_api/api/OrganizationApi.java index cb9daa0..56354bc 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/api/OrganizationApi.java +++ b/src/main/java/io/tiledb/cloud/rest_api/api/OrganizationApi.java @@ -36,10 +36,6 @@ import java.util.List; import java.util.Map; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.api - */ -@Deprecated public class OrganizationApi { private ApiClient localVarApiClient; private int localHostIndex; diff --git a/src/main/java/io/tiledb/cloud/rest_api/api/QueryApi.java b/src/main/java/io/tiledb/cloud/rest_api/api/QueryApi.java index dd26fe6..7d1f6a5 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/api/QueryApi.java +++ b/src/main/java/io/tiledb/cloud/rest_api/api/QueryApi.java @@ -33,10 +33,6 @@ import java.util.List; import java.util.Map; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.api - */ -@Deprecated public class QueryApi { private ApiClient localVarApiClient; private int localHostIndex; diff --git a/src/main/java/io/tiledb/cloud/rest_api/api/RegisteredTaskGraphsApi.java b/src/main/java/io/tiledb/cloud/rest_api/api/RegisteredTaskGraphsApi.java index e33a2ca..4d96ef6 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/api/RegisteredTaskGraphsApi.java +++ b/src/main/java/io/tiledb/cloud/rest_api/api/RegisteredTaskGraphsApi.java @@ -31,10 +31,6 @@ import java.util.List; import java.util.Map; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.api - */ -@Deprecated public class RegisteredTaskGraphsApi { private ApiClient localVarApiClient; private int localHostIndex; diff --git a/src/main/java/io/tiledb/cloud/rest_api/api/SqlApi.java b/src/main/java/io/tiledb/cloud/rest_api/api/SqlApi.java index c8dcf90..ca9273d 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/api/SqlApi.java +++ b/src/main/java/io/tiledb/cloud/rest_api/api/SqlApi.java @@ -30,10 +30,6 @@ import java.util.List; import java.util.Map; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.api - */ -@Deprecated public class SqlApi { private ApiClient localVarApiClient; private int localHostIndex; diff --git a/src/main/java/io/tiledb/cloud/rest_api/api/StatsApi.java b/src/main/java/io/tiledb/cloud/rest_api/api/StatsApi.java index ed59fba..c36a896 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/api/StatsApi.java +++ b/src/main/java/io/tiledb/cloud/rest_api/api/StatsApi.java @@ -30,10 +30,6 @@ import java.util.List; import java.util.Map; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.api - */ -@Deprecated public class StatsApi { private ApiClient localVarApiClient; private int localHostIndex; diff --git a/src/main/java/io/tiledb/cloud/rest_api/api/TaskGraphLogsApi.java b/src/main/java/io/tiledb/cloud/rest_api/api/TaskGraphLogsApi.java index c690946..5585602 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/api/TaskGraphLogsApi.java +++ b/src/main/java/io/tiledb/cloud/rest_api/api/TaskGraphLogsApi.java @@ -34,10 +34,6 @@ import java.util.List; import java.util.Map; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.api - */ -@Deprecated public class TaskGraphLogsApi { private ApiClient localVarApiClient; private int localHostIndex; diff --git a/src/main/java/io/tiledb/cloud/rest_api/api/TaskGraphsApi.java b/src/main/java/io/tiledb/cloud/rest_api/api/TaskGraphsApi.java index 434cdc1..a5d838b 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/api/TaskGraphsApi.java +++ b/src/main/java/io/tiledb/cloud/rest_api/api/TaskGraphsApi.java @@ -32,10 +32,6 @@ import java.util.List; import java.util.Map; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.api - */ -@Deprecated public class TaskGraphsApi { private ApiClient localVarApiClient; private int localHostIndex; diff --git a/src/main/java/io/tiledb/cloud/rest_api/api/TasksApi.java b/src/main/java/io/tiledb/cloud/rest_api/api/TasksApi.java index 8c6172c..c61ffd6 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/api/TasksApi.java +++ b/src/main/java/io/tiledb/cloud/rest_api/api/TasksApi.java @@ -32,10 +32,6 @@ import java.util.List; import java.util.Map; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.api - */ -@Deprecated public class TasksApi { private ApiClient localVarApiClient; private int localHostIndex; diff --git a/src/main/java/io/tiledb/cloud/rest_api/api/UdfApi.java b/src/main/java/io/tiledb/cloud/rest_api/api/UdfApi.java index 689bb29..f027490 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/api/UdfApi.java +++ b/src/main/java/io/tiledb/cloud/rest_api/api/UdfApi.java @@ -39,10 +39,6 @@ import java.util.List; import java.util.Map; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.api - */ -@Deprecated public class UdfApi { private ApiClient localVarApiClient; private int localHostIndex; diff --git a/src/main/java/io/tiledb/cloud/rest_api/api/UserApi.java b/src/main/java/io/tiledb/cloud/rest_api/api/UserApi.java index c11dce9..e6abdcf 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/api/UserApi.java +++ b/src/main/java/io/tiledb/cloud/rest_api/api/UserApi.java @@ -37,10 +37,6 @@ import java.util.List; import java.util.Map; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.api - */ -@Deprecated public class UserApi { private ApiClient localVarApiClient; private int localHostIndex; diff --git a/src/main/java/io/tiledb/cloud/rest_api/auth/ApiKeyAuth.java b/src/main/java/io/tiledb/cloud/rest_api/auth/ApiKeyAuth.java index ed91a2f..0b12fd9 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/auth/ApiKeyAuth.java +++ b/src/main/java/io/tiledb/cloud/rest_api/auth/ApiKeyAuth.java @@ -20,10 +20,6 @@ import java.util.Map; import java.util.List; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.auth - */ -@Deprecated @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") public class ApiKeyAuth implements Authentication { private final String location; diff --git a/src/main/java/io/tiledb/cloud/rest_api/auth/Authentication.java b/src/main/java/io/tiledb/cloud/rest_api/auth/Authentication.java index bcd4733..f7face9 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/auth/Authentication.java +++ b/src/main/java/io/tiledb/cloud/rest_api/auth/Authentication.java @@ -20,10 +20,6 @@ import java.util.Map; import java.util.List; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.auth - */ -@Deprecated public interface Authentication { /** * Apply authentication settings to header and query params. diff --git a/src/main/java/io/tiledb/cloud/rest_api/auth/HttpBasicAuth.java b/src/main/java/io/tiledb/cloud/rest_api/auth/HttpBasicAuth.java index 8f132e2..fdf71ec 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/auth/HttpBasicAuth.java +++ b/src/main/java/io/tiledb/cloud/rest_api/auth/HttpBasicAuth.java @@ -22,10 +22,6 @@ import java.util.Map; import java.util.List; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.auth - */ -@Deprecated public class HttpBasicAuth implements Authentication { private String username; private String password; diff --git a/src/main/java/io/tiledb/cloud/rest_api/auth/HttpBearerAuth.java b/src/main/java/io/tiledb/cloud/rest_api/auth/HttpBearerAuth.java index 4d80b8a..5e79465 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/auth/HttpBearerAuth.java +++ b/src/main/java/io/tiledb/cloud/rest_api/auth/HttpBearerAuth.java @@ -20,10 +20,6 @@ import java.util.Map; import java.util.List; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.auth - */ -@Deprecated @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") public class HttpBearerAuth implements Authentication { private final String scheme; diff --git a/src/main/java/io/tiledb/cloud/rest_api/auth/OAuth.java b/src/main/java/io/tiledb/cloud/rest_api/auth/OAuth.java index 46401d7..8869cab 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/auth/OAuth.java +++ b/src/main/java/io/tiledb/cloud/rest_api/auth/OAuth.java @@ -20,10 +20,6 @@ import java.util.Map; import java.util.List; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.auth - */ -@Deprecated @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") public class OAuth implements Authentication { private String accessToken; diff --git a/src/main/java/io/tiledb/cloud/rest_api/auth/OAuthFlow.java b/src/main/java/io/tiledb/cloud/rest_api/auth/OAuthFlow.java index 32cb4e8..85a361f 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/auth/OAuthFlow.java +++ b/src/main/java/io/tiledb/cloud/rest_api/auth/OAuthFlow.java @@ -15,9 +15,7 @@ /** * OAuth flows that are supported by this client - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.auth */ -@Deprecated @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") public enum OAuthFlow { ACCESS_CODE, //called authorizationCode in OpenAPI 3.0 diff --git a/src/main/java/io/tiledb/cloud/rest_api/auth/OAuthOkHttpClient.java b/src/main/java/io/tiledb/cloud/rest_api/auth/OAuthOkHttpClient.java index ef11580..d50d3bc 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/auth/OAuthOkHttpClient.java +++ b/src/main/java/io/tiledb/cloud/rest_api/auth/OAuthOkHttpClient.java @@ -17,10 +17,6 @@ import java.util.Map; import java.util.Map.Entry; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.auth - */ -@Deprecated public class OAuthOkHttpClient implements HttpClient { private OkHttpClient client; diff --git a/src/main/java/io/tiledb/cloud/rest_api/auth/RetryingOAuth.java b/src/main/java/io/tiledb/cloud/rest_api/auth/RetryingOAuth.java index 05305c8..acfd332 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/auth/RetryingOAuth.java +++ b/src/main/java/io/tiledb/cloud/rest_api/auth/RetryingOAuth.java @@ -23,10 +23,6 @@ import java.util.Map; import java.util.List; -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.auth - */ -@Deprecated public class RetryingOAuth extends OAuth implements Interceptor { private OAuthClient oAuthClient; diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/AWSAccessCredentials.java b/src/main/java/io/tiledb/cloud/rest_api/model/AWSAccessCredentials.java index c154d6b..cfdb7a4 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/AWSAccessCredentials.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/AWSAccessCredentials.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "Model representing aws keys or service role, service roles are currently ignored, but will be preferred option in the future") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class AWSAccessCredentials { public static final String SERIALIZED_NAME_SECRET_ACCESS_KEY = "secret_access_key"; @SerializedName(SERIALIZED_NAME_SECRET_ACCESS_KEY) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/Array.java b/src/main/java/io/tiledb/cloud/rest_api/model/Array.java index 5b8bcd9..e6d1bc6 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/Array.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/Array.java @@ -41,10 +41,6 @@ */ @ApiModel(description = "Represents an open array") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class Array { public static final String SERIALIZED_NAME_TIMESTAMP = "timestamp"; @SerializedName(SERIALIZED_NAME_TIMESTAMP) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayActivityLog.java b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayActivityLog.java index cc8e4ee..55d283e 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayActivityLog.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayActivityLog.java @@ -41,10 +41,6 @@ */ @ApiModel(description = "Actvity of an Array") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class ArrayActivityLog { public static final String SERIALIZED_NAME_EVENT_AT = "event_at"; @SerializedName(SERIALIZED_NAME_EVENT_AT) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayBrowserData.java b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayBrowserData.java index 27e5f57..ce34a3b 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayBrowserData.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayBrowserData.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "Object including array info and pagination metadata") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class ArrayBrowserData { public static final String SERIALIZED_NAME_ARRAYS = "arrays"; @SerializedName(SERIALIZED_NAME_ARRAYS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayBrowserSidebar.java b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayBrowserSidebar.java index 0a32b26..79e83f4 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayBrowserSidebar.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayBrowserSidebar.java @@ -42,10 +42,6 @@ */ @ApiModel(description = "Object for ui array tasks browser page") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class ArrayBrowserSidebar { public static final String SERIALIZED_NAME_NAMESPACES = "namespaces"; @SerializedName(SERIALIZED_NAME_NAMESPACES) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayConsolidationRequest.java b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayConsolidationRequest.java index 9e523a4..e02cf61 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayConsolidationRequest.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayConsolidationRequest.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "Request to consolidate an array") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class ArrayConsolidationRequest { public static final String SERIALIZED_NAME_CONFIG = "config"; @SerializedName(SERIALIZED_NAME_CONFIG) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayEndTimestampData.java b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayEndTimestampData.java index 0e1870b..1eacdbc 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayEndTimestampData.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayEndTimestampData.java @@ -42,10 +42,6 @@ */ @ApiModel(description = "Object including array end_timestamps (list of Unix epoch timestamps in milliseconds) and pagination metadata") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class ArrayEndTimestampData { public static final String SERIALIZED_NAME_END_TIMESTAMPS = "end_timestamps"; @SerializedName(SERIALIZED_NAME_END_TIMESTAMPS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayFavorite.java b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayFavorite.java index 6f7725a..2ad4d03 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayFavorite.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayFavorite.java @@ -40,10 +40,7 @@ */ @ApiModel(description = "A user-favorite array item") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class ArrayFavorite { public static final String SERIALIZED_NAME_ARRAY_UUID = "array_uuid"; @SerializedName(SERIALIZED_NAME_ARRAY_UUID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayFavoritesData.java b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayFavoritesData.java index d5e74b5..62976de 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayFavoritesData.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayFavoritesData.java @@ -43,10 +43,6 @@ */ @ApiModel(description = "Object including array favorites and pagination metadata") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class ArrayFavoritesData { public static final String SERIALIZED_NAME_ARRAYS = "arrays"; @SerializedName(SERIALIZED_NAME_ARRAYS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayInfo.java b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayInfo.java index c98e1dc..4e1ff3d 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayInfo.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayInfo.java @@ -46,10 +46,6 @@ */ @ApiModel(description = "metadata of an array") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class ArrayInfo { public static final String SERIALIZED_NAME_ID = "id"; @SerializedName(SERIALIZED_NAME_ID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayInfoUpdate.java b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayInfoUpdate.java index 75afbda..7a70912 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayInfoUpdate.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayInfoUpdate.java @@ -43,10 +43,6 @@ */ @ApiModel(description = "metadata of an array") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class ArrayInfoUpdate { public static final String SERIALIZED_NAME_DESCRIPTION = "description"; @SerializedName(SERIALIZED_NAME_DESCRIPTION) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayMetadata.java b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayMetadata.java index 3aad282..defbdda 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayMetadata.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayMetadata.java @@ -43,10 +43,6 @@ */ @ApiModel(description = "user's TileDB array metadata") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class ArrayMetadata { public static final String SERIALIZED_NAME_ENTRIES = "entries"; @SerializedName(SERIALIZED_NAME_ENTRIES) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayMetadataEntry.java b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayMetadataEntry.java index d1e4fe2..fff00f8 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayMetadataEntry.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayMetadataEntry.java @@ -42,10 +42,7 @@ */ @ApiModel(description = "key/value pair representing an array metadata map entry") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class ArrayMetadataEntry { public static final String SERIALIZED_NAME_KEY = "key"; @SerializedName(SERIALIZED_NAME_KEY) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/ArraySample.java b/src/main/java/io/tiledb/cloud/rest_api/model/ArraySample.java index 2769199..4410f69 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/ArraySample.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/ArraySample.java @@ -40,10 +40,7 @@ */ @ApiModel(description = "Sample data from array") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class ArraySample { public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/ArraySchema.java b/src/main/java/io/tiledb/cloud/rest_api/model/ArraySchema.java index 91b11ce..ba710cb 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/ArraySchema.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/ArraySchema.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "ArraySchema during creation or retrieval") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class ArraySchema { public static final String SERIALIZED_NAME_URI = "uri"; @SerializedName(SERIALIZED_NAME_URI) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/ArraySharing.java b/src/main/java/io/tiledb/cloud/rest_api/model/ArraySharing.java index 895c942..699939a 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/ArraySharing.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/ArraySharing.java @@ -42,10 +42,6 @@ */ @ApiModel(description = "details for sharing a given array") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class ArraySharing { public static final String SERIALIZED_NAME_ACTIONS = "actions"; @SerializedName(SERIALIZED_NAME_ACTIONS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayTask.java b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayTask.java index 54bcde6..5bd1e78 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayTask.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayTask.java @@ -46,10 +46,6 @@ */ @ApiModel(description = "Synchronous Task to Run") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class ArrayTask { public static final String SERIALIZED_NAME_ID = "id"; @SerializedName(SERIALIZED_NAME_ID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayTaskBrowserSidebar.java b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayTaskBrowserSidebar.java index dd92148..f4d5e3a 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayTaskBrowserSidebar.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayTaskBrowserSidebar.java @@ -42,10 +42,6 @@ */ @ApiModel(description = "Object for ui array tasks browser page") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class ArrayTaskBrowserSidebar { public static final String SERIALIZED_NAME_ORGANIZATIONS = "organizations"; @SerializedName(SERIALIZED_NAME_ORGANIZATIONS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayTaskData.java b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayTaskData.java index b93386f..da3a4b9 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayTaskData.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayTaskData.java @@ -43,10 +43,6 @@ */ @ApiModel(description = "Object including array tasks and metadata") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class ArrayTaskData { public static final String SERIALIZED_NAME_ARRAY_TASKS = "array_tasks"; @SerializedName(SERIALIZED_NAME_ARRAY_TASKS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayTaskLog.java b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayTaskLog.java index 0a47f41..7e26d23 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayTaskLog.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayTaskLog.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "Array task stderr/stdout logs") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class ArrayTaskLog { public static final String SERIALIZED_NAME_ARRAY_TASK_ID = "array_task_id"; @SerializedName(SERIALIZED_NAME_ARRAY_TASK_ID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayVacuumRequest.java b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayVacuumRequest.java index 8c4f25a..b0dbffa 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/ArrayVacuumRequest.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/ArrayVacuumRequest.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "Request to consolidate an array") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class ArrayVacuumRequest { public static final String SERIALIZED_NAME_CONFIG = "config"; @SerializedName(SERIALIZED_NAME_CONFIG) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/AssetLocations.java b/src/main/java/io/tiledb/cloud/rest_api/model/AssetLocations.java index 9c0b4da..205ecf4 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/AssetLocations.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/AssetLocations.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "Custom storage locations on a per–asset type basis. If any is unset, a suffix of the owning (user/organization) `default_s3_path` is used. ") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class AssetLocations { public static final String SERIALIZED_NAME_ARRAYS = "arrays"; @SerializedName(SERIALIZED_NAME_ARRAYS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/Attribute.java b/src/main/java/io/tiledb/cloud/rest_api/model/Attribute.java index fe9abdf..a441375 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/Attribute.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/Attribute.java @@ -42,10 +42,6 @@ */ @ApiModel(description = "Attribute of array") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class Attribute { public static final String SERIALIZED_NAME_NAME = "name"; @SerializedName(SERIALIZED_NAME_NAME) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/AttributeBufferHeader.java b/src/main/java/io/tiledb/cloud/rest_api/model/AttributeBufferHeader.java index 1e0897d..796d0cf 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/AttributeBufferHeader.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/AttributeBufferHeader.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "Represents an attribute buffer header information") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class AttributeBufferHeader { public static final String SERIALIZED_NAME_NAME = "name"; @SerializedName(SERIALIZED_NAME_NAME) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/AttributeBufferSize.java b/src/main/java/io/tiledb/cloud/rest_api/model/AttributeBufferSize.java index ad3af3c..df7d41f 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/AttributeBufferSize.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/AttributeBufferSize.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "object representing buffer size of an attribute") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class AttributeBufferSize { public static final String SERIALIZED_NAME_ATTRIBUTE = "attribute"; @SerializedName(SERIALIZED_NAME_ATTRIBUTE) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/Backoff.java b/src/main/java/io/tiledb/cloud/rest_api/model/Backoff.java index 2097b4a..b479999 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/Backoff.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/Backoff.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "Backoff is a backoff strategy to use within retryStrategy") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class Backoff { public static final String SERIALIZED_NAME_DURATION = "duration"; @SerializedName(SERIALIZED_NAME_DURATION) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/Dimension.java b/src/main/java/io/tiledb/cloud/rest_api/model/Dimension.java index 30cbb8f..f59148b 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/Dimension.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/Dimension.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "Dimension of array") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class Dimension { public static final String SERIALIZED_NAME_NAME = "name"; @SerializedName(SERIALIZED_NAME_NAME) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/DimensionCoordinate.java b/src/main/java/io/tiledb/cloud/rest_api/model/DimensionCoordinate.java index 9f6d488..7011bd1 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/DimensionCoordinate.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/DimensionCoordinate.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "A single, typed coordinate for a dimension") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class DimensionCoordinate { public static final String SERIALIZED_NAME_INT8 = "int8"; @SerializedName(SERIALIZED_NAME_INT8) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/DimensionTileExtent.java b/src/main/java/io/tiledb/cloud/rest_api/model/DimensionTileExtent.java index 262cc7d..d2380df 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/DimensionTileExtent.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/DimensionTileExtent.java @@ -40,10 +40,7 @@ */ @ApiModel(description = "Extent of tile") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class DimensionTileExtent { public static final String SERIALIZED_NAME_INT8 = "int8"; @SerializedName(SERIALIZED_NAME_INT8) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/Domain.java b/src/main/java/io/tiledb/cloud/rest_api/model/Domain.java index 7d116df..d6b6a15 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/Domain.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/Domain.java @@ -43,10 +43,6 @@ */ @ApiModel(description = "Domain of array") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class Domain { public static final String SERIALIZED_NAME_TYPE = "type"; @SerializedName(SERIALIZED_NAME_TYPE) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/DomainArray.java b/src/main/java/io/tiledb/cloud/rest_api/model/DomainArray.java index 60ef825..864474a 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/DomainArray.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/DomainArray.java @@ -42,10 +42,6 @@ */ @ApiModel(description = "Domain object for an array of each type") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class DomainArray { public static final String SERIALIZED_NAME_INT8 = "int8"; @SerializedName(SERIALIZED_NAME_INT8) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/DomainCheckResult.java b/src/main/java/io/tiledb/cloud/rest_api/model/DomainCheckResult.java index aadc3ed..07d164f 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/DomainCheckResult.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/DomainCheckResult.java @@ -41,10 +41,6 @@ */ @ApiModel(description = "The record of a check of a single domain's status.") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class DomainCheckResult { public static final String SERIALIZED_NAME_TIME = "time"; @SerializedName(SERIALIZED_NAME_TIME) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/Error.java b/src/main/java/io/tiledb/cloud/rest_api/model/Error.java index fa18d2d..2189a99 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/Error.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/Error.java @@ -38,10 +38,6 @@ * Error */ @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class Error { public static final String SERIALIZED_NAME_CODE = "code"; @SerializedName(SERIALIZED_NAME_CODE) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/FileCreate.java b/src/main/java/io/tiledb/cloud/rest_api/model/FileCreate.java index e6eb008..146e8f0 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/FileCreate.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/FileCreate.java @@ -40,10 +40,7 @@ */ @ApiModel(description = "Input/Output information required to create a new file") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class FileCreate { public static final String SERIALIZED_NAME_INPUT_URI = "input_uri"; @SerializedName(SERIALIZED_NAME_INPUT_URI) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/FileCreated.java b/src/main/java/io/tiledb/cloud/rest_api/model/FileCreated.java index 9610721..e409d13 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/FileCreated.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/FileCreated.java @@ -40,10 +40,7 @@ */ @ApiModel(description = "Created file name and information") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class FileCreated { public static final String SERIALIZED_NAME_OUTPUT_URI = "output_uri"; @SerializedName(SERIALIZED_NAME_OUTPUT_URI) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/FileExport.java b/src/main/java/io/tiledb/cloud/rest_api/model/FileExport.java index b354d44..5dcc4bc 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/FileExport.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/FileExport.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "Output information required to export a file") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class FileExport { public static final String SERIALIZED_NAME_OUTPUT_URI = "output_uri"; @SerializedName(SERIALIZED_NAME_OUTPUT_URI) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/FileExported.java b/src/main/java/io/tiledb/cloud/rest_api/model/FileExported.java index a7948f8..427c35a 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/FileExported.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/FileExported.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "Output uri of the exported file") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class FileExported { public static final String SERIALIZED_NAME_OUTPUT_URI = "output_uri"; @SerializedName(SERIALIZED_NAME_OUTPUT_URI) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/FileUploaded.java b/src/main/java/io/tiledb/cloud/rest_api/model/FileUploaded.java index 2bfeb34..c77dcad 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/FileUploaded.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/FileUploaded.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "Uploaded file name and information") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class FileUploaded { public static final String SERIALIZED_NAME_OUTPUT_URI = "output_uri"; @SerializedName(SERIALIZED_NAME_OUTPUT_URI) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/Filter.java b/src/main/java/io/tiledb/cloud/rest_api/model/Filter.java index 8385c7a..f593eff 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/Filter.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/Filter.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "Filter") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class Filter { public static final String SERIALIZED_NAME_TYPE = "type"; @SerializedName(SERIALIZED_NAME_TYPE) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/FilterData.java b/src/main/java/io/tiledb/cloud/rest_api/model/FilterData.java index 3d452be..74efd6d 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/FilterData.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/FilterData.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "Filter data") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class FilterData { public static final String SERIALIZED_NAME_INT8 = "int8"; @SerializedName(SERIALIZED_NAME_INT8) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/FilterPipeline.java b/src/main/java/io/tiledb/cloud/rest_api/model/FilterPipeline.java index db9b19e..dc65bb1 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/FilterPipeline.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/FilterPipeline.java @@ -43,10 +43,6 @@ */ @ApiModel(description = "One or more filters to apply") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class FilterPipeline { public static final String SERIALIZED_NAME_FILTERS = "filters"; @SerializedName(SERIALIZED_NAME_FILTERS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/FragmentInfo.java b/src/main/java/io/tiledb/cloud/rest_api/model/FragmentInfo.java index b03ade5..31a51b0 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/FragmentInfo.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/FragmentInfo.java @@ -43,10 +43,6 @@ */ @ApiModel(description = "Fragment info of an array") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class FragmentInfo { public static final String SERIALIZED_NAME_ARRAY_SCHEMA_ALL = "arraySchemaAll"; @SerializedName(SERIALIZED_NAME_ARRAY_SCHEMA_ALL) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/FragmentInfoRequest.java b/src/main/java/io/tiledb/cloud/rest_api/model/FragmentInfoRequest.java index bb8489c..0bc0f1f 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/FragmentInfoRequest.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/FragmentInfoRequest.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "Fragment info request") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class FragmentInfoRequest { public static final String SERIALIZED_NAME_CONFIG = "config"; @SerializedName(SERIALIZED_NAME_CONFIG) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/FragmentMetadata.java b/src/main/java/io/tiledb/cloud/rest_api/model/FragmentMetadata.java index 0c8a0dc..7de1e32 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/FragmentMetadata.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/FragmentMetadata.java @@ -42,10 +42,6 @@ */ @ApiModel(description = "Fragment Metadata") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class FragmentMetadata { public static final String SERIALIZED_NAME_FILE_SIZES = "fileSizes"; @SerializedName(SERIALIZED_NAME_FILE_SIZES) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/GenericUDF.java b/src/main/java/io/tiledb/cloud/rest_api/model/GenericUDF.java index 0cfbf90..2642b82 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/GenericUDF.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/GenericUDF.java @@ -42,10 +42,6 @@ */ @ApiModel(description = "User-defined function") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class GenericUDF { public static final String SERIALIZED_NAME_UDF_INFO_NAME = "udf_info_name"; @SerializedName(SERIALIZED_NAME_UDF_INFO_NAME) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/GetTiledbStats200Response.java b/src/main/java/io/tiledb/cloud/rest_api/model/GetTiledbStats200Response.java index 6068959..7b9da9a 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/GetTiledbStats200Response.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/GetTiledbStats200Response.java @@ -38,10 +38,7 @@ * GetTiledbStats200Response */ @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class GetTiledbStats200Response { public static final String SERIALIZED_NAME_STATS = "stats"; @SerializedName(SERIALIZED_NAME_STATS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/GroupActivity.java b/src/main/java/io/tiledb/cloud/rest_api/model/GroupActivity.java index bb93fe7..2e121ce 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/GroupActivity.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/GroupActivity.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "Object containing activity of an asset of a group") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class GroupActivity { public static final String SERIALIZED_NAME_ASSET = "asset"; @SerializedName(SERIALIZED_NAME_ASSET) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/GroupActivityAsset.java b/src/main/java/io/tiledb/cloud/rest_api/model/GroupActivityAsset.java index 1768849..f4302a5 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/GroupActivityAsset.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/GroupActivityAsset.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "The asset details") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class GroupActivityAsset { public static final String SERIALIZED_NAME_ID = "id"; @SerializedName(SERIALIZED_NAME_ID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/GroupActivityResponse.java b/src/main/java/io/tiledb/cloud/rest_api/model/GroupActivityResponse.java index 8e9e72e..8cd3c58 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/GroupActivityResponse.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/GroupActivityResponse.java @@ -43,10 +43,6 @@ */ @ApiModel(description = "Object containing activity logs of group content along with the pagination metadata") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class GroupActivityResponse { public static final String SERIALIZED_NAME_ACTIVITY = "activity"; @SerializedName(SERIALIZED_NAME_ACTIVITY) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/GroupBrowserData.java b/src/main/java/io/tiledb/cloud/rest_api/model/GroupBrowserData.java index 4705724..a1f7649 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/GroupBrowserData.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/GroupBrowserData.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "Object including group info and pagination metadata") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class GroupBrowserData { public static final String SERIALIZED_NAME_GROUPS = "groups"; @SerializedName(SERIALIZED_NAME_GROUPS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/GroupBrowserFilterData.java b/src/main/java/io/tiledb/cloud/rest_api/model/GroupBrowserFilterData.java index 88141a5..336fea5 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/GroupBrowserFilterData.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/GroupBrowserFilterData.java @@ -42,10 +42,7 @@ */ @ApiModel(description = "Object with data to fill browser filter") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class GroupBrowserFilterData { public static final String SERIALIZED_NAME_NAMESPACES = "namespaces"; @SerializedName(SERIALIZED_NAME_NAMESPACES) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/GroupChanges.java b/src/main/java/io/tiledb/cloud/rest_api/model/GroupChanges.java index 05f2740..d78ff41 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/GroupChanges.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/GroupChanges.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "A request to change the members of a group. Contains assets to add or remove.") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class GroupChanges { public static final String SERIALIZED_NAME_ADD = "add"; @SerializedName(SERIALIZED_NAME_ADD) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/GroupContents.java b/src/main/java/io/tiledb/cloud/rest_api/model/GroupContents.java index ffc0785..8edd821 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/GroupContents.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/GroupContents.java @@ -43,10 +43,6 @@ */ @ApiModel(description = "Object including a page of members of a group and pagination metadata") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class GroupContents { public static final String SERIALIZED_NAME_ENTRIES = "entries"; @SerializedName(SERIALIZED_NAME_ENTRIES) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/GroupContentsFilterData.java b/src/main/java/io/tiledb/cloud/rest_api/model/GroupContentsFilterData.java index 57e4fb1..2c2c072 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/GroupContentsFilterData.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/GroupContentsFilterData.java @@ -42,10 +42,6 @@ */ @ApiModel(description = "Object with data to fill contents filter") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class GroupContentsFilterData { public static final String SERIALIZED_NAME_NAMESPACES = "namespaces"; @SerializedName(SERIALIZED_NAME_NAMESPACES) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/GroupCreate.java b/src/main/java/io/tiledb/cloud/rest_api/model/GroupCreate.java index 8d0843a..f10112b 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/GroupCreate.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/GroupCreate.java @@ -42,10 +42,6 @@ */ @ApiModel(description = "Initial attributes for the creation of a group.") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class GroupCreate { public static final String SERIALIZED_NAME_DESCRIPTION = "description"; @SerializedName(SERIALIZED_NAME_DESCRIPTION) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/GroupEntry.java b/src/main/java/io/tiledb/cloud/rest_api/model/GroupEntry.java index da44de8..9c9e8b3 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/GroupEntry.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/GroupEntry.java @@ -40,10 +40,7 @@ */ @ApiModel(description = "Object describing a single member of a group, which can be an array or a group") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class GroupEntry { public static final String SERIALIZED_NAME_MEMBER_ID = "member_id"; @SerializedName(SERIALIZED_NAME_MEMBER_ID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/GroupInfo.java b/src/main/java/io/tiledb/cloud/rest_api/model/GroupInfo.java index f38e7af..13f5d45 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/GroupInfo.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/GroupInfo.java @@ -45,10 +45,6 @@ */ @ApiModel(description = "metadata of a group") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class GroupInfo { public static final String SERIALIZED_NAME_ID = "id"; @SerializedName(SERIALIZED_NAME_ID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/GroupMember.java b/src/main/java/io/tiledb/cloud/rest_api/model/GroupMember.java index 7462e30..df2b9b1 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/GroupMember.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/GroupMember.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "A groups member, array or another groups, to add or remove from an existing group.") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class GroupMember { public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; @SerializedName(SERIALIZED_NAME_NAMESPACE) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/GroupRegister.java b/src/main/java/io/tiledb/cloud/rest_api/model/GroupRegister.java index e0bbb04..cb9e953 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/GroupRegister.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/GroupRegister.java @@ -42,10 +42,6 @@ */ @ApiModel(description = "Initial attributes for the registration of a an existing group.") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class GroupRegister { public static final String SERIALIZED_NAME_DESCRIPTION = "description"; @SerializedName(SERIALIZED_NAME_DESCRIPTION) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/GroupSharing.java b/src/main/java/io/tiledb/cloud/rest_api/model/GroupSharing.java index 704d6ca..731ac3a 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/GroupSharing.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/GroupSharing.java @@ -42,10 +42,6 @@ */ @ApiModel(description = "sharing state of a group with a namespace") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class GroupSharing { public static final String SERIALIZED_NAME_GROUP_ACTIONS = "group_actions"; @SerializedName(SERIALIZED_NAME_GROUP_ACTIONS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/GroupSharingRequest.java b/src/main/java/io/tiledb/cloud/rest_api/model/GroupSharingRequest.java index 2e90343..c5b8d56 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/GroupSharingRequest.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/GroupSharingRequest.java @@ -42,10 +42,6 @@ */ @ApiModel(description = "a request to share a group and all the contents with a namespace") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class GroupSharingRequest { public static final String SERIALIZED_NAME_GROUP_ACTIONS = "group_actions"; @SerializedName(SERIALIZED_NAME_GROUP_ACTIONS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/GroupUpdate.java b/src/main/java/io/tiledb/cloud/rest_api/model/GroupUpdate.java index 9f35b9c..1b4c4a1 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/GroupUpdate.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/GroupUpdate.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "Updates for a group. New values for the attributes.") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class GroupUpdate { public static final String SERIALIZED_NAME_DESCRIPTION = "description"; @SerializedName(SERIALIZED_NAME_DESCRIPTION) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/Invitation.java b/src/main/java/io/tiledb/cloud/rest_api/model/Invitation.java index d9b6b6f..84e3a0e 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/Invitation.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/Invitation.java @@ -41,10 +41,6 @@ */ @ApiModel(description = "Invitations to share or collaborate") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class Invitation { public static final String SERIALIZED_NAME_ID = "id"; @SerializedName(SERIALIZED_NAME_ID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/InvitationArrayShareEmail.java b/src/main/java/io/tiledb/cloud/rest_api/model/InvitationArrayShareEmail.java index 0bbc521..ab800d2 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/InvitationArrayShareEmail.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/InvitationArrayShareEmail.java @@ -42,10 +42,6 @@ */ @ApiModel(description = "Encapsulates information regarding inviting people using email to share array, same permissions for all invitees") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class InvitationArrayShareEmail { public static final String SERIALIZED_NAME_ACTIONS = "actions"; @SerializedName(SERIALIZED_NAME_ACTIONS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/InvitationData.java b/src/main/java/io/tiledb/cloud/rest_api/model/InvitationData.java index 93414e6..aa30c70 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/InvitationData.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/InvitationData.java @@ -43,10 +43,6 @@ */ @ApiModel(description = "Object including invitations and metadata") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class InvitationData { public static final String SERIALIZED_NAME_INVITATIONS = "invitations"; @SerializedName(SERIALIZED_NAME_INVITATIONS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/InvitationFailedRecipients.java b/src/main/java/io/tiledb/cloud/rest_api/model/InvitationFailedRecipients.java index a822bba..caff6b6 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/InvitationFailedRecipients.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/InvitationFailedRecipients.java @@ -42,10 +42,6 @@ */ @ApiModel(description = "Encapsulates information regarding the failed invitation recipients") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class InvitationFailedRecipients { public static final String SERIALIZED_NAME_FAILED_RECIPIENTS = "failed_recipients"; @SerializedName(SERIALIZED_NAME_FAILED_RECIPIENTS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/InvitationGroupShareEmail.java b/src/main/java/io/tiledb/cloud/rest_api/model/InvitationGroupShareEmail.java index aeedc4b..946f4db 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/InvitationGroupShareEmail.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/InvitationGroupShareEmail.java @@ -42,10 +42,6 @@ */ @ApiModel(description = "Encapsulates information regarding inviting people using email to share group, same permissions for all invitees") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class InvitationGroupShareEmail { public static final String SERIALIZED_NAME_ARRAY_ACTIONS = "array_actions"; @SerializedName(SERIALIZED_NAME_ARRAY_ACTIONS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/InvitationOrganizationJoinEmail.java b/src/main/java/io/tiledb/cloud/rest_api/model/InvitationOrganizationJoinEmail.java index 1f6250f..db83662 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/InvitationOrganizationJoinEmail.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/InvitationOrganizationJoinEmail.java @@ -42,10 +42,7 @@ */ @ApiModel(description = "Encapsulates information regarding inviting people using email to join organization, same permissions for all invitees") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class InvitationOrganizationJoinEmail { public static final String SERIALIZED_NAME_ACTIONS = "actions"; @SerializedName(SERIALIZED_NAME_ACTIONS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/LastAccessedArray.java b/src/main/java/io/tiledb/cloud/rest_api/model/LastAccessedArray.java index 22cc9e8..f538f94 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/LastAccessedArray.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/LastAccessedArray.java @@ -41,10 +41,6 @@ */ @ApiModel(description = "Information related to last access of an array") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class LastAccessedArray { public static final String SERIALIZED_NAME_ARRAY_ID = "array_id"; @SerializedName(SERIALIZED_NAME_ARRAY_ID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/MLModelFavorite.java b/src/main/java/io/tiledb/cloud/rest_api/model/MLModelFavorite.java index fb47a26..b2e1648 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/MLModelFavorite.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/MLModelFavorite.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "A user-favorite MLModel item") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class MLModelFavorite { public static final String SERIALIZED_NAME_MLMODEL_UUID = "mlmodel_uuid"; @SerializedName(SERIALIZED_NAME_MLMODEL_UUID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/MLModelFavoritesData.java b/src/main/java/io/tiledb/cloud/rest_api/model/MLModelFavoritesData.java index f7ce887..d17853c 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/MLModelFavoritesData.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/MLModelFavoritesData.java @@ -43,10 +43,6 @@ */ @ApiModel(description = "Object including MLModel favorites and pagination metadata") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class MLModelFavoritesData { public static final String SERIALIZED_NAME_MLMODELS = "mlmodels"; @SerializedName(SERIALIZED_NAME_MLMODELS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/MaxBufferSizes.java b/src/main/java/io/tiledb/cloud/rest_api/model/MaxBufferSizes.java index d916681..e82a328 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/MaxBufferSizes.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/MaxBufferSizes.java @@ -43,10 +43,6 @@ */ @ApiModel(description = "a list of max buffer sizes, one per attribute") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class MaxBufferSizes { public static final String SERIALIZED_NAME_MAX_BUFFER_SIZES = "maxBufferSizes"; @SerializedName(SERIALIZED_NAME_MAX_BUFFER_SIZES) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/MultiArrayUDF.java b/src/main/java/io/tiledb/cloud/rest_api/model/MultiArrayUDF.java index cf6655d..4f31df8 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/MultiArrayUDF.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/MultiArrayUDF.java @@ -44,10 +44,7 @@ */ @ApiModel(description = "User-defined function") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class MultiArrayUDF { public static final String SERIALIZED_NAME_UDF_INFO_NAME = "udf_info_name"; @SerializedName(SERIALIZED_NAME_UDF_INFO_NAME) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/NonEmptyDomain.java b/src/main/java/io/tiledb/cloud/rest_api/model/NonEmptyDomain.java index f43e8d4..eec5a32 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/NonEmptyDomain.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/NonEmptyDomain.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "object representing a non-empty domain") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class NonEmptyDomain { public static final String SERIALIZED_NAME_NON_EMPTY_DOMAIN = "nonEmptyDomain"; @SerializedName(SERIALIZED_NAME_NON_EMPTY_DOMAIN) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/NotebookCopied.java b/src/main/java/io/tiledb/cloud/rest_api/model/NotebookCopied.java index 1efa26d..dedf556 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/NotebookCopied.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/NotebookCopied.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "Copied notebook uri and information") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class NotebookCopied { public static final String SERIALIZED_NAME_OUTPUT_URI = "output_uri"; @SerializedName(SERIALIZED_NAME_OUTPUT_URI) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/NotebookCopy.java b/src/main/java/io/tiledb/cloud/rest_api/model/NotebookCopy.java index 3764d42..069be7f 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/NotebookCopy.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/NotebookCopy.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "Output information required to copy a notebook") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class NotebookCopy { public static final String SERIALIZED_NAME_OUTPUT_URI = "output_uri"; @SerializedName(SERIALIZED_NAME_OUTPUT_URI) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/NotebookFavorite.java b/src/main/java/io/tiledb/cloud/rest_api/model/NotebookFavorite.java index 85ac80c..3523de4 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/NotebookFavorite.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/NotebookFavorite.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "A user-favorite notebook item") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class NotebookFavorite { public static final String SERIALIZED_NAME_NOTEBOOK_UUID = "notebook_uuid"; @SerializedName(SERIALIZED_NAME_NOTEBOOK_UUID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/NotebookFavoritesData.java b/src/main/java/io/tiledb/cloud/rest_api/model/NotebookFavoritesData.java index 990cdf8..e31b860 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/NotebookFavoritesData.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/NotebookFavoritesData.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "Object including notebook favorites and pagination metadata") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class NotebookFavoritesData { public static final String SERIALIZED_NAME_NOTEBOOKS = "notebooks"; @SerializedName(SERIALIZED_NAME_NOTEBOOKS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/NotebookStatus.java b/src/main/java/io/tiledb/cloud/rest_api/model/NotebookStatus.java index d5e3a9c..8a9f708 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/NotebookStatus.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/NotebookStatus.java @@ -41,10 +41,6 @@ */ @ApiModel(description = "Status details of a notebook server") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class NotebookStatus { public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; @SerializedName(SERIALIZED_NAME_NAMESPACE) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/Organization.java b/src/main/java/io/tiledb/cloud/rest_api/model/Organization.java index b146213..5837ce6 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/Organization.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/Organization.java @@ -46,10 +46,7 @@ */ @ApiModel(description = "Organization") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class Organization { public static final String SERIALIZED_NAME_ID = "id"; @SerializedName(SERIALIZED_NAME_ID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/OrganizationUser.java b/src/main/java/io/tiledb/cloud/rest_api/model/OrganizationUser.java index 5719b16..f1ed197 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/OrganizationUser.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/OrganizationUser.java @@ -42,10 +42,6 @@ */ @ApiModel(description = "user in an organization") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class OrganizationUser { public static final String SERIALIZED_NAME_USER_ID = "user_id"; @SerializedName(SERIALIZED_NAME_USER_ID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/PaginationMetadata.java b/src/main/java/io/tiledb/cloud/rest_api/model/PaginationMetadata.java index 2847f40..ac60f87 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/PaginationMetadata.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/PaginationMetadata.java @@ -39,10 +39,6 @@ * PaginationMetadata */ @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class PaginationMetadata { public static final String SERIALIZED_NAME_PAGE = "page"; @SerializedName(SERIALIZED_NAME_PAGE) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/Pricing.java b/src/main/java/io/tiledb/cloud/rest_api/model/Pricing.java index a414b5d..91b5ca8 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/Pricing.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/Pricing.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "Pricing created by converting an array to product") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class Pricing { public static final String SERIALIZED_NAME_ID = "id"; @SerializedName(SERIALIZED_NAME_ID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/Query.java b/src/main/java/io/tiledb/cloud/rest_api/model/Query.java index 2409038..3040526 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/Query.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/Query.java @@ -41,10 +41,7 @@ * Query */ @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class Query { public static final String SERIALIZED_NAME_TYPE = "type"; @SerializedName(SERIALIZED_NAME_TYPE) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/QueryJson.java b/src/main/java/io/tiledb/cloud/rest_api/model/QueryJson.java index d5d08b6..824c792 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/QueryJson.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/QueryJson.java @@ -42,10 +42,7 @@ */ @ApiModel(description = "Query returning results as JSON") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class QueryJson { public static final String SERIALIZED_NAME_QUERY_RANGES = "query_ranges"; @SerializedName(SERIALIZED_NAME_QUERY_RANGES) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/QueryRanges.java b/src/main/java/io/tiledb/cloud/rest_api/model/QueryRanges.java index 3ea5668..dd96261 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/QueryRanges.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/QueryRanges.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "Subarray bounds to query") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class QueryRanges { public static final String SERIALIZED_NAME_LAYOUT = "layout"; @SerializedName(SERIALIZED_NAME_LAYOUT) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/QueryReader.java b/src/main/java/io/tiledb/cloud/rest_api/model/QueryReader.java index 74d7b4b..932117c 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/QueryReader.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/QueryReader.java @@ -40,10 +40,7 @@ */ @ApiModel(description = "Read struct (can't be called reader due to class name conflict)") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class QueryReader { public static final String SERIALIZED_NAME_LAYOUT = "layout"; @SerializedName(SERIALIZED_NAME_LAYOUT) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/ReadState.java b/src/main/java/io/tiledb/cloud/rest_api/model/ReadState.java index 23e1237..b4daaea 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/ReadState.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/ReadState.java @@ -40,10 +40,7 @@ */ @ApiModel(description = "state for reads") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class ReadState { public static final String SERIALIZED_NAME_INITIALIZED = "initialized"; @SerializedName(SERIALIZED_NAME_INITIALIZED) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/RegisteredTaskGraph.java b/src/main/java/io/tiledb/cloud/rest_api/model/RegisteredTaskGraph.java index 6da865e..8a9dc4b 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/RegisteredTaskGraph.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/RegisteredTaskGraph.java @@ -44,10 +44,7 @@ */ @ApiModel(description = "The structure and metadata of a task graph that can be stored on TileDB Cloud and executed by users who have access to it. ") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class RegisteredTaskGraph { public static final String SERIALIZED_NAME_UUID = "uuid"; @SerializedName(SERIALIZED_NAME_UUID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/ResetUserPasswordRequest.java b/src/main/java/io/tiledb/cloud/rest_api/model/ResetUserPasswordRequest.java index 8a3b1df..9fd739e 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/ResetUserPasswordRequest.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/ResetUserPasswordRequest.java @@ -40,10 +40,7 @@ */ @ApiModel(description = "Password to update") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class ResetUserPasswordRequest { public static final String SERIALIZED_NAME_PASSWORD = "password"; @SerializedName(SERIALIZED_NAME_PASSWORD) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/RetryStrategy.java b/src/main/java/io/tiledb/cloud/rest_api/model/RetryStrategy.java index 9e62dc6..6e8d937 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/RetryStrategy.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/RetryStrategy.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "RetryStrategy provides controls on how to retry a taskgraph node") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class RetryStrategy { public static final String SERIALIZED_NAME_BACKOFF = "backoff"; @SerializedName(SERIALIZED_NAME_BACKOFF) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/SQLParameters.java b/src/main/java/io/tiledb/cloud/rest_api/model/SQLParameters.java index 642fb74..75ae1e7 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/SQLParameters.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/SQLParameters.java @@ -42,10 +42,7 @@ */ @ApiModel(description = "Parameters for running sql query") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class SQLParameters { public static final String SERIALIZED_NAME_NAME = "name"; @SerializedName(SERIALIZED_NAME_NAME) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/SSODomainConfig.java b/src/main/java/io/tiledb/cloud/rest_api/model/SSODomainConfig.java index 96c342c..2aa1220 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/SSODomainConfig.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/SSODomainConfig.java @@ -45,10 +45,7 @@ */ @ApiModel(description = "The information used to set up a single-sign on connection to a customer domain. ") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class SSODomainConfig { public static final String SERIALIZED_NAME_UUID = "uuid"; @SerializedName(SERIALIZED_NAME_UUID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/SSODomainConfigResponse.java b/src/main/java/io/tiledb/cloud/rest_api/model/SSODomainConfigResponse.java index a5bfc18..52259f7 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/SSODomainConfigResponse.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/SSODomainConfigResponse.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "The response to a request for the list of domain claims associated with a particular organization. ") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class SSODomainConfigResponse { public static final String SERIALIZED_NAME_DOMAIN_CONFIGS = "domain_configs"; @SerializedName(SERIALIZED_NAME_DOMAIN_CONFIGS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/SSODomainSetup.java b/src/main/java/io/tiledb/cloud/rest_api/model/SSODomainSetup.java index d87e968..d0f4d4c 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/SSODomainSetup.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/SSODomainSetup.java @@ -40,10 +40,7 @@ */ @ApiModel(description = "Configuration settings to verify ownership of a given domain. At least one of these must be completed enable user login from the domain. ") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class SSODomainSetup { public static final String SERIALIZED_NAME_TXT = "txt"; @SerializedName(SERIALIZED_NAME_TXT) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/SingleFragmentInfo.java b/src/main/java/io/tiledb/cloud/rest_api/model/SingleFragmentInfo.java index b0d6ff3..7ee92f2 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/SingleFragmentInfo.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/SingleFragmentInfo.java @@ -40,10 +40,7 @@ */ @ApiModel(description = "Single Fragment info of an array") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class SingleFragmentInfo { public static final String SERIALIZED_NAME_ARRAY_SCHEMA_NAME = "ArraySchemaName"; @SerializedName(SERIALIZED_NAME_ARRAY_SCHEMA_NAME) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/StorageLocation.java b/src/main/java/io/tiledb/cloud/rest_api/model/StorageLocation.java index eab18f9..ac0ec01 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/StorageLocation.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/StorageLocation.java @@ -41,10 +41,7 @@ */ @ApiModel(description = "The path at which a given asset will be stored, and the credentials used to access that asset. ") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class StorageLocation { public static final String SERIALIZED_NAME_PATH = "path"; @SerializedName(SERIALIZED_NAME_PATH) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/Subarray.java b/src/main/java/io/tiledb/cloud/rest_api/model/Subarray.java index 21dc401..627f307 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/Subarray.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/Subarray.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "A Subarray") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class Subarray { public static final String SERIALIZED_NAME_LAYOUT = "layout"; @SerializedName(SERIALIZED_NAME_LAYOUT) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/SubarrayPartitioner.java b/src/main/java/io/tiledb/cloud/rest_api/model/SubarrayPartitioner.java index 991df0a..45b3a74 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/SubarrayPartitioner.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/SubarrayPartitioner.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "The subarray partitioner") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class SubarrayPartitioner { public static final String SERIALIZED_NAME_SUBARRAY = "subarray"; @SerializedName(SERIALIZED_NAME_SUBARRAY) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/SubarrayPartitionerCurrent.java b/src/main/java/io/tiledb/cloud/rest_api/model/SubarrayPartitionerCurrent.java index 004319a..bcc0725 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/SubarrayPartitionerCurrent.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/SubarrayPartitionerCurrent.java @@ -40,10 +40,7 @@ */ @ApiModel(description = "The current partition info") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class SubarrayPartitionerCurrent { public static final String SERIALIZED_NAME_SUBARRAY = "subarray"; @SerializedName(SERIALIZED_NAME_SUBARRAY) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/SubarrayPartitionerState.java b/src/main/java/io/tiledb/cloud/rest_api/model/SubarrayPartitionerState.java index 0c9b187..13ced4d 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/SubarrayPartitionerState.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/SubarrayPartitionerState.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "The state information for the remaining partitions to be produced") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class SubarrayPartitionerState { public static final String SERIALIZED_NAME_START = "start"; @SerializedName(SERIALIZED_NAME_START) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/SubarrayRanges.java b/src/main/java/io/tiledb/cloud/rest_api/model/SubarrayRanges.java index df525a4..ce5aff3 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/SubarrayRanges.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/SubarrayRanges.java @@ -42,10 +42,7 @@ */ @ApiModel(description = "A set of 1D ranges for a subarray") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class SubarrayRanges { public static final String SERIALIZED_NAME_TYPE = "type"; @SerializedName(SERIALIZED_NAME_TYPE) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/Subscription.java b/src/main/java/io/tiledb/cloud/rest_api/model/Subscription.java index b77e170..1463005 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/Subscription.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/Subscription.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "Subscription of a user (customer) to another user's arrays") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class Subscription { public static final String SERIALIZED_NAME_ID = "id"; @SerializedName(SERIALIZED_NAME_ID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/TGArrayNodeData.java b/src/main/java/io/tiledb/cloud/rest_api/model/TGArrayNodeData.java index 8f7eeb9..6a9eb9e 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/TGArrayNodeData.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/TGArrayNodeData.java @@ -40,10 +40,7 @@ */ @ApiModel(description = "The details of an array that should be queried and provided as the input to a UDF Node. This is essentially a `UDFArrayDetails`, but you’re allowed to provide most of the values as Nodes if you want. ") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class TGArrayNodeData { public static final String SERIALIZED_NAME_URI = "uri"; @SerializedName(SERIALIZED_NAME_URI) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/TGInputNodeData.java b/src/main/java/io/tiledb/cloud/rest_api/model/TGInputNodeData.java index d8019c0..73c28c4 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/TGInputNodeData.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/TGInputNodeData.java @@ -41,10 +41,7 @@ */ @ApiModel(description = "Specifies that a node is an “input value”, allowing for parameterized task graphs. An input node may not depend upon any other nodes. ") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class TGInputNodeData { public static final String SERIALIZED_NAME_DEFAULT_VALUE = "default_value"; @SerializedName(SERIALIZED_NAME_DEFAULT_VALUE) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/TGQueryRanges.java b/src/main/java/io/tiledb/cloud/rest_api/model/TGQueryRanges.java index 8e5c75e..3738a69 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/TGQueryRanges.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/TGQueryRanges.java @@ -40,10 +40,6 @@ */ @ApiModel(description = "Parameterizable version of `QueryRanges`.") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated public class TGQueryRanges { public static final String SERIALIZED_NAME_LAYOUT = "layout"; @SerializedName(SERIALIZED_NAME_LAYOUT) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/TGSQLNodeData.java b/src/main/java/io/tiledb/cloud/rest_api/model/TGSQLNodeData.java index d8ce81b..0c100b0 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/TGSQLNodeData.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/TGSQLNodeData.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "A node specifying an SQL query to execute in TileDB Cloud. ") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class TGSQLNodeData { public static final String SERIALIZED_NAME_INIT_COMMANDS = "init_commands"; @SerializedName(SERIALIZED_NAME_INIT_COMMANDS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/TGUDFArgument.java b/src/main/java/io/tiledb/cloud/rest_api/model/TGUDFArgument.java index 5a5b708..5ee6ce5 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/TGUDFArgument.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/TGUDFArgument.java @@ -41,10 +41,7 @@ */ @ApiModel(description = "A single argument to a UDF. This may represent a positional argument or a named argument, depending upon whether `name` is set. ") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class TGUDFArgument { public static final String SERIALIZED_NAME_NAME = "name"; @SerializedName(SERIALIZED_NAME_NAME) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/TGUDFEnvironment.java b/src/main/java/io/tiledb/cloud/rest_api/model/TGUDFEnvironment.java index a3f8ab7..7b0a305 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/TGUDFEnvironment.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/TGUDFEnvironment.java @@ -42,10 +42,7 @@ */ @ApiModel(description = "Metadata about the environment where we want to execute a UDF.") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class TGUDFEnvironment { public static final String SERIALIZED_NAME_LANGUAGE = "language"; @SerializedName(SERIALIZED_NAME_LANGUAGE) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/TGUDFEnvironmentResources.java b/src/main/java/io/tiledb/cloud/rest_api/model/TGUDFEnvironmentResources.java index 6740066..07233d7 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/TGUDFEnvironmentResources.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/TGUDFEnvironmentResources.java @@ -40,10 +40,7 @@ */ @ApiModel(description = "The resources requested for this particular node. If resources are not specified resource_class is used, if it is not set the standard resource // defaults are used ") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class TGUDFEnvironmentResources { public static final String SERIALIZED_NAME_CPU = "cpu"; @SerializedName(SERIALIZED_NAME_CPU) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/TGUDFNodeData.java b/src/main/java/io/tiledb/cloud/rest_api/model/TGUDFNodeData.java index b70e006..983fb76 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/TGUDFNodeData.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/TGUDFNodeData.java @@ -44,10 +44,7 @@ */ @ApiModel(description = "A node specifying the execution of a user-defined function.") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class TGUDFNodeData { public static final String SERIALIZED_NAME_REGISTERED_UDF_NAME = "registered_udf_name"; @SerializedName(SERIALIZED_NAME_REGISTERED_UDF_NAME) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraph.java b/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraph.java index d17a57d..c5241a1 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraph.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraph.java @@ -45,10 +45,7 @@ */ @ApiModel(description = "Information about a task graph.") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class TaskGraph { public static final String SERIALIZED_NAME_UUID = "uuid"; @SerializedName(SERIALIZED_NAME_UUID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphClientNodeStatus.java b/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphClientNodeStatus.java index 624fa65..e443a0f 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphClientNodeStatus.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphClientNodeStatus.java @@ -40,10 +40,7 @@ */ @ApiModel(description = "A report of the execution status of a node that ran on the client side. ") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class TaskGraphClientNodeStatus { public static final String SERIALIZED_NAME_CLIENT_NODE_UUID = "client_node_uuid"; @SerializedName(SERIALIZED_NAME_CLIENT_NODE_UUID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphLog.java b/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphLog.java index 1ed3d05..f3579f9 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphLog.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphLog.java @@ -47,10 +47,7 @@ */ @ApiModel(description = "Logging information about the execution of a task graph.") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class TaskGraphLog { public static final String SERIALIZED_NAME_UUID = "uuid"; @SerializedName(SERIALIZED_NAME_UUID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphLogsData.java b/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphLogsData.java index 406fa68..a5e519a 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphLogsData.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphLogsData.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "Response data for a task graph list, including pagination metadata.") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class TaskGraphLogsData { public static final String SERIALIZED_NAME_TASK_GRAPH_LOGS = "task_graph_logs"; @SerializedName(SERIALIZED_NAME_TASK_GRAPH_LOGS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphNode.java b/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphNode.java index 2591472..c8d68b9 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphNode.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphNode.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "Information about a single node within a registered task graph. A single node represents one piece of data or a computational step; either as an input value, a data source, or a computation that acts upon earlier nodes. The structure parallels the existing `TaskGraphNodeMetadata`. ") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class TaskGraphNode { public static final String SERIALIZED_NAME_CLIENT_NODE_ID = "client_node_id"; @SerializedName(SERIALIZED_NAME_CLIENT_NODE_ID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphNodeMetadata.java b/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphNodeMetadata.java index e1bbf0e..3ed4672 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphNodeMetadata.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphNodeMetadata.java @@ -45,10 +45,7 @@ */ @ApiModel(description = "Metadata about an individual node in a task graph.") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class TaskGraphNodeMetadata { public static final String SERIALIZED_NAME_CLIENT_NODE_UUID = "client_node_uuid"; @SerializedName(SERIALIZED_NAME_CLIENT_NODE_UUID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphSharing.java b/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphSharing.java index 3ef4386..0f243d3 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphSharing.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphSharing.java @@ -42,10 +42,7 @@ */ @ApiModel(description = "details for sharing a given registered task graph") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class TaskGraphSharing { public static final String SERIALIZED_NAME_ACTIONS = "actions"; @SerializedName(SERIALIZED_NAME_ACTIONS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphs.java b/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphs.java index 1df1dc5..1699690 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphs.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/TaskGraphs.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "Information about a series of task graphs.") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class TaskGraphs { public static final String SERIALIZED_NAME_GRAPHS = "graphs"; @SerializedName(SERIALIZED_NAME_GRAPHS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/TileDBConfig.java b/src/main/java/io/tiledb/cloud/rest_api/model/TileDBConfig.java index 72f55c2..8416228 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/TileDBConfig.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/TileDBConfig.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "TileDB config used for interaction with the embedded library") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class TileDBConfig { public static final String SERIALIZED_NAME_ENTRIES = "entries"; @SerializedName(SERIALIZED_NAME_ENTRIES) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/TileDBConfigEntriesInner.java b/src/main/java/io/tiledb/cloud/rest_api/model/TileDBConfigEntriesInner.java index 5cb9507..8c5333f 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/TileDBConfigEntriesInner.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/TileDBConfigEntriesInner.java @@ -38,10 +38,7 @@ * TileDBConfigEntriesInner */ @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class TileDBConfigEntriesInner { public static final String SERIALIZED_NAME_KEY = "key"; @SerializedName(SERIALIZED_NAME_KEY) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/Token.java b/src/main/java/io/tiledb/cloud/rest_api/model/Token.java index 1f841bb..5d4fadf 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/Token.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/Token.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "A api token and its metadata") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class Token { public static final String SERIALIZED_NAME_TOKEN = "token"; @SerializedName(SERIALIZED_NAME_TOKEN) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/TokenRequest.java b/src/main/java/io/tiledb/cloud/rest_api/model/TokenRequest.java index b87059b..e623046 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/TokenRequest.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/TokenRequest.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "A request from a user for an api token") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class TokenRequest { public static final String SERIALIZED_NAME_EXPIRES = "expires"; @SerializedName(SERIALIZED_NAME_EXPIRES) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/UDFArrayDetails.java b/src/main/java/io/tiledb/cloud/rest_api/model/UDFArrayDetails.java index 0b20d9e..976b048 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/UDFArrayDetails.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/UDFArrayDetails.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "Contains array details for multi-array query including uri, ranges buffers") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class UDFArrayDetails { public static final String SERIALIZED_NAME_PARAMETER_ID = "parameter_id"; @SerializedName(SERIALIZED_NAME_PARAMETER_ID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/UDFCopied.java b/src/main/java/io/tiledb/cloud/rest_api/model/UDFCopied.java index acc4142..60c237d 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/UDFCopied.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/UDFCopied.java @@ -40,10 +40,7 @@ */ @ApiModel(description = "Copied udf uri and information") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class UDFCopied { public static final String SERIALIZED_NAME_OUTPUT_URI = "output_uri"; @SerializedName(SERIALIZED_NAME_OUTPUT_URI) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/UDFCopy.java b/src/main/java/io/tiledb/cloud/rest_api/model/UDFCopy.java index 4a8704f..b3e315c 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/UDFCopy.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/UDFCopy.java @@ -40,10 +40,7 @@ */ @ApiModel(description = "information required to copy a udf") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class UDFCopy { public static final String SERIALIZED_NAME_OUTPUT_URI = "output_uri"; @SerializedName(SERIALIZED_NAME_OUTPUT_URI) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/UDFFavorite.java b/src/main/java/io/tiledb/cloud/rest_api/model/UDFFavorite.java index 16ac069..7d2b7d7 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/UDFFavorite.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/UDFFavorite.java @@ -40,10 +40,7 @@ */ @ApiModel(description = "A user-favorite UDF item") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class UDFFavorite { public static final String SERIALIZED_NAME_UDF_UUID = "udf_uuid"; @SerializedName(SERIALIZED_NAME_UDF_UUID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/UDFFavoritesData.java b/src/main/java/io/tiledb/cloud/rest_api/model/UDFFavoritesData.java index 3e10155..c3d7d28 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/UDFFavoritesData.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/UDFFavoritesData.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "Object including UDF favorites and pagination metadata") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class UDFFavoritesData { public static final String SERIALIZED_NAME_UDFS = "udfs"; @SerializedName(SERIALIZED_NAME_UDFS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/UDFImage.java b/src/main/java/io/tiledb/cloud/rest_api/model/UDFImage.java index 274d31a..d07f710 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/UDFImage.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/UDFImage.java @@ -40,10 +40,7 @@ */ @ApiModel(description = "Defines a set of images related to a specific name") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class UDFImage { public static final String SERIALIZED_NAME_ID = "id"; @SerializedName(SERIALIZED_NAME_ID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/UDFImageVersion.java b/src/main/java/io/tiledb/cloud/rest_api/model/UDFImageVersion.java index 6f356cd..54a491c 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/UDFImageVersion.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/UDFImageVersion.java @@ -41,10 +41,7 @@ */ @ApiModel(description = "Defines an image that belongs to a set of images having a version") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class UDFImageVersion { public static final String SERIALIZED_NAME_ID = "id"; @SerializedName(SERIALIZED_NAME_ID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/UDFInfo.java b/src/main/java/io/tiledb/cloud/rest_api/model/UDFInfo.java index 675a505..b677626 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/UDFInfo.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/UDFInfo.java @@ -42,10 +42,7 @@ */ @ApiModel(description = "User-defined function that can persist in db, used and shared multiple times") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class UDFInfo { public static final String SERIALIZED_NAME_ID = "id"; @SerializedName(SERIALIZED_NAME_ID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/UDFInfoUpdate.java b/src/main/java/io/tiledb/cloud/rest_api/model/UDFInfoUpdate.java index be222da..2693901 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/UDFInfoUpdate.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/UDFInfoUpdate.java @@ -42,10 +42,7 @@ */ @ApiModel(description = "User-defined function that can persist in db, used and shared multiple times") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class UDFInfoUpdate { public static final String SERIALIZED_NAME_NAME = "name"; @SerializedName(SERIALIZED_NAME_NAME) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/UDFSharing.java b/src/main/java/io/tiledb/cloud/rest_api/model/UDFSharing.java index 65ef91d..5ba1e61 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/UDFSharing.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/UDFSharing.java @@ -42,10 +42,7 @@ */ @ApiModel(description = "details for sharing a given UDF") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class UDFSharing { public static final String SERIALIZED_NAME_ACTIONS = "actions"; @SerializedName(SERIALIZED_NAME_ACTIONS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/UDFSubarray.java b/src/main/java/io/tiledb/cloud/rest_api/model/UDFSubarray.java index f3dba0d..9174fee 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/UDFSubarray.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/UDFSubarray.java @@ -43,10 +43,7 @@ */ @ApiModel(description = "Subarray bounds to query for a UDF to operate on") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class UDFSubarray { public static final String SERIALIZED_NAME_LAYOUT = "layout"; @SerializedName(SERIALIZED_NAME_LAYOUT) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/UDFSubarrayRange.java b/src/main/java/io/tiledb/cloud/rest_api/model/UDFSubarrayRange.java index 093d2b8..06473bf 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/UDFSubarrayRange.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/UDFSubarrayRange.java @@ -40,10 +40,7 @@ */ @ApiModel(description = "A dimension range to query") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class UDFSubarrayRange { public static final String SERIALIZED_NAME_DIMENSION_ID = "dimension_id"; @SerializedName(SERIALIZED_NAME_DIMENSION_ID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/User.java b/src/main/java/io/tiledb/cloud/rest_api/model/User.java index 9511a68..eab02ed 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/User.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/User.java @@ -44,10 +44,7 @@ */ @ApiModel(description = "User") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class User { public static final String SERIALIZED_NAME_ID = "id"; @SerializedName(SERIALIZED_NAME_ID) diff --git a/src/main/java/io/tiledb/cloud/rest_api/model/Writer.java b/src/main/java/io/tiledb/cloud/rest_api/model/Writer.java index 08d4c30..e752eb3 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/model/Writer.java +++ b/src/main/java/io/tiledb/cloud/rest_api/model/Writer.java @@ -38,10 +38,7 @@ * Writer */ @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.model - */ -@Deprecated + public class Writer { public static final String SERIALIZED_NAME_CHECK_COORD_DUPS = "checkCoordDups"; @SerializedName(SERIALIZED_NAME_CHECK_COORD_DUPS) diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/ApiCallback.java b/src/main/java/io/tiledb/cloud/rest_api/v1/ApiCallback.java deleted file mode 100644 index a58c056..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/ApiCallback.java +++ /dev/null @@ -1,60 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1; - -import java.util.Map; -import java.util.List; - -/** - * Callback for asynchronous API call. - * - * @param The return type - */ -public interface ApiCallback { - /** - * This is called when the API call fails. - * - * @param e The exception causing the failure - * @param statusCode Status code of the response if available, otherwise it would be 0 - * @param responseHeaders Headers of the response if available, otherwise it would be null - */ - void onFailure(ApiException e, int statusCode, Map> responseHeaders); - - /** - * This is called when the API call succeeded. - * - * @param result The result deserialized from response - * @param statusCode Status code of the response - * @param responseHeaders Headers of the response - */ - void onSuccess(T result, int statusCode, Map> responseHeaders); - - /** - * This is called when the API upload processing. - * - * @param bytesWritten bytes Written - * @param contentLength content length of request body - * @param done write end - */ - void onUploadProgress(long bytesWritten, long contentLength, boolean done); - - /** - * This is called when the API download processing. - * - * @param bytesRead bytes Read - * @param contentLength content length of the response - * @param done Read end - */ - void onDownloadProgress(long bytesRead, long contentLength, boolean done); -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/ApiClient.java b/src/main/java/io/tiledb/cloud/rest_api/v1/ApiClient.java deleted file mode 100644 index 7f21f83..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/ApiClient.java +++ /dev/null @@ -1,1583 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1; - -import okhttp3.*; -import okhttp3.internal.http.HttpMethod; -import okhttp3.internal.tls.OkHostnameVerifier; -import okhttp3.logging.HttpLoggingInterceptor; -import okhttp3.logging.HttpLoggingInterceptor.Level; -import okio.Buffer; -import okio.BufferedSink; -import okio.Okio; -import org.apache.oltu.oauth2.client.request.OAuthClientRequest.TokenRequestBuilder; - -import javax.net.ssl.*; -import java.io.File; -import java.io.IOException; -import java.io.InputStream; -import java.io.UnsupportedEncodingException; -import java.lang.reflect.Type; -import java.net.URI; -import java.net.URLConnection; -import java.net.URLEncoder; -import java.nio.file.Files; -import java.nio.file.Paths; -import java.security.GeneralSecurityException; -import java.security.KeyStore; -import java.security.SecureRandom; -import java.security.cert.Certificate; -import java.security.cert.CertificateException; -import java.security.cert.CertificateFactory; -import java.text.DateFormat; -import java.time.LocalDate; -import java.time.OffsetDateTime; -import java.time.format.DateTimeFormatter; -import java.util.*; -import java.util.Map.Entry; -import java.util.concurrent.TimeUnit; -import java.util.regex.Matcher; -import java.util.regex.Pattern; - -import io.tiledb.cloud.rest_api.v1.auth.Authentication; -import io.tiledb.cloud.rest_api.v1.auth.HttpBasicAuth; -import io.tiledb.cloud.rest_api.v1.auth.ApiKeyAuth; -import io.tiledb.cloud.rest_api.v1.auth.OAuth; -import io.tiledb.cloud.rest_api.v1.auth.RetryingOAuth; -import io.tiledb.cloud.rest_api.v1.auth.OAuthFlow; - -/** - *

ApiClient class.

- */ -public class ApiClient { - - private String basePath = "/v1"; - private boolean debugging = false; - private Map defaultHeaderMap = new HashMap(); - private Map defaultCookieMap = new HashMap(); - private String tempFolderPath = null; - - private Map authentications; - - private DateFormat dateFormat; - private DateFormat datetimeFormat; - private boolean lenientDatetimeFormat; - private int dateLength; - - private InputStream sslCaCert; - private boolean verifyingSsl; - private KeyManager[] keyManagers; - - private OkHttpClient httpClient; - private JSON json; - - private HttpLoggingInterceptor loggingInterceptor; - - /** - * Basic constructor for ApiClient - */ - public ApiClient() { - init(); - initHttpClient(); - - // Setup authentications (key: authentication name, value: authentication). - authentications.put("ApiKeyAuth", new ApiKeyAuth("header", "X-TILEDB-REST-API-KEY")); - authentications.put("BasicAuth", new HttpBasicAuth()); - authentications.put("OAuth2", new OAuth()); - // Prevent the authentications from being modified. - authentications = Collections.unmodifiableMap(authentications); - } - - /** - * Basic constructor with custom OkHttpClient - * - * @param client a {@link okhttp3.OkHttpClient} object - */ - public ApiClient(OkHttpClient client) { - init(); - - httpClient = client; - - // Setup authentications (key: authentication name, value: authentication). - authentications.put("ApiKeyAuth", new ApiKeyAuth("header", "X-TILEDB-REST-API-KEY")); - authentications.put("BasicAuth", new HttpBasicAuth()); - authentications.put("OAuth2", new OAuth()); - // Prevent the authentications from being modified. - authentications = Collections.unmodifiableMap(authentications); - } - - /** - * Constructor for ApiClient to support access token retry on 401/403 configured with client ID - * - * @param clientId client ID - */ - public ApiClient(String clientId) { - this(clientId, null, null); - } - - /** - * Constructor for ApiClient to support access token retry on 401/403 configured with client ID and additional parameters - * - * @param clientId client ID - * @param parameters a {@link java.util.Map} of parameters - */ - public ApiClient(String clientId, Map parameters) { - this(clientId, null, parameters); - } - - /** - * Constructor for ApiClient to support access token retry on 401/403 configured with client ID, secret, and additional parameters - * - * @param clientId client ID - * @param clientSecret client secret - * @param parameters a {@link java.util.Map} of parameters - */ - public ApiClient(String clientId, String clientSecret, Map parameters) { - this(null, clientId, clientSecret, parameters); - } - - /** - * Constructor for ApiClient to support access token retry on 401/403 configured with base path, client ID, secret, and additional parameters - * - * @param basePath base path - * @param clientId client ID - * @param clientSecret client secret - * @param parameters a {@link java.util.Map} of parameters - */ - public ApiClient(String basePath, String clientId, String clientSecret, Map parameters) { - init(); - if (basePath != null) { - this.basePath = basePath; - } - - String tokenUrl = "https://oauth2.tiledb.com/oauth2/token"; - if (!"".equals(tokenUrl) && !URI.create(tokenUrl).isAbsolute()) { - URI uri = URI.create(getBasePath()); - tokenUrl = uri.getScheme() + ":" + - (uri.getAuthority() != null ? "//" + uri.getAuthority() : "") + - tokenUrl; - if (!URI.create(tokenUrl).isAbsolute()) { - throw new IllegalArgumentException("OAuth2 token URL must be an absolute URL"); - } - } - RetryingOAuth retryingOAuth = new RetryingOAuth(tokenUrl, clientId, OAuthFlow.ACCESS_CODE, clientSecret, parameters); - authentications.put( - "OAuth2", - retryingOAuth - ); - initHttpClient(Collections.singletonList(retryingOAuth)); - // Setup authentications (key: authentication name, value: authentication). - authentications.put("ApiKeyAuth", new ApiKeyAuth("header", "X-TILEDB-REST-API-KEY")); - authentications.put("BasicAuth", new HttpBasicAuth()); - - // Prevent the authentications from being modified. - authentications = Collections.unmodifiableMap(authentications); - } - - private void initHttpClient() { - initHttpClient(Collections.emptyList()); - } - - private void initHttpClient(List interceptors) { - OkHttpClient.Builder builder = new OkHttpClient.Builder(); - builder.addNetworkInterceptor(getProgressInterceptor()); - for (Interceptor interceptor: interceptors) { - builder.addInterceptor(interceptor); - } - - httpClient = builder.build(); - } - - private void init() { - verifyingSsl = true; - - json = new JSON(); - - // Set default User-Agent. - setUserAgent("OpenAPI-Generator/2.2.19/java"); - - authentications = new HashMap(); - } - - /** - * Get base path - * - * @return Base path - */ - public String getBasePath() { - return basePath; - } - - /** - * Set base path - * - * @param basePath Base path of the URL (e.g /v1 - * @return An instance of OkHttpClient - */ - public ApiClient setBasePath(String basePath) { - this.basePath = basePath; - return this; - } - - /** - * Get HTTP client - * - * @return An instance of OkHttpClient - */ - public OkHttpClient getHttpClient() { - return httpClient; - } - - /** - * Set HTTP client, which must never be null. - * - * @param newHttpClient An instance of OkHttpClient - * @return Api Client - * @throws java.lang.NullPointerException when newHttpClient is null - */ - public ApiClient setHttpClient(OkHttpClient newHttpClient) { - this.httpClient = Objects.requireNonNull(newHttpClient, "HttpClient must not be null!"); - return this; - } - - /** - * Get JSON - * - * @return JSON object - */ - public JSON getJSON() { - return json; - } - - /** - * Set JSON - * - * @param json JSON object - * @return Api client - */ - public ApiClient setJSON(JSON json) { - this.json = json; - return this; - } - - /** - * True if isVerifyingSsl flag is on - * - * @return True if isVerifySsl flag is on - */ - public boolean isVerifyingSsl() { - return verifyingSsl; - } - - /** - * Configure whether to verify certificate and hostname when making https requests. - * Default to true. - * NOTE: Do NOT set to false in production code, otherwise you would face multiple types of cryptographic attacks. - * - * @param verifyingSsl True to verify TLS/SSL connection - * @return ApiClient - */ - public ApiClient setVerifyingSsl(boolean verifyingSsl) { - this.verifyingSsl = verifyingSsl; - applySslSettings(); - return this; - } - - /** - * Get SSL CA cert. - * - * @return Input stream to the SSL CA cert - */ - public InputStream getSslCaCert() { - return sslCaCert; - } - - /** - * Configure the CA certificate to be trusted when making https requests. - * Use null to reset to default. - * - * @param sslCaCert input stream for SSL CA cert - * @return ApiClient - */ - public ApiClient setSslCaCert(InputStream sslCaCert) { - this.sslCaCert = sslCaCert; - applySslSettings(); - return this; - } - - /** - *

Getter for the field keyManagers.

- * - * @return an array of {@link javax.net.ssl.KeyManager} objects - */ - public KeyManager[] getKeyManagers() { - return keyManagers; - } - - /** - * Configure client keys to use for authorization in an SSL session. - * Use null to reset to default. - * - * @param managers The KeyManagers to use - * @return ApiClient - */ - public ApiClient setKeyManagers(KeyManager[] managers) { - this.keyManagers = managers; - applySslSettings(); - return this; - } - - /** - *

Getter for the field dateFormat.

- * - * @return a {@link java.text.DateFormat} object - */ - public DateFormat getDateFormat() { - return dateFormat; - } - - /** - *

Setter for the field dateFormat.

- * - * @param dateFormat a {@link java.text.DateFormat} object - * @return a {@link ApiClient} object - */ - public ApiClient setDateFormat(DateFormat dateFormat) { - this.json.setDateFormat(dateFormat); - return this; - } - - /** - *

Set SqlDateFormat.

- * - * @param dateFormat a {@link java.text.DateFormat} object - * @return a {@link ApiClient} object - */ - public ApiClient setSqlDateFormat(DateFormat dateFormat) { - this.json.setSqlDateFormat(dateFormat); - return this; - } - - /** - *

Set OffsetDateTimeFormat.

- * - * @param dateFormat a {@link java.time.format.DateTimeFormatter} object - * @return a {@link ApiClient} object - */ - public ApiClient setOffsetDateTimeFormat(DateTimeFormatter dateFormat) { - this.json.setOffsetDateTimeFormat(dateFormat); - return this; - } - - /** - *

Set LocalDateFormat.

- * - * @param dateFormat a {@link java.time.format.DateTimeFormatter} object - * @return a {@link ApiClient} object - */ - public ApiClient setLocalDateFormat(DateTimeFormatter dateFormat) { - this.json.setLocalDateFormat(dateFormat); - return this; - } - - /** - *

Set LenientOnJson.

- * - * @param lenientOnJson a boolean - * @return a {@link ApiClient} object - */ - public ApiClient setLenientOnJson(boolean lenientOnJson) { - this.json.setLenientOnJson(lenientOnJson); - return this; - } - - /** - * Get authentications (key: authentication name, value: authentication). - * - * @return Map of authentication objects - */ - public Map getAuthentications() { - return authentications; - } - - /** - * Get authentication for the given name. - * - * @param authName The authentication name - * @return The authentication, null if not found - */ - public Authentication getAuthentication(String authName) { - return authentications.get(authName); - } - - - /** - * Helper method to set username for the first HTTP basic authentication. - * - * @param username Username - */ - public void setUsername(String username) { - for (Authentication auth : authentications.values()) { - if (auth instanceof HttpBasicAuth) { - ((HttpBasicAuth) auth).setUsername(username); - return; - } - } - throw new RuntimeException("No HTTP basic authentication configured!"); - } - - /** - * Helper method to set password for the first HTTP basic authentication. - * - * @param password Password - */ - public void setPassword(String password) { - for (Authentication auth : authentications.values()) { - if (auth instanceof HttpBasicAuth) { - ((HttpBasicAuth) auth).setPassword(password); - return; - } - } - throw new RuntimeException("No HTTP basic authentication configured!"); - } - - /** - * Helper method to set API key value for the first API key authentication. - * - * @param apiKey API key - */ - public void setApiKey(String apiKey) { - for (Authentication auth : authentications.values()) { - if (auth instanceof ApiKeyAuth) { - ((ApiKeyAuth) auth).setApiKey(apiKey); - return; - } - } - throw new RuntimeException("No API key authentication configured!"); - } - - /** - * Helper method to set API key prefix for the first API key authentication. - * - * @param apiKeyPrefix API key prefix - */ - public void setApiKeyPrefix(String apiKeyPrefix) { - for (Authentication auth : authentications.values()) { - if (auth instanceof ApiKeyAuth) { - ((ApiKeyAuth) auth).setApiKeyPrefix(apiKeyPrefix); - return; - } - } - throw new RuntimeException("No API key authentication configured!"); - } - - /** - * Helper method to set access token for the first OAuth2 authentication. - * - * @param accessToken Access token - */ - public void setAccessToken(String accessToken) { - for (Authentication auth : authentications.values()) { - if (auth instanceof OAuth) { - ((OAuth) auth).setAccessToken(accessToken); - return; - } - } - throw new RuntimeException("No OAuth2 authentication configured!"); - } - - /** - * Set the User-Agent header's value (by adding to the default header map). - * - * @param userAgent HTTP request's user agent - * @return ApiClient - */ - public ApiClient setUserAgent(String userAgent) { - addDefaultHeader("User-Agent", userAgent); - return this; - } - - /** - * Add a default header. - * - * @param key The header's key - * @param value The header's value - * @return ApiClient - */ - public ApiClient addDefaultHeader(String key, String value) { - defaultHeaderMap.put(key, value); - return this; - } - - /** - * Add a default cookie. - * - * @param key The cookie's key - * @param value The cookie's value - * @return ApiClient - */ - public ApiClient addDefaultCookie(String key, String value) { - defaultCookieMap.put(key, value); - return this; - } - - /** - * Check that whether debugging is enabled for this API client. - * - * @return True if debugging is enabled, false otherwise. - */ - public boolean isDebugging() { - return debugging; - } - - /** - * Enable/disable debugging for this API client. - * - * @param debugging To enable (true) or disable (false) debugging - * @return ApiClient - */ - public ApiClient setDebugging(boolean debugging) { - if (debugging != this.debugging) { - if (debugging) { - loggingInterceptor = new HttpLoggingInterceptor(); - loggingInterceptor.setLevel(Level.BODY); - httpClient = httpClient.newBuilder().addInterceptor(loggingInterceptor).build(); - } else { - final OkHttpClient.Builder builder = httpClient.newBuilder(); - builder.interceptors().remove(loggingInterceptor); - httpClient = builder.build(); - loggingInterceptor = null; - } - } - this.debugging = debugging; - return this; - } - - /** - * The path of temporary folder used to store downloaded files from endpoints - * with file response. The default value is null, i.e. using - * the system's default temporary folder. - * - * @see createTempFile - * @return Temporary folder path - */ - public String getTempFolderPath() { - return tempFolderPath; - } - - /** - * Set the temporary folder path (for downloading files) - * - * @param tempFolderPath Temporary folder path - * @return ApiClient - */ - public ApiClient setTempFolderPath(String tempFolderPath) { - this.tempFolderPath = tempFolderPath; - return this; - } - - /** - * Get connection timeout (in milliseconds). - * - * @return Timeout in milliseconds - */ - public int getConnectTimeout() { - return httpClient.connectTimeoutMillis(); - } - - /** - * Sets the connect timeout (in milliseconds). - * A value of 0 means no timeout, otherwise values must be between 1 and - * {@link java.lang.Integer#MAX_VALUE}. - * - * @param connectionTimeout connection timeout in milliseconds - * @return Api client - */ - public ApiClient setConnectTimeout(int connectionTimeout) { - httpClient = httpClient.newBuilder().connectTimeout(connectionTimeout, TimeUnit.MILLISECONDS).build(); - return this; - } - - /** - * Get read timeout (in milliseconds). - * - * @return Timeout in milliseconds - */ - public int getReadTimeout() { - return httpClient.readTimeoutMillis(); - } - - /** - * Sets the read timeout (in milliseconds). - * A value of 0 means no timeout, otherwise values must be between 1 and - * {@link java.lang.Integer#MAX_VALUE}. - * - * @param readTimeout read timeout in milliseconds - * @return Api client - */ - public ApiClient setReadTimeout(int readTimeout) { - httpClient = httpClient.newBuilder().readTimeout(readTimeout, TimeUnit.MILLISECONDS).build(); - return this; - } - - /** - * Get write timeout (in milliseconds). - * - * @return Timeout in milliseconds - */ - public int getWriteTimeout() { - return httpClient.writeTimeoutMillis(); - } - - /** - * Sets the write timeout (in milliseconds). - * A value of 0 means no timeout, otherwise values must be between 1 and - * {@link java.lang.Integer#MAX_VALUE}. - * - * @param writeTimeout connection timeout in milliseconds - * @return Api client - */ - public ApiClient setWriteTimeout(int writeTimeout) { - httpClient = httpClient.newBuilder().writeTimeout(writeTimeout, TimeUnit.MILLISECONDS).build(); - return this; - } - - /** - * Helper method to configure the token endpoint of the first oauth found in the apiAuthorizations (there should be only one) - * - * @return Token request builder - */ - public TokenRequestBuilder getTokenEndPoint() { - for (Authentication apiAuth : authentications.values()) { - if (apiAuth instanceof RetryingOAuth) { - RetryingOAuth retryingOAuth = (RetryingOAuth) apiAuth; - return retryingOAuth.getTokenRequestBuilder(); - } - } - return null; - } - - /** - * Format the given parameter object into string. - * - * @param param Parameter - * @return String representation of the parameter - */ - public String parameterToString(Object param) { - if (param == null) { - return ""; - } else if (param instanceof Date || param instanceof OffsetDateTime || param instanceof LocalDate) { - //Serialize to json string and remove the " enclosing characters - String jsonStr = json.serialize(param); - return jsonStr.substring(1, jsonStr.length() - 1); - } else if (param instanceof Collection) { - StringBuilder b = new StringBuilder(); - for (Object o : (Collection) param) { - if (b.length() > 0) { - b.append(","); - } - b.append(String.valueOf(o)); - } - return b.toString(); - } else { - return String.valueOf(param); - } - } - - /** - * Formats the specified query parameter to a list containing a single {@code Pair} object. - * - * Note that {@code value} must not be a collection. - * - * @param name The name of the parameter. - * @param value The value of the parameter. - * @return A list containing a single {@code Pair} object. - */ - public List parameterToPair(String name, Object value) { - List params = new ArrayList(); - - // preconditions - if (name == null || name.isEmpty() || value == null || value instanceof Collection) { - return params; - } - - params.add(new Pair(name, parameterToString(value))); - return params; - } - - /** - * Formats the specified collection query parameters to a list of {@code Pair} objects. - * - * Note that the values of each of the returned Pair objects are percent-encoded. - * - * @param collectionFormat The collection format of the parameter. - * @param name The name of the parameter. - * @param value The value of the parameter. - * @return A list of {@code Pair} objects. - */ - public List parameterToPairs(String collectionFormat, String name, Collection value) { - List params = new ArrayList(); - - // preconditions - if (name == null || name.isEmpty() || value == null || value.isEmpty()) { - return params; - } - - // create the params based on the collection format - if ("multi".equals(collectionFormat)) { - for (Object item : value) { - params.add(new Pair(name, escapeString(parameterToString(item)))); - } - return params; - } - - // collectionFormat is assumed to be "csv" by default - String delimiter = ","; - - // escape all delimiters except commas, which are URI reserved - // characters - if ("ssv".equals(collectionFormat)) { - delimiter = escapeString(" "); - } else if ("tsv".equals(collectionFormat)) { - delimiter = escapeString("\t"); - } else if ("pipes".equals(collectionFormat)) { - delimiter = escapeString("|"); - } - - StringBuilder sb = new StringBuilder(); - for (Object item : value) { - sb.append(delimiter); - sb.append(escapeString(parameterToString(item))); - } - - params.add(new Pair(name, sb.substring(delimiter.length()))); - - return params; - } - - /** - * Formats the specified collection path parameter to a string value. - * - * @param collectionFormat The collection format of the parameter. - * @param value The value of the parameter. - * @return String representation of the parameter - */ - public String collectionPathParameterToString(String collectionFormat, Collection value) { - // create the value based on the collection format - if ("multi".equals(collectionFormat)) { - // not valid for path params - return parameterToString(value); - } - - // collectionFormat is assumed to be "csv" by default - String delimiter = ","; - - if ("ssv".equals(collectionFormat)) { - delimiter = " "; - } else if ("tsv".equals(collectionFormat)) { - delimiter = "\t"; - } else if ("pipes".equals(collectionFormat)) { - delimiter = "|"; - } - - StringBuilder sb = new StringBuilder() ; - for (Object item : value) { - sb.append(delimiter); - sb.append(parameterToString(item)); - } - - return sb.substring(delimiter.length()); - } - - /** - * Sanitize filename by removing path. - * e.g. ../../sun.gif becomes sun.gif - * - * @param filename The filename to be sanitized - * @return The sanitized filename - */ - public String sanitizeFilename(String filename) { - return filename.replaceAll(".*[/\\\\]", ""); - } - - /** - * Check if the given MIME is a JSON MIME. - * JSON MIME examples: - * application/json - * application/json; charset=UTF8 - * APPLICATION/JSON - * application/vnd.company+json - * "* / *" is also default to JSON - * @param mime MIME (Multipurpose Internet Mail Extensions) - * @return True if the given MIME is JSON, false otherwise. - */ - public boolean isJsonMime(String mime) { - String jsonMime = "(?i)^(application/json|[^;/ \t]+/[^;/ \t]+[+]json)[ \t]*(;.*)?$"; - return mime != null && (mime.matches(jsonMime) || mime.equals("*/*")); - } - - /** - * Select the Accept header's value from the given accepts array: - * if JSON exists in the given array, use it; - * otherwise use all of them (joining into a string) - * - * @param accepts The accepts array to select from - * @return The Accept header to use. If the given array is empty, - * null will be returned (not to set the Accept header explicitly). - */ - public String selectHeaderAccept(String[] accepts) { - if (accepts.length == 0) { - return null; - } - for (String accept : accepts) { - if (isJsonMime(accept)) { - return accept; - } - } - return StringUtil.join(accepts, ","); - } - - /** - * Select the Content-Type header's value from the given array: - * if JSON exists in the given array, use it; - * otherwise use the first one of the array. - * - * @param contentTypes The Content-Type array to select from - * @return The Content-Type header to use. If the given array is empty, - * returns null. If it matches "any", JSON will be used. - */ - public String selectHeaderContentType(String[] contentTypes) { - if (contentTypes.length == 0) { - return null; - } - - if (contentTypes[0].equals("*/*")) { - return "application/json"; - } - - for (String contentType : contentTypes) { - if (isJsonMime(contentType)) { - return contentType; - } - } - - return contentTypes[0]; - } - - /** - * Escape the given string to be used as URL query value. - * - * @param str String to be escaped - * @return Escaped string - */ - public String escapeString(String str) { - try { - return URLEncoder.encode(str, "utf8").replaceAll("\\+", "%20"); - } catch (UnsupportedEncodingException e) { - return str; - } - } - - /** - * Deserialize response body to Java object, according to the return type and - * the Content-Type response header. - * - * @param Type - * @param response HTTP response - * @param returnType The type of the Java object - * @return The deserialized Java object - * @throws ApiException If fail to deserialize response body, i.e. cannot read response body - * or the Content-Type of the response is not supported. - */ - @SuppressWarnings("unchecked") - public T deserialize(Response response, Type returnType) throws ApiException { - if (response == null || returnType == null) { - return null; - } - - if ("byte[]".equals(returnType.toString())) { - // Handle binary response (byte array). - try { - return (T) response.body().bytes(); - } catch (IOException e) { - throw new ApiException(e); - } - } else if (returnType.equals(File.class)) { - // Handle file downloading. - return (T) downloadFileFromResponse(response); - } - - String respBody; - try { - if (response.body() != null) - respBody = response.body().string(); - else - respBody = null; - } catch (IOException e) { - throw new ApiException(e); - } - - if (respBody == null || "".equals(respBody)) { - return null; - } - - String contentType = response.headers().get("Content-Type"); - if (contentType == null) { - // ensuring a default content type - contentType = "application/json"; - } - if (isJsonMime(contentType)) { - return json.deserialize(respBody, returnType); - } else if (returnType.equals(String.class)) { - // Expecting string, return the raw response body. - return (T) respBody; - } else { - throw new ApiException( - "Content type \"" + contentType + "\" is not supported for type: " + returnType, - response.code(), - response.headers().toMultimap(), - respBody); - } - } - - /** - * Serialize the given Java object into request body according to the object's - * class and the request Content-Type. - * - * @param obj The Java object - * @param contentType The request Content-Type - * @return The serialized request body - * @throws ApiException If fail to serialize the given object - */ - public RequestBody serialize(Object obj, String contentType) throws ApiException { - if (obj instanceof byte[]) { - // Binary (byte array) body parameter support. - return RequestBody.create((byte[]) obj, MediaType.parse(contentType)); - } else if (obj instanceof File) { - // File body parameter support. - return RequestBody.create((File) obj, MediaType.parse(contentType)); - } else if ("text/plain".equals(contentType) && obj instanceof String) { - return RequestBody.create((String) obj, MediaType.parse(contentType)); - } else if (isJsonMime(contentType)) { - String content; - if (obj != null) { - content = json.serialize(obj); - } else { - content = null; - } - return RequestBody.create(content, MediaType.parse(contentType)); - } else if (obj instanceof String) { - return RequestBody.create(MediaType.parse(contentType), (String) obj); - } else { - throw new ApiException("Content type \"" + contentType + "\" is not supported"); - } - } - - /** - * Download file from the given response. - * - * @param response An instance of the Response object - * @throws ApiException If fail to read file content from response and write to disk - * @return Downloaded file - */ - public File downloadFileFromResponse(Response response) throws ApiException { - try { - File file = prepareDownloadFile(response); - BufferedSink sink = Okio.buffer(Okio.sink(file)); - sink.writeAll(response.body().source()); - sink.close(); - return file; - } catch (IOException e) { - throw new ApiException(e); - } - } - - /** - * Prepare file for download - * - * @param response An instance of the Response object - * @return Prepared file for the download - * @throws java.io.IOException If fail to prepare file for download - */ - public File prepareDownloadFile(Response response) throws IOException { - String filename = null; - String contentDisposition = response.header("Content-Disposition"); - if (contentDisposition != null && !"".equals(contentDisposition)) { - // Get filename from the Content-Disposition header. - Pattern pattern = Pattern.compile("filename=['\"]?([^'\"\\s]+)['\"]?"); - Matcher matcher = pattern.matcher(contentDisposition); - if (matcher.find()) { - filename = sanitizeFilename(matcher.group(1)); - } - } - - String prefix = null; - String suffix = null; - if (filename == null) { - prefix = "download-"; - suffix = ""; - } else { - int pos = filename.lastIndexOf("."); - if (pos == -1) { - prefix = filename + "-"; - } else { - prefix = filename.substring(0, pos) + "-"; - suffix = filename.substring(pos); - } - // Files.createTempFile requires the prefix to be at least three characters long - if (prefix.length() < 3) - prefix = "download-"; - } - - if (tempFolderPath == null) - return Files.createTempFile(prefix, suffix).toFile(); - else - return Files.createTempFile(Paths.get(tempFolderPath), prefix, suffix).toFile(); - } - - /** - * {@link #execute(Call, Type)} - * - * @param Type - * @param call An instance of the Call object - * @return ApiResponse<T> - * @throws ApiException If fail to execute the call - */ - public ApiResponse execute(Call call) throws ApiException { - return execute(call, null); - } - - /** - * Execute HTTP call and deserialize the HTTP response body into the given return type. - * - * @param returnType The return type used to deserialize HTTP response body - * @param The return type corresponding to (same with) returnType - * @param call Call - * @return ApiResponse object containing response status, headers and - * data, which is a Java object deserialized from response body and would be null - * when returnType is null. - * @throws ApiException If fail to execute the call - */ - public ApiResponse execute(Call call, Type returnType) throws ApiException { - try { - Response response = call.execute(); - T data = handleResponse(response, returnType); - return new ApiResponse(response.code(), response.headers().toMultimap(), data); - } catch (IOException e) { - throw new ApiException(e); - } - } - - /** - * {@link #executeAsync(Call, Type, ApiCallback)} - * - * @param Type - * @param call An instance of the Call object - * @param callback ApiCallback<T> - */ - public void executeAsync(Call call, ApiCallback callback) { - executeAsync(call, null, callback); - } - - /** - * Execute HTTP call asynchronously. - * - * @param Type - * @param call The callback to be executed when the API call finishes - * @param returnType Return type - * @param callback ApiCallback - * @see #execute(Call, Type) - */ - @SuppressWarnings("unchecked") - public void executeAsync(Call call, final Type returnType, final ApiCallback callback) { - call.enqueue(new Callback() { - @Override - public void onFailure(Call call, IOException e) { - callback.onFailure(new ApiException(e), 0, null); - } - - @Override - public void onResponse(Call call, Response response) throws IOException { - T result; - try { - result = (T) handleResponse(response, returnType); - } catch (ApiException e) { - callback.onFailure(e, response.code(), response.headers().toMultimap()); - return; - } catch (Exception e) { - callback.onFailure(new ApiException(e), response.code(), response.headers().toMultimap()); - return; - } - callback.onSuccess(result, response.code(), response.headers().toMultimap()); - } - }); - } - - /** - * Handle the given response, return the deserialized object when the response is successful. - * - * @param Type - * @param response Response - * @param returnType Return type - * @return Type - * @throws ApiException If the response has an unsuccessful status code or - * fail to deserialize the response body - */ - public T handleResponse(Response response, Type returnType) throws ApiException { - if (response.isSuccessful()) { - if (returnType == null || response.code() == 204) { - // returning null if the returnType is not defined, - // or the status code is 204 (No Content) - if (response.body() != null) { - try { - response.body().close(); - } catch (Exception e) { - throw new ApiException(response.message(), e, response.code(), response.headers().toMultimap()); - } - } - return null; - } else { - return deserialize(response, returnType); - } - } else { - String respBody = null; - if (response.body() != null) { - try { - respBody = response.body().string(); - } catch (IOException e) { - throw new ApiException(response.message(), e, response.code(), response.headers().toMultimap()); - } - } - throw new ApiException(response.message(), response.code(), response.headers().toMultimap(), respBody); - } - } - - /** - * Build HTTP call with the given options. - * - * @param baseUrl The base URL - * @param path The sub-path of the HTTP URL - * @param method The request method, one of "GET", "HEAD", "OPTIONS", "POST", "PUT", "PATCH" and "DELETE" - * @param queryParams The query parameters - * @param collectionQueryParams The collection query parameters - * @param body The request body object - * @param headerParams The header parameters - * @param cookieParams The cookie parameters - * @param formParams The form parameters - * @param authNames The authentications to apply - * @param callback Callback for upload/download progress - * @return The HTTP call - * @throws ApiException If fail to serialize the request body object - */ - public Call buildCall(String baseUrl, String path, String method, List queryParams, List collectionQueryParams, Object body, Map headerParams, Map cookieParams, Map formParams, String[] authNames, ApiCallback callback) throws ApiException { - Request request = buildRequest(baseUrl, path, method, queryParams, collectionQueryParams, body, headerParams, cookieParams, formParams, authNames, callback); - - return httpClient.newCall(request); - } - - /** - * Build an HTTP request with the given options. - * - * @param baseUrl The base URL - * @param path The sub-path of the HTTP URL - * @param method The request method, one of "GET", "HEAD", "OPTIONS", "POST", "PUT", "PATCH" and "DELETE" - * @param queryParams The query parameters - * @param collectionQueryParams The collection query parameters - * @param body The request body object - * @param headerParams The header parameters - * @param cookieParams The cookie parameters - * @param formParams The form parameters - * @param authNames The authentications to apply - * @param callback Callback for upload/download progress - * @return The HTTP request - * @throws ApiException If fail to serialize the request body object - */ - public Request buildRequest(String baseUrl, String path, String method, List queryParams, List collectionQueryParams, Object body, Map headerParams, Map cookieParams, Map formParams, String[] authNames, ApiCallback callback) throws ApiException { - // aggregate queryParams (non-collection) and collectionQueryParams into allQueryParams - List allQueryParams = new ArrayList(queryParams); - allQueryParams.addAll(collectionQueryParams); - - final String url = buildUrl(baseUrl, path, queryParams, collectionQueryParams); - - // prepare HTTP request body - RequestBody reqBody; - String contentType = headerParams.get("Content-Type"); - - if (!HttpMethod.permitsRequestBody(method)) { - reqBody = null; - } else if ("application/x-www-form-urlencoded".equals(contentType)) { - reqBody = buildRequestBodyFormEncoding(formParams); - } else if ("multipart/form-data".equals(contentType)) { - reqBody = buildRequestBodyMultipart(formParams); - } else if (body == null) { - if ("DELETE".equals(method)) { - // allow calling DELETE without sending a request body - reqBody = null; - } else { - // use an empty request body (for POST, PUT and PATCH) - reqBody = RequestBody.create("", contentType == null ? null : MediaType.parse(contentType)); - } - } else { - reqBody = serialize(body, contentType); - } - - // update parameters with authentication settings - updateParamsForAuth(authNames, allQueryParams, headerParams, cookieParams, requestBodyToString(reqBody), method, URI.create(url)); - - final Request.Builder reqBuilder = new Request.Builder().url(url); - processHeaderParams(headerParams, reqBuilder); - processCookieParams(cookieParams, reqBuilder); - - // Associate callback with request (if not null) so interceptor can - // access it when creating ProgressResponseBody - reqBuilder.tag(callback); - - Request request = null; - - if (callback != null && reqBody != null) { - ProgressRequestBody progressRequestBody = new ProgressRequestBody(reqBody, callback); - request = reqBuilder.method(method, progressRequestBody).build(); - } else { - request = reqBuilder.method(method, reqBody).build(); - } - - return request; - } - - /** - * Build full URL by concatenating base path, the given sub path and query parameters. - * - * @param baseUrl The base URL - * @param path The sub path - * @param queryParams The query parameters - * @param collectionQueryParams The collection query parameters - * @return The full URL - */ - public String buildUrl(String baseUrl, String path, List queryParams, List collectionQueryParams) { - final StringBuilder url = new StringBuilder(); - if (baseUrl != null) { - url.append(baseUrl).append(path); - } else { - url.append(basePath).append(path); - } - - if (queryParams != null && !queryParams.isEmpty()) { - // support (constant) query string in `path`, e.g. "/posts?draft=1" - String prefix = path.contains("?") ? "&" : "?"; - for (Pair param : queryParams) { - if (param.getValue() != null) { - if (prefix != null) { - url.append(prefix); - prefix = null; - } else { - url.append("&"); - } - String value = parameterToString(param.getValue()); - url.append(escapeString(param.getName())).append("=").append(escapeString(value)); - } - } - } - - if (collectionQueryParams != null && !collectionQueryParams.isEmpty()) { - String prefix = url.toString().contains("?") ? "&" : "?"; - for (Pair param : collectionQueryParams) { - if (param.getValue() != null) { - if (prefix != null) { - url.append(prefix); - prefix = null; - } else { - url.append("&"); - } - String value = parameterToString(param.getValue()); - // collection query parameter value already escaped as part of parameterToPairs - url.append(escapeString(param.getName())).append("=").append(value); - } - } - } - - return url.toString(); - } - - /** - * Set header parameters to the request builder, including default headers. - * - * @param headerParams Header parameters in the form of Map - * @param reqBuilder Request.Builder - */ - public void processHeaderParams(Map headerParams, Request.Builder reqBuilder) { - for (Entry param : headerParams.entrySet()) { - reqBuilder.header(param.getKey(), parameterToString(param.getValue())); - } - for (Entry header : defaultHeaderMap.entrySet()) { - if (!headerParams.containsKey(header.getKey())) { - reqBuilder.header(header.getKey(), parameterToString(header.getValue())); - } - } - } - - /** - * Set cookie parameters to the request builder, including default cookies. - * - * @param cookieParams Cookie parameters in the form of Map - * @param reqBuilder Request.Builder - */ - public void processCookieParams(Map cookieParams, Request.Builder reqBuilder) { - for (Entry param : cookieParams.entrySet()) { - reqBuilder.addHeader("Cookie", String.format("%s=%s", param.getKey(), param.getValue())); - } - for (Entry param : defaultCookieMap.entrySet()) { - if (!cookieParams.containsKey(param.getKey())) { - reqBuilder.addHeader("Cookie", String.format("%s=%s", param.getKey(), param.getValue())); - } - } - } - - /** - * Update query and header parameters based on authentication settings. - * - * @param authNames The authentications to apply - * @param queryParams List of query parameters - * @param headerParams Map of header parameters - * @param cookieParams Map of cookie parameters - * @param payload HTTP request body - * @param method HTTP method - * @param uri URI - * @throws ApiException If fails to update the parameters - */ - public void updateParamsForAuth(String[] authNames, List queryParams, Map headerParams, - Map cookieParams, String payload, String method, URI uri) throws ApiException { - for (String authName : authNames) { - Authentication auth = authentications.get(authName); - if (auth == null) { - throw new RuntimeException("Authentication undefined: " + authName); - } - auth.applyToParams(queryParams, headerParams, cookieParams, payload, method, uri); - } - } - - /** - * Build a form-encoding request body with the given form parameters. - * - * @param formParams Form parameters in the form of Map - * @return RequestBody - */ - public RequestBody buildRequestBodyFormEncoding(Map formParams) { - okhttp3.FormBody.Builder formBuilder = new okhttp3.FormBody.Builder(); - for (Entry param : formParams.entrySet()) { - formBuilder.add(param.getKey(), parameterToString(param.getValue())); - } - return formBuilder.build(); - } - - /** - * Build a multipart (file uploading) request body with the given form parameters, - * which could contain text fields and file fields. - * - * @param formParams Form parameters in the form of Map - * @return RequestBody - */ - public RequestBody buildRequestBodyMultipart(Map formParams) { - MultipartBody.Builder mpBuilder = new MultipartBody.Builder().setType(MultipartBody.FORM); - for (Entry param : formParams.entrySet()) { - if (param.getValue() instanceof File) { - File file = (File) param.getValue(); - addPartToMultiPartBuilder(mpBuilder, param.getKey(), file); - } else if (param.getValue() instanceof List) { - List list = (List) param.getValue(); - for (Object item: list) { - if (item instanceof File) { - addPartToMultiPartBuilder(mpBuilder, param.getKey(), (File) item); - } else { - addPartToMultiPartBuilder(mpBuilder, param.getKey(), param.getValue()); - } - } - } else { - addPartToMultiPartBuilder(mpBuilder, param.getKey(), param.getValue()); - } - } - return mpBuilder.build(); - } - - /** - * Guess Content-Type header from the given file (defaults to "application/octet-stream"). - * - * @param file The given file - * @return The guessed Content-Type - */ - public String guessContentTypeFromFile(File file) { - String contentType = URLConnection.guessContentTypeFromName(file.getName()); - if (contentType == null) { - return "application/octet-stream"; - } else { - return contentType; - } - } - - /** - * Add a Content-Disposition Header for the given key and file to the MultipartBody Builder. - * - * @param mpBuilder MultipartBody.Builder - * @param key The key of the Header element - * @param file The file to add to the Header - */ - private void addPartToMultiPartBuilder(MultipartBody.Builder mpBuilder, String key, File file) { - Headers partHeaders = Headers.of("Content-Disposition", "form-data; name=\"" + key + "\"; filename=\"" + file.getName() + "\""); - MediaType mediaType = MediaType.parse(guessContentTypeFromFile(file)); - mpBuilder.addPart(partHeaders, RequestBody.create(file, mediaType)); - } - - /** - * Add a Content-Disposition Header for the given key and complex object to the MultipartBody Builder. - * - * @param mpBuilder MultipartBody.Builder - * @param key The key of the Header element - * @param obj The complex object to add to the Header - */ - private void addPartToMultiPartBuilder(MultipartBody.Builder mpBuilder, String key, Object obj) { - RequestBody requestBody; - if (obj instanceof String) { - requestBody = RequestBody.create((String) obj, MediaType.parse("text/plain")); - } else { - String content; - if (obj != null) { - content = json.serialize(obj); - } else { - content = null; - } - requestBody = RequestBody.create(content, MediaType.parse("application/json")); - } - - Headers partHeaders = Headers.of("Content-Disposition", "form-data; name=\"" + key + "\""); - mpBuilder.addPart(partHeaders, requestBody); - } - - /** - * Get network interceptor to add it to the httpClient to track download progress for - * async requests. - */ - private Interceptor getProgressInterceptor() { - return new Interceptor() { - @Override - public Response intercept(Interceptor.Chain chain) throws IOException { - final Request request = chain.request(); - final Response originalResponse = chain.proceed(request); - if (request.tag() instanceof ApiCallback) { - final ApiCallback callback = (ApiCallback) request.tag(); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), callback)) - .build(); - } - return originalResponse; - } - }; - } - - /** - * Apply SSL related settings to httpClient according to the current values of - * verifyingSsl and sslCaCert. - */ - private void applySslSettings() { - try { - TrustManager[] trustManagers; - HostnameVerifier hostnameVerifier; - if (!verifyingSsl) { - trustManagers = new TrustManager[]{ - new X509TrustManager() { - @Override - public void checkClientTrusted(java.security.cert.X509Certificate[] chain, String authType) throws CertificateException { - } - - @Override - public void checkServerTrusted(java.security.cert.X509Certificate[] chain, String authType) throws CertificateException { - } - - @Override - public java.security.cert.X509Certificate[] getAcceptedIssuers() { - return new java.security.cert.X509Certificate[]{}; - } - } - }; - hostnameVerifier = new HostnameVerifier() { - @Override - public boolean verify(String hostname, SSLSession session) { - return true; - } - }; - } else { - TrustManagerFactory trustManagerFactory = TrustManagerFactory.getInstance(TrustManagerFactory.getDefaultAlgorithm()); - - if (sslCaCert == null) { - trustManagerFactory.init((KeyStore) null); - } else { - char[] password = null; // Any password will work. - CertificateFactory certificateFactory = CertificateFactory.getInstance("X.509"); - Collection certificates = certificateFactory.generateCertificates(sslCaCert); - if (certificates.isEmpty()) { - throw new IllegalArgumentException("expected non-empty set of trusted certificates"); - } - KeyStore caKeyStore = newEmptyKeyStore(password); - int index = 0; - for (Certificate certificate : certificates) { - String certificateAlias = "ca" + Integer.toString(index++); - caKeyStore.setCertificateEntry(certificateAlias, certificate); - } - trustManagerFactory.init(caKeyStore); - } - trustManagers = trustManagerFactory.getTrustManagers(); - hostnameVerifier = OkHostnameVerifier.INSTANCE; - } - - SSLContext sslContext = SSLContext.getInstance("TLS"); - sslContext.init(keyManagers, trustManagers, new SecureRandom()); - httpClient = httpClient.newBuilder() - .sslSocketFactory(sslContext.getSocketFactory(), (X509TrustManager) trustManagers[0]) - .hostnameVerifier(hostnameVerifier) - .build(); - } catch (GeneralSecurityException e) { - throw new RuntimeException(e); - } - } - - private KeyStore newEmptyKeyStore(char[] password) throws GeneralSecurityException { - try { - KeyStore keyStore = KeyStore.getInstance(KeyStore.getDefaultType()); - keyStore.load(null, password); - return keyStore; - } catch (IOException e) { - throw new AssertionError(e); - } - } - - /** - * Convert the HTTP request body to a string. - * - * @param requestBody The HTTP request object - * @return The string representation of the HTTP request body - * @throws ApiException If fail to serialize the request body object into a string - */ - private String requestBodyToString(RequestBody requestBody) throws ApiException { - if (requestBody != null) { - try { - final Buffer buffer = new Buffer(); - requestBody.writeTo(buffer); - return buffer.readUtf8(); - } catch (final IOException e) { - throw new ApiException(e); - } - } - - // empty http request body - return ""; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/ApiException.java b/src/main/java/io/tiledb/cloud/rest_api/v1/ApiException.java deleted file mode 100644 index fdcbc09..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/ApiException.java +++ /dev/null @@ -1,166 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1; - -import java.util.Map; -import java.util.List; - -import javax.ws.rs.core.GenericType; - -/** - *

ApiException class.

- */ -@SuppressWarnings("serial") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ApiException extends Exception { - private int code = 0; - private Map> responseHeaders = null; - private String responseBody = null; - - /** - *

Constructor for ApiException.

- */ - public ApiException() {} - - /** - *

Constructor for ApiException.

- * - * @param throwable a {@link java.lang.Throwable} object - */ - public ApiException(Throwable throwable) { - super(throwable); - } - - /** - *

Constructor for ApiException.

- * - * @param message the error message - */ - public ApiException(String message) { - super(message); - } - - /** - *

Constructor for ApiException.

- * - * @param message the error message - * @param throwable a {@link java.lang.Throwable} object - * @param code HTTP status code - * @param responseHeaders a {@link java.util.Map} of HTTP response headers - * @param responseBody the response body - */ - public ApiException(String message, Throwable throwable, int code, Map> responseHeaders, String responseBody) { - super(message, throwable); - this.code = code; - this.responseHeaders = responseHeaders; - this.responseBody = responseBody; - } - - /** - *

Constructor for ApiException.

- * - * @param message the error message - * @param code HTTP status code - * @param responseHeaders a {@link java.util.Map} of HTTP response headers - * @param responseBody the response body - */ - public ApiException(String message, int code, Map> responseHeaders, String responseBody) { - this(message, (Throwable) null, code, responseHeaders, responseBody); - } - - /** - *

Constructor for ApiException.

- * - * @param message the error message - * @param throwable a {@link java.lang.Throwable} object - * @param code HTTP status code - * @param responseHeaders a {@link java.util.Map} of HTTP response headers - */ - public ApiException(String message, Throwable throwable, int code, Map> responseHeaders) { - this(message, throwable, code, responseHeaders, null); - } - - /** - *

Constructor for ApiException.

- * - * @param code HTTP status code - * @param responseHeaders a {@link java.util.Map} of HTTP response headers - * @param responseBody the response body - */ - public ApiException(int code, Map> responseHeaders, String responseBody) { - this((String) null, (Throwable) null, code, responseHeaders, responseBody); - } - - /** - *

Constructor for ApiException.

- * - * @param code HTTP status code - * @param message a {@link java.lang.String} object - */ - public ApiException(int code, String message) { - super(message); - this.code = code; - } - - /** - *

Constructor for ApiException.

- * - * @param code HTTP status code - * @param message the error message - * @param responseHeaders a {@link java.util.Map} of HTTP response headers - * @param responseBody the response body - */ - public ApiException(int code, String message, Map> responseHeaders, String responseBody) { - this(code, message); - this.responseHeaders = responseHeaders; - this.responseBody = responseBody; - } - - /** - * Get the HTTP status code. - * - * @return HTTP status code - */ - public int getCode() { - return code; - } - - /** - * Get the HTTP response headers. - * - * @return A map of list of string - */ - public Map> getResponseHeaders() { - return responseHeaders; - } - - /** - * Get the HTTP response body. - * - * @return Response body in the form of string - */ - public String getResponseBody() { - return responseBody; - } - - /** - * Get the exception message including HTTP response data. - * - * @return The exception message - */ - public String getMessage() { - return String.format("Message: %s%nHTTP response code: %s%nHTTP response body: %s%nHTTP response headers: %s", - super.getMessage(), this.getCode(), this.getResponseBody(), this.getResponseHeaders()); - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/ApiResponse.java b/src/main/java/io/tiledb/cloud/rest_api/v1/ApiResponse.java deleted file mode 100644 index d58e005..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/ApiResponse.java +++ /dev/null @@ -1,76 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1; - -import java.util.List; -import java.util.Map; - -/** - * API response returned by API call. - */ -public class ApiResponse { - final private int statusCode; - final private Map> headers; - final private T data; - - /** - *

Constructor for ApiResponse.

- * - * @param statusCode The status code of HTTP response - * @param headers The headers of HTTP response - */ - public ApiResponse(int statusCode, Map> headers) { - this(statusCode, headers, null); - } - - /** - *

Constructor for ApiResponse.

- * - * @param statusCode The status code of HTTP response - * @param headers The headers of HTTP response - * @param data The object deserialized from response bod - */ - public ApiResponse(int statusCode, Map> headers, T data) { - this.statusCode = statusCode; - this.headers = headers; - this.data = data; - } - - /** - *

Get the status code.

- * - * @return the status code - */ - public int getStatusCode() { - return statusCode; - } - - /** - *

Get the headers.

- * - * @return a {@link java.util.Map} of headers - */ - public Map> getHeaders() { - return headers; - } - - /** - *

Get the data.

- * - * @return the data - */ - public T getData() { - return data; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/Configuration.java b/src/main/java/io/tiledb/cloud/rest_api/v1/Configuration.java deleted file mode 100644 index 6d6864c..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/Configuration.java +++ /dev/null @@ -1,39 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1; - -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class Configuration { - private static ApiClient defaultApiClient = new ApiClient(); - - /** - * Get the default API client, which would be used when creating API - * instances without providing an API client. - * - * @return Default API client - */ - public static ApiClient getDefaultApiClient() { - return defaultApiClient; - } - - /** - * Set the default API client, which would be used when creating API - * instances without providing an API client. - * - * @param apiClient API client - */ - public static void setDefaultApiClient(ApiClient apiClient) { - defaultApiClient = apiClient; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/GzipRequestInterceptor.java b/src/main/java/io/tiledb/cloud/rest_api/v1/GzipRequestInterceptor.java deleted file mode 100644 index 588a150..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/GzipRequestInterceptor.java +++ /dev/null @@ -1,85 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1; - -import okhttp3.*; -import okio.Buffer; -import okio.BufferedSink; -import okio.GzipSink; -import okio.Okio; - -import java.io.IOException; - -/** - * Encodes request bodies using gzip. - * - * Taken from https://github.com/square/okhttp/issues/350 - */ -class GzipRequestInterceptor implements Interceptor { - @Override - public Response intercept(Chain chain) throws IOException { - Request originalRequest = chain.request(); - if (originalRequest.body() == null || originalRequest.header("Content-Encoding") != null) { - return chain.proceed(originalRequest); - } - - Request compressedRequest = originalRequest.newBuilder() - .header("Content-Encoding", "gzip") - .method(originalRequest.method(), forceContentLength(gzip(originalRequest.body()))) - .build(); - return chain.proceed(compressedRequest); - } - - private RequestBody forceContentLength(final RequestBody requestBody) throws IOException { - final Buffer buffer = new Buffer(); - requestBody.writeTo(buffer); - return new RequestBody() { - @Override - public MediaType contentType() { - return requestBody.contentType(); - } - - @Override - public long contentLength() { - return buffer.size(); - } - - @Override - public void writeTo(BufferedSink sink) throws IOException { - sink.write(buffer.snapshot()); - } - }; - } - - private RequestBody gzip(final RequestBody body) { - return new RequestBody() { - @Override - public MediaType contentType() { - return body.contentType(); - } - - @Override - public long contentLength() { - return -1; // We don't know the compressed length in advance! - } - - @Override - public void writeTo(BufferedSink sink) throws IOException { - BufferedSink gzipSink = Okio.buffer(new GzipSink(sink)); - body.writeTo(gzipSink); - gzipSink.close(); - } - }; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/JSON.java b/src/main/java/io/tiledb/cloud/rest_api/v1/JSON.java deleted file mode 100644 index abf1bbd..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/JSON.java +++ /dev/null @@ -1,536 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1; - -import com.google.gson.Gson; -import com.google.gson.GsonBuilder; -import com.google.gson.JsonParseException; -import com.google.gson.TypeAdapter; -import com.google.gson.internal.bind.util.ISO8601Utils; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import com.google.gson.JsonElement; -import io.gsonfire.GsonFireBuilder; - -import io.tiledb.cloud.rest_api.v1.model.*; -import io.tiledb.cloud.rest_api.v1.model.Error; -import okio.ByteString; - -import java.io.IOException; -import java.io.StringReader; -import java.lang.reflect.Type; -import java.text.DateFormat; -import java.text.ParseException; -import java.text.ParsePosition; -import java.time.LocalDate; -import java.time.OffsetDateTime; -import java.time.format.DateTimeFormatter; -import java.util.Date; -import java.util.Map; - -/* - * A JSON utility class - * - * NOTE: in the future, this class may be converted to static, which may break - * backward-compatibility - */ -public class JSON { - private static Gson gson; - private static boolean isLenientOnJson = false; - private static DateTypeAdapter dateTypeAdapter = new DateTypeAdapter(); - private static SqlDateTypeAdapter sqlDateTypeAdapter = new SqlDateTypeAdapter(); - private static OffsetDateTimeTypeAdapter offsetDateTimeTypeAdapter = new OffsetDateTimeTypeAdapter(); - private static LocalDateTypeAdapter localDateTypeAdapter = new LocalDateTypeAdapter(); - private static ByteArrayAdapter byteArrayAdapter = new ByteArrayAdapter(); - - @SuppressWarnings("unchecked") - public static GsonBuilder createGson() { - GsonFireBuilder fireBuilder = new GsonFireBuilder() - ; - GsonBuilder builder = fireBuilder.createGsonBuilder(); - return builder; - } - - private static String getDiscriminatorValue(JsonElement readElement, String discriminatorField) { - JsonElement element = readElement.getAsJsonObject().get(discriminatorField); - if (null == element) { - throw new IllegalArgumentException("missing discriminator field: <" + discriminatorField + ">"); - } - return element.getAsString(); - } - - /** - * Returns the Java class that implements the OpenAPI schema for the specified discriminator value. - * - * @param classByDiscriminatorValue The map of discriminator values to Java classes. - * @param discriminatorValue The value of the OpenAPI discriminator in the input data. - * @return The Java class that implements the OpenAPI schema - */ - private static Class getClassByDiscriminator(Map classByDiscriminatorValue, String discriminatorValue) { - Class clazz = (Class) classByDiscriminatorValue.get(discriminatorValue); - if (null == clazz) { - throw new IllegalArgumentException("cannot determine model class of name: <" + discriminatorValue + ">"); - } - return clazz; - } - - { - GsonBuilder gsonBuilder = createGson(); - gsonBuilder.registerTypeAdapter(Date.class, dateTypeAdapter); - gsonBuilder.registerTypeAdapter(java.sql.Date.class, sqlDateTypeAdapter); - gsonBuilder.registerTypeAdapter(OffsetDateTime.class, offsetDateTimeTypeAdapter); - gsonBuilder.registerTypeAdapter(LocalDate.class, localDateTypeAdapter); - gsonBuilder.registerTypeAdapter(byte[].class, byteArrayAdapter); - gsonBuilder.registerTypeAdapterFactory(new AWSAccessCredentials.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new Array.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new ArrayActivityLog.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new ArrayBrowserData.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new ArrayBrowserSidebar.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new ArrayConsolidationRequest.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new ArrayEndTimestampData.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new ArrayFavorite.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new io.tiledb.cloud.rest_api.v1.model.ArrayFavoritesData.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new ArrayInfo.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new ArrayInfoUpdate.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new ArrayMetadata.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new ArrayMetadataEntry.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new ArraySample.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new ArraySchema.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new ArraySharing.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new ArrayTask.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new ArrayTaskBrowserSidebar.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new ArrayTaskData.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new io.tiledb.cloud.rest_api.v1.model.ArrayTaskLog.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new ArrayVacuumRequest.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new AssetLocations.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new Attribute.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new AttributeBufferHeader.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new AttributeBufferSize.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new Backoff.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new Dimension.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new DimensionCoordinate.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new DimensionTileExtent.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new io.tiledb.cloud.rest_api.v1.model.Domain.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new DomainArray.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new DomainCheckResult.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new Error.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new FileCreate.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new FileCreated.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new FileExport.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new FileExported.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new FileUploaded.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new io.tiledb.cloud.rest_api.v1.model.Filter.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new FilterData.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new FilterPipeline.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new FragmentInfo.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new FragmentInfoRequest.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new FragmentMetadata.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new GenericUDF.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new GetTiledbStats200Response.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new GroupActivity.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new GroupActivityAsset.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new GroupActivityResponse.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new GroupBrowserData.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new GroupBrowserFilterData.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new GroupChanges.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new GroupContents.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new GroupContentsFilterData.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new GroupCreate.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new GroupEntry.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new GroupInfo.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new GroupMember.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new GroupRegister.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new GroupSharing.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new GroupSharingRequest.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new GroupUpdate.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new Invitation.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new InvitationArrayShareEmail.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new InvitationData.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new InvitationFailedRecipients.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new InvitationGroupShareEmail.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new InvitationOrganizationJoinEmail.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new LastAccessedArray.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new MLModelFavorite.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new MLModelFavoritesData.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new MaxBufferSizes.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new io.tiledb.cloud.rest_api.v1.model.MultiArrayUDF.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new NonEmptyDomain.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new NotebookCopied.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new NotebookCopy.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new NotebookFavorite.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new NotebookFavoritesData.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new NotebookStatus.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new Organization.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new OrganizationUser.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new PaginationMetadata.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new Pricing.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new Query.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new QueryJson.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new QueryRanges.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new QueryReader.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new ReadState.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new RegisteredTaskGraph.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new ResetUserPasswordRequest.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new RetryStrategy.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new SQLParameters.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new SSODomainConfig.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new SSODomainConfigResponse.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new SSODomainSetup.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new SingleFragmentInfo.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new StorageLocation.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new Subarray.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new SubarrayPartitioner.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new SubarrayPartitionerCurrent.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new SubarrayPartitionerState.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new SubarrayRanges.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new Subscription.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new TGArrayNodeData.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new TGInputNodeData.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new TGQueryRanges.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new TGSQLNodeData.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new TGUDFArgument.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new TGUDFEnvironment.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new TGUDFEnvironmentResources.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new io.tiledb.cloud.rest_api.v1.model.TGUDFNodeData.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new TaskGraph.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new TaskGraphClientNodeStatus.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new TaskGraphLog.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new TaskGraphLogsData.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new io.tiledb.cloud.rest_api.v1.model.TaskGraphNode.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new TaskGraphNodeMetadata.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new TaskGraphSharing.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new TaskGraphs.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new TileDBConfig.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new TileDBConfigEntriesInner.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new Token.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new TokenRequest.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new UDFArrayDetails.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new UDFCopied.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new UDFCopy.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new UDFFavorite.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new UDFFavoritesData.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new UDFImage.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new UDFImageVersion.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new UDFInfo.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new UDFInfoUpdate.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new UDFSharing.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new UDFSubarray.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new UDFSubarrayRange.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new User.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory(new Writer.CustomTypeAdapterFactory()); - gson = gsonBuilder.create(); - } - - /** - * Get Gson. - * - * @return Gson - */ - public static Gson getGson() { - return gson; - } - - /** - * Set Gson. - * - * @param gson Gson - */ - public static void setGson(Gson gson) { - JSON.gson = gson; - } - - public static void setLenientOnJson(boolean lenientOnJson) { - isLenientOnJson = lenientOnJson; - } - - /** - * Serialize the given Java object into JSON string. - * - * @param obj Object - * @return String representation of the JSON - */ - public static String serialize(Object obj) { - return gson.toJson(obj); - } - - /** - * Deserialize the given JSON string to Java object. - * - * @param Type - * @param body The JSON string - * @param returnType The type to deserialize into - * @return The deserialized Java object - */ - @SuppressWarnings("unchecked") - public static T deserialize(String body, Type returnType) { - try { - if (isLenientOnJson) { - JsonReader jsonReader = new JsonReader(new StringReader(body)); - // see https://google-gson.googlecode.com/svn/trunk/gson/docs/javadocs/com/google/gson/stream/JsonReader.html#setLenient(boolean) - jsonReader.setLenient(true); - return gson.fromJson(jsonReader, returnType); - } else { - return gson.fromJson(body, returnType); - } - } catch (JsonParseException e) { - // Fallback processing when failed to parse JSON form response body: - // return the response body string directly for the String return type; - if (returnType.equals(String.class)) { - return (T) body; - } else { - throw (e); - } - } - } - - /** - * Gson TypeAdapter for Byte Array type - */ - public static class ByteArrayAdapter extends TypeAdapter { - - @Override - public void write(JsonWriter out, byte[] value) throws IOException { - if (value == null) { - out.nullValue(); - } else { - out.value(ByteString.of(value).base64()); - } - } - - @Override - public byte[] read(JsonReader in) throws IOException { - switch (in.peek()) { - case NULL: - in.nextNull(); - return null; - default: - String bytesAsBase64 = in.nextString(); - ByteString byteString = ByteString.decodeBase64(bytesAsBase64); - return byteString.toByteArray(); - } - } - } - - /** - * Gson TypeAdapter for JSR310 OffsetDateTime type - */ - public static class OffsetDateTimeTypeAdapter extends TypeAdapter { - - private DateTimeFormatter formatter; - - public OffsetDateTimeTypeAdapter() { - this(DateTimeFormatter.ISO_OFFSET_DATE_TIME); - } - - public OffsetDateTimeTypeAdapter(DateTimeFormatter formatter) { - this.formatter = formatter; - } - - public void setFormat(DateTimeFormatter dateFormat) { - this.formatter = dateFormat; - } - - @Override - public void write(JsonWriter out, OffsetDateTime date) throws IOException { - if (date == null) { - out.nullValue(); - } else { - out.value(formatter.format(date)); - } - } - - @Override - public OffsetDateTime read(JsonReader in) throws IOException { - switch (in.peek()) { - case NULL: - in.nextNull(); - return null; - default: - String date = in.nextString(); - if (date.endsWith("+0000")) { - date = date.substring(0, date.length()-5) + "Z"; - } - return OffsetDateTime.parse(date, formatter); - } - } - } - - /** - * Gson TypeAdapter for JSR310 LocalDate type - */ - public static class LocalDateTypeAdapter extends TypeAdapter { - - private DateTimeFormatter formatter; - - public LocalDateTypeAdapter() { - this(DateTimeFormatter.ISO_LOCAL_DATE); - } - - public LocalDateTypeAdapter(DateTimeFormatter formatter) { - this.formatter = formatter; - } - - public void setFormat(DateTimeFormatter dateFormat) { - this.formatter = dateFormat; - } - - @Override - public void write(JsonWriter out, LocalDate date) throws IOException { - if (date == null) { - out.nullValue(); - } else { - out.value(formatter.format(date)); - } - } - - @Override - public LocalDate read(JsonReader in) throws IOException { - switch (in.peek()) { - case NULL: - in.nextNull(); - return null; - default: - String date = in.nextString(); - return LocalDate.parse(date, formatter); - } - } - } - - public static void setOffsetDateTimeFormat(DateTimeFormatter dateFormat) { - offsetDateTimeTypeAdapter.setFormat(dateFormat); - } - - public static void setLocalDateFormat(DateTimeFormatter dateFormat) { - localDateTypeAdapter.setFormat(dateFormat); - } - - /** - * Gson TypeAdapter for java.sql.Date type - * If the dateFormat is null, a simple "yyyy-MM-dd" format will be used - * (more efficient than SimpleDateFormat). - */ - public static class SqlDateTypeAdapter extends TypeAdapter { - - private DateFormat dateFormat; - - public SqlDateTypeAdapter() {} - - public SqlDateTypeAdapter(DateFormat dateFormat) { - this.dateFormat = dateFormat; - } - - public void setFormat(DateFormat dateFormat) { - this.dateFormat = dateFormat; - } - - @Override - public void write(JsonWriter out, java.sql.Date date) throws IOException { - if (date == null) { - out.nullValue(); - } else { - String value; - if (dateFormat != null) { - value = dateFormat.format(date); - } else { - value = date.toString(); - } - out.value(value); - } - } - - @Override - public java.sql.Date read(JsonReader in) throws IOException { - switch (in.peek()) { - case NULL: - in.nextNull(); - return null; - default: - String date = in.nextString(); - try { - if (dateFormat != null) { - return new java.sql.Date(dateFormat.parse(date).getTime()); - } - return new java.sql.Date(ISO8601Utils.parse(date, new ParsePosition(0)).getTime()); - } catch (ParseException e) { - throw new JsonParseException(e); - } - } - } - } - - /** - * Gson TypeAdapter for java.util.Date type - * If the dateFormat is null, ISO8601Utils will be used. - */ - public static class DateTypeAdapter extends TypeAdapter { - - private DateFormat dateFormat; - - public DateTypeAdapter() {} - - public DateTypeAdapter(DateFormat dateFormat) { - this.dateFormat = dateFormat; - } - - public void setFormat(DateFormat dateFormat) { - this.dateFormat = dateFormat; - } - - @Override - public void write(JsonWriter out, Date date) throws IOException { - if (date == null) { - out.nullValue(); - } else { - String value; - if (dateFormat != null) { - value = dateFormat.format(date); - } else { - value = ISO8601Utils.format(date, true); - } - out.value(value); - } - } - - @Override - public Date read(JsonReader in) throws IOException { - try { - switch (in.peek()) { - case NULL: - in.nextNull(); - return null; - default: - String date = in.nextString(); - try { - if (dateFormat != null) { - return dateFormat.parse(date); - } - return ISO8601Utils.parse(date, new ParsePosition(0)); - } catch (ParseException e) { - throw new JsonParseException(e); - } - } - } catch (IllegalArgumentException e) { - throw new JsonParseException(e); - } - } - } - - public static void setDateFormat(DateFormat dateFormat) { - dateTypeAdapter.setFormat(dateFormat); - } - - public static void setSqlDateFormat(DateFormat dateFormat) { - sqlDateTypeAdapter.setFormat(dateFormat); - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/Pair.java b/src/main/java/io/tiledb/cloud/rest_api/v1/Pair.java deleted file mode 100644 index 7e1eb2d..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/Pair.java +++ /dev/null @@ -1,57 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1; - -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class Pair { - private String name = ""; - private String value = ""; - - public Pair (String name, String value) { - setName(name); - setValue(value); - } - - private void setName(String name) { - if (!isValidString(name)) { - return; - } - - this.name = name; - } - - private void setValue(String value) { - if (!isValidString(value)) { - return; - } - - this.value = value; - } - - public String getName() { - return this.name; - } - - public String getValue() { - return this.value; - } - - private boolean isValidString(String arg) { - if (arg == null) { - return false; - } - - return true; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/ProgressRequestBody.java b/src/main/java/io/tiledb/cloud/rest_api/v1/ProgressRequestBody.java deleted file mode 100644 index 1209c86..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/ProgressRequestBody.java +++ /dev/null @@ -1,73 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1; - -import okhttp3.MediaType; -import okhttp3.RequestBody; - -import java.io.IOException; - -import okio.Buffer; -import okio.BufferedSink; -import okio.ForwardingSink; -import okio.Okio; -import okio.Sink; - -public class ProgressRequestBody extends RequestBody { - - private final RequestBody requestBody; - - private final ApiCallback callback; - - public ProgressRequestBody(RequestBody requestBody, ApiCallback callback) { - this.requestBody = requestBody; - this.callback = callback; - } - - @Override - public MediaType contentType() { - return requestBody.contentType(); - } - - @Override - public long contentLength() throws IOException { - return requestBody.contentLength(); - } - - @Override - public void writeTo(BufferedSink sink) throws IOException { - BufferedSink bufferedSink = Okio.buffer(sink(sink)); - requestBody.writeTo(bufferedSink); - bufferedSink.flush(); - } - - private Sink sink(Sink sink) { - return new ForwardingSink(sink) { - - long bytesWritten = 0L; - long contentLength = 0L; - - @Override - public void write(Buffer source, long byteCount) throws IOException { - super.write(source, byteCount); - if (contentLength == 0) { - contentLength = contentLength(); - } - - bytesWritten += byteCount; - callback.onUploadProgress(bytesWritten, contentLength, bytesWritten == contentLength); - } - }; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/ProgressResponseBody.java b/src/main/java/io/tiledb/cloud/rest_api/v1/ProgressResponseBody.java deleted file mode 100644 index fc12fb4..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/ProgressResponseBody.java +++ /dev/null @@ -1,70 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1; - -import okhttp3.MediaType; -import okhttp3.ResponseBody; - -import java.io.IOException; - -import okio.Buffer; -import okio.BufferedSource; -import okio.ForwardingSource; -import okio.Okio; -import okio.Source; - -public class ProgressResponseBody extends ResponseBody { - - private final ResponseBody responseBody; - private final ApiCallback callback; - private BufferedSource bufferedSource; - - public ProgressResponseBody(ResponseBody responseBody, ApiCallback callback) { - this.responseBody = responseBody; - this.callback = callback; - } - - @Override - public MediaType contentType() { - return responseBody.contentType(); - } - - @Override - public long contentLength() { - return responseBody.contentLength(); - } - - @Override - public BufferedSource source() { - if (bufferedSource == null) { - bufferedSource = Okio.buffer(source(responseBody.source())); - } - return bufferedSource; - } - - private Source source(Source source) { - return new ForwardingSource(source) { - long totalBytesRead = 0L; - - @Override - public long read(Buffer sink, long byteCount) throws IOException { - long bytesRead = super.read(sink, byteCount); - // read() returns the number of bytes read, or -1 if this source is exhausted. - totalBytesRead += bytesRead != -1 ? bytesRead : 0; - callback.onDownloadProgress(totalBytesRead, responseBody.contentLength(), bytesRead == -1); - return bytesRead; - } - }; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/ServerConfiguration.java b/src/main/java/io/tiledb/cloud/rest_api/v1/ServerConfiguration.java deleted file mode 100644 index a090382..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/ServerConfiguration.java +++ /dev/null @@ -1,58 +0,0 @@ -package io.tiledb.cloud.rest_api.v1; - -import java.util.Map; - -/** - * Representing a Server configuration. - */ -public class ServerConfiguration { - public String URL; - public String description; - public Map variables; - - /** - * @param URL A URL to the target host. - * @param description A description of the host designated by the URL. - * @param variables A map between a variable name and its value. The value is used for substitution in the server's URL template. - */ - public ServerConfiguration(String URL, String description, Map variables) { - this.URL = URL; - this.description = description; - this.variables = variables; - } - - /** - * Format URL template using given variables. - * - * @param variables A map between a variable name and its value. - * @return Formatted URL. - */ - public String URL(Map variables) { - String url = this.URL; - - // go through variables and replace placeholders - for (Map.Entry variable: this.variables.entrySet()) { - String name = variable.getKey(); - ServerVariable serverVariable = variable.getValue(); - String value = serverVariable.defaultValue; - - if (variables != null && variables.containsKey(name)) { - value = variables.get(name); - if (serverVariable.enumValues.size() > 0 && !serverVariable.enumValues.contains(value)) { - throw new IllegalArgumentException("The variable " + name + " in the server URL has invalid value " + value + "."); - } - } - url = url.replaceAll("\\{" + name + "\\}", value); - } - return url; - } - - /** - * Format URL template using default server variables. - * - * @return Formatted URL. - */ - public String URL() { - return URL(null); - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/ServerVariable.java b/src/main/java/io/tiledb/cloud/rest_api/v1/ServerVariable.java deleted file mode 100644 index db808bc..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/ServerVariable.java +++ /dev/null @@ -1,23 +0,0 @@ -package io.tiledb.cloud.rest_api.v1; - -import java.util.HashSet; - -/** - * Representing a Server Variable for server URL template substitution. - */ -public class ServerVariable { - public String description; - public String defaultValue; - public HashSet enumValues = null; - - /** - * @param description A description for the server variable. - * @param defaultValue The default value to use for substitution. - * @param enumValues An enumeration of string values to be used if the substitution options are from a limited set. - */ - public ServerVariable(String description, String defaultValue, HashSet enumValues) { - this.description = description; - this.defaultValue = defaultValue; - this.enumValues = enumValues; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/StringUtil.java b/src/main/java/io/tiledb/cloud/rest_api/v1/StringUtil.java deleted file mode 100644 index 5c87547..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/StringUtil.java +++ /dev/null @@ -1,83 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1; - -import java.util.Collection; -import java.util.Iterator; - -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class StringUtil { - /** - * Check if the given array contains the given value (with case-insensitive comparison). - * - * @param array The array - * @param value The value to search - * @return true if the array contains the value - */ - public static boolean containsIgnoreCase(String[] array, String value) { - for (String str : array) { - if (value == null && str == null) { - return true; - } - if (value != null && value.equalsIgnoreCase(str)) { - return true; - } - } - return false; - } - - /** - * Join an array of strings with the given separator. - *

- * Note: This might be replaced by utility method from commons-lang or guava someday - * if one of those libraries is added as dependency. - *

- * - * @param array The array of strings - * @param separator The separator - * @return the resulting string - */ - public static String join(String[] array, String separator) { - int len = array.length; - if (len == 0) { - return ""; - } - - StringBuilder out = new StringBuilder(); - out.append(array[0]); - for (int i = 1; i < len; i++) { - out.append(separator).append(array[i]); - } - return out.toString(); - } - - /** - * Join a list of strings with the given separator. - * - * @param list The list of strings - * @param separator The separator - * @return the resulting string - */ - public static String join(Collection list, String separator) { - Iterator iterator = list.iterator(); - StringBuilder out = new StringBuilder(); - if (iterator.hasNext()) { - out.append(iterator.next()); - } - while (iterator.hasNext()) { - out.append(separator).append(iterator.next()); - } - return out.toString(); - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/api/ArrayApi.java b/src/main/java/io/tiledb/cloud/rest_api/v1/api/ArrayApi.java deleted file mode 100644 index 661e09c..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/api/ArrayApi.java +++ /dev/null @@ -1,5176 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.api; - -import io.tiledb.cloud.rest_api.v1.ApiCallback; -import io.tiledb.cloud.rest_api.v1.ApiClient; -import io.tiledb.cloud.rest_api.v1.ApiException; -import io.tiledb.cloud.rest_api.v1.ApiResponse; -import io.tiledb.cloud.rest_api.v1.Configuration; -import io.tiledb.cloud.rest_api.v1.Pair; - -import com.google.gson.reflect.TypeToken; - - -import io.tiledb.cloud.rest_api.v1.model.ArrayActivityLog; -import io.tiledb.cloud.rest_api.v1.model.ArrayBrowserData; -import io.tiledb.cloud.rest_api.v1.model.ArrayBrowserSidebar; -import io.tiledb.cloud.rest_api.v1.model.ArrayConsolidationRequest; -import io.tiledb.cloud.rest_api.v1.model.ArrayEndTimestampData; -import io.tiledb.cloud.rest_api.v1.model.ArrayInfo; -import io.tiledb.cloud.rest_api.v1.model.ArrayInfoUpdate; -import io.tiledb.cloud.rest_api.v1.model.ArrayMetadata; -import io.tiledb.cloud.rest_api.v1.model.ArraySample; -import io.tiledb.cloud.rest_api.v1.model.ArraySchema; -import io.tiledb.cloud.rest_api.v1.model.ArraySharing; -import io.tiledb.cloud.rest_api.v1.model.ArrayVacuumRequest; -import java.math.BigDecimal; - -import io.tiledb.cloud.rest_api.v1.model.FragmentInfo; -import io.tiledb.cloud.rest_api.v1.model.FragmentInfoRequest; -import io.tiledb.cloud.rest_api.v1.model.LastAccessedArray; -import io.tiledb.cloud.rest_api.v1.model.MaxBufferSizes; -import io.tiledb.cloud.rest_api.v1.model.NonEmptyDomain; - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class ArrayApi { - private ApiClient localVarApiClient; - private int localHostIndex; - private String localCustomBaseUrl; - - public ArrayApi() { - this(Configuration.getDefaultApiClient()); - } - - public ArrayApi(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public ApiClient getApiClient() { - return localVarApiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public int getHostIndex() { - return localHostIndex; - } - - public void setHostIndex(int hostIndex) { - this.localHostIndex = hostIndex; - } - - public String getCustomBaseUrl() { - return localCustomBaseUrl; - } - - public void setCustomBaseUrl(String customBaseUrl) { - this.localCustomBaseUrl = customBaseUrl; - } - - /** - * Build call for arrayActivityLog - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param start Start time of window of fetch logs, unix epoch in seconds (default: seven days ago) (optional) - * @param end End time of window of fetch logs, unix epoch in seconds (default: current utc timestamp) (optional) - * @param eventTypes Refer to ActivityEventType for possible values (optional) - * @param taskId Array task ID To filter activity to (optional) - * @param hasTaskId Excludes activity log results that do not contain an array task UUID (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 log of array activity -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call arrayActivityLogCall(String namespace, String array, Integer start, Integer end, String eventTypes, String taskId, Boolean hasTaskId, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/activity" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (start != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("start", start)); - } - - if (end != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("end", end)); - } - - if (eventTypes != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("event_types", eventTypes)); - } - - if (taskId != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("task_id", taskId)); - } - - if (hasTaskId != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("has_task_id", hasTaskId)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call arrayActivityLogValidateBeforeCall(String namespace, String array, Integer start, Integer end, String eventTypes, String taskId, Boolean hasTaskId, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling arrayActivityLog(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling arrayActivityLog(Async)"); - } - - - okhttp3.Call localVarCall = arrayActivityLogCall(namespace, array, start, end, eventTypes, taskId, hasTaskId, _callback); - return localVarCall; - - } - - /** - * - * get array activity logs - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param start Start time of window of fetch logs, unix epoch in seconds (default: seven days ago) (optional) - * @param end End time of window of fetch logs, unix epoch in seconds (default: current utc timestamp) (optional) - * @param eventTypes Refer to ActivityEventType for possible values (optional) - * @param taskId Array task ID To filter activity to (optional) - * @param hasTaskId Excludes activity log results that do not contain an array task UUID (optional) - * @return List<ArrayActivityLog> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 log of array activity -
502 Bad Gateway -
0 error response -
- */ - public List arrayActivityLog(String namespace, String array, Integer start, Integer end, String eventTypes, String taskId, Boolean hasTaskId) throws ApiException { - ApiResponse> localVarResp = arrayActivityLogWithHttpInfo(namespace, array, start, end, eventTypes, taskId, hasTaskId); - return localVarResp.getData(); - } - - /** - * - * get array activity logs - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param start Start time of window of fetch logs, unix epoch in seconds (default: seven days ago) (optional) - * @param end End time of window of fetch logs, unix epoch in seconds (default: current utc timestamp) (optional) - * @param eventTypes Refer to ActivityEventType for possible values (optional) - * @param taskId Array task ID To filter activity to (optional) - * @param hasTaskId Excludes activity log results that do not contain an array task UUID (optional) - * @return ApiResponse<List<ArrayActivityLog>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 log of array activity -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse> arrayActivityLogWithHttpInfo(String namespace, String array, Integer start, Integer end, String eventTypes, String taskId, Boolean hasTaskId) throws ApiException { - okhttp3.Call localVarCall = arrayActivityLogValidateBeforeCall(namespace, array, start, end, eventTypes, taskId, hasTaskId, null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * get array activity logs - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param start Start time of window of fetch logs, unix epoch in seconds (default: seven days ago) (optional) - * @param end End time of window of fetch logs, unix epoch in seconds (default: current utc timestamp) (optional) - * @param eventTypes Refer to ActivityEventType for possible values (optional) - * @param taskId Array task ID To filter activity to (optional) - * @param hasTaskId Excludes activity log results that do not contain an array task UUID (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 log of array activity -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call arrayActivityLogAsync(String namespace, String array, Integer start, Integer end, String eventTypes, String taskId, Boolean hasTaskId, final ApiCallback> _callback) throws ApiException { - - okhttp3.Call localVarCall = arrayActivityLogValidateBeforeCall(namespace, array, start, end, eventTypes, taskId, hasTaskId, _callback); - Type localVarReturnType = new TypeToken>(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for arraysBrowserOwnedGet - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that are owned directly by user or user's organizations -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call arraysBrowserOwnedGetCall(Integer page, Integer perPage, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, List fileType, List excludeFileType, List fileProperty, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/browser/owned"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (page != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("page", page)); - } - - if (perPage != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("per_page", perPage)); - } - - if (search != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("search", search)); - } - - if (namespace != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("namespace", namespace)); - } - - if (orderby != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("orderby", orderby)); - } - - if (permissions != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("permissions", permissions)); - } - - if (tag != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "tag", tag)); - } - - if (excludeTag != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "exclude_tag", excludeTag)); - } - - if (fileType != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "file_type", fileType)); - } - - if (excludeFileType != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "exclude_file_type", excludeFileType)); - } - - if (fileProperty != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "file_property", fileProperty)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call arraysBrowserOwnedGetValidateBeforeCall(Integer page, Integer perPage, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, List fileType, List excludeFileType, List fileProperty, final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = arraysBrowserOwnedGetCall(page, perPage, search, namespace, orderby, permissions, tag, excludeTag, fileType, excludeFileType, fileProperty, _callback); - return localVarCall; - - } - - /** - * - * Fetch a list of all arrays that are owned directly by user or user's organizations - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @return ArrayBrowserData - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that are owned directly by user or user's organizations -
502 Bad Gateway -
0 error response -
- */ - public ArrayBrowserData arraysBrowserOwnedGet(Integer page, Integer perPage, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, List fileType, List excludeFileType, List fileProperty) throws ApiException { - ApiResponse localVarResp = arraysBrowserOwnedGetWithHttpInfo(page, perPage, search, namespace, orderby, permissions, tag, excludeTag, fileType, excludeFileType, fileProperty); - return localVarResp.getData(); - } - - /** - * - * Fetch a list of all arrays that are owned directly by user or user's organizations - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @return ApiResponse<ArrayBrowserData> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that are owned directly by user or user's organizations -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse arraysBrowserOwnedGetWithHttpInfo(Integer page, Integer perPage, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, List fileType, List excludeFileType, List fileProperty) throws ApiException { - okhttp3.Call localVarCall = arraysBrowserOwnedGetValidateBeforeCall(page, perPage, search, namespace, orderby, permissions, tag, excludeTag, fileType, excludeFileType, fileProperty, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch a list of all arrays that are owned directly by user or user's organizations - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that are owned directly by user or user's organizations -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call arraysBrowserOwnedGetAsync(Integer page, Integer perPage, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, List fileType, List excludeFileType, List fileProperty, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = arraysBrowserOwnedGetValidateBeforeCall(page, perPage, search, namespace, orderby, permissions, tag, excludeTag, fileType, excludeFileType, fileProperty, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for arraysBrowserOwnedSidebarGet - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that are owned directly by user or user's organizations -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call arraysBrowserOwnedSidebarGetCall(List fileType, List excludeFileType, List fileProperty, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/browser/owned/sidebar"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (fileType != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "file_type", fileType)); - } - - if (excludeFileType != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "exclude_file_type", excludeFileType)); - } - - if (fileProperty != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "file_property", fileProperty)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call arraysBrowserOwnedSidebarGetValidateBeforeCall(List fileType, List excludeFileType, List fileProperty, final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = arraysBrowserOwnedSidebarGetCall(fileType, excludeFileType, fileProperty, _callback); - return localVarCall; - - } - - /** - * - * Fetch a sidebar for arrays that are owned directly by user or user's organizations - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @return ArrayBrowserSidebar - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that are owned directly by user or user's organizations -
502 Bad Gateway -
0 error response -
- */ - public ArrayBrowserSidebar arraysBrowserOwnedSidebarGet(List fileType, List excludeFileType, List fileProperty) throws ApiException { - ApiResponse localVarResp = arraysBrowserOwnedSidebarGetWithHttpInfo(fileType, excludeFileType, fileProperty); - return localVarResp.getData(); - } - - /** - * - * Fetch a sidebar for arrays that are owned directly by user or user's organizations - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @return ApiResponse<ArrayBrowserSidebar> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that are owned directly by user or user's organizations -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse arraysBrowserOwnedSidebarGetWithHttpInfo(List fileType, List excludeFileType, List fileProperty) throws ApiException { - okhttp3.Call localVarCall = arraysBrowserOwnedSidebarGetValidateBeforeCall(fileType, excludeFileType, fileProperty, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch a sidebar for arrays that are owned directly by user or user's organizations - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that are owned directly by user or user's organizations -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call arraysBrowserOwnedSidebarGetAsync(List fileType, List excludeFileType, List fileProperty, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = arraysBrowserOwnedSidebarGetValidateBeforeCall(fileType, excludeFileType, fileProperty, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for arraysBrowserPublicGet - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that has been shared publically -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call arraysBrowserPublicGetCall(Integer page, Integer perPage, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, List fileType, List excludeFileType, List fileProperty, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/browser/public"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (page != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("page", page)); - } - - if (perPage != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("per_page", perPage)); - } - - if (search != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("search", search)); - } - - if (namespace != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("namespace", namespace)); - } - - if (orderby != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("orderby", orderby)); - } - - if (permissions != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("permissions", permissions)); - } - - if (tag != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "tag", tag)); - } - - if (excludeTag != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "exclude_tag", excludeTag)); - } - - if (fileType != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "file_type", fileType)); - } - - if (excludeFileType != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "exclude_file_type", excludeFileType)); - } - - if (fileProperty != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "file_property", fileProperty)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call arraysBrowserPublicGetValidateBeforeCall(Integer page, Integer perPage, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, List fileType, List excludeFileType, List fileProperty, final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = arraysBrowserPublicGetCall(page, perPage, search, namespace, orderby, permissions, tag, excludeTag, fileType, excludeFileType, fileProperty, _callback); - return localVarCall; - - } - - /** - * - * Fetch a list of all arrays that have been shared publically - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @return ArrayBrowserData - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that has been shared publically -
502 Bad Gateway -
0 error response -
- */ - public ArrayBrowserData arraysBrowserPublicGet(Integer page, Integer perPage, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, List fileType, List excludeFileType, List fileProperty) throws ApiException { - ApiResponse localVarResp = arraysBrowserPublicGetWithHttpInfo(page, perPage, search, namespace, orderby, permissions, tag, excludeTag, fileType, excludeFileType, fileProperty); - return localVarResp.getData(); - } - - /** - * - * Fetch a list of all arrays that have been shared publically - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @return ApiResponse<ArrayBrowserData> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that has been shared publically -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse arraysBrowserPublicGetWithHttpInfo(Integer page, Integer perPage, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, List fileType, List excludeFileType, List fileProperty) throws ApiException { - okhttp3.Call localVarCall = arraysBrowserPublicGetValidateBeforeCall(page, perPage, search, namespace, orderby, permissions, tag, excludeTag, fileType, excludeFileType, fileProperty, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch a list of all arrays that have been shared publically - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that has been shared publically -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call arraysBrowserPublicGetAsync(Integer page, Integer perPage, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, List fileType, List excludeFileType, List fileProperty, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = arraysBrowserPublicGetValidateBeforeCall(page, perPage, search, namespace, orderby, permissions, tag, excludeTag, fileType, excludeFileType, fileProperty, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for arraysBrowserPublicSidebarGet - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that has been shared publically -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call arraysBrowserPublicSidebarGetCall(List fileType, List excludeFileType, List fileProperty, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/browser/public/sidebar"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (fileType != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "file_type", fileType)); - } - - if (excludeFileType != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "exclude_file_type", excludeFileType)); - } - - if (fileProperty != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "file_property", fileProperty)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call arraysBrowserPublicSidebarGetValidateBeforeCall(List fileType, List excludeFileType, List fileProperty, final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = arraysBrowserPublicSidebarGetCall(fileType, excludeFileType, fileProperty, _callback); - return localVarCall; - - } - - /** - * - * Fetch a sidebar of all arrays that have been shared publically - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @return ArrayBrowserSidebar - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that has been shared publically -
502 Bad Gateway -
0 error response -
- */ - public ArrayBrowserSidebar arraysBrowserPublicSidebarGet(List fileType, List excludeFileType, List fileProperty) throws ApiException { - ApiResponse localVarResp = arraysBrowserPublicSidebarGetWithHttpInfo(fileType, excludeFileType, fileProperty); - return localVarResp.getData(); - } - - /** - * - * Fetch a sidebar of all arrays that have been shared publically - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @return ApiResponse<ArrayBrowserSidebar> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that has been shared publically -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse arraysBrowserPublicSidebarGetWithHttpInfo(List fileType, List excludeFileType, List fileProperty) throws ApiException { - okhttp3.Call localVarCall = arraysBrowserPublicSidebarGetValidateBeforeCall(fileType, excludeFileType, fileProperty, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch a sidebar of all arrays that have been shared publically - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that has been shared publically -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call arraysBrowserPublicSidebarGetAsync(List fileType, List excludeFileType, List fileProperty, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = arraysBrowserPublicSidebarGetValidateBeforeCall(fileType, excludeFileType, fileProperty, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for arraysBrowserSharedGet - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @param sharedTo namespaces to filter results of where there arrays were shared to (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that has been shared with the user -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call arraysBrowserSharedGetCall(Integer page, Integer perPage, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, List fileType, List excludeFileType, List fileProperty, List sharedTo, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/browser/shared"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (page != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("page", page)); - } - - if (perPage != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("per_page", perPage)); - } - - if (search != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("search", search)); - } - - if (namespace != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("namespace", namespace)); - } - - if (orderby != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("orderby", orderby)); - } - - if (permissions != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("permissions", permissions)); - } - - if (tag != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "tag", tag)); - } - - if (excludeTag != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "exclude_tag", excludeTag)); - } - - if (fileType != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "file_type", fileType)); - } - - if (excludeFileType != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "exclude_file_type", excludeFileType)); - } - - if (fileProperty != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "file_property", fileProperty)); - } - - if (sharedTo != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "shared_to", sharedTo)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call arraysBrowserSharedGetValidateBeforeCall(Integer page, Integer perPage, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, List fileType, List excludeFileType, List fileProperty, List sharedTo, final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = arraysBrowserSharedGetCall(page, perPage, search, namespace, orderby, permissions, tag, excludeTag, fileType, excludeFileType, fileProperty, sharedTo, _callback); - return localVarCall; - - } - - /** - * - * Fetch a list of all arrays that have been shared with the user - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @param sharedTo namespaces to filter results of where there arrays were shared to (optional) - * @return ArrayBrowserData - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that has been shared with the user -
502 Bad Gateway -
0 error response -
- */ - public ArrayBrowserData arraysBrowserSharedGet(Integer page, Integer perPage, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, List fileType, List excludeFileType, List fileProperty, List sharedTo) throws ApiException { - ApiResponse localVarResp = arraysBrowserSharedGetWithHttpInfo(page, perPage, search, namespace, orderby, permissions, tag, excludeTag, fileType, excludeFileType, fileProperty, sharedTo); - return localVarResp.getData(); - } - - /** - * - * Fetch a list of all arrays that have been shared with the user - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @param sharedTo namespaces to filter results of where there arrays were shared to (optional) - * @return ApiResponse<ArrayBrowserData> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that has been shared with the user -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse arraysBrowserSharedGetWithHttpInfo(Integer page, Integer perPage, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, List fileType, List excludeFileType, List fileProperty, List sharedTo) throws ApiException { - okhttp3.Call localVarCall = arraysBrowserSharedGetValidateBeforeCall(page, perPage, search, namespace, orderby, permissions, tag, excludeTag, fileType, excludeFileType, fileProperty, sharedTo, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch a list of all arrays that have been shared with the user - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @param sharedTo namespaces to filter results of where there arrays were shared to (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that has been shared with the user -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call arraysBrowserSharedGetAsync(Integer page, Integer perPage, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, List fileType, List excludeFileType, List fileProperty, List sharedTo, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = arraysBrowserSharedGetValidateBeforeCall(page, perPage, search, namespace, orderby, permissions, tag, excludeTag, fileType, excludeFileType, fileProperty, sharedTo, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for arraysBrowserSharedSidebarGet - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @param sharedTo namespaces to filter results of where there groups were shared to (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that has been shared with the user -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call arraysBrowserSharedSidebarGetCall(List fileType, List excludeFileType, List fileProperty, List sharedTo, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/browser/shared/sidebar"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (fileType != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "file_type", fileType)); - } - - if (excludeFileType != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "exclude_file_type", excludeFileType)); - } - - if (fileProperty != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "file_property", fileProperty)); - } - - if (sharedTo != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "shared_to", sharedTo)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call arraysBrowserSharedSidebarGetValidateBeforeCall(List fileType, List excludeFileType, List fileProperty, List sharedTo, final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = arraysBrowserSharedSidebarGetCall(fileType, excludeFileType, fileProperty, sharedTo, _callback); - return localVarCall; - - } - - /** - * - * Fetch a list of all arrays that have been shared with the user - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @param sharedTo namespaces to filter results of where there groups were shared to (optional) - * @return ArrayBrowserSidebar - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that has been shared with the user -
502 Bad Gateway -
0 error response -
- */ - public ArrayBrowserSidebar arraysBrowserSharedSidebarGet(List fileType, List excludeFileType, List fileProperty, List sharedTo) throws ApiException { - ApiResponse localVarResp = arraysBrowserSharedSidebarGetWithHttpInfo(fileType, excludeFileType, fileProperty, sharedTo); - return localVarResp.getData(); - } - - /** - * - * Fetch a list of all arrays that have been shared with the user - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @param sharedTo namespaces to filter results of where there groups were shared to (optional) - * @return ApiResponse<ArrayBrowserSidebar> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that has been shared with the user -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse arraysBrowserSharedSidebarGetWithHttpInfo(List fileType, List excludeFileType, List fileProperty, List sharedTo) throws ApiException { - okhttp3.Call localVarCall = arraysBrowserSharedSidebarGetValidateBeforeCall(fileType, excludeFileType, fileProperty, sharedTo, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch a list of all arrays that have been shared with the user - * @param fileType file_type to search for, more than one can be included (optional) - * @param excludeFileType file_type to exclude matching array in results, more than one can be included (optional) - * @param fileProperty file_property key-value pair (comma separated, i.e. key,value) to search for, more than one can be included (optional) - * @param sharedTo namespaces to filter results of where there groups were shared to (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of array info that has been shared with the user -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call arraysBrowserSharedSidebarGetAsync(List fileType, List excludeFileType, List fileProperty, List sharedTo, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = arraysBrowserSharedSidebarGetValidateBeforeCall(fileType, excludeFileType, fileProperty, sharedTo, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for arraysNamespaceArrayEndTimestampsGet - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 list of timestamps in milliseconds, paginated -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call arraysNamespaceArrayEndTimestampsGetCall(String namespace, String array, Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/end_timestamps" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (page != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("page", page)); - } - - if (perPage != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("per_page", perPage)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call arraysNamespaceArrayEndTimestampsGetValidateBeforeCall(String namespace, String array, Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling arraysNamespaceArrayEndTimestampsGet(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling arraysNamespaceArrayEndTimestampsGet(Async)"); - } - - - okhttp3.Call localVarCall = arraysNamespaceArrayEndTimestampsGetCall(namespace, array, page, perPage, _callback); - return localVarCall; - - } - - /** - * - * retrieve a list of timestamps from the array fragment info listing in milliseconds, paginated - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @return ArrayEndTimestampData - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 list of timestamps in milliseconds, paginated -
502 Bad Gateway -
0 error response -
- */ - public ArrayEndTimestampData arraysNamespaceArrayEndTimestampsGet(String namespace, String array, Integer page, Integer perPage) throws ApiException { - ApiResponse localVarResp = arraysNamespaceArrayEndTimestampsGetWithHttpInfo(namespace, array, page, perPage); - return localVarResp.getData(); - } - - /** - * - * retrieve a list of timestamps from the array fragment info listing in milliseconds, paginated - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @return ApiResponse<ArrayEndTimestampData> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 list of timestamps in milliseconds, paginated -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse arraysNamespaceArrayEndTimestampsGetWithHttpInfo(String namespace, String array, Integer page, Integer perPage) throws ApiException { - okhttp3.Call localVarCall = arraysNamespaceArrayEndTimestampsGetValidateBeforeCall(namespace, array, page, perPage, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * retrieve a list of timestamps from the array fragment info listing in milliseconds, paginated - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 list of timestamps in milliseconds, paginated -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call arraysNamespaceArrayEndTimestampsGetAsync(String namespace, String array, Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = arraysNamespaceArrayEndTimestampsGetValidateBeforeCall(namespace, array, page, perPage, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for consolidateArray - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param consolidateRequest Consolidate Request (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 array consolidated successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call consolidateArrayCall(String namespace, String array, ArrayConsolidationRequest consolidateRequest, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = consolidateRequest; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/consolidate" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call consolidateArrayValidateBeforeCall(String namespace, String array, ArrayConsolidationRequest consolidateRequest, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling consolidateArray(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling consolidateArray(Async)"); - } - - // verify the required parameter 'consolidateRequest' is set - if (consolidateRequest == null) { - throw new ApiException("Missing the required parameter 'consolidateRequest' when calling consolidateArray(Async)"); - } - - - okhttp3.Call localVarCall = consolidateArrayCall(namespace, array, consolidateRequest, _callback); - return localVarCall; - - } - - /** - * - * consolidate an array at a specified URI - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param consolidateRequest Consolidate Request (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 array consolidated successfully -
502 Bad Gateway -
0 error response -
- */ - public void consolidateArray(String namespace, String array, ArrayConsolidationRequest consolidateRequest) throws ApiException { - consolidateArrayWithHttpInfo(namespace, array, consolidateRequest); - } - - /** - * - * consolidate an array at a specified URI - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param consolidateRequest Consolidate Request (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 array consolidated successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse consolidateArrayWithHttpInfo(String namespace, String array, ArrayConsolidationRequest consolidateRequest) throws ApiException { - okhttp3.Call localVarCall = consolidateArrayValidateBeforeCall(namespace, array, consolidateRequest, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * consolidate an array at a specified URI - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param consolidateRequest Consolidate Request (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 array consolidated successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call consolidateArrayAsync(String namespace, String array, ArrayConsolidationRequest consolidateRequest, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = consolidateArrayValidateBeforeCall(namespace, array, consolidateRequest, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for createArray - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param arraySchema ArraySchema being created (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 schema created successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call createArrayCall(String namespace, String array, String contentType, ArraySchema arraySchema, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = arraySchema; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (contentType != null) { - localVarHeaderParams.put("Content-Type", localVarApiClient.parameterToString(contentType)); - } - - if (X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME != null) { - localVarHeaderParams.put("X-TILEDB-CLOUD-ACCESS-CREDENTIALS-NAME", localVarApiClient.parameterToString(X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call createArrayValidateBeforeCall(String namespace, String array, String contentType, ArraySchema arraySchema, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling createArray(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling createArray(Async)"); - } - - // verify the required parameter 'contentType' is set - if (contentType == null) { - throw new ApiException("Missing the required parameter 'contentType' when calling createArray(Async)"); - } - - // verify the required parameter 'arraySchema' is set - if (arraySchema == null) { - throw new ApiException("Missing the required parameter 'arraySchema' when calling createArray(Async)"); - } - - - okhttp3.Call localVarCall = createArrayCall(namespace, array, contentType, arraySchema, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, _callback); - return localVarCall; - - } - - /** - * - * create a array schema at a specified URI registered to a group/project - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param arraySchema ArraySchema being created (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 schema created successfully -
502 Bad Gateway -
0 error response -
- */ - public void createArray(String namespace, String array, String contentType, ArraySchema arraySchema, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME) throws ApiException { - createArrayWithHttpInfo(namespace, array, contentType, arraySchema, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME); - } - - /** - * - * create a array schema at a specified URI registered to a group/project - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param arraySchema ArraySchema being created (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 schema created successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse createArrayWithHttpInfo(String namespace, String array, String contentType, ArraySchema arraySchema, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME) throws ApiException { - okhttp3.Call localVarCall = createArrayValidateBeforeCall(namespace, array, contentType, arraySchema, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * create a array schema at a specified URI registered to a group/project - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param arraySchema ArraySchema being created (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 schema created successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call createArrayAsync(String namespace, String array, String contentType, ArraySchema arraySchema, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = createArrayValidateBeforeCall(namespace, array, contentType, arraySchema, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for deleteArray - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 delete array successful -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteArrayCall(String namespace, String array, String contentType, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (contentType != null) { - localVarHeaderParams.put("Content-Type", localVarApiClient.parameterToString(contentType)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call deleteArrayValidateBeforeCall(String namespace, String array, String contentType, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling deleteArray(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling deleteArray(Async)"); - } - - // verify the required parameter 'contentType' is set - if (contentType == null) { - throw new ApiException("Missing the required parameter 'contentType' when calling deleteArray(Async)"); - } - - - okhttp3.Call localVarCall = deleteArrayCall(namespace, array, contentType, _callback); - return localVarCall; - - } - - /** - * - * delete a array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 delete array successful -
502 Bad Gateway -
0 error response -
- */ - public void deleteArray(String namespace, String array, String contentType) throws ApiException { - deleteArrayWithHttpInfo(namespace, array, contentType); - } - - /** - * - * delete a array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 delete array successful -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse deleteArrayWithHttpInfo(String namespace, String array, String contentType) throws ApiException { - okhttp3.Call localVarCall = deleteArrayValidateBeforeCall(namespace, array, contentType, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * delete a array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 delete array successful -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteArrayAsync(String namespace, String array, String contentType, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = deleteArrayValidateBeforeCall(namespace, array, contentType, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for deregisterArray - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 deregistered array successful -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deregisterArrayCall(String namespace, String array, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/deregister" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call deregisterArrayValidateBeforeCall(String namespace, String array, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling deregisterArray(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling deregisterArray(Async)"); - } - - - okhttp3.Call localVarCall = deregisterArrayCall(namespace, array, _callback); - return localVarCall; - - } - - /** - * - * deregister a array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 deregistered array successful -
502 Bad Gateway -
0 error response -
- */ - public void deregisterArray(String namespace, String array) throws ApiException { - deregisterArrayWithHttpInfo(namespace, array); - } - - /** - * - * deregister a array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 deregistered array successful -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse deregisterArrayWithHttpInfo(String namespace, String array) throws ApiException { - okhttp3.Call localVarCall = deregisterArrayValidateBeforeCall(namespace, array, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * deregister a array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 deregistered array successful -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deregisterArrayAsync(String namespace, String array, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = deregisterArrayValidateBeforeCall(namespace, array, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for fragmentInfo - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param fragmentInfoRequest ArraySchema being created (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - -
Status Code Description Response Headers
200 fragment info -
0 error response -
- */ - public okhttp3.Call fragmentInfoCall(String namespace, String array, String contentType, FragmentInfoRequest fragmentInfoRequest, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = fragmentInfoRequest; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/fragment_info" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (contentType != null) { - localVarHeaderParams.put("Content-Type", localVarApiClient.parameterToString(contentType)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call fragmentInfoValidateBeforeCall(String namespace, String array, String contentType, FragmentInfoRequest fragmentInfoRequest, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling fragmentInfo(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling fragmentInfo(Async)"); - } - - // verify the required parameter 'contentType' is set - if (contentType == null) { - throw new ApiException("Missing the required parameter 'contentType' when calling fragmentInfo(Async)"); - } - - // verify the required parameter 'fragmentInfoRequest' is set - if (fragmentInfoRequest == null) { - throw new ApiException("Missing the required parameter 'fragmentInfoRequest' when calling fragmentInfo(Async)"); - } - - - okhttp3.Call localVarCall = fragmentInfoCall(namespace, array, contentType, fragmentInfoRequest, _callback); - return localVarCall; - - } - - /** - * - * fetch an array's fragment info - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param fragmentInfoRequest ArraySchema being created (required) - * @return FragmentInfo - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 fragment info -
0 error response -
- */ - public FragmentInfo fragmentInfo(String namespace, String array, String contentType, FragmentInfoRequest fragmentInfoRequest) throws ApiException { - ApiResponse localVarResp = fragmentInfoWithHttpInfo(namespace, array, contentType, fragmentInfoRequest); - return localVarResp.getData(); - } - - /** - * - * fetch an array's fragment info - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param fragmentInfoRequest ArraySchema being created (required) - * @return ApiResponse<FragmentInfo> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 fragment info -
0 error response -
- */ - public ApiResponse fragmentInfoWithHttpInfo(String namespace, String array, String contentType, FragmentInfoRequest fragmentInfoRequest) throws ApiException { - okhttp3.Call localVarCall = fragmentInfoValidateBeforeCall(namespace, array, contentType, fragmentInfoRequest, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * fetch an array's fragment info - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param fragmentInfoRequest ArraySchema being created (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - -
Status Code Description Response Headers
200 fragment info -
0 error response -
- */ - public okhttp3.Call fragmentInfoAsync(String namespace, String array, String contentType, FragmentInfoRequest fragmentInfoRequest, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = fragmentInfoValidateBeforeCall(namespace, array, contentType, fragmentInfoRequest, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getActivityLogById - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param id ID of the activity (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array activity -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getActivityLogByIdCall(String namespace, String array, String id, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/activity/{id}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())) - .replaceAll("\\{" + "id" + "\\}", localVarApiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getActivityLogByIdValidateBeforeCall(String namespace, String array, String id, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getActivityLogById(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling getActivityLogById(Async)"); - } - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getActivityLogById(Async)"); - } - - - okhttp3.Call localVarCall = getActivityLogByIdCall(namespace, array, id, _callback); - return localVarCall; - - } - - /** - * - * get activity log by ID - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param id ID of the activity (required) - * @return ArrayActivityLog - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array activity -
502 Bad Gateway -
0 error response -
- */ - public ArrayActivityLog getActivityLogById(String namespace, String array, String id) throws ApiException { - ApiResponse localVarResp = getActivityLogByIdWithHttpInfo(namespace, array, id); - return localVarResp.getData(); - } - - /** - * - * get activity log by ID - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param id ID of the activity (required) - * @return ApiResponse<ArrayActivityLog> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array activity -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getActivityLogByIdWithHttpInfo(String namespace, String array, String id) throws ApiException { - okhttp3.Call localVarCall = getActivityLogByIdValidateBeforeCall(namespace, array, id, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * get activity log by ID - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param id ID of the activity (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array activity -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getActivityLogByIdAsync(String namespace, String array, String id, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getActivityLogByIdValidateBeforeCall(namespace, array, id, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getAllArrayMetadata - * @param publicShare Public share values can be one of exclude, only (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array metadata for all arrays user has access to -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getAllArrayMetadataCall(String publicShare, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (publicShare != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("public_share", publicShare)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getAllArrayMetadataValidateBeforeCall(String publicShare, final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = getAllArrayMetadataCall(publicShare, _callback); - return localVarCall; - - } - - /** - * - * get all array metadata user has access to - * @param publicShare Public share values can be one of exclude, only (optional) - * @return List<ArrayInfo> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array metadata for all arrays user has access to -
502 Bad Gateway -
0 error response -
- */ - public List getAllArrayMetadata(String publicShare) throws ApiException { - ApiResponse> localVarResp = getAllArrayMetadataWithHttpInfo(publicShare); - return localVarResp.getData(); - } - - /** - * - * get all array metadata user has access to - * @param publicShare Public share values can be one of exclude, only (optional) - * @return ApiResponse<List<ArrayInfo>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array metadata for all arrays user has access to -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse> getAllArrayMetadataWithHttpInfo(String publicShare) throws ApiException { - okhttp3.Call localVarCall = getAllArrayMetadataValidateBeforeCall(publicShare, null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * get all array metadata user has access to - * @param publicShare Public share values can be one of exclude, only (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array metadata for all arrays user has access to -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getAllArrayMetadataAsync(String publicShare, final ApiCallback> _callback) throws ApiException { - - okhttp3.Call localVarCall = getAllArrayMetadataValidateBeforeCall(publicShare, _callback); - Type localVarReturnType = new TypeToken>(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getArray - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get ArraySchema -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArrayCall(String namespace, String array, String contentType, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (contentType != null) { - localVarHeaderParams.put("Content-Type", localVarApiClient.parameterToString(contentType)); - } - - final String[] localVarAccepts = { - "application/json", "application/capnp" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getArrayValidateBeforeCall(String namespace, String array, String contentType, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getArray(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling getArray(Async)"); - } - - // verify the required parameter 'contentType' is set - if (contentType == null) { - throw new ApiException("Missing the required parameter 'contentType' when calling getArray(Async)"); - } - - - okhttp3.Call localVarCall = getArrayCall(namespace, array, contentType, _callback); - return localVarCall; - - } - - /** - * - * get an ArraySchema using a url encoded uri - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @return ArraySchema - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get ArraySchema -
502 Bad Gateway -
0 error response -
- */ - public ArraySchema getArray(String namespace, String array, String contentType) throws ApiException { - ApiResponse localVarResp = getArrayWithHttpInfo(namespace, array, contentType); - return localVarResp.getData(); - } - - /** - * - * get an ArraySchema using a url encoded uri - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @return ApiResponse<ArraySchema> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get ArraySchema -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getArrayWithHttpInfo(String namespace, String array, String contentType) throws ApiException { - okhttp3.Call localVarCall = getArrayValidateBeforeCall(namespace, array, contentType, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * get an ArraySchema using a url encoded uri - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get ArraySchema -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArrayAsync(String namespace, String array, String contentType, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getArrayValidateBeforeCall(namespace, array, contentType, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getArrayMaxBufferSizes - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param subarray CSV string of subarray to get max buffer sizes for (required) - * @param contentType Content Type of input and return mime (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get the max buffer sizes of an array for a subarray -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArrayMaxBufferSizesCall(String namespace, String array, String subarray, String contentType, String xPayer, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/max_buffer_sizes" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (subarray != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("subarray", subarray)); - } - - if (contentType != null) { - localVarHeaderParams.put("Content-Type", localVarApiClient.parameterToString(contentType)); - } - - if (xPayer != null) { - localVarHeaderParams.put("X-Payer", localVarApiClient.parameterToString(xPayer)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getArrayMaxBufferSizesValidateBeforeCall(String namespace, String array, String subarray, String contentType, String xPayer, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getArrayMaxBufferSizes(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling getArrayMaxBufferSizes(Async)"); - } - - // verify the required parameter 'subarray' is set - if (subarray == null) { - throw new ApiException("Missing the required parameter 'subarray' when calling getArrayMaxBufferSizes(Async)"); - } - - // verify the required parameter 'contentType' is set - if (contentType == null) { - throw new ApiException("Missing the required parameter 'contentType' when calling getArrayMaxBufferSizes(Async)"); - } - - - okhttp3.Call localVarCall = getArrayMaxBufferSizesCall(namespace, array, subarray, contentType, xPayer, _callback); - return localVarCall; - - } - - /** - * - * get the max buffer sizes of an array for a subarray - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param subarray CSV string of subarray to get max buffer sizes for (required) - * @param contentType Content Type of input and return mime (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @return MaxBufferSizes - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get the max buffer sizes of an array for a subarray -
502 Bad Gateway -
0 error response -
- */ - public MaxBufferSizes getArrayMaxBufferSizes(String namespace, String array, String subarray, String contentType, String xPayer) throws ApiException { - ApiResponse localVarResp = getArrayMaxBufferSizesWithHttpInfo(namespace, array, subarray, contentType, xPayer); - return localVarResp.getData(); - } - - /** - * - * get the max buffer sizes of an array for a subarray - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param subarray CSV string of subarray to get max buffer sizes for (required) - * @param contentType Content Type of input and return mime (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @return ApiResponse<MaxBufferSizes> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get the max buffer sizes of an array for a subarray -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getArrayMaxBufferSizesWithHttpInfo(String namespace, String array, String subarray, String contentType, String xPayer) throws ApiException { - okhttp3.Call localVarCall = getArrayMaxBufferSizesValidateBeforeCall(namespace, array, subarray, contentType, xPayer, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * get the max buffer sizes of an array for a subarray - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param subarray CSV string of subarray to get max buffer sizes for (required) - * @param contentType Content Type of input and return mime (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get the max buffer sizes of an array for a subarray -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArrayMaxBufferSizesAsync(String namespace, String array, String subarray, String contentType, String xPayer, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getArrayMaxBufferSizesValidateBeforeCall(namespace, array, subarray, contentType, xPayer, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getArrayMetaDataJson - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param length (optional) limit character length of returned values (optional) - * @param endTimestamp Milliseconds since Unix epoch, metadata will use open_at functionality to open array at the specific timestamp (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get array metadata -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArrayMetaDataJsonCall(String namespace, String array, Integer length, Integer endTimestamp, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/metadata_json" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (length != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("length", length)); - } - - if (endTimestamp != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("end_timestamp", endTimestamp)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getArrayMetaDataJsonValidateBeforeCall(String namespace, String array, Integer length, Integer endTimestamp, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getArrayMetaDataJson(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling getArrayMetaDataJson(Async)"); - } - - - okhttp3.Call localVarCall = getArrayMetaDataJsonCall(namespace, array, length, endTimestamp, _callback); - return localVarCall; - - } - - /** - * - * get metadata from the array in JSON format - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param length (optional) limit character length of returned values (optional) - * @param endTimestamp Milliseconds since Unix epoch, metadata will use open_at functionality to open array at the specific timestamp (optional) - * @return Object - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get array metadata -
502 Bad Gateway -
0 error response -
- */ - public Object getArrayMetaDataJson(String namespace, String array, Integer length, Integer endTimestamp) throws ApiException { - ApiResponse localVarResp = getArrayMetaDataJsonWithHttpInfo(namespace, array, length, endTimestamp); - return localVarResp.getData(); - } - - /** - * - * get metadata from the array in JSON format - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param length (optional) limit character length of returned values (optional) - * @param endTimestamp Milliseconds since Unix epoch, metadata will use open_at functionality to open array at the specific timestamp (optional) - * @return ApiResponse<Object> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get array metadata -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getArrayMetaDataJsonWithHttpInfo(String namespace, String array, Integer length, Integer endTimestamp) throws ApiException { - okhttp3.Call localVarCall = getArrayMetaDataJsonValidateBeforeCall(namespace, array, length, endTimestamp, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * get metadata from the array in JSON format - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param length (optional) limit character length of returned values (optional) - * @param endTimestamp Milliseconds since Unix epoch, metadata will use open_at functionality to open array at the specific timestamp (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get array metadata -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArrayMetaDataJsonAsync(String namespace, String array, Integer length, Integer endTimestamp, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getArrayMetaDataJsonValidateBeforeCall(namespace, array, length, endTimestamp, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getArrayMetadata - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array metadata for an array -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArrayMetadataCall(String namespace, String array, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/metadata" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getArrayMetadataValidateBeforeCall(String namespace, String array, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getArrayMetadata(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling getArrayMetadata(Async)"); - } - - - okhttp3.Call localVarCall = getArrayMetadataCall(namespace, array, _callback); - return localVarCall; - - } - - /** - * - * get metadata on an array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @return ArrayInfo - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array metadata for an array -
502 Bad Gateway -
0 error response -
- */ - public ArrayInfo getArrayMetadata(String namespace, String array) throws ApiException { - ApiResponse localVarResp = getArrayMetadataWithHttpInfo(namespace, array); - return localVarResp.getData(); - } - - /** - * - * get metadata on an array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @return ApiResponse<ArrayInfo> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array metadata for an array -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getArrayMetadataWithHttpInfo(String namespace, String array) throws ApiException { - okhttp3.Call localVarCall = getArrayMetadataValidateBeforeCall(namespace, array, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * get metadata on an array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array metadata for an array -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArrayMetadataAsync(String namespace, String array, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getArrayMetadataValidateBeforeCall(namespace, array, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getArrayMetadataCapnp - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array metadata for an array -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArrayMetadataCapnpCall(String namespace, String array, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/array_metadata" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/capnp" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getArrayMetadataCapnpValidateBeforeCall(String namespace, String array, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getArrayMetadataCapnp(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling getArrayMetadataCapnp(Async)"); - } - - - okhttp3.Call localVarCall = getArrayMetadataCapnpCall(namespace, array, _callback); - return localVarCall; - - } - - /** - * - * get metadata on an array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @return ArrayMetadata - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array metadata for an array -
502 Bad Gateway -
0 error response -
- */ - public ArrayMetadata getArrayMetadataCapnp(String namespace, String array) throws ApiException { - ApiResponse localVarResp = getArrayMetadataCapnpWithHttpInfo(namespace, array); - return localVarResp.getData(); - } - - /** - * - * get metadata on an array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @return ApiResponse<ArrayMetadata> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array metadata for an array -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getArrayMetadataCapnpWithHttpInfo(String namespace, String array) throws ApiException { - okhttp3.Call localVarCall = getArrayMetadataCapnpValidateBeforeCall(namespace, array, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * get metadata on an array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array metadata for an array -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArrayMetadataCapnpAsync(String namespace, String array, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getArrayMetadataCapnpValidateBeforeCall(namespace, array, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getArrayNonEmptyDomain - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get the non empty domain of an array -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArrayNonEmptyDomainCall(String namespace, String array, String contentType, String xPayer, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/non_empty_domain" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (contentType != null) { - localVarHeaderParams.put("Content-Type", localVarApiClient.parameterToString(contentType)); - } - - if (xPayer != null) { - localVarHeaderParams.put("X-Payer", localVarApiClient.parameterToString(xPayer)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getArrayNonEmptyDomainValidateBeforeCall(String namespace, String array, String contentType, String xPayer, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getArrayNonEmptyDomain(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling getArrayNonEmptyDomain(Async)"); - } - - // verify the required parameter 'contentType' is set - if (contentType == null) { - throw new ApiException("Missing the required parameter 'contentType' when calling getArrayNonEmptyDomain(Async)"); - } - - - okhttp3.Call localVarCall = getArrayNonEmptyDomainCall(namespace, array, contentType, xPayer, _callback); - return localVarCall; - - } - - /** - * - * get the non empty domain of an array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @return NonEmptyDomain - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get the non empty domain of an array -
502 Bad Gateway -
0 error response -
- */ - public NonEmptyDomain getArrayNonEmptyDomain(String namespace, String array, String contentType, String xPayer) throws ApiException { - ApiResponse localVarResp = getArrayNonEmptyDomainWithHttpInfo(namespace, array, contentType, xPayer); - return localVarResp.getData(); - } - - /** - * - * get the non empty domain of an array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @return ApiResponse<NonEmptyDomain> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get the non empty domain of an array -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getArrayNonEmptyDomainWithHttpInfo(String namespace, String array, String contentType, String xPayer) throws ApiException { - okhttp3.Call localVarCall = getArrayNonEmptyDomainValidateBeforeCall(namespace, array, contentType, xPayer, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * get the non empty domain of an array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get the non empty domain of an array -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArrayNonEmptyDomainAsync(String namespace, String array, String contentType, String xPayer, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getArrayNonEmptyDomainValidateBeforeCall(namespace, array, contentType, xPayer, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getArrayNonEmptyDomainJson - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get array non-empty domaim -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArrayNonEmptyDomainJsonCall(String namespace, String array, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/non_empty_domain_json" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getArrayNonEmptyDomainJsonValidateBeforeCall(String namespace, String array, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getArrayNonEmptyDomainJson(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling getArrayNonEmptyDomainJson(Async)"); - } - - - okhttp3.Call localVarCall = getArrayNonEmptyDomainJsonCall(namespace, array, _callback); - return localVarCall; - - } - - /** - * - * get non-empty domain from the array in json format - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @return Object - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get array non-empty domaim -
502 Bad Gateway -
0 error response -
- */ - public Object getArrayNonEmptyDomainJson(String namespace, String array) throws ApiException { - ApiResponse localVarResp = getArrayNonEmptyDomainJsonWithHttpInfo(namespace, array); - return localVarResp.getData(); - } - - /** - * - * get non-empty domain from the array in json format - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @return ApiResponse<Object> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get array non-empty domaim -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getArrayNonEmptyDomainJsonWithHttpInfo(String namespace, String array) throws ApiException { - okhttp3.Call localVarCall = getArrayNonEmptyDomainJsonValidateBeforeCall(namespace, array, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * get non-empty domain from the array in json format - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get array non-empty domaim -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArrayNonEmptyDomainJsonAsync(String namespace, String array, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getArrayNonEmptyDomainJsonValidateBeforeCall(namespace, array, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getArraySampleData - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param samples Number of sample results to return (optional, default to 5.0) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get array sample data -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArraySampleDataCall(String namespace, String array, BigDecimal samples, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/sample" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (samples != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("samples", samples)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getArraySampleDataValidateBeforeCall(String namespace, String array, BigDecimal samples, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getArraySampleData(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling getArraySampleData(Async)"); - } - - - okhttp3.Call localVarCall = getArraySampleDataCall(namespace, array, samples, _callback); - return localVarCall; - - } - - /** - * - * get an sample set of data from the array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param samples Number of sample results to return (optional, default to 5.0) - * @return ArraySample - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get array sample data -
502 Bad Gateway -
0 error response -
- */ - public ArraySample getArraySampleData(String namespace, String array, BigDecimal samples) throws ApiException { - ApiResponse localVarResp = getArraySampleDataWithHttpInfo(namespace, array, samples); - return localVarResp.getData(); - } - - /** - * - * get an sample set of data from the array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param samples Number of sample results to return (optional, default to 5.0) - * @return ApiResponse<ArraySample> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get array sample data -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getArraySampleDataWithHttpInfo(String namespace, String array, BigDecimal samples) throws ApiException { - okhttp3.Call localVarCall = getArraySampleDataValidateBeforeCall(namespace, array, samples, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * get an sample set of data from the array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param samples Number of sample results to return (optional, default to 5.0) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 get array sample data -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArraySampleDataAsync(String namespace, String array, BigDecimal samples, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getArraySampleDataValidateBeforeCall(namespace, array, samples, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getArraySharingPolicies - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 List of all specific sharing policies -
404 Array does not exist or user does not have permissions to view array-sharing policies -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArraySharingPoliciesCall(String namespace, String array, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/share" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getArraySharingPoliciesValidateBeforeCall(String namespace, String array, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getArraySharingPolicies(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling getArraySharingPolicies(Async)"); - } - - - okhttp3.Call localVarCall = getArraySharingPoliciesCall(namespace, array, _callback); - return localVarCall; - - } - - /** - * - * Get all sharing details of the array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @return List<ArraySharing> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 List of all specific sharing policies -
404 Array does not exist or user does not have permissions to view array-sharing policies -
502 Bad Gateway -
0 error response -
- */ - public List getArraySharingPolicies(String namespace, String array) throws ApiException { - ApiResponse> localVarResp = getArraySharingPoliciesWithHttpInfo(namespace, array); - return localVarResp.getData(); - } - - /** - * - * Get all sharing details of the array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @return ApiResponse<List<ArraySharing>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 List of all specific sharing policies -
404 Array does not exist or user does not have permissions to view array-sharing policies -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse> getArraySharingPoliciesWithHttpInfo(String namespace, String array) throws ApiException { - okhttp3.Call localVarCall = getArraySharingPoliciesValidateBeforeCall(namespace, array, null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Get all sharing details of the array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 List of all specific sharing policies -
404 Array does not exist or user does not have permissions to view array-sharing policies -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArraySharingPoliciesAsync(String namespace, String array, final ApiCallback> _callback) throws ApiException { - - okhttp3.Call localVarCall = getArraySharingPoliciesValidateBeforeCall(namespace, array, _callback); - Type localVarReturnType = new TypeToken>(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getArraysInNamespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array metadata for all arrays in a namespace -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArraysInNamespaceCall(String namespace, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/{namespace}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getArraysInNamespaceValidateBeforeCall(String namespace, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getArraysInNamespace(Async)"); - } - - - okhttp3.Call localVarCall = getArraysInNamespaceCall(namespace, _callback); - return localVarCall; - - } - - /** - * - * get metadata on all arrays in a namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @return List<ArrayInfo> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array metadata for all arrays in a namespace -
502 Bad Gateway -
0 error response -
- */ - public List getArraysInNamespace(String namespace) throws ApiException { - ApiResponse> localVarResp = getArraysInNamespaceWithHttpInfo(namespace); - return localVarResp.getData(); - } - - /** - * - * get metadata on all arrays in a namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @return ApiResponse<List<ArrayInfo>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array metadata for all arrays in a namespace -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse> getArraysInNamespaceWithHttpInfo(String namespace) throws ApiException { - okhttp3.Call localVarCall = getArraysInNamespaceValidateBeforeCall(namespace, null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * get metadata on all arrays in a namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array metadata for all arrays in a namespace -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArraysInNamespaceAsync(String namespace, final ApiCallback> _callback) throws ApiException { - - okhttp3.Call localVarCall = getArraysInNamespaceValidateBeforeCall(namespace, _callback); - Type localVarReturnType = new TypeToken>(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getFragmentEndTimestamp - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param endTimestamp Milliseconds since Unix epoch (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 fragment end_timestamp on an array -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getFragmentEndTimestampCall(String namespace, String array, Integer endTimestamp, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/fragment_end_timestamp" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (endTimestamp != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("end_timestamp", endTimestamp)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getFragmentEndTimestampValidateBeforeCall(String namespace, String array, Integer endTimestamp, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getFragmentEndTimestamp(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling getFragmentEndTimestamp(Async)"); - } - - - okhttp3.Call localVarCall = getFragmentEndTimestampCall(namespace, array, endTimestamp, _callback); - return localVarCall; - - } - - /** - * - * Get fragment end_timestamp on an array, will search for the closest end_timestamp to the timestamp asked - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param endTimestamp Milliseconds since Unix epoch (optional) - * @return Integer - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 fragment end_timestamp on an array -
502 Bad Gateway -
0 error response -
- */ - public Integer getFragmentEndTimestamp(String namespace, String array, Integer endTimestamp) throws ApiException { - ApiResponse localVarResp = getFragmentEndTimestampWithHttpInfo(namespace, array, endTimestamp); - return localVarResp.getData(); - } - - /** - * - * Get fragment end_timestamp on an array, will search for the closest end_timestamp to the timestamp asked - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param endTimestamp Milliseconds since Unix epoch (optional) - * @return ApiResponse<Integer> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 fragment end_timestamp on an array -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getFragmentEndTimestampWithHttpInfo(String namespace, String array, Integer endTimestamp) throws ApiException { - okhttp3.Call localVarCall = getFragmentEndTimestampValidateBeforeCall(namespace, array, endTimestamp, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Get fragment end_timestamp on an array, will search for the closest end_timestamp to the timestamp asked - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param endTimestamp Milliseconds since Unix epoch (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 fragment end_timestamp on an array -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getFragmentEndTimestampAsync(String namespace, String array, Integer endTimestamp, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getFragmentEndTimestampValidateBeforeCall(namespace, array, endTimestamp, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getLastAccessedArrays - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 gets last accessed arrays -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getLastAccessedArraysCall(final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/last_accessed"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getLastAccessedArraysValidateBeforeCall(final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = getLastAccessedArraysCall(_callback); - return localVarCall; - - } - - /** - * - * - * @return List<LastAccessedArray> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 gets last accessed arrays -
502 Bad Gateway -
0 error response -
- */ - public List getLastAccessedArrays() throws ApiException { - ApiResponse> localVarResp = getLastAccessedArraysWithHttpInfo(); - return localVarResp.getData(); - } - - /** - * - * - * @return ApiResponse<List<LastAccessedArray>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 gets last accessed arrays -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse> getLastAccessedArraysWithHttpInfo() throws ApiException { - okhttp3.Call localVarCall = getLastAccessedArraysValidateBeforeCall(null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 gets last accessed arrays -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getLastAccessedArraysAsync(final ApiCallback> _callback) throws ApiException { - - okhttp3.Call localVarCall = getLastAccessedArraysValidateBeforeCall(_callback); - Type localVarReturnType = new TypeToken>(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for registerArray - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param arrayMetadata metadata associated with array (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array registered successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call registerArrayCall(String namespace, String array, ArrayInfoUpdate arrayMetadata, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = arrayMetadata; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/register" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call registerArrayValidateBeforeCall(String namespace, String array, ArrayInfoUpdate arrayMetadata, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling registerArray(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling registerArray(Async)"); - } - - // verify the required parameter 'arrayMetadata' is set - if (arrayMetadata == null) { - throw new ApiException("Missing the required parameter 'arrayMetadata' when calling registerArray(Async)"); - } - - - okhttp3.Call localVarCall = registerArrayCall(namespace, array, arrayMetadata, _callback); - return localVarCall; - - } - - /** - * - * register an array at a specified URI registered to the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param arrayMetadata metadata associated with array (required) - * @return ArrayInfo - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array registered successfully -
502 Bad Gateway -
0 error response -
- */ - public ArrayInfo registerArray(String namespace, String array, ArrayInfoUpdate arrayMetadata) throws ApiException { - ApiResponse localVarResp = registerArrayWithHttpInfo(namespace, array, arrayMetadata); - return localVarResp.getData(); - } - - /** - * - * register an array at a specified URI registered to the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param arrayMetadata metadata associated with array (required) - * @return ApiResponse<ArrayInfo> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array registered successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse registerArrayWithHttpInfo(String namespace, String array, ArrayInfoUpdate arrayMetadata) throws ApiException { - okhttp3.Call localVarCall = registerArrayValidateBeforeCall(namespace, array, arrayMetadata, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * register an array at a specified URI registered to the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param arrayMetadata metadata associated with array (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array registered successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call registerArrayAsync(String namespace, String array, ArrayInfoUpdate arrayMetadata, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = registerArrayValidateBeforeCall(namespace, array, arrayMetadata, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for shareArray - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param arraySharing Namespace and list of permissions to share with. An empty list of permissions will remove the namespace; if permissions already exist they will be deleted then new ones added. In the event of a failure, the new policies will be rolled back to prevent partial policies, and it's likely the array will not be shared with the namespace at all. (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Array shared successfully -
404 Array does not exist or user does not have permissions to share array -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call shareArrayCall(String namespace, String array, ArraySharing arraySharing, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = arraySharing; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/share" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call shareArrayValidateBeforeCall(String namespace, String array, ArraySharing arraySharing, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling shareArray(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling shareArray(Async)"); - } - - // verify the required parameter 'arraySharing' is set - if (arraySharing == null) { - throw new ApiException("Missing the required parameter 'arraySharing' when calling shareArray(Async)"); - } - - - okhttp3.Call localVarCall = shareArrayCall(namespace, array, arraySharing, _callback); - return localVarCall; - - } - - /** - * - * Share an array with a user - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param arraySharing Namespace and list of permissions to share with. An empty list of permissions will remove the namespace; if permissions already exist they will be deleted then new ones added. In the event of a failure, the new policies will be rolled back to prevent partial policies, and it's likely the array will not be shared with the namespace at all. (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Array shared successfully -
404 Array does not exist or user does not have permissions to share array -
502 Bad Gateway -
0 error response -
- */ - public void shareArray(String namespace, String array, ArraySharing arraySharing) throws ApiException { - shareArrayWithHttpInfo(namespace, array, arraySharing); - } - - /** - * - * Share an array with a user - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param arraySharing Namespace and list of permissions to share with. An empty list of permissions will remove the namespace; if permissions already exist they will be deleted then new ones added. In the event of a failure, the new policies will be rolled back to prevent partial policies, and it's likely the array will not be shared with the namespace at all. (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Array shared successfully -
404 Array does not exist or user does not have permissions to share array -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse shareArrayWithHttpInfo(String namespace, String array, ArraySharing arraySharing) throws ApiException { - okhttp3.Call localVarCall = shareArrayValidateBeforeCall(namespace, array, arraySharing, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Share an array with a user - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param arraySharing Namespace and list of permissions to share with. An empty list of permissions will remove the namespace; if permissions already exist they will be deleted then new ones added. In the event of a failure, the new policies will be rolled back to prevent partial policies, and it's likely the array will not be shared with the namespace at all. (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Array shared successfully -
404 Array does not exist or user does not have permissions to share array -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call shareArrayAsync(String namespace, String array, ArraySharing arraySharing, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = shareArrayValidateBeforeCall(namespace, array, arraySharing, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for updateArrayMetadata - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param arrayMetadata array metadata to update (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 array metadata updated successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateArrayMetadataCall(String namespace, String array, ArrayInfoUpdate arrayMetadata, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = arrayMetadata; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/metadata" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call updateArrayMetadataValidateBeforeCall(String namespace, String array, ArrayInfoUpdate arrayMetadata, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling updateArrayMetadata(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling updateArrayMetadata(Async)"); - } - - // verify the required parameter 'arrayMetadata' is set - if (arrayMetadata == null) { - throw new ApiException("Missing the required parameter 'arrayMetadata' when calling updateArrayMetadata(Async)"); - } - - - okhttp3.Call localVarCall = updateArrayMetadataCall(namespace, array, arrayMetadata, _callback); - return localVarCall; - - } - - /** - * - * update metadata on an array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param arrayMetadata array metadata to update (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 array metadata updated successfully -
502 Bad Gateway -
0 error response -
- */ - public void updateArrayMetadata(String namespace, String array, ArrayInfoUpdate arrayMetadata) throws ApiException { - updateArrayMetadataWithHttpInfo(namespace, array, arrayMetadata); - } - - /** - * - * update metadata on an array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param arrayMetadata array metadata to update (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 array metadata updated successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse updateArrayMetadataWithHttpInfo(String namespace, String array, ArrayInfoUpdate arrayMetadata) throws ApiException { - okhttp3.Call localVarCall = updateArrayMetadataValidateBeforeCall(namespace, array, arrayMetadata, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * update metadata on an array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param arrayMetadata array metadata to update (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 array metadata updated successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateArrayMetadataAsync(String namespace, String array, ArrayInfoUpdate arrayMetadata, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = updateArrayMetadataValidateBeforeCall(namespace, array, arrayMetadata, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for updateArrayMetadataCapnp - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param arrayMetadataEntries List of metadata entries (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array metadata updated successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateArrayMetadataCapnpCall(String namespace, String array, ArrayMetadata arrayMetadataEntries, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = arrayMetadataEntries; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/array_metadata" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/capnp" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json", "application/capnp" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call updateArrayMetadataCapnpValidateBeforeCall(String namespace, String array, ArrayMetadata arrayMetadataEntries, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling updateArrayMetadataCapnp(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling updateArrayMetadataCapnp(Async)"); - } - - // verify the required parameter 'arrayMetadataEntries' is set - if (arrayMetadataEntries == null) { - throw new ApiException("Missing the required parameter 'arrayMetadataEntries' when calling updateArrayMetadataCapnp(Async)"); - } - - - okhttp3.Call localVarCall = updateArrayMetadataCapnpCall(namespace, array, arrayMetadataEntries, _callback); - return localVarCall; - - } - - /** - * - * update metadata on an array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param arrayMetadataEntries List of metadata entries (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array metadata updated successfully -
502 Bad Gateway -
0 error response -
- */ - public void updateArrayMetadataCapnp(String namespace, String array, ArrayMetadata arrayMetadataEntries) throws ApiException { - updateArrayMetadataCapnpWithHttpInfo(namespace, array, arrayMetadataEntries); - } - - /** - * - * update metadata on an array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param arrayMetadataEntries List of metadata entries (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array metadata updated successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse updateArrayMetadataCapnpWithHttpInfo(String namespace, String array, ArrayMetadata arrayMetadataEntries) throws ApiException { - okhttp3.Call localVarCall = updateArrayMetadataCapnpValidateBeforeCall(namespace, array, arrayMetadataEntries, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * update metadata on an array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param arrayMetadataEntries List of metadata entries (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 array metadata updated successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateArrayMetadataCapnpAsync(String namespace, String array, ArrayMetadata arrayMetadataEntries, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = updateArrayMetadataCapnpValidateBeforeCall(namespace, array, arrayMetadataEntries, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for vacuumArray - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param vaccumRequest Vaccum Request (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 array vacuumed successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call vacuumArrayCall(String namespace, String array, ArrayVacuumRequest vaccumRequest, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = vaccumRequest; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/vacuum" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call vacuumArrayValidateBeforeCall(String namespace, String array, ArrayVacuumRequest vaccumRequest, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling vacuumArray(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling vacuumArray(Async)"); - } - - // verify the required parameter 'vaccumRequest' is set - if (vaccumRequest == null) { - throw new ApiException("Missing the required parameter 'vaccumRequest' when calling vacuumArray(Async)"); - } - - - okhttp3.Call localVarCall = vacuumArrayCall(namespace, array, vaccumRequest, _callback); - return localVarCall; - - } - - /** - * - * vacuum an array at a specified URI - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param vaccumRequest Vaccum Request (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 array vacuumed successfully -
502 Bad Gateway -
0 error response -
- */ - public void vacuumArray(String namespace, String array, ArrayVacuumRequest vaccumRequest) throws ApiException { - vacuumArrayWithHttpInfo(namespace, array, vaccumRequest); - } - - /** - * - * vacuum an array at a specified URI - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param vaccumRequest Vaccum Request (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 array vacuumed successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse vacuumArrayWithHttpInfo(String namespace, String array, ArrayVacuumRequest vaccumRequest) throws ApiException { - okhttp3.Call localVarCall = vacuumArrayValidateBeforeCall(namespace, array, vaccumRequest, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * vacuum an array at a specified URI - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param vaccumRequest Vaccum Request (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 array vacuumed successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call vacuumArrayAsync(String namespace, String array, ArrayVacuumRequest vaccumRequest, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = vacuumArrayValidateBeforeCall(namespace, array, vaccumRequest, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/api/ArrayTasksApi.java b/src/main/java/io/tiledb/cloud/rest_api/v1/api/ArrayTasksApi.java deleted file mode 100644 index 618d106..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/api/ArrayTasksApi.java +++ /dev/null @@ -1,215 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.api; - -import io.tiledb.cloud.rest_api.v1.Configuration; -import io.tiledb.cloud.rest_api.v1.model.ArrayTaskBrowserSidebar; -import io.tiledb.cloud.rest_api.v1.ApiCallback; -import io.tiledb.cloud.rest_api.v1.ApiClient; -import io.tiledb.cloud.rest_api.v1.ApiException; -import io.tiledb.cloud.rest_api.v1.ApiResponse; -import io.tiledb.cloud.rest_api.v1.Pair; - -import com.google.gson.reflect.TypeToken; - - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class ArrayTasksApi { - private ApiClient localVarApiClient; - private int localHostIndex; - private String localCustomBaseUrl; - - public ArrayTasksApi() { - this(Configuration.getDefaultApiClient()); - } - - public ArrayTasksApi(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public ApiClient getApiClient() { - return localVarApiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public int getHostIndex() { - return localHostIndex; - } - - public void setHostIndex(int hostIndex) { - this.localHostIndex = hostIndex; - } - - public String getCustomBaseUrl() { - return localCustomBaseUrl; - } - - public void setCustomBaseUrl(String customBaseUrl) { - this.localCustomBaseUrl = customBaseUrl; - } - - /** - * Build call for getArrayTasksSidebar - * @param start Fetch tasks created after this time, unix epoch in seconds, default 7 days ago (optional) - * @param end Fetch tasks created before this time, unix epoch in seconds, default now (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 sidebar metadata for task definitions for all arrays user has access to -
404 array tasks not found -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArrayTasksSidebarCall(Integer start, Integer end, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/tasks/sidebar"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (start != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("start", start)); - } - - if (end != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("end", end)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getArrayTasksSidebarValidateBeforeCall(Integer start, Integer end, final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = getArrayTasksSidebarCall(start, end, _callback); - return localVarCall; - - } - - /** - * - * - * @param start Fetch tasks created after this time, unix epoch in seconds, default 7 days ago (optional) - * @param end Fetch tasks created before this time, unix epoch in seconds, default now (optional) - * @return ArrayTaskBrowserSidebar - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 sidebar metadata for task definitions for all arrays user has access to -
404 array tasks not found -
502 Bad Gateway -
0 error response -
- */ - public ArrayTaskBrowserSidebar getArrayTasksSidebar(Integer start, Integer end) throws ApiException { - ApiResponse localVarResp = getArrayTasksSidebarWithHttpInfo(start, end); - return localVarResp.getData(); - } - - /** - * - * - * @param start Fetch tasks created after this time, unix epoch in seconds, default 7 days ago (optional) - * @param end Fetch tasks created before this time, unix epoch in seconds, default now (optional) - * @return ApiResponse<ArrayTaskBrowserSidebar> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 sidebar metadata for task definitions for all arrays user has access to -
404 array tasks not found -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getArrayTasksSidebarWithHttpInfo(Integer start, Integer end) throws ApiException { - okhttp3.Call localVarCall = getArrayTasksSidebarValidateBeforeCall(start, end, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * - * @param start Fetch tasks created after this time, unix epoch in seconds, default 7 days ago (optional) - * @param end Fetch tasks created before this time, unix epoch in seconds, default now (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 sidebar metadata for task definitions for all arrays user has access to -
404 array tasks not found -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArrayTasksSidebarAsync(Integer start, Integer end, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getArrayTasksSidebarValidateBeforeCall(start, end, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/api/FavoritesApi.java b/src/main/java/io/tiledb/cloud/rest_api/v1/api/FavoritesApi.java deleted file mode 100644 index 798758f..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/api/FavoritesApi.java +++ /dev/null @@ -1,2858 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.api; - -import io.tiledb.cloud.rest_api.v1.ApiCallback; -import io.tiledb.cloud.rest_api.v1.ApiClient; -import io.tiledb.cloud.rest_api.v1.ApiException; -import io.tiledb.cloud.rest_api.v1.ApiResponse; -import io.tiledb.cloud.rest_api.v1.Configuration; -import io.tiledb.cloud.rest_api.v1.Pair; - -import com.google.gson.reflect.TypeToken; - - -import io.tiledb.cloud.rest_api.v1.model.ArrayFavorite; -import io.tiledb.cloud.rest_api.v1.model.ArrayFavoritesData; -import io.tiledb.cloud.rest_api.v1.model.MLModelFavorite; -import io.tiledb.cloud.rest_api.v1.model.MLModelFavoritesData; -import io.tiledb.cloud.rest_api.v1.model.NotebookFavorite; -import io.tiledb.cloud.rest_api.v1.model.NotebookFavoritesData; -import io.tiledb.cloud.rest_api.v1.model.UDFFavorite; -import io.tiledb.cloud.rest_api.v1.model.UDFFavoritesData; - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class FavoritesApi { - private ApiClient localVarApiClient; - private int localHostIndex; - private String localCustomBaseUrl; - - public FavoritesApi() { - this(Configuration.getDefaultApiClient()); - } - - public FavoritesApi(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public ApiClient getApiClient() { - return localVarApiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public int getHostIndex() { - return localHostIndex; - } - - public void setHostIndex(int hostIndex) { - this.localHostIndex = hostIndex; - } - - public String getCustomBaseUrl() { - return localCustomBaseUrl; - } - - public void setCustomBaseUrl(String customBaseUrl) { - this.localCustomBaseUrl = customBaseUrl; - } - - /** - * Build call for addArrayFavorite - * @param namespace The namespace of the array (required) - * @param name The name of the array (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Item added to favorites successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call addArrayFavoriteCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/favorites/{namespace}/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call addArrayFavoriteValidateBeforeCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling addArrayFavorite(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling addArrayFavorite(Async)"); - } - - - okhttp3.Call localVarCall = addArrayFavoriteCall(namespace, name, _callback); - return localVarCall; - - } - - /** - * - * Add a new array favorite - * @param namespace The namespace of the array (required) - * @param name The name of the array (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Item added to favorites successfully -
502 Bad Gateway -
0 error response -
- */ - public void addArrayFavorite(String namespace, String name) throws ApiException { - addArrayFavoriteWithHttpInfo(namespace, name); - } - - /** - * - * Add a new array favorite - * @param namespace The namespace of the array (required) - * @param name The name of the array (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Item added to favorites successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse addArrayFavoriteWithHttpInfo(String namespace, String name) throws ApiException { - okhttp3.Call localVarCall = addArrayFavoriteValidateBeforeCall(namespace, name, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Add a new array favorite - * @param namespace The namespace of the array (required) - * @param name The name of the array (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Item added to favorites successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call addArrayFavoriteAsync(String namespace, String name, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = addArrayFavoriteValidateBeforeCall(namespace, name, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for addMLModelFavorite - * @param namespace The namespace of the ML model (required) - * @param name The name of the ML model (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Item added to favorites successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call addMLModelFavoriteCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/ml_models/favorites/{namespace}/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call addMLModelFavoriteValidateBeforeCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling addMLModelFavorite(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling addMLModelFavorite(Async)"); - } - - - okhttp3.Call localVarCall = addMLModelFavoriteCall(namespace, name, _callback); - return localVarCall; - - } - - /** - * - * Add a new ML model favorite - * @param namespace The namespace of the ML model (required) - * @param name The name of the ML model (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Item added to favorites successfully -
502 Bad Gateway -
0 error response -
- */ - public void addMLModelFavorite(String namespace, String name) throws ApiException { - addMLModelFavoriteWithHttpInfo(namespace, name); - } - - /** - * - * Add a new ML model favorite - * @param namespace The namespace of the ML model (required) - * @param name The name of the ML model (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Item added to favorites successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse addMLModelFavoriteWithHttpInfo(String namespace, String name) throws ApiException { - okhttp3.Call localVarCall = addMLModelFavoriteValidateBeforeCall(namespace, name, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Add a new ML model favorite - * @param namespace The namespace of the ML model (required) - * @param name The name of the ML model (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Item added to favorites successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call addMLModelFavoriteAsync(String namespace, String name, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = addMLModelFavoriteValidateBeforeCall(namespace, name, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for addNotebookFavorite - * @param namespace The namespace of the notebook (required) - * @param name The name of the notebook (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Item added to favorites successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call addNotebookFavoriteCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/notebooks/favorites/{namespace}/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call addNotebookFavoriteValidateBeforeCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling addNotebookFavorite(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling addNotebookFavorite(Async)"); - } - - - okhttp3.Call localVarCall = addNotebookFavoriteCall(namespace, name, _callback); - return localVarCall; - - } - - /** - * - * Add a new notebook favorite - * @param namespace The namespace of the notebook (required) - * @param name The name of the notebook (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Item added to favorites successfully -
502 Bad Gateway -
0 error response -
- */ - public void addNotebookFavorite(String namespace, String name) throws ApiException { - addNotebookFavoriteWithHttpInfo(namespace, name); - } - - /** - * - * Add a new notebook favorite - * @param namespace The namespace of the notebook (required) - * @param name The name of the notebook (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Item added to favorites successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse addNotebookFavoriteWithHttpInfo(String namespace, String name) throws ApiException { - okhttp3.Call localVarCall = addNotebookFavoriteValidateBeforeCall(namespace, name, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Add a new notebook favorite - * @param namespace The namespace of the notebook (required) - * @param name The name of the notebook (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Item added to favorites successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call addNotebookFavoriteAsync(String namespace, String name, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = addNotebookFavoriteValidateBeforeCall(namespace, name, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for addUDFFavorite - * @param namespace The namespace of the UDF (required) - * @param name The name of the UDF (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Item added to favorites successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call addUDFFavoriteCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/udfs/favorites/{namespace}/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call addUDFFavoriteValidateBeforeCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling addUDFFavorite(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling addUDFFavorite(Async)"); - } - - - okhttp3.Call localVarCall = addUDFFavoriteCall(namespace, name, _callback); - return localVarCall; - - } - - /** - * - * Add a new UDF favorite - * @param namespace The namespace of the UDF (required) - * @param name The name of the UDF (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Item added to favorites successfully -
502 Bad Gateway -
0 error response -
- */ - public void addUDFFavorite(String namespace, String name) throws ApiException { - addUDFFavoriteWithHttpInfo(namespace, name); - } - - /** - * - * Add a new UDF favorite - * @param namespace The namespace of the UDF (required) - * @param name The name of the UDF (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Item added to favorites successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse addUDFFavoriteWithHttpInfo(String namespace, String name) throws ApiException { - okhttp3.Call localVarCall = addUDFFavoriteValidateBeforeCall(namespace, name, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Add a new UDF favorite - * @param namespace The namespace of the UDF (required) - * @param name The name of the UDF (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Item added to favorites successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call addUDFFavoriteAsync(String namespace, String name, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = addUDFFavoriteValidateBeforeCall(namespace, name, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for deleteArrayFavorite - * @param namespace The namespace of the array (required) - * @param name The name of the array (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 array favorite item deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteArrayFavoriteCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/favorites/{namespace}/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call deleteArrayFavoriteValidateBeforeCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling deleteArrayFavorite(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling deleteArrayFavorite(Async)"); - } - - - okhttp3.Call localVarCall = deleteArrayFavoriteCall(namespace, name, _callback); - return localVarCall; - - } - - /** - * - * Delete specific array favorite - * @param namespace The namespace of the array (required) - * @param name The name of the array (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 array favorite item deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public void deleteArrayFavorite(String namespace, String name) throws ApiException { - deleteArrayFavoriteWithHttpInfo(namespace, name); - } - - /** - * - * Delete specific array favorite - * @param namespace The namespace of the array (required) - * @param name The name of the array (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 array favorite item deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse deleteArrayFavoriteWithHttpInfo(String namespace, String name) throws ApiException { - okhttp3.Call localVarCall = deleteArrayFavoriteValidateBeforeCall(namespace, name, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Delete specific array favorite - * @param namespace The namespace of the array (required) - * @param name The name of the array (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 array favorite item deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteArrayFavoriteAsync(String namespace, String name, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = deleteArrayFavoriteValidateBeforeCall(namespace, name, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for deleteMLModelFavorite - * @param namespace The namespace of the ML model (required) - * @param name The name of the ML model (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 ML model favorite item deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteMLModelFavoriteCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/ml_models/favorites/{namespace}/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call deleteMLModelFavoriteValidateBeforeCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling deleteMLModelFavorite(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling deleteMLModelFavorite(Async)"); - } - - - okhttp3.Call localVarCall = deleteMLModelFavoriteCall(namespace, name, _callback); - return localVarCall; - - } - - /** - * - * Delete specific ML model favorite - * @param namespace The namespace of the ML model (required) - * @param name The name of the ML model (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 ML model favorite item deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public void deleteMLModelFavorite(String namespace, String name) throws ApiException { - deleteMLModelFavoriteWithHttpInfo(namespace, name); - } - - /** - * - * Delete specific ML model favorite - * @param namespace The namespace of the ML model (required) - * @param name The name of the ML model (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 ML model favorite item deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse deleteMLModelFavoriteWithHttpInfo(String namespace, String name) throws ApiException { - okhttp3.Call localVarCall = deleteMLModelFavoriteValidateBeforeCall(namespace, name, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Delete specific ML model favorite - * @param namespace The namespace of the ML model (required) - * @param name The name of the ML model (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 ML model favorite item deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteMLModelFavoriteAsync(String namespace, String name, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = deleteMLModelFavoriteValidateBeforeCall(namespace, name, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for deleteNotebookFavorite - * @param namespace The namespace of the notebook (required) - * @param name The name of the notebook (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 notebook favorite item deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteNotebookFavoriteCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/notebooks/favorites/{namespace}/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call deleteNotebookFavoriteValidateBeforeCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling deleteNotebookFavorite(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling deleteNotebookFavorite(Async)"); - } - - - okhttp3.Call localVarCall = deleteNotebookFavoriteCall(namespace, name, _callback); - return localVarCall; - - } - - /** - * - * Delete specific notebook favorite - * @param namespace The namespace of the notebook (required) - * @param name The name of the notebook (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 notebook favorite item deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public void deleteNotebookFavorite(String namespace, String name) throws ApiException { - deleteNotebookFavoriteWithHttpInfo(namespace, name); - } - - /** - * - * Delete specific notebook favorite - * @param namespace The namespace of the notebook (required) - * @param name The name of the notebook (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 notebook favorite item deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse deleteNotebookFavoriteWithHttpInfo(String namespace, String name) throws ApiException { - okhttp3.Call localVarCall = deleteNotebookFavoriteValidateBeforeCall(namespace, name, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Delete specific notebook favorite - * @param namespace The namespace of the notebook (required) - * @param name The name of the notebook (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 notebook favorite item deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteNotebookFavoriteAsync(String namespace, String name, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = deleteNotebookFavoriteValidateBeforeCall(namespace, name, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for deleteUDFFavorite - * @param namespace The namespace of the UDF (required) - * @param name The name of the UDF (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 UDF favorite item deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteUDFFavoriteCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/udfs/favorites/{namespace}/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call deleteUDFFavoriteValidateBeforeCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling deleteUDFFavorite(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling deleteUDFFavorite(Async)"); - } - - - okhttp3.Call localVarCall = deleteUDFFavoriteCall(namespace, name, _callback); - return localVarCall; - - } - - /** - * - * Delete specific UDF favorite - * @param namespace The namespace of the UDF (required) - * @param name The name of the UDF (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 UDF favorite item deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public void deleteUDFFavorite(String namespace, String name) throws ApiException { - deleteUDFFavoriteWithHttpInfo(namespace, name); - } - - /** - * - * Delete specific UDF favorite - * @param namespace The namespace of the UDF (required) - * @param name The name of the UDF (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 UDF favorite item deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse deleteUDFFavoriteWithHttpInfo(String namespace, String name) throws ApiException { - okhttp3.Call localVarCall = deleteUDFFavoriteValidateBeforeCall(namespace, name, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Delete specific UDF favorite - * @param namespace The namespace of the UDF (required) - * @param name The name of the UDF (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 UDF favorite item deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteUDFFavoriteAsync(String namespace, String name, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = deleteUDFFavoriteValidateBeforeCall(namespace, name, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for getArrayFavorite - * @param namespace The namespace of the array (required) - * @param name The name of the array (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 OK -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArrayFavoriteCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/favorites/{namespace}/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getArrayFavoriteValidateBeforeCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getArrayFavorite(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling getArrayFavorite(Async)"); - } - - - okhttp3.Call localVarCall = getArrayFavoriteCall(namespace, name, _callback); - return localVarCall; - - } - - /** - * - * Fetch array favorite of a specific array - * @param namespace The namespace of the array (required) - * @param name The name of the array (required) - * @return ArrayFavorite - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 OK -
502 Bad Gateway -
0 error response -
- */ - public ArrayFavorite getArrayFavorite(String namespace, String name) throws ApiException { - ApiResponse localVarResp = getArrayFavoriteWithHttpInfo(namespace, name); - return localVarResp.getData(); - } - - /** - * - * Fetch array favorite of a specific array - * @param namespace The namespace of the array (required) - * @param name The name of the array (required) - * @return ApiResponse<ArrayFavorite> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 OK -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getArrayFavoriteWithHttpInfo(String namespace, String name) throws ApiException { - okhttp3.Call localVarCall = getArrayFavoriteValidateBeforeCall(namespace, name, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch array favorite of a specific array - * @param namespace The namespace of the array (required) - * @param name The name of the array (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 OK -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getArrayFavoriteAsync(String namespace, String name, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getArrayFavoriteValidateBeforeCall(namespace, name, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getMLModelFavorite - * @param namespace The namespace of the ML model (required) - * @param name The name of the ML model (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 OK -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getMLModelFavoriteCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/ml_models/favorites/{namespace}/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getMLModelFavoriteValidateBeforeCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getMLModelFavorite(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling getMLModelFavorite(Async)"); - } - - - okhttp3.Call localVarCall = getMLModelFavoriteCall(namespace, name, _callback); - return localVarCall; - - } - - /** - * - * Fetch ML model favorite of a specific ML model - * @param namespace The namespace of the ML model (required) - * @param name The name of the ML model (required) - * @return MLModelFavorite - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 OK -
502 Bad Gateway -
0 error response -
- */ - public MLModelFavorite getMLModelFavorite(String namespace, String name) throws ApiException { - ApiResponse localVarResp = getMLModelFavoriteWithHttpInfo(namespace, name); - return localVarResp.getData(); - } - - /** - * - * Fetch ML model favorite of a specific ML model - * @param namespace The namespace of the ML model (required) - * @param name The name of the ML model (required) - * @return ApiResponse<MLModelFavorite> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 OK -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getMLModelFavoriteWithHttpInfo(String namespace, String name) throws ApiException { - okhttp3.Call localVarCall = getMLModelFavoriteValidateBeforeCall(namespace, name, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch ML model favorite of a specific ML model - * @param namespace The namespace of the ML model (required) - * @param name The name of the ML model (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 OK -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getMLModelFavoriteAsync(String namespace, String name, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getMLModelFavoriteValidateBeforeCall(namespace, name, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getNotebookFavorite - * @param namespace The namespace of the notebook (required) - * @param name The name of the notebook (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 OK -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getNotebookFavoriteCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/notebooks/favorites/{namespace}/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getNotebookFavoriteValidateBeforeCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getNotebookFavorite(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling getNotebookFavorite(Async)"); - } - - - okhttp3.Call localVarCall = getNotebookFavoriteCall(namespace, name, _callback); - return localVarCall; - - } - - /** - * - * Fetch notebook favorite of a specific notebook - * @param namespace The namespace of the notebook (required) - * @param name The name of the notebook (required) - * @return NotebookFavorite - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 OK -
502 Bad Gateway -
0 error response -
- */ - public NotebookFavorite getNotebookFavorite(String namespace, String name) throws ApiException { - ApiResponse localVarResp = getNotebookFavoriteWithHttpInfo(namespace, name); - return localVarResp.getData(); - } - - /** - * - * Fetch notebook favorite of a specific notebook - * @param namespace The namespace of the notebook (required) - * @param name The name of the notebook (required) - * @return ApiResponse<NotebookFavorite> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 OK -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getNotebookFavoriteWithHttpInfo(String namespace, String name) throws ApiException { - okhttp3.Call localVarCall = getNotebookFavoriteValidateBeforeCall(namespace, name, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch notebook favorite of a specific notebook - * @param namespace The namespace of the notebook (required) - * @param name The name of the notebook (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 OK -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getNotebookFavoriteAsync(String namespace, String name, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getNotebookFavoriteValidateBeforeCall(namespace, name, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getUDFFavorite - * @param namespace The namespace of the UDF (required) - * @param name The name of the UDF (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 OK -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getUDFFavoriteCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/udfs/favorites/{namespace}/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getUDFFavoriteValidateBeforeCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getUDFFavorite(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling getUDFFavorite(Async)"); - } - - - okhttp3.Call localVarCall = getUDFFavoriteCall(namespace, name, _callback); - return localVarCall; - - } - - /** - * - * Fetch UDF favorite of a specific UDF - * @param namespace The namespace of the UDF (required) - * @param name The name of the UDF (required) - * @return UDFFavorite - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 OK -
502 Bad Gateway -
0 error response -
- */ - public UDFFavorite getUDFFavorite(String namespace, String name) throws ApiException { - ApiResponse localVarResp = getUDFFavoriteWithHttpInfo(namespace, name); - return localVarResp.getData(); - } - - /** - * - * Fetch UDF favorite of a specific UDF - * @param namespace The namespace of the UDF (required) - * @param name The name of the UDF (required) - * @return ApiResponse<UDFFavorite> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 OK -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getUDFFavoriteWithHttpInfo(String namespace, String name) throws ApiException { - okhttp3.Call localVarCall = getUDFFavoriteValidateBeforeCall(namespace, name, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch UDF favorite of a specific UDF - * @param namespace The namespace of the UDF (required) - * @param name The name of the UDF (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 OK -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getUDFFavoriteAsync(String namespace, String name, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getUDFFavoriteValidateBeforeCall(namespace, name, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for listArrayFavorites - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available array favorites are returned -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listArrayFavoritesCall(Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/favorites"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (page != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("page", page)); - } - - if (perPage != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("per_page", perPage)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call listArrayFavoritesValidateBeforeCall(Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = listArrayFavoritesCall(page, perPage, _callback); - return localVarCall; - - } - - /** - * - * Fetch a page of array favorites of connected user - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @return ArrayFavoritesData - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available array favorites are returned -
502 Bad Gateway -
0 error response -
- */ - public ArrayFavoritesData listArrayFavorites(Integer page, Integer perPage) throws ApiException { - ApiResponse localVarResp = listArrayFavoritesWithHttpInfo(page, perPage); - return localVarResp.getData(); - } - - /** - * - * Fetch a page of array favorites of connected user - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @return ApiResponse<ArrayFavoritesData> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available array favorites are returned -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse listArrayFavoritesWithHttpInfo(Integer page, Integer perPage) throws ApiException { - okhttp3.Call localVarCall = listArrayFavoritesValidateBeforeCall(page, perPage, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch a page of array favorites of connected user - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available array favorites are returned -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listArrayFavoritesAsync(Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = listArrayFavoritesValidateBeforeCall(page, perPage, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for listArrayFavoritesUUIDs - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available favorites array uuids are returned -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listArrayFavoritesUUIDsCall(final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/favorites/uuids"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call listArrayFavoritesUUIDsValidateBeforeCall(final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = listArrayFavoritesUUIDsCall(_callback); - return localVarCall; - - } - - /** - * - * Fetch all favorite array uuids of connected user - * @return List<ArrayFavorite> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available favorites array uuids are returned -
502 Bad Gateway -
0 error response -
- */ - public List listArrayFavoritesUUIDs() throws ApiException { - ApiResponse> localVarResp = listArrayFavoritesUUIDsWithHttpInfo(); - return localVarResp.getData(); - } - - /** - * - * Fetch all favorite array uuids of connected user - * @return ApiResponse<List<ArrayFavorite>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available favorites array uuids are returned -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse> listArrayFavoritesUUIDsWithHttpInfo() throws ApiException { - okhttp3.Call localVarCall = listArrayFavoritesUUIDsValidateBeforeCall(null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch all favorite array uuids of connected user - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available favorites array uuids are returned -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listArrayFavoritesUUIDsAsync(final ApiCallback> _callback) throws ApiException { - - okhttp3.Call localVarCall = listArrayFavoritesUUIDsValidateBeforeCall(_callback); - Type localVarReturnType = new TypeToken>(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for listMLModelFavorites - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available ML models favorites are returned -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listMLModelFavoritesCall(Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/ml_models/favorites"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (page != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("page", page)); - } - - if (perPage != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("per_page", perPage)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call listMLModelFavoritesValidateBeforeCall(Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = listMLModelFavoritesCall(page, perPage, _callback); - return localVarCall; - - } - - /** - * - * Fetch a page of ML models favorites of connected user - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @return MLModelFavoritesData - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available ML models favorites are returned -
502 Bad Gateway -
0 error response -
- */ - public MLModelFavoritesData listMLModelFavorites(Integer page, Integer perPage) throws ApiException { - ApiResponse localVarResp = listMLModelFavoritesWithHttpInfo(page, perPage); - return localVarResp.getData(); - } - - /** - * - * Fetch a page of ML models favorites of connected user - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @return ApiResponse<MLModelFavoritesData> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available ML models favorites are returned -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse listMLModelFavoritesWithHttpInfo(Integer page, Integer perPage) throws ApiException { - okhttp3.Call localVarCall = listMLModelFavoritesValidateBeforeCall(page, perPage, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch a page of ML models favorites of connected user - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available ML models favorites are returned -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listMLModelFavoritesAsync(Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = listMLModelFavoritesValidateBeforeCall(page, perPage, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for listMLModelFavoritesUUIDs - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available favorites ML model uuids are returned -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listMLModelFavoritesUUIDsCall(final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/ml_models/favorites/uuids"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call listMLModelFavoritesUUIDsValidateBeforeCall(final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = listMLModelFavoritesUUIDsCall(_callback); - return localVarCall; - - } - - /** - * - * Fetch all favorite ML models uuids of connected user - * @return List<MLModelFavorite> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available favorites ML model uuids are returned -
502 Bad Gateway -
0 error response -
- */ - public List listMLModelFavoritesUUIDs() throws ApiException { - ApiResponse> localVarResp = listMLModelFavoritesUUIDsWithHttpInfo(); - return localVarResp.getData(); - } - - /** - * - * Fetch all favorite ML models uuids of connected user - * @return ApiResponse<List<MLModelFavorite>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available favorites ML model uuids are returned -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse> listMLModelFavoritesUUIDsWithHttpInfo() throws ApiException { - okhttp3.Call localVarCall = listMLModelFavoritesUUIDsValidateBeforeCall(null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch all favorite ML models uuids of connected user - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available favorites ML model uuids are returned -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listMLModelFavoritesUUIDsAsync(final ApiCallback> _callback) throws ApiException { - - okhttp3.Call localVarCall = listMLModelFavoritesUUIDsValidateBeforeCall(_callback); - Type localVarReturnType = new TypeToken>(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for listNotebookFavorites - * @param isDashboard return only dashboards (optional) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available notebook favorites are returned -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listNotebookFavoritesCall(Boolean isDashboard, Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/notebooks/favorites"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (isDashboard != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("is_dashboard", isDashboard)); - } - - if (page != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("page", page)); - } - - if (perPage != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("per_page", perPage)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call listNotebookFavoritesValidateBeforeCall(Boolean isDashboard, Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = listNotebookFavoritesCall(isDashboard, page, perPage, _callback); - return localVarCall; - - } - - /** - * - * Fetch a page of notebook favorites of connected user - * @param isDashboard return only dashboards (optional) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @return NotebookFavoritesData - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available notebook favorites are returned -
502 Bad Gateway -
0 error response -
- */ - public NotebookFavoritesData listNotebookFavorites(Boolean isDashboard, Integer page, Integer perPage) throws ApiException { - ApiResponse localVarResp = listNotebookFavoritesWithHttpInfo(isDashboard, page, perPage); - return localVarResp.getData(); - } - - /** - * - * Fetch a page of notebook favorites of connected user - * @param isDashboard return only dashboards (optional) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @return ApiResponse<NotebookFavoritesData> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available notebook favorites are returned -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse listNotebookFavoritesWithHttpInfo(Boolean isDashboard, Integer page, Integer perPage) throws ApiException { - okhttp3.Call localVarCall = listNotebookFavoritesValidateBeforeCall(isDashboard, page, perPage, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch a page of notebook favorites of connected user - * @param isDashboard return only dashboards (optional) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available notebook favorites are returned -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listNotebookFavoritesAsync(Boolean isDashboard, Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = listNotebookFavoritesValidateBeforeCall(isDashboard, page, perPage, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for listNotebookFavoritesUUIDs - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available favorites notebook uuids are returned -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listNotebookFavoritesUUIDsCall(final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/notebooks/favorites/uuids"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call listNotebookFavoritesUUIDsValidateBeforeCall(final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = listNotebookFavoritesUUIDsCall(_callback); - return localVarCall; - - } - - /** - * - * Fetch all favorite notebook uuids of connected user - * @return List<NotebookFavorite> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available favorites notebook uuids are returned -
502 Bad Gateway -
0 error response -
- */ - public List listNotebookFavoritesUUIDs() throws ApiException { - ApiResponse> localVarResp = listNotebookFavoritesUUIDsWithHttpInfo(); - return localVarResp.getData(); - } - - /** - * - * Fetch all favorite notebook uuids of connected user - * @return ApiResponse<List<NotebookFavorite>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available favorites notebook uuids are returned -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse> listNotebookFavoritesUUIDsWithHttpInfo() throws ApiException { - okhttp3.Call localVarCall = listNotebookFavoritesUUIDsValidateBeforeCall(null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch all favorite notebook uuids of connected user - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available favorites notebook uuids are returned -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listNotebookFavoritesUUIDsAsync(final ApiCallback> _callback) throws ApiException { - - okhttp3.Call localVarCall = listNotebookFavoritesUUIDsValidateBeforeCall(_callback); - Type localVarReturnType = new TypeToken>(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for listUDFFavorites - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available UDF favorites are returned -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listUDFFavoritesCall(Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/udfs/favorites"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (page != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("page", page)); - } - - if (perPage != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("per_page", perPage)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call listUDFFavoritesValidateBeforeCall(Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = listUDFFavoritesCall(page, perPage, _callback); - return localVarCall; - - } - - /** - * - * Fetch a page of UDF favorites of connected user - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @return UDFFavoritesData - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available UDF favorites are returned -
502 Bad Gateway -
0 error response -
- */ - public UDFFavoritesData listUDFFavorites(Integer page, Integer perPage) throws ApiException { - ApiResponse localVarResp = listUDFFavoritesWithHttpInfo(page, perPage); - return localVarResp.getData(); - } - - /** - * - * Fetch a page of UDF favorites of connected user - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @return ApiResponse<UDFFavoritesData> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available UDF favorites are returned -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse listUDFFavoritesWithHttpInfo(Integer page, Integer perPage) throws ApiException { - okhttp3.Call localVarCall = listUDFFavoritesValidateBeforeCall(page, perPage, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch a page of UDF favorites of connected user - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available UDF favorites are returned -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listUDFFavoritesAsync(Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = listUDFFavoritesValidateBeforeCall(page, perPage, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for listUDFFavoritesUUIDs - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available favorites UDF uuids are returned -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listUDFFavoritesUUIDsCall(final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/udfs/favorites/uuids"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call listUDFFavoritesUUIDsValidateBeforeCall(final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = listUDFFavoritesUUIDsCall(_callback); - return localVarCall; - - } - - /** - * - * Fetch all favorite UDF uuids of connected user - * @return List<UDFFavorite> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available favorites UDF uuids are returned -
502 Bad Gateway -
0 error response -
- */ - public List listUDFFavoritesUUIDs() throws ApiException { - ApiResponse> localVarResp = listUDFFavoritesUUIDsWithHttpInfo(); - return localVarResp.getData(); - } - - /** - * - * Fetch all favorite UDF uuids of connected user - * @return ApiResponse<List<UDFFavorite>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available favorites UDF uuids are returned -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse> listUDFFavoritesUUIDsWithHttpInfo() throws ApiException { - okhttp3.Call localVarCall = listUDFFavoritesUUIDsValidateBeforeCall(null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch all favorite UDF uuids of connected user - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Available favorites UDF uuids are returned -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listUDFFavoritesUUIDsAsync(final ApiCallback> _callback) throws ApiException { - - okhttp3.Call localVarCall = listUDFFavoritesUUIDsValidateBeforeCall(_callback); - Type localVarReturnType = new TypeToken>(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/api/FilesApi.java b/src/main/java/io/tiledb/cloud/rest_api/v1/api/FilesApi.java deleted file mode 100644 index 84b66ea..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/api/FilesApi.java +++ /dev/null @@ -1,554 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.api; - -import io.tiledb.cloud.rest_api.v1.ApiCallback; -import io.tiledb.cloud.rest_api.v1.ApiClient; -import io.tiledb.cloud.rest_api.v1.ApiException; -import io.tiledb.cloud.rest_api.v1.ApiResponse; -import io.tiledb.cloud.rest_api.v1.Configuration; -import io.tiledb.cloud.rest_api.v1.Pair; - -import com.google.gson.reflect.TypeToken; - - -import java.io.File; -import io.tiledb.cloud.rest_api.v1.model.FileCreate; -import io.tiledb.cloud.rest_api.v1.model.FileCreated; -import io.tiledb.cloud.rest_api.v1.model.FileExport; -import io.tiledb.cloud.rest_api.v1.model.FileExported; -import io.tiledb.cloud.rest_api.v1.model.FileUploaded; - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class FilesApi { - private ApiClient localVarApiClient; - private int localHostIndex; - private String localCustomBaseUrl; - - public FilesApi() { - this(Configuration.getDefaultApiClient()); - } - - public FilesApi(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public ApiClient getApiClient() { - return localVarApiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public int getHostIndex() { - return localHostIndex; - } - - public void setHostIndex(int hostIndex) { - this.localHostIndex = hostIndex; - } - - public String getCustomBaseUrl() { - return localCustomBaseUrl; - } - - public void setCustomBaseUrl(String customBaseUrl) { - this.localCustomBaseUrl = customBaseUrl; - } - - /** - * Build call for handleCreateFile - * @param namespace The namespace of the file (required) - * @param fileCreate Input/Output information to create a new TileDB file (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
201 File created -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call handleCreateFileCall(String namespace, FileCreate fileCreate, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = fileCreate; - - // create path and map variables - String localVarPath = "/files/{namespace}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME != null) { - localVarHeaderParams.put("X-TILEDB-CLOUD-ACCESS-CREDENTIALS-NAME", localVarApiClient.parameterToString(X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call handleCreateFileValidateBeforeCall(String namespace, FileCreate fileCreate, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling handleCreateFile(Async)"); - } - - // verify the required parameter 'fileCreate' is set - if (fileCreate == null) { - throw new ApiException("Missing the required parameter 'fileCreate' when calling handleCreateFile(Async)"); - } - - - okhttp3.Call localVarCall = handleCreateFileCall(namespace, fileCreate, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, _callback); - return localVarCall; - - } - - /** - * - * Create a tiledb file at the specified location - * @param namespace The namespace of the file (required) - * @param fileCreate Input/Output information to create a new TileDB file (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @return FileCreated - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
201 File created -
502 Bad Gateway -
0 error response -
- */ - public FileCreated handleCreateFile(String namespace, FileCreate fileCreate, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME) throws ApiException { - ApiResponse localVarResp = handleCreateFileWithHttpInfo(namespace, fileCreate, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME); - return localVarResp.getData(); - } - - /** - * - * Create a tiledb file at the specified location - * @param namespace The namespace of the file (required) - * @param fileCreate Input/Output information to create a new TileDB file (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @return ApiResponse<FileCreated> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
201 File created -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse handleCreateFileWithHttpInfo(String namespace, FileCreate fileCreate, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME) throws ApiException { - okhttp3.Call localVarCall = handleCreateFileValidateBeforeCall(namespace, fileCreate, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Create a tiledb file at the specified location - * @param namespace The namespace of the file (required) - * @param fileCreate Input/Output information to create a new TileDB file (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
201 File created -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call handleCreateFileAsync(String namespace, FileCreate fileCreate, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = handleCreateFileValidateBeforeCall(namespace, fileCreate, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for handleExportFile - * @param namespace The namespace of the file (required) - * @param _file The file identifier (required) - * @param fileExport Export configuration information (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
201 File exported -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call handleExportFileCall(String namespace, String _file, FileExport fileExport, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = fileExport; - - // create path and map variables - String localVarPath = "/files/{namespace}/{file}/export" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "file" + "\\}", localVarApiClient.escapeString(_file.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call handleExportFileValidateBeforeCall(String namespace, String _file, FileExport fileExport, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling handleExportFile(Async)"); - } - - // verify the required parameter '_file' is set - if (_file == null) { - throw new ApiException("Missing the required parameter '_file' when calling handleExportFile(Async)"); - } - - // verify the required parameter 'fileExport' is set - if (fileExport == null) { - throw new ApiException("Missing the required parameter 'fileExport' when calling handleExportFile(Async)"); - } - - - okhttp3.Call localVarCall = handleExportFileCall(namespace, _file, fileExport, _callback); - return localVarCall; - - } - - /** - * - * Export a TileDB File back to its original file format - * @param namespace The namespace of the file (required) - * @param _file The file identifier (required) - * @param fileExport Export configuration information (required) - * @return FileExported - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
201 File exported -
502 Bad Gateway -
0 error response -
- */ - public FileExported handleExportFile(String namespace, String _file, FileExport fileExport) throws ApiException { - ApiResponse localVarResp = handleExportFileWithHttpInfo(namespace, _file, fileExport); - return localVarResp.getData(); - } - - /** - * - * Export a TileDB File back to its original file format - * @param namespace The namespace of the file (required) - * @param _file The file identifier (required) - * @param fileExport Export configuration information (required) - * @return ApiResponse<FileExported> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
201 File exported -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse handleExportFileWithHttpInfo(String namespace, String _file, FileExport fileExport) throws ApiException { - okhttp3.Call localVarCall = handleExportFileValidateBeforeCall(namespace, _file, fileExport, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Export a TileDB File back to its original file format - * @param namespace The namespace of the file (required) - * @param _file The file identifier (required) - * @param fileExport Export configuration information (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
201 File exported -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call handleExportFileAsync(String namespace, String _file, FileExport fileExport, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = handleExportFileValidateBeforeCall(namespace, _file, fileExport, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for handleUploadFile - * @param namespace The namespace of the file (required) - * @param inputFile the file to upload (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @param outputUri output location of the TileDB File (optional) - * @param name name to set for registered file (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
201 File uploaded -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call handleUploadFileCall(String namespace, File inputFile, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, String outputUri, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/files/{namespace}/upload" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (inputFile != null) { - localVarFormParams.put("input_file", inputFile); - } - - if (outputUri != null) { - localVarFormParams.put("output_uri", outputUri); - } - - if (name != null) { - localVarFormParams.put("name", name); - } - - if (X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME != null) { - localVarHeaderParams.put("X-TILEDB-CLOUD-ACCESS-CREDENTIALS-NAME", localVarApiClient.parameterToString(X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "multipart/form-data" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call handleUploadFileValidateBeforeCall(String namespace, File inputFile, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, String outputUri, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling handleUploadFile(Async)"); - } - - // verify the required parameter 'inputFile' is set - if (inputFile == null) { - throw new ApiException("Missing the required parameter 'inputFile' when calling handleUploadFile(Async)"); - } - - - okhttp3.Call localVarCall = handleUploadFileCall(namespace, inputFile, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, outputUri, name, _callback); - return localVarCall; - - } - - /** - * - * Upload a tiledb file at the specified location - * @param namespace The namespace of the file (required) - * @param inputFile the file to upload (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @param outputUri output location of the TileDB File (optional) - * @param name name to set for registered file (optional) - * @return FileUploaded - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
201 File uploaded -
502 Bad Gateway -
0 error response -
- */ - public FileUploaded handleUploadFile(String namespace, File inputFile, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, String outputUri, String name) throws ApiException { - ApiResponse localVarResp = handleUploadFileWithHttpInfo(namespace, inputFile, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, outputUri, name); - return localVarResp.getData(); - } - - /** - * - * Upload a tiledb file at the specified location - * @param namespace The namespace of the file (required) - * @param inputFile the file to upload (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @param outputUri output location of the TileDB File (optional) - * @param name name to set for registered file (optional) - * @return ApiResponse<FileUploaded> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
201 File uploaded -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse handleUploadFileWithHttpInfo(String namespace, File inputFile, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, String outputUri, String name) throws ApiException { - okhttp3.Call localVarCall = handleUploadFileValidateBeforeCall(namespace, inputFile, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, outputUri, name, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Upload a tiledb file at the specified location - * @param namespace The namespace of the file (required) - * @param inputFile the file to upload (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @param outputUri output location of the TileDB File (optional) - * @param name name to set for registered file (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
201 File uploaded -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call handleUploadFileAsync(String namespace, File inputFile, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, String outputUri, String name, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = handleUploadFileValidateBeforeCall(namespace, inputFile, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, outputUri, name, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/api/GroupsApi.java b/src/main/java/io/tiledb/cloud/rest_api/v1/api/GroupsApi.java deleted file mode 100644 index f82d681..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/api/GroupsApi.java +++ /dev/null @@ -1,2802 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.api; - -import io.tiledb.cloud.rest_api.v1.ApiCallback; -import io.tiledb.cloud.rest_api.v1.ApiClient; -import io.tiledb.cloud.rest_api.v1.ApiException; -import io.tiledb.cloud.rest_api.v1.ApiResponse; -import io.tiledb.cloud.rest_api.v1.Configuration; -import io.tiledb.cloud.rest_api.v1.Pair; - -import com.google.gson.reflect.TypeToken; - - -import io.tiledb.cloud.rest_api.v1.model.GroupActivityResponse; -import io.tiledb.cloud.rest_api.v1.model.GroupBrowserData; -import io.tiledb.cloud.rest_api.v1.model.GroupBrowserFilterData; -import io.tiledb.cloud.rest_api.v1.model.GroupChanges; -import io.tiledb.cloud.rest_api.v1.model.GroupContents; -import io.tiledb.cloud.rest_api.v1.model.GroupContentsFilterData; -import io.tiledb.cloud.rest_api.v1.model.GroupCreate; -import io.tiledb.cloud.rest_api.v1.model.GroupInfo; -import io.tiledb.cloud.rest_api.v1.model.GroupRegister; -import io.tiledb.cloud.rest_api.v1.model.GroupSharing; -import io.tiledb.cloud.rest_api.v1.model.GroupSharingRequest; -import io.tiledb.cloud.rest_api.v1.model.GroupUpdate; - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class GroupsApi { - private ApiClient localVarApiClient; - private int localHostIndex; - private String localCustomBaseUrl; - - public GroupsApi() { - this(Configuration.getDefaultApiClient()); - } - - public GroupsApi(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public ApiClient getApiClient() { - return localVarApiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public int getHostIndex() { - return localHostIndex; - } - - public void setHostIndex(int hostIndex) { - this.localHostIndex = hostIndex; - } - - public String getCustomBaseUrl() { - return localCustomBaseUrl; - } - - public void setCustomBaseUrl(String customBaseUrl) { - this.localCustomBaseUrl = customBaseUrl; - } - - /** - * Build call for changeGroupContents - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param groupChanges (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 all changes applied successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call changeGroupContentsCall(String groupNamespace, String groupName, GroupChanges groupChanges, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = groupChanges; - - // create path and map variables - String localVarPath = "/groups/{group_namespace}/{group_name}/contents" - .replaceAll("\\{" + "group_namespace" + "\\}", localVarApiClient.escapeString(groupNamespace.toString())) - .replaceAll("\\{" + "group_name" + "\\}", localVarApiClient.escapeString(groupName.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call changeGroupContentsValidateBeforeCall(String groupNamespace, String groupName, GroupChanges groupChanges, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'groupNamespace' is set - if (groupNamespace == null) { - throw new ApiException("Missing the required parameter 'groupNamespace' when calling changeGroupContents(Async)"); - } - - // verify the required parameter 'groupName' is set - if (groupName == null) { - throw new ApiException("Missing the required parameter 'groupName' when calling changeGroupContents(Async)"); - } - - - okhttp3.Call localVarCall = changeGroupContentsCall(groupNamespace, groupName, groupChanges, _callback); - return localVarCall; - - } - - /** - * - * Changes the contents of the group by adding/removing members. - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param groupChanges (optional) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 all changes applied successfully -
502 Bad Gateway -
0 error response -
- */ - public void changeGroupContents(String groupNamespace, String groupName, GroupChanges groupChanges) throws ApiException { - changeGroupContentsWithHttpInfo(groupNamespace, groupName, groupChanges); - } - - /** - * - * Changes the contents of the group by adding/removing members. - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param groupChanges (optional) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 all changes applied successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse changeGroupContentsWithHttpInfo(String groupNamespace, String groupName, GroupChanges groupChanges) throws ApiException { - okhttp3.Call localVarCall = changeGroupContentsValidateBeforeCall(groupNamespace, groupName, groupChanges, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Changes the contents of the group by adding/removing members. - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param groupChanges (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 all changes applied successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call changeGroupContentsAsync(String groupNamespace, String groupName, GroupChanges groupChanges, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = changeGroupContentsValidateBeforeCall(groupNamespace, groupName, groupChanges, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for createGroup - * @param namespace The namespace of the group (required) - * @param groupCreate (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 group created successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call createGroupCall(String namespace, GroupCreate groupCreate, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = groupCreate; - - // create path and map variables - String localVarPath = "/groups/{namespace}/create" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call createGroupValidateBeforeCall(String namespace, GroupCreate groupCreate, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling createGroup(Async)"); - } - - - okhttp3.Call localVarCall = createGroupCall(namespace, groupCreate, _callback); - return localVarCall; - - } - - /** - * - * Creates a new group in the namespace. - * @param namespace The namespace of the group (required) - * @param groupCreate (optional) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 group created successfully -
502 Bad Gateway -
0 error response -
- */ - public void createGroup(String namespace, GroupCreate groupCreate) throws ApiException { - createGroupWithHttpInfo(namespace, groupCreate); - } - - /** - * - * Creates a new group in the namespace. - * @param namespace The namespace of the group (required) - * @param groupCreate (optional) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 group created successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse createGroupWithHttpInfo(String namespace, GroupCreate groupCreate) throws ApiException { - okhttp3.Call localVarCall = createGroupValidateBeforeCall(namespace, groupCreate, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Creates a new group in the namespace. - * @param namespace The namespace of the group (required) - * @param groupCreate (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 group created successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call createGroupAsync(String namespace, GroupCreate groupCreate, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = createGroupValidateBeforeCall(namespace, groupCreate, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for deleteGroup - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 group deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteGroupCall(String groupNamespace, String groupName, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/groups/{group_namespace}/{group_name}" - .replaceAll("\\{" + "group_namespace" + "\\}", localVarApiClient.escapeString(groupNamespace.toString())) - .replaceAll("\\{" + "group_name" + "\\}", localVarApiClient.escapeString(groupName.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call deleteGroupValidateBeforeCall(String groupNamespace, String groupName, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'groupNamespace' is set - if (groupNamespace == null) { - throw new ApiException("Missing the required parameter 'groupNamespace' when calling deleteGroup(Async)"); - } - - // verify the required parameter 'groupName' is set - if (groupName == null) { - throw new ApiException("Missing the required parameter 'groupName' when calling deleteGroup(Async)"); - } - - - okhttp3.Call localVarCall = deleteGroupCall(groupNamespace, groupName, _callback); - return localVarCall; - - } - - /** - * - * Deletes the group. The assets are not deleted nor are not relocated to any other group - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 group deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public void deleteGroup(String groupNamespace, String groupName) throws ApiException { - deleteGroupWithHttpInfo(groupNamespace, groupName); - } - - /** - * - * Deletes the group. The assets are not deleted nor are not relocated to any other group - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 group deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse deleteGroupWithHttpInfo(String groupNamespace, String groupName) throws ApiException { - okhttp3.Call localVarCall = deleteGroupValidateBeforeCall(groupNamespace, groupName, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Deletes the group. The assets are not deleted nor are not relocated to any other group - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 group deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteGroupAsync(String groupNamespace, String groupName, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = deleteGroupValidateBeforeCall(groupNamespace, groupName, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for getGroup - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 the group metadata -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getGroupCall(String groupNamespace, String groupName, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/groups/{group_namespace}/{group_name}" - .replaceAll("\\{" + "group_namespace" + "\\}", localVarApiClient.escapeString(groupNamespace.toString())) - .replaceAll("\\{" + "group_name" + "\\}", localVarApiClient.escapeString(groupName.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getGroupValidateBeforeCall(String groupNamespace, String groupName, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'groupNamespace' is set - if (groupNamespace == null) { - throw new ApiException("Missing the required parameter 'groupNamespace' when calling getGroup(Async)"); - } - - // verify the required parameter 'groupName' is set - if (groupName == null) { - throw new ApiException("Missing the required parameter 'groupName' when calling getGroup(Async)"); - } - - - okhttp3.Call localVarCall = getGroupCall(groupNamespace, groupName, _callback); - return localVarCall; - - } - - /** - * - * Returns the the group - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @return GroupInfo - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 the group metadata -
502 Bad Gateway -
0 error response -
- */ - public GroupInfo getGroup(String groupNamespace, String groupName) throws ApiException { - ApiResponse localVarResp = getGroupWithHttpInfo(groupNamespace, groupName); - return localVarResp.getData(); - } - - /** - * - * Returns the the group - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @return ApiResponse<GroupInfo> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 the group metadata -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getGroupWithHttpInfo(String groupNamespace, String groupName) throws ApiException { - okhttp3.Call localVarCall = getGroupValidateBeforeCall(groupNamespace, groupName, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Returns the the group - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 the group metadata -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getGroupAsync(String groupNamespace, String groupName, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getGroupValidateBeforeCall(groupNamespace, groupName, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getGroupActivity - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Activity logs of group contents along with the pagination metadata -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getGroupActivityCall(String groupNamespace, String groupName, Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/groups/{group_namespace}/{group_name}/content_activity" - .replaceAll("\\{" + "group_namespace" + "\\}", localVarApiClient.escapeString(groupNamespace.toString())) - .replaceAll("\\{" + "group_name" + "\\}", localVarApiClient.escapeString(groupName.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (page != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("page", page)); - } - - if (perPage != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("per_page", perPage)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getGroupActivityValidateBeforeCall(String groupNamespace, String groupName, Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'groupNamespace' is set - if (groupNamespace == null) { - throw new ApiException("Missing the required parameter 'groupNamespace' when calling getGroupActivity(Async)"); - } - - // verify the required parameter 'groupName' is set - if (groupName == null) { - throw new ApiException("Missing the required parameter 'groupName' when calling getGroupActivity(Async)"); - } - - - okhttp3.Call localVarCall = getGroupActivityCall(groupNamespace, groupName, page, perPage, _callback); - return localVarCall; - - } - - /** - * - * Returns the activity of group content - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @return GroupActivityResponse - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Activity logs of group contents along with the pagination metadata -
502 Bad Gateway -
0 error response -
- */ - public GroupActivityResponse getGroupActivity(String groupNamespace, String groupName, Integer page, Integer perPage) throws ApiException { - ApiResponse localVarResp = getGroupActivityWithHttpInfo(groupNamespace, groupName, page, perPage); - return localVarResp.getData(); - } - - /** - * - * Returns the activity of group content - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @return ApiResponse<GroupActivityResponse> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Activity logs of group contents along with the pagination metadata -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getGroupActivityWithHttpInfo(String groupNamespace, String groupName, Integer page, Integer perPage) throws ApiException { - okhttp3.Call localVarCall = getGroupActivityValidateBeforeCall(groupNamespace, groupName, page, perPage, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Returns the activity of group content - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Activity logs of group contents along with the pagination metadata -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getGroupActivityAsync(String groupNamespace, String groupName, Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getGroupActivityValidateBeforeCall(groupNamespace, groupName, page, perPage, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getGroupContents - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param page pagination offset for assets (optional) - * @param perPage pagination limit for assets (optional) - * @param namespace namespace to search for (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param memberType member type to search for, more than one can be included (optional) - * @param excludeMemberType member type to exclude matching groups in results, more than one can be included (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 the group contents -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getGroupContentsCall(String groupNamespace, String groupName, Integer page, Integer perPage, String namespace, String search, String orderby, List tag, List excludeTag, List memberType, List excludeMemberType, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/groups/{group_namespace}/{group_name}/contents" - .replaceAll("\\{" + "group_namespace" + "\\}", localVarApiClient.escapeString(groupNamespace.toString())) - .replaceAll("\\{" + "group_name" + "\\}", localVarApiClient.escapeString(groupName.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (page != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("page", page)); - } - - if (perPage != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("per_page", perPage)); - } - - if (namespace != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("namespace", namespace)); - } - - if (search != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("search", search)); - } - - if (orderby != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("orderby", orderby)); - } - - if (tag != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "tag", tag)); - } - - if (excludeTag != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "exclude_tag", excludeTag)); - } - - if (memberType != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "member_type", memberType)); - } - - if (excludeMemberType != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "exclude_member_type", excludeMemberType)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getGroupContentsValidateBeforeCall(String groupNamespace, String groupName, Integer page, Integer perPage, String namespace, String search, String orderby, List tag, List excludeTag, List memberType, List excludeMemberType, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'groupNamespace' is set - if (groupNamespace == null) { - throw new ApiException("Missing the required parameter 'groupNamespace' when calling getGroupContents(Async)"); - } - - // verify the required parameter 'groupName' is set - if (groupName == null) { - throw new ApiException("Missing the required parameter 'groupName' when calling getGroupContents(Async)"); - } - - - okhttp3.Call localVarCall = getGroupContentsCall(groupNamespace, groupName, page, perPage, namespace, search, orderby, tag, excludeTag, memberType, excludeMemberType, _callback); - return localVarCall; - - } - - /** - * - * Returns the contents of the group - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param page pagination offset for assets (optional) - * @param perPage pagination limit for assets (optional) - * @param namespace namespace to search for (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param memberType member type to search for, more than one can be included (optional) - * @param excludeMemberType member type to exclude matching groups in results, more than one can be included (optional) - * @return GroupContents - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 the group contents -
502 Bad Gateway -
0 error response -
- */ - public GroupContents getGroupContents(String groupNamespace, String groupName, Integer page, Integer perPage, String namespace, String search, String orderby, List tag, List excludeTag, List memberType, List excludeMemberType) throws ApiException { - ApiResponse localVarResp = getGroupContentsWithHttpInfo(groupNamespace, groupName, page, perPage, namespace, search, orderby, tag, excludeTag, memberType, excludeMemberType); - return localVarResp.getData(); - } - - /** - * - * Returns the contents of the group - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param page pagination offset for assets (optional) - * @param perPage pagination limit for assets (optional) - * @param namespace namespace to search for (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param memberType member type to search for, more than one can be included (optional) - * @param excludeMemberType member type to exclude matching groups in results, more than one can be included (optional) - * @return ApiResponse<GroupContents> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 the group contents -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getGroupContentsWithHttpInfo(String groupNamespace, String groupName, Integer page, Integer perPage, String namespace, String search, String orderby, List tag, List excludeTag, List memberType, List excludeMemberType) throws ApiException { - okhttp3.Call localVarCall = getGroupContentsValidateBeforeCall(groupNamespace, groupName, page, perPage, namespace, search, orderby, tag, excludeTag, memberType, excludeMemberType, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Returns the contents of the group - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param page pagination offset for assets (optional) - * @param perPage pagination limit for assets (optional) - * @param namespace namespace to search for (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param memberType member type to search for, more than one can be included (optional) - * @param excludeMemberType member type to exclude matching groups in results, more than one can be included (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 the group contents -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getGroupContentsAsync(String groupNamespace, String groupName, Integer page, Integer perPage, String namespace, String search, String orderby, List tag, List excludeTag, List memberType, List excludeMemberType, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getGroupContentsValidateBeforeCall(groupNamespace, groupName, page, perPage, namespace, search, orderby, tag, excludeTag, memberType, excludeMemberType, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getGroupSharingPolicies - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 List of all specific sharing policies -
404 Group does not exist or user does not have permissions to view group-sharing policies -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getGroupSharingPoliciesCall(String groupNamespace, String groupName, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/groups/{group_namespace}/{group_name}/share" - .replaceAll("\\{" + "group_namespace" + "\\}", localVarApiClient.escapeString(groupNamespace.toString())) - .replaceAll("\\{" + "group_name" + "\\}", localVarApiClient.escapeString(groupName.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getGroupSharingPoliciesValidateBeforeCall(String groupNamespace, String groupName, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'groupNamespace' is set - if (groupNamespace == null) { - throw new ApiException("Missing the required parameter 'groupNamespace' when calling getGroupSharingPolicies(Async)"); - } - - // verify the required parameter 'groupName' is set - if (groupName == null) { - throw new ApiException("Missing the required parameter 'groupName' when calling getGroupSharingPolicies(Async)"); - } - - - okhttp3.Call localVarCall = getGroupSharingPoliciesCall(groupNamespace, groupName, _callback); - return localVarCall; - - } - - /** - * - * Get all sharing details of the group - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @return List<GroupSharing> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 List of all specific sharing policies -
404 Group does not exist or user does not have permissions to view group-sharing policies -
502 Bad Gateway -
0 error response -
- */ - public List getGroupSharingPolicies(String groupNamespace, String groupName) throws ApiException { - ApiResponse> localVarResp = getGroupSharingPoliciesWithHttpInfo(groupNamespace, groupName); - return localVarResp.getData(); - } - - /** - * - * Get all sharing details of the group - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @return ApiResponse<List<GroupSharing>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 List of all specific sharing policies -
404 Group does not exist or user does not have permissions to view group-sharing policies -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse> getGroupSharingPoliciesWithHttpInfo(String groupNamespace, String groupName) throws ApiException { - okhttp3.Call localVarCall = getGroupSharingPoliciesValidateBeforeCall(groupNamespace, groupName, null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Get all sharing details of the group - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 List of all specific sharing policies -
404 Group does not exist or user does not have permissions to view group-sharing policies -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getGroupSharingPoliciesAsync(String groupNamespace, String groupName, final ApiCallback> _callback) throws ApiException { - - okhttp3.Call localVarCall = getGroupSharingPoliciesValidateBeforeCall(groupNamespace, groupName, _callback); - Type localVarReturnType = new TypeToken>(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for groupsBrowserOwnedFiltersGet - * @param namespace namespace (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Filter data -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call groupsBrowserOwnedFiltersGetCall(String namespace, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/groups/browser/owned/filters"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (namespace != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("namespace", namespace)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call groupsBrowserOwnedFiltersGetValidateBeforeCall(String namespace, final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = groupsBrowserOwnedFiltersGetCall(namespace, _callback); - return localVarCall; - - } - - /** - * - * Fetch data to initialize filters for the groups browser - * @param namespace namespace (optional) - * @return GroupBrowserFilterData - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Filter data -
502 Bad Gateway -
0 error response -
- */ - public GroupBrowserFilterData groupsBrowserOwnedFiltersGet(String namespace) throws ApiException { - ApiResponse localVarResp = groupsBrowserOwnedFiltersGetWithHttpInfo(namespace); - return localVarResp.getData(); - } - - /** - * - * Fetch data to initialize filters for the groups browser - * @param namespace namespace (optional) - * @return ApiResponse<GroupBrowserFilterData> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Filter data -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse groupsBrowserOwnedFiltersGetWithHttpInfo(String namespace) throws ApiException { - okhttp3.Call localVarCall = groupsBrowserOwnedFiltersGetValidateBeforeCall(namespace, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch data to initialize filters for the groups browser - * @param namespace namespace (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Filter data -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call groupsBrowserOwnedFiltersGetAsync(String namespace, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = groupsBrowserOwnedFiltersGetValidateBeforeCall(namespace, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for groupsBrowserPublicFiltersGet - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Filter data -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call groupsBrowserPublicFiltersGetCall(final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/groups/browser/public/filters"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call groupsBrowserPublicFiltersGetValidateBeforeCall(final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = groupsBrowserPublicFiltersGetCall(_callback); - return localVarCall; - - } - - /** - * - * Fetch data to initialize filters for the groups browser - * @return GroupBrowserFilterData - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Filter data -
502 Bad Gateway -
0 error response -
- */ - public GroupBrowserFilterData groupsBrowserPublicFiltersGet() throws ApiException { - ApiResponse localVarResp = groupsBrowserPublicFiltersGetWithHttpInfo(); - return localVarResp.getData(); - } - - /** - * - * Fetch data to initialize filters for the groups browser - * @return ApiResponse<GroupBrowserFilterData> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Filter data -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse groupsBrowserPublicFiltersGetWithHttpInfo() throws ApiException { - okhttp3.Call localVarCall = groupsBrowserPublicFiltersGetValidateBeforeCall(null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch data to initialize filters for the groups browser - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Filter data -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call groupsBrowserPublicFiltersGetAsync(final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = groupsBrowserPublicFiltersGetValidateBeforeCall(_callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for groupsBrowserSharedFiltersGet - * @param namespace namespace (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Filter data -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call groupsBrowserSharedFiltersGetCall(String namespace, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/groups/browser/shared/filters"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (namespace != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("namespace", namespace)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call groupsBrowserSharedFiltersGetValidateBeforeCall(String namespace, final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = groupsBrowserSharedFiltersGetCall(namespace, _callback); - return localVarCall; - - } - - /** - * - * Fetch data to initialize filters for the groups browser - * @param namespace namespace (optional) - * @return GroupBrowserFilterData - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Filter data -
502 Bad Gateway -
0 error response -
- */ - public GroupBrowserFilterData groupsBrowserSharedFiltersGet(String namespace) throws ApiException { - ApiResponse localVarResp = groupsBrowserSharedFiltersGetWithHttpInfo(namespace); - return localVarResp.getData(); - } - - /** - * - * Fetch data to initialize filters for the groups browser - * @param namespace namespace (optional) - * @return ApiResponse<GroupBrowserFilterData> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Filter data -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse groupsBrowserSharedFiltersGetWithHttpInfo(String namespace) throws ApiException { - okhttp3.Call localVarCall = groupsBrowserSharedFiltersGetValidateBeforeCall(namespace, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch data to initialize filters for the groups browser - * @param namespace namespace (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Filter data -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call groupsBrowserSharedFiltersGetAsync(String namespace, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = groupsBrowserSharedFiltersGetValidateBeforeCall(namespace, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for groupsGroupNamespaceGroupNameContentsFiltersGet - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Filter data -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call groupsGroupNamespaceGroupNameContentsFiltersGetCall(String groupNamespace, String groupName, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/groups/{group_namespace}/{group_name}/contents/filters" - .replaceAll("\\{" + "group_namespace" + "\\}", localVarApiClient.escapeString(groupNamespace.toString())) - .replaceAll("\\{" + "group_name" + "\\}", localVarApiClient.escapeString(groupName.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call groupsGroupNamespaceGroupNameContentsFiltersGetValidateBeforeCall(String groupNamespace, String groupName, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'groupNamespace' is set - if (groupNamespace == null) { - throw new ApiException("Missing the required parameter 'groupNamespace' when calling groupsGroupNamespaceGroupNameContentsFiltersGet(Async)"); - } - - // verify the required parameter 'groupName' is set - if (groupName == null) { - throw new ApiException("Missing the required parameter 'groupName' when calling groupsGroupNamespaceGroupNameContentsFiltersGet(Async)"); - } - - - okhttp3.Call localVarCall = groupsGroupNamespaceGroupNameContentsFiltersGetCall(groupNamespace, groupName, _callback); - return localVarCall; - - } - - /** - * - * Fetch data to initialize filters for the group contents - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @return GroupContentsFilterData - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Filter data -
502 Bad Gateway -
0 error response -
- */ - public GroupContentsFilterData groupsGroupNamespaceGroupNameContentsFiltersGet(String groupNamespace, String groupName) throws ApiException { - ApiResponse localVarResp = groupsGroupNamespaceGroupNameContentsFiltersGetWithHttpInfo(groupNamespace, groupName); - return localVarResp.getData(); - } - - /** - * - * Fetch data to initialize filters for the group contents - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @return ApiResponse<GroupContentsFilterData> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Filter data -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse groupsGroupNamespaceGroupNameContentsFiltersGetWithHttpInfo(String groupNamespace, String groupName) throws ApiException { - okhttp3.Call localVarCall = groupsGroupNamespaceGroupNameContentsFiltersGetValidateBeforeCall(groupNamespace, groupName, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch data to initialize filters for the group contents - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Filter data -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call groupsGroupNamespaceGroupNameContentsFiltersGetAsync(String groupNamespace, String groupName, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = groupsGroupNamespaceGroupNameContentsFiltersGetValidateBeforeCall(groupNamespace, groupName, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for listOwnedGroups - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param groupType filter by a specific group type (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param flat if true, ignores the nesting of groups and searches all of them (optional) - * @param parent search only the children of the groups with this uuid (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 the group contents -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listOwnedGroupsCall(Integer page, Integer perPage, String groupType, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, Boolean flat, String parent, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/groups/browser/owned"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (page != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("page", page)); - } - - if (perPage != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("per_page", perPage)); - } - - if (groupType != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("group_type", groupType)); - } - - if (search != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("search", search)); - } - - if (namespace != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("namespace", namespace)); - } - - if (orderby != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("orderby", orderby)); - } - - if (permissions != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("permissions", permissions)); - } - - if (tag != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "tag", tag)); - } - - if (excludeTag != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "exclude_tag", excludeTag)); - } - - if (flat != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("flat", flat)); - } - - if (parent != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("parent", parent)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call listOwnedGroupsValidateBeforeCall(Integer page, Integer perPage, String groupType, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, Boolean flat, String parent, final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = listOwnedGroupsCall(page, perPage, groupType, search, namespace, orderby, permissions, tag, excludeTag, flat, parent, _callback); - return localVarCall; - - } - - /** - * - * Returns one page of owned groups. - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param groupType filter by a specific group type (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param flat if true, ignores the nesting of groups and searches all of them (optional) - * @param parent search only the children of the groups with this uuid (optional) - * @return GroupBrowserData - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 the group contents -
502 Bad Gateway -
0 error response -
- */ - public GroupBrowserData listOwnedGroups(Integer page, Integer perPage, String groupType, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, Boolean flat, String parent) throws ApiException { - ApiResponse localVarResp = listOwnedGroupsWithHttpInfo(page, perPage, groupType, search, namespace, orderby, permissions, tag, excludeTag, flat, parent); - return localVarResp.getData(); - } - - /** - * - * Returns one page of owned groups. - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param groupType filter by a specific group type (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param flat if true, ignores the nesting of groups and searches all of them (optional) - * @param parent search only the children of the groups with this uuid (optional) - * @return ApiResponse<GroupBrowserData> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 the group contents -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse listOwnedGroupsWithHttpInfo(Integer page, Integer perPage, String groupType, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, Boolean flat, String parent) throws ApiException { - okhttp3.Call localVarCall = listOwnedGroupsValidateBeforeCall(page, perPage, groupType, search, namespace, orderby, permissions, tag, excludeTag, flat, parent, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Returns one page of owned groups. - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param groupType filter by a specific group type (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param flat if true, ignores the nesting of groups and searches all of them (optional) - * @param parent search only the children of the groups with this uuid (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 the group contents -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listOwnedGroupsAsync(Integer page, Integer perPage, String groupType, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, Boolean flat, String parent, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = listOwnedGroupsValidateBeforeCall(page, perPage, groupType, search, namespace, orderby, permissions, tag, excludeTag, flat, parent, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for listPublicGroups - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param groupType filter by a specific group type (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param flat if true, ignores the nesting of groups and searches all of them (optional) - * @param parent search only the children of the groups with this uuid (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 the group contents -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listPublicGroupsCall(Integer page, Integer perPage, String groupType, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, Boolean flat, String parent, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/groups/browser/public"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (page != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("page", page)); - } - - if (perPage != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("per_page", perPage)); - } - - if (groupType != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("group_type", groupType)); - } - - if (search != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("search", search)); - } - - if (namespace != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("namespace", namespace)); - } - - if (orderby != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("orderby", orderby)); - } - - if (permissions != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("permissions", permissions)); - } - - if (tag != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "tag", tag)); - } - - if (excludeTag != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "exclude_tag", excludeTag)); - } - - if (flat != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("flat", flat)); - } - - if (parent != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("parent", parent)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call listPublicGroupsValidateBeforeCall(Integer page, Integer perPage, String groupType, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, Boolean flat, String parent, final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = listPublicGroupsCall(page, perPage, groupType, search, namespace, orderby, permissions, tag, excludeTag, flat, parent, _callback); - return localVarCall; - - } - - /** - * - * Returns one page of public groups. - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param groupType filter by a specific group type (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param flat if true, ignores the nesting of groups and searches all of them (optional) - * @param parent search only the children of the groups with this uuid (optional) - * @return GroupBrowserData - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 the group contents -
502 Bad Gateway -
0 error response -
- */ - public GroupBrowserData listPublicGroups(Integer page, Integer perPage, String groupType, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, Boolean flat, String parent) throws ApiException { - ApiResponse localVarResp = listPublicGroupsWithHttpInfo(page, perPage, groupType, search, namespace, orderby, permissions, tag, excludeTag, flat, parent); - return localVarResp.getData(); - } - - /** - * - * Returns one page of public groups. - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param groupType filter by a specific group type (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param flat if true, ignores the nesting of groups and searches all of them (optional) - * @param parent search only the children of the groups with this uuid (optional) - * @return ApiResponse<GroupBrowserData> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 the group contents -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse listPublicGroupsWithHttpInfo(Integer page, Integer perPage, String groupType, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, Boolean flat, String parent) throws ApiException { - okhttp3.Call localVarCall = listPublicGroupsValidateBeforeCall(page, perPage, groupType, search, namespace, orderby, permissions, tag, excludeTag, flat, parent, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Returns one page of public groups. - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param groupType filter by a specific group type (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param flat if true, ignores the nesting of groups and searches all of them (optional) - * @param parent search only the children of the groups with this uuid (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 the group contents -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listPublicGroupsAsync(Integer page, Integer perPage, String groupType, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, Boolean flat, String parent, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = listPublicGroupsValidateBeforeCall(page, perPage, groupType, search, namespace, orderby, permissions, tag, excludeTag, flat, parent, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for listSharedGroups - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param groupType filter by a specific group type (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param flat if true, ignores the nesting of groups and searches all of them (optional) - * @param parent search only the children of the groups with this uuid (optional) - * @param sharedTo namespaces to filter results of where there groups were shared to (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 the group contents -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listSharedGroupsCall(Integer page, Integer perPage, String groupType, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, Boolean flat, String parent, List sharedTo, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/groups/browser/shared"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (page != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("page", page)); - } - - if (perPage != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("per_page", perPage)); - } - - if (groupType != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("group_type", groupType)); - } - - if (search != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("search", search)); - } - - if (namespace != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("namespace", namespace)); - } - - if (orderby != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("orderby", orderby)); - } - - if (permissions != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("permissions", permissions)); - } - - if (tag != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "tag", tag)); - } - - if (excludeTag != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "exclude_tag", excludeTag)); - } - - if (flat != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("flat", flat)); - } - - if (parent != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("parent", parent)); - } - - if (sharedTo != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "shared_to", sharedTo)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call listSharedGroupsValidateBeforeCall(Integer page, Integer perPage, String groupType, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, Boolean flat, String parent, List sharedTo, final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = listSharedGroupsCall(page, perPage, groupType, search, namespace, orderby, permissions, tag, excludeTag, flat, parent, sharedTo, _callback); - return localVarCall; - - } - - /** - * - * Returns one page of shared groups. - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param groupType filter by a specific group type (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param flat if true, ignores the nesting of groups and searches all of them (optional) - * @param parent search only the children of the groups with this uuid (optional) - * @param sharedTo namespaces to filter results of where there groups were shared to (optional) - * @return GroupBrowserData - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 the group contents -
502 Bad Gateway -
0 error response -
- */ - public GroupBrowserData listSharedGroups(Integer page, Integer perPage, String groupType, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, Boolean flat, String parent, List sharedTo) throws ApiException { - ApiResponse localVarResp = listSharedGroupsWithHttpInfo(page, perPage, groupType, search, namespace, orderby, permissions, tag, excludeTag, flat, parent, sharedTo); - return localVarResp.getData(); - } - - /** - * - * Returns one page of shared groups. - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param groupType filter by a specific group type (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param flat if true, ignores the nesting of groups and searches all of them (optional) - * @param parent search only the children of the groups with this uuid (optional) - * @param sharedTo namespaces to filter results of where there groups were shared to (optional) - * @return ApiResponse<GroupBrowserData> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 the group contents -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse listSharedGroupsWithHttpInfo(Integer page, Integer perPage, String groupType, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, Boolean flat, String parent, List sharedTo) throws ApiException { - okhttp3.Call localVarCall = listSharedGroupsValidateBeforeCall(page, perPage, groupType, search, namespace, orderby, permissions, tag, excludeTag, flat, parent, sharedTo, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Returns one page of shared groups. - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param groupType filter by a specific group type (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param namespace namespace (optional) - * @param orderby sort by which field valid values include last_accessed, size, name (optional) - * @param permissions permissions valid values include read, read_write, write, admin (optional) - * @param tag tag to search for, more than one can be included (optional) - * @param excludeTag tags to exclude matching array in results, more than one can be included (optional) - * @param flat if true, ignores the nesting of groups and searches all of them (optional) - * @param parent search only the children of the groups with this uuid (optional) - * @param sharedTo namespaces to filter results of where there groups were shared to (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 the group contents -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listSharedGroupsAsync(Integer page, Integer perPage, String groupType, String search, String namespace, String orderby, String permissions, List tag, List excludeTag, Boolean flat, String parent, List sharedTo, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = listSharedGroupsValidateBeforeCall(page, perPage, groupType, search, namespace, orderby, permissions, tag, excludeTag, flat, parent, sharedTo, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for registerGroup - * @param namespace The namespace of the group (required) - * @param array The unique name or id of the group (required) - * @param groupRegister (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 group created successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call registerGroupCall(String namespace, String array, GroupRegister groupRegister, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = groupRegister; - - // create path and map variables - String localVarPath = "/groups/{namespace}/{array}/register" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call registerGroupValidateBeforeCall(String namespace, String array, GroupRegister groupRegister, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling registerGroup(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling registerGroup(Async)"); - } - - - okhttp3.Call localVarCall = registerGroupCall(namespace, array, groupRegister, _callback); - return localVarCall; - - } - - /** - * - * Registers an existing group in the namespace. - * @param namespace The namespace of the group (required) - * @param array The unique name or id of the group (required) - * @param groupRegister (optional) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 group created successfully -
502 Bad Gateway -
0 error response -
- */ - public void registerGroup(String namespace, String array, GroupRegister groupRegister) throws ApiException { - registerGroupWithHttpInfo(namespace, array, groupRegister); - } - - /** - * - * Registers an existing group in the namespace. - * @param namespace The namespace of the group (required) - * @param array The unique name or id of the group (required) - * @param groupRegister (optional) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 group created successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse registerGroupWithHttpInfo(String namespace, String array, GroupRegister groupRegister) throws ApiException { - okhttp3.Call localVarCall = registerGroupValidateBeforeCall(namespace, array, groupRegister, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Registers an existing group in the namespace. - * @param namespace The namespace of the group (required) - * @param array The unique name or id of the group (required) - * @param groupRegister (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 group created successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call registerGroupAsync(String namespace, String array, GroupRegister groupRegister, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = registerGroupValidateBeforeCall(namespace, array, groupRegister, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for shareGroup - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param groupSharingRequest Namespace and list of permissions to share with. Sharing is recursive, it is applied to all reachable subgroups and arrays of the group. An empty list of permissions will remove the namespace; if permissions already exist they will be deleted then new ones added. In the event of a failure, the new policies will be rolled back to prevent partial policies, and it's likely the group will not be shared with the namespace at all. (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Group shared successfully -
404 Group does not exist or user does not have permissions to share group -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call shareGroupCall(String groupNamespace, String groupName, GroupSharingRequest groupSharingRequest, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = groupSharingRequest; - - // create path and map variables - String localVarPath = "/groups/{group_namespace}/{group_name}/share" - .replaceAll("\\{" + "group_namespace" + "\\}", localVarApiClient.escapeString(groupNamespace.toString())) - .replaceAll("\\{" + "group_name" + "\\}", localVarApiClient.escapeString(groupName.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call shareGroupValidateBeforeCall(String groupNamespace, String groupName, GroupSharingRequest groupSharingRequest, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'groupNamespace' is set - if (groupNamespace == null) { - throw new ApiException("Missing the required parameter 'groupNamespace' when calling shareGroup(Async)"); - } - - // verify the required parameter 'groupName' is set - if (groupName == null) { - throw new ApiException("Missing the required parameter 'groupName' when calling shareGroup(Async)"); - } - - // verify the required parameter 'groupSharingRequest' is set - if (groupSharingRequest == null) { - throw new ApiException("Missing the required parameter 'groupSharingRequest' when calling shareGroup(Async)"); - } - - - okhttp3.Call localVarCall = shareGroupCall(groupNamespace, groupName, groupSharingRequest, _callback); - return localVarCall; - - } - - /** - * - * Share a group with a namespace - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param groupSharingRequest Namespace and list of permissions to share with. Sharing is recursive, it is applied to all reachable subgroups and arrays of the group. An empty list of permissions will remove the namespace; if permissions already exist they will be deleted then new ones added. In the event of a failure, the new policies will be rolled back to prevent partial policies, and it's likely the group will not be shared with the namespace at all. (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Group shared successfully -
404 Group does not exist or user does not have permissions to share group -
502 Bad Gateway -
0 error response -
- */ - public void shareGroup(String groupNamespace, String groupName, GroupSharingRequest groupSharingRequest) throws ApiException { - shareGroupWithHttpInfo(groupNamespace, groupName, groupSharingRequest); - } - - /** - * - * Share a group with a namespace - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param groupSharingRequest Namespace and list of permissions to share with. Sharing is recursive, it is applied to all reachable subgroups and arrays of the group. An empty list of permissions will remove the namespace; if permissions already exist they will be deleted then new ones added. In the event of a failure, the new policies will be rolled back to prevent partial policies, and it's likely the group will not be shared with the namespace at all. (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Group shared successfully -
404 Group does not exist or user does not have permissions to share group -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse shareGroupWithHttpInfo(String groupNamespace, String groupName, GroupSharingRequest groupSharingRequest) throws ApiException { - okhttp3.Call localVarCall = shareGroupValidateBeforeCall(groupNamespace, groupName, groupSharingRequest, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Share a group with a namespace - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param groupSharingRequest Namespace and list of permissions to share with. Sharing is recursive, it is applied to all reachable subgroups and arrays of the group. An empty list of permissions will remove the namespace; if permissions already exist they will be deleted then new ones added. In the event of a failure, the new policies will be rolled back to prevent partial policies, and it's likely the group will not be shared with the namespace at all. (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Group shared successfully -
404 Group does not exist or user does not have permissions to share group -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call shareGroupAsync(String groupNamespace, String groupName, GroupSharingRequest groupSharingRequest, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = shareGroupValidateBeforeCall(groupNamespace, groupName, groupSharingRequest, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for updateGroup - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param groupUpdate (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 attributes changed successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateGroupCall(String groupNamespace, String groupName, GroupUpdate groupUpdate, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = groupUpdate; - - // create path and map variables - String localVarPath = "/groups/{group_namespace}/{group_name}" - .replaceAll("\\{" + "group_namespace" + "\\}", localVarApiClient.escapeString(groupNamespace.toString())) - .replaceAll("\\{" + "group_name" + "\\}", localVarApiClient.escapeString(groupName.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call updateGroupValidateBeforeCall(String groupNamespace, String groupName, GroupUpdate groupUpdate, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'groupNamespace' is set - if (groupNamespace == null) { - throw new ApiException("Missing the required parameter 'groupNamespace' when calling updateGroup(Async)"); - } - - // verify the required parameter 'groupName' is set - if (groupName == null) { - throw new ApiException("Missing the required parameter 'groupName' when calling updateGroup(Async)"); - } - - - okhttp3.Call localVarCall = updateGroupCall(groupNamespace, groupName, groupUpdate, _callback); - return localVarCall; - - } - - /** - * - * Changes attributes of the group - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param groupUpdate (optional) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 attributes changed successfully -
502 Bad Gateway -
0 error response -
- */ - public void updateGroup(String groupNamespace, String groupName, GroupUpdate groupUpdate) throws ApiException { - updateGroupWithHttpInfo(groupNamespace, groupName, groupUpdate); - } - - /** - * - * Changes attributes of the group - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param groupUpdate (optional) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 attributes changed successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse updateGroupWithHttpInfo(String groupNamespace, String groupName, GroupUpdate groupUpdate) throws ApiException { - okhttp3.Call localVarCall = updateGroupValidateBeforeCall(groupNamespace, groupName, groupUpdate, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Changes attributes of the group - * @param groupNamespace The namespace of the group (required) - * @param groupName The unique name or id of the group (required) - * @param groupUpdate (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 attributes changed successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateGroupAsync(String groupNamespace, String groupName, GroupUpdate groupUpdate, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = updateGroupValidateBeforeCall(groupNamespace, groupName, groupUpdate, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/api/InvitationApi.java b/src/main/java/io/tiledb/cloud/rest_api/v1/api/InvitationApi.java deleted file mode 100644 index 2169d43..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/api/InvitationApi.java +++ /dev/null @@ -1,1332 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.api; - -import io.tiledb.cloud.rest_api.v1.model.InvitationArrayShareEmail; -import io.tiledb.cloud.rest_api.v1.model.InvitationData; -import io.tiledb.cloud.rest_api.v1.model.InvitationGroupShareEmail; -import io.tiledb.cloud.rest_api.v1.model.InvitationOrganizationJoinEmail; -import io.tiledb.cloud.rest_api.v1.ApiCallback; -import io.tiledb.cloud.rest_api.v1.ApiClient; -import io.tiledb.cloud.rest_api.v1.ApiException; -import io.tiledb.cloud.rest_api.v1.ApiResponse; -import io.tiledb.cloud.rest_api.v1.Configuration; -import io.tiledb.cloud.rest_api.v1.Pair; - -import com.google.gson.reflect.TypeToken; - - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class InvitationApi { - private ApiClient localVarApiClient; - private int localHostIndex; - private String localCustomBaseUrl; - - public InvitationApi() { - this(Configuration.getDefaultApiClient()); - } - - public InvitationApi(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public ApiClient getApiClient() { - return localVarApiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public int getHostIndex() { - return localHostIndex; - } - - public void setHostIndex(int hostIndex) { - this.localHostIndex = hostIndex; - } - - public String getCustomBaseUrl() { - return localCustomBaseUrl; - } - - public void setCustomBaseUrl(String customBaseUrl) { - this.localCustomBaseUrl = customBaseUrl; - } - - /** - * Build call for acceptInvitation - * @param invitation the ID of invitation about to be accepted (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Invitation was accepted successfully -
404 Could not find invitation identifier -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call acceptInvitationCall(String invitation, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/invitations/{invitation}" - .replaceAll("\\{" + "invitation" + "\\}", localVarApiClient.escapeString(invitation.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call acceptInvitationValidateBeforeCall(String invitation, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'invitation' is set - if (invitation == null) { - throw new ApiException("Missing the required parameter 'invitation' when calling acceptInvitation(Async)"); - } - - - okhttp3.Call localVarCall = acceptInvitationCall(invitation, _callback); - return localVarCall; - - } - - /** - * - * Accepts invitation - * @param invitation the ID of invitation about to be accepted (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Invitation was accepted successfully -
404 Could not find invitation identifier -
502 Bad Gateway -
0 error response -
- */ - public void acceptInvitation(String invitation) throws ApiException { - acceptInvitationWithHttpInfo(invitation); - } - - /** - * - * Accepts invitation - * @param invitation the ID of invitation about to be accepted (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Invitation was accepted successfully -
404 Could not find invitation identifier -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse acceptInvitationWithHttpInfo(String invitation) throws ApiException { - okhttp3.Call localVarCall = acceptInvitationValidateBeforeCall(invitation, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Accepts invitation - * @param invitation the ID of invitation about to be accepted (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Invitation was accepted successfully -
404 Could not find invitation identifier -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call acceptInvitationAsync(String invitation, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = acceptInvitationValidateBeforeCall(invitation, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for cancelJoinOrganization - * @param invitation the ID of invitation about to be cancelled (required) - * @param organization name or UUID of organization (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Invitation cancelled successfully -
404 No invitation was found to cancel -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call cancelJoinOrganizationCall(String invitation, String organization, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/invitations/{invitation}/{organization}/join" - .replaceAll("\\{" + "invitation" + "\\}", localVarApiClient.escapeString(invitation.toString())) - .replaceAll("\\{" + "organization" + "\\}", localVarApiClient.escapeString(organization.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call cancelJoinOrganizationValidateBeforeCall(String invitation, String organization, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'invitation' is set - if (invitation == null) { - throw new ApiException("Missing the required parameter 'invitation' when calling cancelJoinOrganization(Async)"); - } - - // verify the required parameter 'organization' is set - if (organization == null) { - throw new ApiException("Missing the required parameter 'organization' when calling cancelJoinOrganization(Async)"); - } - - - okhttp3.Call localVarCall = cancelJoinOrganizationCall(invitation, organization, _callback); - return localVarCall; - - } - - /** - * - * Cancels join organization invitation - * @param invitation the ID of invitation about to be cancelled (required) - * @param organization name or UUID of organization (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Invitation cancelled successfully -
404 No invitation was found to cancel -
502 Bad Gateway -
0 error response -
- */ - public void cancelJoinOrganization(String invitation, String organization) throws ApiException { - cancelJoinOrganizationWithHttpInfo(invitation, organization); - } - - /** - * - * Cancels join organization invitation - * @param invitation the ID of invitation about to be cancelled (required) - * @param organization name or UUID of organization (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Invitation cancelled successfully -
404 No invitation was found to cancel -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse cancelJoinOrganizationWithHttpInfo(String invitation, String organization) throws ApiException { - okhttp3.Call localVarCall = cancelJoinOrganizationValidateBeforeCall(invitation, organization, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Cancels join organization invitation - * @param invitation the ID of invitation about to be cancelled (required) - * @param organization name or UUID of organization (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Invitation cancelled successfully -
404 No invitation was found to cancel -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call cancelJoinOrganizationAsync(String invitation, String organization, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = cancelJoinOrganizationValidateBeforeCall(invitation, organization, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for cancelShareArrayByInvite - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param invitation the ID of invitation about to be cancelled (required) - * @param array name/uri of array that is url-encoded (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Invitation cancelled successfully -
404 No invitation was found to cancel -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call cancelShareArrayByInviteCall(String namespace, String invitation, String array, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/invitations/{invitation}/{namespace}/{array}/share" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "invitation" + "\\}", localVarApiClient.escapeString(invitation.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call cancelShareArrayByInviteValidateBeforeCall(String namespace, String invitation, String array, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling cancelShareArrayByInvite(Async)"); - } - - // verify the required parameter 'invitation' is set - if (invitation == null) { - throw new ApiException("Missing the required parameter 'invitation' when calling cancelShareArrayByInvite(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling cancelShareArrayByInvite(Async)"); - } - - - okhttp3.Call localVarCall = cancelShareArrayByInviteCall(namespace, invitation, array, _callback); - return localVarCall; - - } - - /** - * - * Cancels array sharing invitation - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param invitation the ID of invitation about to be cancelled (required) - * @param array name/uri of array that is url-encoded (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Invitation cancelled successfully -
404 No invitation was found to cancel -
502 Bad Gateway -
0 error response -
- */ - public void cancelShareArrayByInvite(String namespace, String invitation, String array) throws ApiException { - cancelShareArrayByInviteWithHttpInfo(namespace, invitation, array); - } - - /** - * - * Cancels array sharing invitation - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param invitation the ID of invitation about to be cancelled (required) - * @param array name/uri of array that is url-encoded (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Invitation cancelled successfully -
404 No invitation was found to cancel -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse cancelShareArrayByInviteWithHttpInfo(String namespace, String invitation, String array) throws ApiException { - okhttp3.Call localVarCall = cancelShareArrayByInviteValidateBeforeCall(namespace, invitation, array, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Cancels array sharing invitation - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param invitation the ID of invitation about to be cancelled (required) - * @param array name/uri of array that is url-encoded (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Invitation cancelled successfully -
404 No invitation was found to cancel -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call cancelShareArrayByInviteAsync(String namespace, String invitation, String array, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = cancelShareArrayByInviteValidateBeforeCall(namespace, invitation, array, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for cancelShareGroupByInvite - * @param namespace namespace group is in (an organization name or user's username) (required) - * @param invitation the ID of invitation about to be cancelled (required) - * @param groupName name/uuid of group that is url-encoded (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Invitation cancelled successfully -
404 No invitation was found to cancel -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call cancelShareGroupByInviteCall(String namespace, String invitation, String groupName, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/invitations/group/{invitation}/{namespace}/{group_name}/share" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "invitation" + "\\}", localVarApiClient.escapeString(invitation.toString())) - .replaceAll("\\{" + "group_name" + "\\}", localVarApiClient.escapeString(groupName.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call cancelShareGroupByInviteValidateBeforeCall(String namespace, String invitation, String groupName, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling cancelShareGroupByInvite(Async)"); - } - - // verify the required parameter 'invitation' is set - if (invitation == null) { - throw new ApiException("Missing the required parameter 'invitation' when calling cancelShareGroupByInvite(Async)"); - } - - // verify the required parameter 'groupName' is set - if (groupName == null) { - throw new ApiException("Missing the required parameter 'groupName' when calling cancelShareGroupByInvite(Async)"); - } - - - okhttp3.Call localVarCall = cancelShareGroupByInviteCall(namespace, invitation, groupName, _callback); - return localVarCall; - - } - - /** - * - * Cancels group sharing invitation - * @param namespace namespace group is in (an organization name or user's username) (required) - * @param invitation the ID of invitation about to be cancelled (required) - * @param groupName name/uuid of group that is url-encoded (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Invitation cancelled successfully -
404 No invitation was found to cancel -
502 Bad Gateway -
0 error response -
- */ - public void cancelShareGroupByInvite(String namespace, String invitation, String groupName) throws ApiException { - cancelShareGroupByInviteWithHttpInfo(namespace, invitation, groupName); - } - - /** - * - * Cancels group sharing invitation - * @param namespace namespace group is in (an organization name or user's username) (required) - * @param invitation the ID of invitation about to be cancelled (required) - * @param groupName name/uuid of group that is url-encoded (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Invitation cancelled successfully -
404 No invitation was found to cancel -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse cancelShareGroupByInviteWithHttpInfo(String namespace, String invitation, String groupName) throws ApiException { - okhttp3.Call localVarCall = cancelShareGroupByInviteValidateBeforeCall(namespace, invitation, groupName, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Cancels group sharing invitation - * @param namespace namespace group is in (an organization name or user's username) (required) - * @param invitation the ID of invitation about to be cancelled (required) - * @param groupName name/uuid of group that is url-encoded (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Invitation cancelled successfully -
404 No invitation was found to cancel -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call cancelShareGroupByInviteAsync(String namespace, String invitation, String groupName, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = cancelShareGroupByInviteValidateBeforeCall(namespace, invitation, groupName, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for fetchInvitations - * @param organization name or ID of organization to filter (optional) - * @param array name/uri of array that is url-encoded to filter (optional) - * @param group name or ID of group to filter (optional) - * @param start start time for tasks to filter by (optional) - * @param end end time for tasks to filter by (optional) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param type invitation type, \"ARRAY_SHARE\", \"JOIN_ORGANIZATION\" (optional) - * @param status Filter to only return \"PENDING\", \"ACCEPTED\" (optional) - * @param orderby sort by which field valid values include timestamp, array_name, organization_name (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 List of invitations and pagination metadata -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call fetchInvitationsCall(String organization, String array, String group, Integer start, Integer end, Integer page, Integer perPage, String type, String status, String orderby, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/invitations"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (organization != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("organization", organization)); - } - - if (array != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("array", array)); - } - - if (group != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("group", group)); - } - - if (start != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("start", start)); - } - - if (end != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("end", end)); - } - - if (page != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("page", page)); - } - - if (perPage != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("per_page", perPage)); - } - - if (type != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("type", type)); - } - - if (status != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("status", status)); - } - - if (orderby != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("orderby", orderby)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call fetchInvitationsValidateBeforeCall(String organization, String array, String group, Integer start, Integer end, Integer page, Integer perPage, String type, String status, String orderby, final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = fetchInvitationsCall(organization, array, group, start, end, page, perPage, type, status, orderby, _callback); - return localVarCall; - - } - - /** - * - * Fetch a list of invitations - * @param organization name or ID of organization to filter (optional) - * @param array name/uri of array that is url-encoded to filter (optional) - * @param group name or ID of group to filter (optional) - * @param start start time for tasks to filter by (optional) - * @param end end time for tasks to filter by (optional) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param type invitation type, \"ARRAY_SHARE\", \"JOIN_ORGANIZATION\" (optional) - * @param status Filter to only return \"PENDING\", \"ACCEPTED\" (optional) - * @param orderby sort by which field valid values include timestamp, array_name, organization_name (optional) - * @return InvitationData - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 List of invitations and pagination metadata -
502 Bad Gateway -
0 error response -
- */ - public InvitationData fetchInvitations(String organization, String array, String group, Integer start, Integer end, Integer page, Integer perPage, String type, String status, String orderby) throws ApiException { - ApiResponse localVarResp = fetchInvitationsWithHttpInfo(organization, array, group, start, end, page, perPage, type, status, orderby); - return localVarResp.getData(); - } - - /** - * - * Fetch a list of invitations - * @param organization name or ID of organization to filter (optional) - * @param array name/uri of array that is url-encoded to filter (optional) - * @param group name or ID of group to filter (optional) - * @param start start time for tasks to filter by (optional) - * @param end end time for tasks to filter by (optional) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param type invitation type, \"ARRAY_SHARE\", \"JOIN_ORGANIZATION\" (optional) - * @param status Filter to only return \"PENDING\", \"ACCEPTED\" (optional) - * @param orderby sort by which field valid values include timestamp, array_name, organization_name (optional) - * @return ApiResponse<InvitationData> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 List of invitations and pagination metadata -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse fetchInvitationsWithHttpInfo(String organization, String array, String group, Integer start, Integer end, Integer page, Integer perPage, String type, String status, String orderby) throws ApiException { - okhttp3.Call localVarCall = fetchInvitationsValidateBeforeCall(organization, array, group, start, end, page, perPage, type, status, orderby, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch a list of invitations - * @param organization name or ID of organization to filter (optional) - * @param array name/uri of array that is url-encoded to filter (optional) - * @param group name or ID of group to filter (optional) - * @param start start time for tasks to filter by (optional) - * @param end end time for tasks to filter by (optional) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param type invitation type, \"ARRAY_SHARE\", \"JOIN_ORGANIZATION\" (optional) - * @param status Filter to only return \"PENDING\", \"ACCEPTED\" (optional) - * @param orderby sort by which field valid values include timestamp, array_name, organization_name (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 List of invitations and pagination metadata -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call fetchInvitationsAsync(String organization, String array, String group, Integer start, Integer end, Integer page, Integer perPage, String type, String status, String orderby, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = fetchInvitationsValidateBeforeCall(organization, array, group, start, end, page, perPage, type, status, orderby, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for joinOrganization - * @param organization name or UUID of organization (required) - * @param emailInvite list of email recipients (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - - -
Status Code Description Response Headers
204 Email sent successfully to user for email confirmation link -
207 Only a portion of the invitations succeeded, some failed -
500 Could not reach any recipients -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call joinOrganizationCall(String organization, InvitationOrganizationJoinEmail emailInvite, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = emailInvite; - - // create path and map variables - String localVarPath = "/invitations/{organization}/join" - .replaceAll("\\{" + "organization" + "\\}", localVarApiClient.escapeString(organization.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call joinOrganizationValidateBeforeCall(String organization, InvitationOrganizationJoinEmail emailInvite, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'organization' is set - if (organization == null) { - throw new ApiException("Missing the required parameter 'organization' when calling joinOrganization(Async)"); - } - - // verify the required parameter 'emailInvite' is set - if (emailInvite == null) { - throw new ApiException("Missing the required parameter 'emailInvite' when calling joinOrganization(Async)"); - } - - - okhttp3.Call localVarCall = joinOrganizationCall(organization, emailInvite, _callback); - return localVarCall; - - } - - /** - * - * Sends email to multiple recipients with joining information regarding an organization - * @param organization name or UUID of organization (required) - * @param emailInvite list of email recipients (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - - -
Status Code Description Response Headers
204 Email sent successfully to user for email confirmation link -
207 Only a portion of the invitations succeeded, some failed -
500 Could not reach any recipients -
502 Bad Gateway -
0 error response -
- */ - public void joinOrganization(String organization, InvitationOrganizationJoinEmail emailInvite) throws ApiException { - joinOrganizationWithHttpInfo(organization, emailInvite); - } - - /** - * - * Sends email to multiple recipients with joining information regarding an organization - * @param organization name or UUID of organization (required) - * @param emailInvite list of email recipients (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - - -
Status Code Description Response Headers
204 Email sent successfully to user for email confirmation link -
207 Only a portion of the invitations succeeded, some failed -
500 Could not reach any recipients -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse joinOrganizationWithHttpInfo(String organization, InvitationOrganizationJoinEmail emailInvite) throws ApiException { - okhttp3.Call localVarCall = joinOrganizationValidateBeforeCall(organization, emailInvite, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Sends email to multiple recipients with joining information regarding an organization - * @param organization name or UUID of organization (required) - * @param emailInvite list of email recipients (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - - -
Status Code Description Response Headers
204 Email sent successfully to user for email confirmation link -
207 Only a portion of the invitations succeeded, some failed -
500 Could not reach any recipients -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call joinOrganizationAsync(String organization, InvitationOrganizationJoinEmail emailInvite, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = joinOrganizationValidateBeforeCall(organization, emailInvite, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for shareArrayByInvite - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param emailInvite list of email recipients (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - - -
Status Code Description Response Headers
204 Email sent successfully to user for email confirmation link -
207 Only a portion of the invitations succeeded, some failed -
500 Could not reach any recipients -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call shareArrayByInviteCall(String namespace, String array, InvitationArrayShareEmail emailInvite, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = emailInvite; - - // create path and map variables - String localVarPath = "/invitations/{namespace}/{array}/share" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call shareArrayByInviteValidateBeforeCall(String namespace, String array, InvitationArrayShareEmail emailInvite, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling shareArrayByInvite(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling shareArrayByInvite(Async)"); - } - - // verify the required parameter 'emailInvite' is set - if (emailInvite == null) { - throw new ApiException("Missing the required parameter 'emailInvite' when calling shareArrayByInvite(Async)"); - } - - - okhttp3.Call localVarCall = shareArrayByInviteCall(namespace, array, emailInvite, _callback); - return localVarCall; - - } - - /** - * - * Sends email to multiple recipients with sharing information regarding an array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param emailInvite list of email recipients (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - - -
Status Code Description Response Headers
204 Email sent successfully to user for email confirmation link -
207 Only a portion of the invitations succeeded, some failed -
500 Could not reach any recipients -
502 Bad Gateway -
0 error response -
- */ - public void shareArrayByInvite(String namespace, String array, InvitationArrayShareEmail emailInvite) throws ApiException { - shareArrayByInviteWithHttpInfo(namespace, array, emailInvite); - } - - /** - * - * Sends email to multiple recipients with sharing information regarding an array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param emailInvite list of email recipients (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - - -
Status Code Description Response Headers
204 Email sent successfully to user for email confirmation link -
207 Only a portion of the invitations succeeded, some failed -
500 Could not reach any recipients -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse shareArrayByInviteWithHttpInfo(String namespace, String array, InvitationArrayShareEmail emailInvite) throws ApiException { - okhttp3.Call localVarCall = shareArrayByInviteValidateBeforeCall(namespace, array, emailInvite, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Sends email to multiple recipients with sharing information regarding an array - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param emailInvite list of email recipients (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - - -
Status Code Description Response Headers
204 Email sent successfully to user for email confirmation link -
207 Only a portion of the invitations succeeded, some failed -
500 Could not reach any recipients -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call shareArrayByInviteAsync(String namespace, String array, InvitationArrayShareEmail emailInvite, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = shareArrayByInviteValidateBeforeCall(namespace, array, emailInvite, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for shareGroupByInvite - * @param namespace namespace group is in (an organization name or user's username) (required) - * @param group name/uri of group that is url-encoded (required) - * @param emailInvite list of email/namespace recipients (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - - -
Status Code Description Response Headers
204 Email sent successfully to user with an email confirmation link -
207 Only a portion of the invitations succeeded, some failed -
500 Could not reach any recipients -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call shareGroupByInviteCall(String namespace, String group, InvitationGroupShareEmail emailInvite, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = emailInvite; - - // create path and map variables - String localVarPath = "/invitations/group/{namespace}/{group}/share" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "group" + "\\}", localVarApiClient.escapeString(group.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call shareGroupByInviteValidateBeforeCall(String namespace, String group, InvitationGroupShareEmail emailInvite, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling shareGroupByInvite(Async)"); - } - - // verify the required parameter 'group' is set - if (group == null) { - throw new ApiException("Missing the required parameter 'group' when calling shareGroupByInvite(Async)"); - } - - // verify the required parameter 'emailInvite' is set - if (emailInvite == null) { - throw new ApiException("Missing the required parameter 'emailInvite' when calling shareGroupByInvite(Async)"); - } - - - okhttp3.Call localVarCall = shareGroupByInviteCall(namespace, group, emailInvite, _callback); - return localVarCall; - - } - - /** - * - * Sends email to multiple recipients with sharing information regarding a group - * @param namespace namespace group is in (an organization name or user's username) (required) - * @param group name/uri of group that is url-encoded (required) - * @param emailInvite list of email/namespace recipients (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - - -
Status Code Description Response Headers
204 Email sent successfully to user with an email confirmation link -
207 Only a portion of the invitations succeeded, some failed -
500 Could not reach any recipients -
502 Bad Gateway -
0 error response -
- */ - public void shareGroupByInvite(String namespace, String group, InvitationGroupShareEmail emailInvite) throws ApiException { - shareGroupByInviteWithHttpInfo(namespace, group, emailInvite); - } - - /** - * - * Sends email to multiple recipients with sharing information regarding a group - * @param namespace namespace group is in (an organization name or user's username) (required) - * @param group name/uri of group that is url-encoded (required) - * @param emailInvite list of email/namespace recipients (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - - -
Status Code Description Response Headers
204 Email sent successfully to user with an email confirmation link -
207 Only a portion of the invitations succeeded, some failed -
500 Could not reach any recipients -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse shareGroupByInviteWithHttpInfo(String namespace, String group, InvitationGroupShareEmail emailInvite) throws ApiException { - okhttp3.Call localVarCall = shareGroupByInviteValidateBeforeCall(namespace, group, emailInvite, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Sends email to multiple recipients with sharing information regarding a group - * @param namespace namespace group is in (an organization name or user's username) (required) - * @param group name/uri of group that is url-encoded (required) - * @param emailInvite list of email/namespace recipients (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - - -
Status Code Description Response Headers
204 Email sent successfully to user with an email confirmation link -
207 Only a portion of the invitations succeeded, some failed -
500 Could not reach any recipients -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call shareGroupByInviteAsync(String namespace, String group, InvitationGroupShareEmail emailInvite, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = shareGroupByInviteValidateBeforeCall(namespace, group, emailInvite, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/api/NotebookApi.java b/src/main/java/io/tiledb/cloud/rest_api/v1/api/NotebookApi.java deleted file mode 100644 index 3488693..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/api/NotebookApi.java +++ /dev/null @@ -1,851 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.api; - -import io.tiledb.cloud.rest_api.v1.ApiCallback; -import io.tiledb.cloud.rest_api.v1.ApiClient; -import io.tiledb.cloud.rest_api.v1.ApiException; -import io.tiledb.cloud.rest_api.v1.ApiResponse; -import io.tiledb.cloud.rest_api.v1.Configuration; -import io.tiledb.cloud.rest_api.v1.Pair; - -import com.google.gson.reflect.TypeToken; - - -import io.tiledb.cloud.rest_api.v1.model.ArrayInfoUpdate; - -import java.io.File; -import io.tiledb.cloud.rest_api.v1.model.FileUploaded; -import io.tiledb.cloud.rest_api.v1.model.NotebookCopied; -import io.tiledb.cloud.rest_api.v1.model.NotebookCopy; -import io.tiledb.cloud.rest_api.v1.model.NotebookStatus; - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class NotebookApi { - private ApiClient localVarApiClient; - private int localHostIndex; - private String localCustomBaseUrl; - - public NotebookApi() { - this(Configuration.getDefaultApiClient()); - } - - public NotebookApi(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public ApiClient getApiClient() { - return localVarApiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public int getHostIndex() { - return localHostIndex; - } - - public void setHostIndex(int hostIndex) { - this.localHostIndex = hostIndex; - } - - public String getCustomBaseUrl() { - return localCustomBaseUrl; - } - - public void setCustomBaseUrl(String customBaseUrl) { - this.localCustomBaseUrl = customBaseUrl; - } - - /** - * Build call for getNotebookServerStatus - * @param namespace namespace notebook is in (an organization name or user's username) (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - - - -
Status Code Description Response Headers
200 status of running notebook -
202 Notebook server is pending -
402 Payment required -
404 Notebook is not running -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getNotebookServerStatusCall(String namespace, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/notebooks/server/{namespace}/status" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getNotebookServerStatusValidateBeforeCall(String namespace, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getNotebookServerStatus(Async)"); - } - - - okhttp3.Call localVarCall = getNotebookServerStatusCall(namespace, _callback); - return localVarCall; - - } - - /** - * - * Get status of the notebook server - * @param namespace namespace notebook is in (an organization name or user's username) (required) - * @return NotebookStatus - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - - - -
Status Code Description Response Headers
200 status of running notebook -
202 Notebook server is pending -
402 Payment required -
404 Notebook is not running -
502 Bad Gateway -
0 error response -
- */ - public NotebookStatus getNotebookServerStatus(String namespace) throws ApiException { - ApiResponse localVarResp = getNotebookServerStatusWithHttpInfo(namespace); - return localVarResp.getData(); - } - - /** - * - * Get status of the notebook server - * @param namespace namespace notebook is in (an organization name or user's username) (required) - * @return ApiResponse<NotebookStatus> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - - - -
Status Code Description Response Headers
200 status of running notebook -
202 Notebook server is pending -
402 Payment required -
404 Notebook is not running -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getNotebookServerStatusWithHttpInfo(String namespace) throws ApiException { - okhttp3.Call localVarCall = getNotebookServerStatusValidateBeforeCall(namespace, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Get status of the notebook server - * @param namespace namespace notebook is in (an organization name or user's username) (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - - - -
Status Code Description Response Headers
200 status of running notebook -
202 Notebook server is pending -
402 Payment required -
404 Notebook is not running -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getNotebookServerStatusAsync(String namespace, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getNotebookServerStatusValidateBeforeCall(namespace, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for handleCopyNotebook - * @param namespace The namespace of the notebook (required) - * @param array The name of the notebook (required) - * @param notebookCopy Input/Output information to create a new TileDB file (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @param endTimestamp Milliseconds since Unix epoch, copy will use open_at functionality to copy notebook created at the specific timestamp (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
201 Notebook copied -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call handleCopyNotebookCall(String namespace, String array, NotebookCopy notebookCopy, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, Integer endTimestamp, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = notebookCopy; - - // create path and map variables - String localVarPath = "/notebooks/{namespace}/{array}/copy" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (endTimestamp != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("end_timestamp", endTimestamp)); - } - - if (X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME != null) { - localVarHeaderParams.put("X-TILEDB-CLOUD-ACCESS-CREDENTIALS-NAME", localVarApiClient.parameterToString(X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call handleCopyNotebookValidateBeforeCall(String namespace, String array, NotebookCopy notebookCopy, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, Integer endTimestamp, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling handleCopyNotebook(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling handleCopyNotebook(Async)"); - } - - // verify the required parameter 'notebookCopy' is set - if (notebookCopy == null) { - throw new ApiException("Missing the required parameter 'notebookCopy' when calling handleCopyNotebook(Async)"); - } - - - okhttp3.Call localVarCall = handleCopyNotebookCall(namespace, array, notebookCopy, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, endTimestamp, _callback); - return localVarCall; - - } - - /** - * - * Copy a tiledb notebook at the specified location - * @param namespace The namespace of the notebook (required) - * @param array The name of the notebook (required) - * @param notebookCopy Input/Output information to create a new TileDB file (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @param endTimestamp Milliseconds since Unix epoch, copy will use open_at functionality to copy notebook created at the specific timestamp (optional) - * @return NotebookCopied - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
201 Notebook copied -
502 Bad Gateway -
0 error response -
- */ - public NotebookCopied handleCopyNotebook(String namespace, String array, NotebookCopy notebookCopy, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, Integer endTimestamp) throws ApiException { - ApiResponse localVarResp = handleCopyNotebookWithHttpInfo(namespace, array, notebookCopy, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, endTimestamp); - return localVarResp.getData(); - } - - /** - * - * Copy a tiledb notebook at the specified location - * @param namespace The namespace of the notebook (required) - * @param array The name of the notebook (required) - * @param notebookCopy Input/Output information to create a new TileDB file (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @param endTimestamp Milliseconds since Unix epoch, copy will use open_at functionality to copy notebook created at the specific timestamp (optional) - * @return ApiResponse<NotebookCopied> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
201 Notebook copied -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse handleCopyNotebookWithHttpInfo(String namespace, String array, NotebookCopy notebookCopy, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, Integer endTimestamp) throws ApiException { - okhttp3.Call localVarCall = handleCopyNotebookValidateBeforeCall(namespace, array, notebookCopy, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, endTimestamp, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Copy a tiledb notebook at the specified location - * @param namespace The namespace of the notebook (required) - * @param array The name of the notebook (required) - * @param notebookCopy Input/Output information to create a new TileDB file (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @param endTimestamp Milliseconds since Unix epoch, copy will use open_at functionality to copy notebook created at the specific timestamp (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
201 Notebook copied -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call handleCopyNotebookAsync(String namespace, String array, NotebookCopy notebookCopy, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, Integer endTimestamp, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = handleCopyNotebookValidateBeforeCall(namespace, array, notebookCopy, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, endTimestamp, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for handleUploadNotebook - * @param namespace The namespace of the notebook (required) - * @param inputFile the notebook to upload (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @param outputUri output location of the TileDB File (optional) - * @param name name to set for registered file (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
201 File uploaded -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call handleUploadNotebookCall(String namespace, File inputFile, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, String outputUri, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/notebooks/{namespace}/upload" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (inputFile != null) { - localVarFormParams.put("input_file", inputFile); - } - - if (outputUri != null) { - localVarFormParams.put("output_uri", outputUri); - } - - if (name != null) { - localVarFormParams.put("name", name); - } - - if (X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME != null) { - localVarHeaderParams.put("X-TILEDB-CLOUD-ACCESS-CREDENTIALS-NAME", localVarApiClient.parameterToString(X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "multipart/form-data" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call handleUploadNotebookValidateBeforeCall(String namespace, File inputFile, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, String outputUri, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling handleUploadNotebook(Async)"); - } - - // verify the required parameter 'inputFile' is set - if (inputFile == null) { - throw new ApiException("Missing the required parameter 'inputFile' when calling handleUploadNotebook(Async)"); - } - - - okhttp3.Call localVarCall = handleUploadNotebookCall(namespace, inputFile, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, outputUri, name, _callback); - return localVarCall; - - } - - /** - * - * Upload a notebook at the specified location - * @param namespace The namespace of the notebook (required) - * @param inputFile the notebook to upload (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @param outputUri output location of the TileDB File (optional) - * @param name name to set for registered file (optional) - * @return FileUploaded - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
201 File uploaded -
502 Bad Gateway -
0 error response -
- */ - public FileUploaded handleUploadNotebook(String namespace, File inputFile, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, String outputUri, String name) throws ApiException { - ApiResponse localVarResp = handleUploadNotebookWithHttpInfo(namespace, inputFile, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, outputUri, name); - return localVarResp.getData(); - } - - /** - * - * Upload a notebook at the specified location - * @param namespace The namespace of the notebook (required) - * @param inputFile the notebook to upload (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @param outputUri output location of the TileDB File (optional) - * @param name name to set for registered file (optional) - * @return ApiResponse<FileUploaded> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
201 File uploaded -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse handleUploadNotebookWithHttpInfo(String namespace, File inputFile, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, String outputUri, String name) throws ApiException { - okhttp3.Call localVarCall = handleUploadNotebookValidateBeforeCall(namespace, inputFile, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, outputUri, name, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Upload a notebook at the specified location - * @param namespace The namespace of the notebook (required) - * @param inputFile the notebook to upload (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @param outputUri output location of the TileDB File (optional) - * @param name name to set for registered file (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
201 File uploaded -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call handleUploadNotebookAsync(String namespace, File inputFile, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, String outputUri, String name, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = handleUploadNotebookValidateBeforeCall(namespace, inputFile, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, outputUri, name, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for shutdownNotebookServer - * @param namespace namespace notebook is in (an organization name or user's username) (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Notebook shutdown successfully -
404 Notebook is not running -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call shutdownNotebookServerCall(String namespace, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/notebooks/server/{namespace}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call shutdownNotebookServerValidateBeforeCall(String namespace, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling shutdownNotebookServer(Async)"); - } - - - okhttp3.Call localVarCall = shutdownNotebookServerCall(namespace, _callback); - return localVarCall; - - } - - /** - * - * Shutdown a notebook server - * @param namespace namespace notebook is in (an organization name or user's username) (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Notebook shutdown successfully -
404 Notebook is not running -
502 Bad Gateway -
0 error response -
- */ - public void shutdownNotebookServer(String namespace) throws ApiException { - shutdownNotebookServerWithHttpInfo(namespace); - } - - /** - * - * Shutdown a notebook server - * @param namespace namespace notebook is in (an organization name or user's username) (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Notebook shutdown successfully -
404 Notebook is not running -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse shutdownNotebookServerWithHttpInfo(String namespace) throws ApiException { - okhttp3.Call localVarCall = shutdownNotebookServerValidateBeforeCall(namespace, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Shutdown a notebook server - * @param namespace namespace notebook is in (an organization name or user's username) (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 Notebook shutdown successfully -
404 Notebook is not running -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call shutdownNotebookServerAsync(String namespace, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = shutdownNotebookServerValidateBeforeCall(namespace, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for updateNotebookName - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of notebook (array) that is url-encoded (required) - * @param notebookMetadata notebook (array) metadata to update (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 notebook name updated successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateNotebookNameCall(String namespace, String array, ArrayInfoUpdate notebookMetadata, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = notebookMetadata; - - // create path and map variables - String localVarPath = "/notebooks/{namespace}/{array}/rename" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call updateNotebookNameValidateBeforeCall(String namespace, String array, ArrayInfoUpdate notebookMetadata, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling updateNotebookName(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling updateNotebookName(Async)"); - } - - // verify the required parameter 'notebookMetadata' is set - if (notebookMetadata == null) { - throw new ApiException("Missing the required parameter 'notebookMetadata' when calling updateNotebookName(Async)"); - } - - - okhttp3.Call localVarCall = updateNotebookNameCall(namespace, array, notebookMetadata, _callback); - return localVarCall; - - } - - /** - * - * update name on a notebok, moving related S3 object to new location - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of notebook (array) that is url-encoded (required) - * @param notebookMetadata notebook (array) metadata to update (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 notebook name updated successfully -
502 Bad Gateway -
0 error response -
- */ - public void updateNotebookName(String namespace, String array, ArrayInfoUpdate notebookMetadata) throws ApiException { - updateNotebookNameWithHttpInfo(namespace, array, notebookMetadata); - } - - /** - * - * update name on a notebok, moving related S3 object to new location - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of notebook (array) that is url-encoded (required) - * @param notebookMetadata notebook (array) metadata to update (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 notebook name updated successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse updateNotebookNameWithHttpInfo(String namespace, String array, ArrayInfoUpdate notebookMetadata) throws ApiException { - okhttp3.Call localVarCall = updateNotebookNameValidateBeforeCall(namespace, array, notebookMetadata, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * update name on a notebok, moving related S3 object to new location - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of notebook (array) that is url-encoded (required) - * @param notebookMetadata notebook (array) metadata to update (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 notebook name updated successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateNotebookNameAsync(String namespace, String array, ArrayInfoUpdate notebookMetadata, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = updateNotebookNameValidateBeforeCall(namespace, array, notebookMetadata, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/api/NotebooksApi.java b/src/main/java/io/tiledb/cloud/rest_api/v1/api/NotebooksApi.java deleted file mode 100644 index 50fd737..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/api/NotebooksApi.java +++ /dev/null @@ -1,380 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.api; - -import io.tiledb.cloud.rest_api.v1.model.ArrayEndTimestampData; -import io.tiledb.cloud.rest_api.v1.ApiCallback; -import io.tiledb.cloud.rest_api.v1.ApiClient; -import io.tiledb.cloud.rest_api.v1.ApiException; -import io.tiledb.cloud.rest_api.v1.ApiResponse; -import io.tiledb.cloud.rest_api.v1.Configuration; -import io.tiledb.cloud.rest_api.v1.Pair; - -import com.google.gson.reflect.TypeToken; - - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class NotebooksApi { - private ApiClient localVarApiClient; - private int localHostIndex; - private String localCustomBaseUrl; - - public NotebooksApi() { - this(Configuration.getDefaultApiClient()); - } - - public NotebooksApi(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public ApiClient getApiClient() { - return localVarApiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public int getHostIndex() { - return localHostIndex; - } - - public void setHostIndex(int hostIndex) { - this.localHostIndex = hostIndex; - } - - public String getCustomBaseUrl() { - return localCustomBaseUrl; - } - - public void setCustomBaseUrl(String customBaseUrl) { - this.localCustomBaseUrl = customBaseUrl; - } - - /** - * Build call for notebooksNamespaceArrayEndTimestampsGet - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 list of timestamps in milliseconds, paginated -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call notebooksNamespaceArrayEndTimestampsGetCall(String namespace, String array, Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/notebooks/{namespace}/{array}/end_timestamps" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (page != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("page", page)); - } - - if (perPage != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("per_page", perPage)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call notebooksNamespaceArrayEndTimestampsGetValidateBeforeCall(String namespace, String array, Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling notebooksNamespaceArrayEndTimestampsGet(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling notebooksNamespaceArrayEndTimestampsGet(Async)"); - } - - - okhttp3.Call localVarCall = notebooksNamespaceArrayEndTimestampsGetCall(namespace, array, page, perPage, _callback); - return localVarCall; - - } - - /** - * - * retrieve a list of timestamps from the array fragment info listing in milliseconds, paginated - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @return ArrayEndTimestampData - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 list of timestamps in milliseconds, paginated -
502 Bad Gateway -
0 error response -
- */ - public ArrayEndTimestampData notebooksNamespaceArrayEndTimestampsGet(String namespace, String array, Integer page, Integer perPage) throws ApiException { - ApiResponse localVarResp = notebooksNamespaceArrayEndTimestampsGetWithHttpInfo(namespace, array, page, perPage); - return localVarResp.getData(); - } - - /** - * - * retrieve a list of timestamps from the array fragment info listing in milliseconds, paginated - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @return ApiResponse<ArrayEndTimestampData> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 list of timestamps in milliseconds, paginated -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse notebooksNamespaceArrayEndTimestampsGetWithHttpInfo(String namespace, String array, Integer page, Integer perPage) throws ApiException { - okhttp3.Call localVarCall = notebooksNamespaceArrayEndTimestampsGetValidateBeforeCall(namespace, array, page, perPage, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * retrieve a list of timestamps from the array fragment info listing in milliseconds, paginated - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 list of timestamps in milliseconds, paginated -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call notebooksNamespaceArrayEndTimestampsGetAsync(String namespace, String array, Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = notebooksNamespaceArrayEndTimestampsGetValidateBeforeCall(namespace, array, page, perPage, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for notebooksNamespaceArrayPrunePost - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param keepVersions The number of most recents fragment to preserve (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 notebook pruned -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call notebooksNamespaceArrayPrunePostCall(String namespace, String array, Integer keepVersions, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/notebooks/{namespace}/{array}/prune" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (keepVersions != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("keep_versions", keepVersions)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call notebooksNamespaceArrayPrunePostValidateBeforeCall(String namespace, String array, Integer keepVersions, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling notebooksNamespaceArrayPrunePost(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling notebooksNamespaceArrayPrunePost(Async)"); - } - - - okhttp3.Call localVarCall = notebooksNamespaceArrayPrunePostCall(namespace, array, keepVersions, _callback); - return localVarCall; - - } - - /** - * - * prune fragments of the notebook - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param keepVersions The number of most recents fragment to preserve (optional) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 notebook pruned -
502 Bad Gateway -
0 error response -
- */ - public void notebooksNamespaceArrayPrunePost(String namespace, String array, Integer keepVersions) throws ApiException { - notebooksNamespaceArrayPrunePostWithHttpInfo(namespace, array, keepVersions); - } - - /** - * - * prune fragments of the notebook - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param keepVersions The number of most recents fragment to preserve (optional) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 notebook pruned -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse notebooksNamespaceArrayPrunePostWithHttpInfo(String namespace, String array, Integer keepVersions) throws ApiException { - okhttp3.Call localVarCall = notebooksNamespaceArrayPrunePostValidateBeforeCall(namespace, array, keepVersions, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * prune fragments of the notebook - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param keepVersions The number of most recents fragment to preserve (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 notebook pruned -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call notebooksNamespaceArrayPrunePostAsync(String namespace, String array, Integer keepVersions, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = notebooksNamespaceArrayPrunePostValidateBeforeCall(namespace, array, keepVersions, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/api/OrganizationApi.java b/src/main/java/io/tiledb/cloud/rest_api/v1/api/OrganizationApi.java deleted file mode 100644 index 3e9ed77..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/api/OrganizationApi.java +++ /dev/null @@ -1,2880 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.api; - -import io.tiledb.cloud.rest_api.v1.ApiCallback; -import io.tiledb.cloud.rest_api.v1.ApiClient; -import io.tiledb.cloud.rest_api.v1.ApiException; -import io.tiledb.cloud.rest_api.v1.ApiResponse; -import io.tiledb.cloud.rest_api.v1.Configuration; -import io.tiledb.cloud.rest_api.v1.Pair; - -import com.google.gson.reflect.TypeToken; - - -import io.tiledb.cloud.rest_api.v1.model.AWSAccessCredentials; -import io.tiledb.cloud.rest_api.v1.model.DomainCheckResult; -import io.tiledb.cloud.rest_api.v1.model.Organization; -import io.tiledb.cloud.rest_api.v1.model.OrganizationUser; -import io.tiledb.cloud.rest_api.v1.model.SSODomainConfig; -import io.tiledb.cloud.rest_api.v1.model.SSODomainConfigResponse; - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class OrganizationApi { - private ApiClient localVarApiClient; - private int localHostIndex; - private String localCustomBaseUrl; - - public OrganizationApi() { - this(Configuration.getDefaultApiClient()); - } - - public OrganizationApi(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public ApiClient getApiClient() { - return localVarApiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public int getHostIndex() { - return localHostIndex; - } - - public void setHostIndex(int hostIndex) { - this.localHostIndex = hostIndex; - } - - public String getCustomBaseUrl() { - return localCustomBaseUrl; - } - - public void setCustomBaseUrl(String customBaseUrl) { - this.localCustomBaseUrl = customBaseUrl; - } - - /** - * Build call for addAWSAccessCredentials - * @param namespace namespace (required) - * @param awsAccessCredentials aws access credentials to store for a namespace (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS keys added successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call addAWSAccessCredentialsCall(String namespace, AWSAccessCredentials awsAccessCredentials, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = awsAccessCredentials; - - // create path and map variables - String localVarPath = "/credentials/{namespace}/aws" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call addAWSAccessCredentialsValidateBeforeCall(String namespace, AWSAccessCredentials awsAccessCredentials, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling addAWSAccessCredentials(Async)"); - } - - // verify the required parameter 'awsAccessCredentials' is set - if (awsAccessCredentials == null) { - throw new ApiException("Missing the required parameter 'awsAccessCredentials' when calling addAWSAccessCredentials(Async)"); - } - - - okhttp3.Call localVarCall = addAWSAccessCredentialsCall(namespace, awsAccessCredentials, _callback); - return localVarCall; - - } - - /** - * - * Add aws keys - * @param namespace namespace (required) - * @param awsAccessCredentials aws access credentials to store for a namespace (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS keys added successfully -
502 Bad Gateway -
0 error response -
- */ - public void addAWSAccessCredentials(String namespace, AWSAccessCredentials awsAccessCredentials) throws ApiException { - addAWSAccessCredentialsWithHttpInfo(namespace, awsAccessCredentials); - } - - /** - * - * Add aws keys - * @param namespace namespace (required) - * @param awsAccessCredentials aws access credentials to store for a namespace (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS keys added successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse addAWSAccessCredentialsWithHttpInfo(String namespace, AWSAccessCredentials awsAccessCredentials) throws ApiException { - okhttp3.Call localVarCall = addAWSAccessCredentialsValidateBeforeCall(namespace, awsAccessCredentials, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Add aws keys - * @param namespace namespace (required) - * @param awsAccessCredentials aws access credentials to store for a namespace (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS keys added successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call addAWSAccessCredentialsAsync(String namespace, AWSAccessCredentials awsAccessCredentials, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = addAWSAccessCredentialsValidateBeforeCall(namespace, awsAccessCredentials, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for addUserToOrganization - * @param organization organization name (required) - * @param user user to add (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user added to organization successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call addUserToOrganizationCall(String organization, OrganizationUser user, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = user; - - // create path and map variables - String localVarPath = "/organizations/{organization}/user" - .replaceAll("\\{" + "organization" + "\\}", localVarApiClient.escapeString(organization.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call addUserToOrganizationValidateBeforeCall(String organization, OrganizationUser user, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'organization' is set - if (organization == null) { - throw new ApiException("Missing the required parameter 'organization' when calling addUserToOrganization(Async)"); - } - - // verify the required parameter 'user' is set - if (user == null) { - throw new ApiException("Missing the required parameter 'user' when calling addUserToOrganization(Async)"); - } - - - okhttp3.Call localVarCall = addUserToOrganizationCall(organization, user, _callback); - return localVarCall; - - } - - /** - * - * add a user to an organization - * @param organization organization name (required) - * @param user user to add (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user added to organization successfully -
502 Bad Gateway -
0 error response -
- */ - public void addUserToOrganization(String organization, OrganizationUser user) throws ApiException { - addUserToOrganizationWithHttpInfo(organization, user); - } - - /** - * - * add a user to an organization - * @param organization organization name (required) - * @param user user to add (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user added to organization successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse addUserToOrganizationWithHttpInfo(String organization, OrganizationUser user) throws ApiException { - okhttp3.Call localVarCall = addUserToOrganizationValidateBeforeCall(organization, user, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * add a user to an organization - * @param organization organization name (required) - * @param user user to add (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user added to organization successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call addUserToOrganizationAsync(String organization, OrganizationUser user, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = addUserToOrganizationValidateBeforeCall(organization, user, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for checkAWSAccessCredentials - * @param namespace namespace (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 AWS keys are set -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call checkAWSAccessCredentialsCall(String namespace, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/credentials/{namespace}/aws" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call checkAWSAccessCredentialsValidateBeforeCall(String namespace, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling checkAWSAccessCredentials(Async)"); - } - - - okhttp3.Call localVarCall = checkAWSAccessCredentialsCall(namespace, _callback); - return localVarCall; - - } - - /** - * - * Check if aws keys are set - * @param namespace namespace (required) - * @return List<AWSAccessCredentials> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 AWS keys are set -
502 Bad Gateway -
0 error response -
- */ - public List checkAWSAccessCredentials(String namespace) throws ApiException { - ApiResponse> localVarResp = checkAWSAccessCredentialsWithHttpInfo(namespace); - return localVarResp.getData(); - } - - /** - * - * Check if aws keys are set - * @param namespace namespace (required) - * @return ApiResponse<List<AWSAccessCredentials>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 AWS keys are set -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse> checkAWSAccessCredentialsWithHttpInfo(String namespace) throws ApiException { - okhttp3.Call localVarCall = checkAWSAccessCredentialsValidateBeforeCall(namespace, null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Check if aws keys are set - * @param namespace namespace (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 AWS keys are set -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call checkAWSAccessCredentialsAsync(String namespace, final ApiCallback> _callback) throws ApiException { - - okhttp3.Call localVarCall = checkAWSAccessCredentialsValidateBeforeCall(namespace, _callback); - Type localVarReturnType = new TypeToken>(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for checkAWSAccessCredentialsByName - * @param namespace namespace (required) - * @param name name (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 AWS keys are set -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call checkAWSAccessCredentialsByNameCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/credentials/{namespace}/aws/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call checkAWSAccessCredentialsByNameValidateBeforeCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling checkAWSAccessCredentialsByName(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling checkAWSAccessCredentialsByName(Async)"); - } - - - okhttp3.Call localVarCall = checkAWSAccessCredentialsByNameCall(namespace, name, _callback); - return localVarCall; - - } - - /** - * - * Check if aws keys are set by name - * @param namespace namespace (required) - * @param name name (required) - * @return AWSAccessCredentials - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 AWS keys are set -
502 Bad Gateway -
0 error response -
- */ - public AWSAccessCredentials checkAWSAccessCredentialsByName(String namespace, String name) throws ApiException { - ApiResponse localVarResp = checkAWSAccessCredentialsByNameWithHttpInfo(namespace, name); - return localVarResp.getData(); - } - - /** - * - * Check if aws keys are set by name - * @param namespace namespace (required) - * @param name name (required) - * @return ApiResponse<AWSAccessCredentials> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 AWS keys are set -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse checkAWSAccessCredentialsByNameWithHttpInfo(String namespace, String name) throws ApiException { - okhttp3.Call localVarCall = checkAWSAccessCredentialsByNameValidateBeforeCall(namespace, name, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Check if aws keys are set by name - * @param namespace namespace (required) - * @param name name (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 AWS keys are set -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call checkAWSAccessCredentialsByNameAsync(String namespace, String name, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = checkAWSAccessCredentialsByNameValidateBeforeCall(namespace, name, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for checkSSODomain - * @param organization organization name (required) - * @param uuid configuration ID (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - -
Status Code Description Response Headers
200 The check executed. Detailed results are available in the response. -
0 error response -
- */ - public okhttp3.Call checkSSODomainCall(String organization, String uuid, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/organizations/{organization}/sso_domains/{uuid}/run_check" - .replaceAll("\\{" + "organization" + "\\}", localVarApiClient.escapeString(organization.toString())) - .replaceAll("\\{" + "uuid" + "\\}", localVarApiClient.escapeString(uuid.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call checkSSODomainValidateBeforeCall(String organization, String uuid, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'organization' is set - if (organization == null) { - throw new ApiException("Missing the required parameter 'organization' when calling checkSSODomain(Async)"); - } - - // verify the required parameter 'uuid' is set - if (uuid == null) { - throw new ApiException("Missing the required parameter 'uuid' when calling checkSSODomain(Async)"); - } - - - okhttp3.Call localVarCall = checkSSODomainCall(organization, uuid, _callback); - return localVarCall; - - } - - /** - * - * Immediately verify ownership of the specified SSO domain ownership claim. - * @param organization organization name (required) - * @param uuid configuration ID (required) - * @return DomainCheckResult - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 The check executed. Detailed results are available in the response. -
0 error response -
- */ - public DomainCheckResult checkSSODomain(String organization, String uuid) throws ApiException { - ApiResponse localVarResp = checkSSODomainWithHttpInfo(organization, uuid); - return localVarResp.getData(); - } - - /** - * - * Immediately verify ownership of the specified SSO domain ownership claim. - * @param organization organization name (required) - * @param uuid configuration ID (required) - * @return ApiResponse<DomainCheckResult> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 The check executed. Detailed results are available in the response. -
0 error response -
- */ - public ApiResponse checkSSODomainWithHttpInfo(String organization, String uuid) throws ApiException { - okhttp3.Call localVarCall = checkSSODomainValidateBeforeCall(organization, uuid, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Immediately verify ownership of the specified SSO domain ownership claim. - * @param organization organization name (required) - * @param uuid configuration ID (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - -
Status Code Description Response Headers
200 The check executed. Detailed results are available in the response. -
0 error response -
- */ - public okhttp3.Call checkSSODomainAsync(String organization, String uuid, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = checkSSODomainValidateBeforeCall(organization, uuid, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for createOrganization - * @param organization organization to create (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 organization created successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call createOrganizationCall(Organization organization, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = organization; - - // create path and map variables - String localVarPath = "/organization"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call createOrganizationValidateBeforeCall(Organization organization, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'organization' is set - if (organization == null) { - throw new ApiException("Missing the required parameter 'organization' when calling createOrganization(Async)"); - } - - - okhttp3.Call localVarCall = createOrganizationCall(organization, _callback); - return localVarCall; - - } - - /** - * - * create a organization, the user creating will be listed as owner - * @param organization organization to create (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 organization created successfully -
502 Bad Gateway -
0 error response -
- */ - public void createOrganization(Organization organization) throws ApiException { - createOrganizationWithHttpInfo(organization); - } - - /** - * - * create a organization, the user creating will be listed as owner - * @param organization organization to create (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 organization created successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse createOrganizationWithHttpInfo(Organization organization) throws ApiException { - okhttp3.Call localVarCall = createOrganizationValidateBeforeCall(organization, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * create a organization, the user creating will be listed as owner - * @param organization organization to create (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 organization created successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call createOrganizationAsync(Organization organization, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = createOrganizationValidateBeforeCall(organization, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for createSSODomain - * @param organization organization name (required) - * @param config The SSO connection to create. (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - -
Status Code Description Response Headers
200 Claim created successfully. -
0 error response -
- */ - public okhttp3.Call createSSODomainCall(String organization, SSODomainConfig config, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = config; - - // create path and map variables - String localVarPath = "/organizations/{organization}/sso_domain" - .replaceAll("\\{" + "organization" + "\\}", localVarApiClient.escapeString(organization.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call createSSODomainValidateBeforeCall(String organization, SSODomainConfig config, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'organization' is set - if (organization == null) { - throw new ApiException("Missing the required parameter 'organization' when calling createSSODomain(Async)"); - } - - // verify the required parameter 'config' is set - if (config == null) { - throw new ApiException("Missing the required parameter 'config' when calling createSSODomain(Async)"); - } - - - okhttp3.Call localVarCall = createSSODomainCall(organization, config, _callback); - return localVarCall; - - } - - /** - * - * Create a new SSO connection that connects this organization to this domain. - * @param organization organization name (required) - * @param config The SSO connection to create. (required) - * @return SSODomainConfig - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 Claim created successfully. -
0 error response -
- */ - public SSODomainConfig createSSODomain(String organization, SSODomainConfig config) throws ApiException { - ApiResponse localVarResp = createSSODomainWithHttpInfo(organization, config); - return localVarResp.getData(); - } - - /** - * - * Create a new SSO connection that connects this organization to this domain. - * @param organization organization name (required) - * @param config The SSO connection to create. (required) - * @return ApiResponse<SSODomainConfig> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 Claim created successfully. -
0 error response -
- */ - public ApiResponse createSSODomainWithHttpInfo(String organization, SSODomainConfig config) throws ApiException { - okhttp3.Call localVarCall = createSSODomainValidateBeforeCall(organization, config, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Create a new SSO connection that connects this organization to this domain. - * @param organization organization name (required) - * @param config The SSO connection to create. (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - -
Status Code Description Response Headers
200 Claim created successfully. -
0 error response -
- */ - public okhttp3.Call createSSODomainAsync(String organization, SSODomainConfig config, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = createSSODomainValidateBeforeCall(organization, config, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for deleteAWSAccessCredentials - * @param namespace namespace (required) - * @param name name (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS credentials deleted -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteAWSAccessCredentialsCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/credentials/{namespace}/aws/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call deleteAWSAccessCredentialsValidateBeforeCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling deleteAWSAccessCredentials(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling deleteAWSAccessCredentials(Async)"); - } - - - okhttp3.Call localVarCall = deleteAWSAccessCredentialsCall(namespace, name, _callback); - return localVarCall; - - } - - /** - * - * delete a AWS Access credentials in a namespace. This will likely cause arrays to become unreachable - * @param namespace namespace (required) - * @param name name (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS credentials deleted -
502 Bad Gateway -
0 error response -
- */ - public void deleteAWSAccessCredentials(String namespace, String name) throws ApiException { - deleteAWSAccessCredentialsWithHttpInfo(namespace, name); - } - - /** - * - * delete a AWS Access credentials in a namespace. This will likely cause arrays to become unreachable - * @param namespace namespace (required) - * @param name name (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS credentials deleted -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse deleteAWSAccessCredentialsWithHttpInfo(String namespace, String name) throws ApiException { - okhttp3.Call localVarCall = deleteAWSAccessCredentialsValidateBeforeCall(namespace, name, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * delete a AWS Access credentials in a namespace. This will likely cause arrays to become unreachable - * @param namespace namespace (required) - * @param name name (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS credentials deleted -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteAWSAccessCredentialsAsync(String namespace, String name, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = deleteAWSAccessCredentialsValidateBeforeCall(namespace, name, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for deleteOrganization - * @param organization organization name or ID (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 organization deleted -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteOrganizationCall(String organization, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/organizations/{organization}" - .replaceAll("\\{" + "organization" + "\\}", localVarApiClient.escapeString(organization.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call deleteOrganizationValidateBeforeCall(String organization, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'organization' is set - if (organization == null) { - throw new ApiException("Missing the required parameter 'organization' when calling deleteOrganization(Async)"); - } - - - okhttp3.Call localVarCall = deleteOrganizationCall(organization, _callback); - return localVarCall; - - } - - /** - * - * delete a organization - * @param organization organization name or ID (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 organization deleted -
502 Bad Gateway -
0 error response -
- */ - public void deleteOrganization(String organization) throws ApiException { - deleteOrganizationWithHttpInfo(organization); - } - - /** - * - * delete a organization - * @param organization organization name or ID (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 organization deleted -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse deleteOrganizationWithHttpInfo(String organization) throws ApiException { - okhttp3.Call localVarCall = deleteOrganizationValidateBeforeCall(organization, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * delete a organization - * @param organization organization name or ID (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 organization deleted -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteOrganizationAsync(String organization, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = deleteOrganizationValidateBeforeCall(organization, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for deleteSSODomain - * @param organization organization name (required) - * @param uuid configuration ID (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - -
Status Code Description Response Headers
204 Deletion successful. -
0 error response -
- */ - public okhttp3.Call deleteSSODomainCall(String organization, String uuid, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/organizations/{organization}/sso_domains/{uuid}" - .replaceAll("\\{" + "organization" + "\\}", localVarApiClient.escapeString(organization.toString())) - .replaceAll("\\{" + "uuid" + "\\}", localVarApiClient.escapeString(uuid.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call deleteSSODomainValidateBeforeCall(String organization, String uuid, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'organization' is set - if (organization == null) { - throw new ApiException("Missing the required parameter 'organization' when calling deleteSSODomain(Async)"); - } - - // verify the required parameter 'uuid' is set - if (uuid == null) { - throw new ApiException("Missing the required parameter 'uuid' when calling deleteSSODomain(Async)"); - } - - - okhttp3.Call localVarCall = deleteSSODomainCall(organization, uuid, _callback); - return localVarCall; - - } - - /** - * - * Deletes the configuration for the given SSO connection. - * @param organization organization name (required) - * @param uuid configuration ID (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
204 Deletion successful. -
0 error response -
- */ - public void deleteSSODomain(String organization, String uuid) throws ApiException { - deleteSSODomainWithHttpInfo(organization, uuid); - } - - /** - * - * Deletes the configuration for the given SSO connection. - * @param organization organization name (required) - * @param uuid configuration ID (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
204 Deletion successful. -
0 error response -
- */ - public ApiResponse deleteSSODomainWithHttpInfo(String organization, String uuid) throws ApiException { - okhttp3.Call localVarCall = deleteSSODomainValidateBeforeCall(organization, uuid, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Deletes the configuration for the given SSO connection. - * @param organization organization name (required) - * @param uuid configuration ID (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - -
Status Code Description Response Headers
204 Deletion successful. -
0 error response -
- */ - public okhttp3.Call deleteSSODomainAsync(String organization, String uuid, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = deleteSSODomainValidateBeforeCall(organization, uuid, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for deleteUserFromOrganization - * @param organization organization name (required) - * @param username username to manipulate (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user delete from organization successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteUserFromOrganizationCall(String organization, String username, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/organizations/{organization}/{username}" - .replaceAll("\\{" + "organization" + "\\}", localVarApiClient.escapeString(organization.toString())) - .replaceAll("\\{" + "username" + "\\}", localVarApiClient.escapeString(username.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call deleteUserFromOrganizationValidateBeforeCall(String organization, String username, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'organization' is set - if (organization == null) { - throw new ApiException("Missing the required parameter 'organization' when calling deleteUserFromOrganization(Async)"); - } - - // verify the required parameter 'username' is set - if (username == null) { - throw new ApiException("Missing the required parameter 'username' when calling deleteUserFromOrganization(Async)"); - } - - - okhttp3.Call localVarCall = deleteUserFromOrganizationCall(organization, username, _callback); - return localVarCall; - - } - - /** - * - * delete a user from an organization - * @param organization organization name (required) - * @param username username to manipulate (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user delete from organization successfully -
502 Bad Gateway -
0 error response -
- */ - public void deleteUserFromOrganization(String organization, String username) throws ApiException { - deleteUserFromOrganizationWithHttpInfo(organization, username); - } - - /** - * - * delete a user from an organization - * @param organization organization name (required) - * @param username username to manipulate (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user delete from organization successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse deleteUserFromOrganizationWithHttpInfo(String organization, String username) throws ApiException { - okhttp3.Call localVarCall = deleteUserFromOrganizationValidateBeforeCall(organization, username, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * delete a user from an organization - * @param organization organization name (required) - * @param username username to manipulate (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user delete from organization successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteUserFromOrganizationAsync(String organization, String username, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = deleteUserFromOrganizationValidateBeforeCall(organization, username, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for getAllOrganizations - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - - -
Status Code Description Response Headers
200 array of organizations the user is member of -
400 Error finding organizations -
500 Request user not found, or has empty context -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getAllOrganizationsCall(final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/organizations"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getAllOrganizationsValidateBeforeCall(final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = getAllOrganizationsCall(_callback); - return localVarCall; - - } - - /** - * - * get all organizations that the user is member of - * @return List<Organization> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - - -
Status Code Description Response Headers
200 array of organizations the user is member of -
400 Error finding organizations -
500 Request user not found, or has empty context -
502 Bad Gateway -
0 error response -
- */ - public List getAllOrganizations() throws ApiException { - ApiResponse> localVarResp = getAllOrganizationsWithHttpInfo(); - return localVarResp.getData(); - } - - /** - * - * get all organizations that the user is member of - * @return ApiResponse<List<Organization>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - - -
Status Code Description Response Headers
200 array of organizations the user is member of -
400 Error finding organizations -
500 Request user not found, or has empty context -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse> getAllOrganizationsWithHttpInfo() throws ApiException { - okhttp3.Call localVarCall = getAllOrganizationsValidateBeforeCall(null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * get all organizations that the user is member of - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - - -
Status Code Description Response Headers
200 array of organizations the user is member of -
400 Error finding organizations -
500 Request user not found, or has empty context -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getAllOrganizationsAsync(final ApiCallback> _callback) throws ApiException { - - okhttp3.Call localVarCall = getAllOrganizationsValidateBeforeCall(_callback); - Type localVarReturnType = new TypeToken>(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getOrganization - * @param organization organization name or ID (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 organization details -
404 Organization does not exist -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getOrganizationCall(String organization, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/organizations/{organization}" - .replaceAll("\\{" + "organization" + "\\}", localVarApiClient.escapeString(organization.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getOrganizationValidateBeforeCall(String organization, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'organization' is set - if (organization == null) { - throw new ApiException("Missing the required parameter 'organization' when calling getOrganization(Async)"); - } - - - okhttp3.Call localVarCall = getOrganizationCall(organization, _callback); - return localVarCall; - - } - - /** - * - * get a organization - * @param organization organization name or ID (required) - * @return Organization - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 organization details -
404 Organization does not exist -
502 Bad Gateway -
0 error response -
- */ - public Organization getOrganization(String organization) throws ApiException { - ApiResponse localVarResp = getOrganizationWithHttpInfo(organization); - return localVarResp.getData(); - } - - /** - * - * get a organization - * @param organization organization name or ID (required) - * @return ApiResponse<Organization> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 organization details -
404 Organization does not exist -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getOrganizationWithHttpInfo(String organization) throws ApiException { - okhttp3.Call localVarCall = getOrganizationValidateBeforeCall(organization, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * get a organization - * @param organization organization name or ID (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 organization details -
404 Organization does not exist -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getOrganizationAsync(String organization, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getOrganizationValidateBeforeCall(organization, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getOrganizationUser - * @param organization organization name (required) - * @param username username to manipulate (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 user from organization -
404 User is not in organization -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getOrganizationUserCall(String organization, String username, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/organizations/{organization}/{username}" - .replaceAll("\\{" + "organization" + "\\}", localVarApiClient.escapeString(organization.toString())) - .replaceAll("\\{" + "username" + "\\}", localVarApiClient.escapeString(username.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getOrganizationUserValidateBeforeCall(String organization, String username, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'organization' is set - if (organization == null) { - throw new ApiException("Missing the required parameter 'organization' when calling getOrganizationUser(Async)"); - } - - // verify the required parameter 'username' is set - if (username == null) { - throw new ApiException("Missing the required parameter 'username' when calling getOrganizationUser(Async)"); - } - - - okhttp3.Call localVarCall = getOrganizationUserCall(organization, username, _callback); - return localVarCall; - - } - - /** - * - * get a user from an organization - * @param organization organization name (required) - * @param username username to manipulate (required) - * @return OrganizationUser - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 user from organization -
404 User is not in organization -
502 Bad Gateway -
0 error response -
- */ - public OrganizationUser getOrganizationUser(String organization, String username) throws ApiException { - ApiResponse localVarResp = getOrganizationUserWithHttpInfo(organization, username); - return localVarResp.getData(); - } - - /** - * - * get a user from an organization - * @param organization organization name (required) - * @param username username to manipulate (required) - * @return ApiResponse<OrganizationUser> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 user from organization -
404 User is not in organization -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getOrganizationUserWithHttpInfo(String organization, String username) throws ApiException { - okhttp3.Call localVarCall = getOrganizationUserValidateBeforeCall(organization, username, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * get a user from an organization - * @param organization organization name (required) - * @param username username to manipulate (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 user from organization -
404 User is not in organization -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getOrganizationUserAsync(String organization, String username, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getOrganizationUserValidateBeforeCall(organization, username, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getSSODomain - * @param organization organization name (required) - * @param uuid configuration ID (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - -
Status Code Description Response Headers
200 The details about this domain connection. -
0 error response -
- */ - public okhttp3.Call getSSODomainCall(String organization, String uuid, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/organizations/{organization}/sso_domains/{uuid}" - .replaceAll("\\{" + "organization" + "\\}", localVarApiClient.escapeString(organization.toString())) - .replaceAll("\\{" + "uuid" + "\\}", localVarApiClient.escapeString(uuid.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getSSODomainValidateBeforeCall(String organization, String uuid, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'organization' is set - if (organization == null) { - throw new ApiException("Missing the required parameter 'organization' when calling getSSODomain(Async)"); - } - - // verify the required parameter 'uuid' is set - if (uuid == null) { - throw new ApiException("Missing the required parameter 'uuid' when calling getSSODomain(Async)"); - } - - - okhttp3.Call localVarCall = getSSODomainCall(organization, uuid, _callback); - return localVarCall; - - } - - /** - * - * Gets details about the given SSO domain connection. - * @param organization organization name (required) - * @param uuid configuration ID (required) - * @return SSODomainConfig - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 The details about this domain connection. -
0 error response -
- */ - public SSODomainConfig getSSODomain(String organization, String uuid) throws ApiException { - ApiResponse localVarResp = getSSODomainWithHttpInfo(organization, uuid); - return localVarResp.getData(); - } - - /** - * - * Gets details about the given SSO domain connection. - * @param organization organization name (required) - * @param uuid configuration ID (required) - * @return ApiResponse<SSODomainConfig> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 The details about this domain connection. -
0 error response -
- */ - public ApiResponse getSSODomainWithHttpInfo(String organization, String uuid) throws ApiException { - okhttp3.Call localVarCall = getSSODomainValidateBeforeCall(organization, uuid, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Gets details about the given SSO domain connection. - * @param organization organization name (required) - * @param uuid configuration ID (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - -
Status Code Description Response Headers
200 The details about this domain connection. -
0 error response -
- */ - public okhttp3.Call getSSODomainAsync(String organization, String uuid, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getSSODomainValidateBeforeCall(organization, uuid, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getSSODomains - * @param organization organization name (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - -
Status Code Description Response Headers
200 The SSO domains associated with the org. -
0 error response -
- */ - public okhttp3.Call getSSODomainsCall(String organization, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/organizations/{organization}/sso_domains" - .replaceAll("\\{" + "organization" + "\\}", localVarApiClient.escapeString(organization.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getSSODomainsValidateBeforeCall(String organization, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'organization' is set - if (organization == null) { - throw new ApiException("Missing the required parameter 'organization' when calling getSSODomains(Async)"); - } - - - okhttp3.Call localVarCall = getSSODomainsCall(organization, _callback); - return localVarCall; - - } - - /** - * - * Lists all the SSO connections associated with the given organization. - * @param organization organization name (required) - * @return SSODomainConfigResponse - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 The SSO domains associated with the org. -
0 error response -
- */ - public SSODomainConfigResponse getSSODomains(String organization) throws ApiException { - ApiResponse localVarResp = getSSODomainsWithHttpInfo(organization); - return localVarResp.getData(); - } - - /** - * - * Lists all the SSO connections associated with the given organization. - * @param organization organization name (required) - * @return ApiResponse<SSODomainConfigResponse> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 The SSO domains associated with the org. -
0 error response -
- */ - public ApiResponse getSSODomainsWithHttpInfo(String organization) throws ApiException { - okhttp3.Call localVarCall = getSSODomainsValidateBeforeCall(organization, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Lists all the SSO connections associated with the given organization. - * @param organization organization name (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - -
Status Code Description Response Headers
200 The SSO domains associated with the org. -
0 error response -
- */ - public okhttp3.Call getSSODomainsAsync(String organization, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getSSODomainsValidateBeforeCall(organization, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for updateAWSAccessCredentials - * @param namespace namespace (required) - * @param name name (required) - * @param awsAccessCredentials aws credentials to update (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS keys updated successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateAWSAccessCredentialsCall(String namespace, String name, AWSAccessCredentials awsAccessCredentials, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = awsAccessCredentials; - - // create path and map variables - String localVarPath = "/credentials/{namespace}/aws/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call updateAWSAccessCredentialsValidateBeforeCall(String namespace, String name, AWSAccessCredentials awsAccessCredentials, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling updateAWSAccessCredentials(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling updateAWSAccessCredentials(Async)"); - } - - // verify the required parameter 'awsAccessCredentials' is set - if (awsAccessCredentials == null) { - throw new ApiException("Missing the required parameter 'awsAccessCredentials' when calling updateAWSAccessCredentials(Async)"); - } - - - okhttp3.Call localVarCall = updateAWSAccessCredentialsCall(namespace, name, awsAccessCredentials, _callback); - return localVarCall; - - } - - /** - * - * Update aws keys or associated buckets. This will update the key associations for each array in the namespace - * @param namespace namespace (required) - * @param name name (required) - * @param awsAccessCredentials aws credentials to update (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS keys updated successfully -
502 Bad Gateway -
0 error response -
- */ - public void updateAWSAccessCredentials(String namespace, String name, AWSAccessCredentials awsAccessCredentials) throws ApiException { - updateAWSAccessCredentialsWithHttpInfo(namespace, name, awsAccessCredentials); - } - - /** - * - * Update aws keys or associated buckets. This will update the key associations for each array in the namespace - * @param namespace namespace (required) - * @param name name (required) - * @param awsAccessCredentials aws credentials to update (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS keys updated successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse updateAWSAccessCredentialsWithHttpInfo(String namespace, String name, AWSAccessCredentials awsAccessCredentials) throws ApiException { - okhttp3.Call localVarCall = updateAWSAccessCredentialsValidateBeforeCall(namespace, name, awsAccessCredentials, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Update aws keys or associated buckets. This will update the key associations for each array in the namespace - * @param namespace namespace (required) - * @param name name (required) - * @param awsAccessCredentials aws credentials to update (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS keys updated successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateAWSAccessCredentialsAsync(String namespace, String name, AWSAccessCredentials awsAccessCredentials, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = updateAWSAccessCredentialsValidateBeforeCall(namespace, name, awsAccessCredentials, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for updateOrganization - * @param organization organization name or ID (required) - * @param organizationDetails organization details to update (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 organization updated successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateOrganizationCall(String organization, Organization organizationDetails, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = organizationDetails; - - // create path and map variables - String localVarPath = "/organizations/{organization}" - .replaceAll("\\{" + "organization" + "\\}", localVarApiClient.escapeString(organization.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call updateOrganizationValidateBeforeCall(String organization, Organization organizationDetails, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'organization' is set - if (organization == null) { - throw new ApiException("Missing the required parameter 'organization' when calling updateOrganization(Async)"); - } - - // verify the required parameter 'organizationDetails' is set - if (organizationDetails == null) { - throw new ApiException("Missing the required parameter 'organizationDetails' when calling updateOrganization(Async)"); - } - - - okhttp3.Call localVarCall = updateOrganizationCall(organization, organizationDetails, _callback); - return localVarCall; - - } - - /** - * - * update a organization - * @param organization organization name or ID (required) - * @param organizationDetails organization details to update (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 organization updated successfully -
502 Bad Gateway -
0 error response -
- */ - public void updateOrganization(String organization, Organization organizationDetails) throws ApiException { - updateOrganizationWithHttpInfo(organization, organizationDetails); - } - - /** - * - * update a organization - * @param organization organization name or ID (required) - * @param organizationDetails organization details to update (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 organization updated successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse updateOrganizationWithHttpInfo(String organization, Organization organizationDetails) throws ApiException { - okhttp3.Call localVarCall = updateOrganizationValidateBeforeCall(organization, organizationDetails, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * update a organization - * @param organization organization name or ID (required) - * @param organizationDetails organization details to update (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 organization updated successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateOrganizationAsync(String organization, Organization organizationDetails, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = updateOrganizationValidateBeforeCall(organization, organizationDetails, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for updateSSODomain - * @param organization organization name (required) - * @param uuid configuration ID (required) - * @param config The changes to make to the configuration. (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - -
Status Code Description Response Headers
200 The updated details about the SSO connection. -
0 error response -
- */ - public okhttp3.Call updateSSODomainCall(String organization, String uuid, SSODomainConfig config, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = config; - - // create path and map variables - String localVarPath = "/organizations/{organization}/sso_domains/{uuid}" - .replaceAll("\\{" + "organization" + "\\}", localVarApiClient.escapeString(organization.toString())) - .replaceAll("\\{" + "uuid" + "\\}", localVarApiClient.escapeString(uuid.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call updateSSODomainValidateBeforeCall(String organization, String uuid, SSODomainConfig config, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'organization' is set - if (organization == null) { - throw new ApiException("Missing the required parameter 'organization' when calling updateSSODomain(Async)"); - } - - // verify the required parameter 'uuid' is set - if (uuid == null) { - throw new ApiException("Missing the required parameter 'uuid' when calling updateSSODomain(Async)"); - } - - // verify the required parameter 'config' is set - if (config == null) { - throw new ApiException("Missing the required parameter 'config' when calling updateSSODomain(Async)"); - } - - - okhttp3.Call localVarCall = updateSSODomainCall(organization, uuid, config, _callback); - return localVarCall; - - } - - /** - * - * Updates the configuration for the given SSO connection. - * @param organization organization name (required) - * @param uuid configuration ID (required) - * @param config The changes to make to the configuration. (required) - * @return SSODomainConfig - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 The updated details about the SSO connection. -
0 error response -
- */ - public SSODomainConfig updateSSODomain(String organization, String uuid, SSODomainConfig config) throws ApiException { - ApiResponse localVarResp = updateSSODomainWithHttpInfo(organization, uuid, config); - return localVarResp.getData(); - } - - /** - * - * Updates the configuration for the given SSO connection. - * @param organization organization name (required) - * @param uuid configuration ID (required) - * @param config The changes to make to the configuration. (required) - * @return ApiResponse<SSODomainConfig> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 The updated details about the SSO connection. -
0 error response -
- */ - public ApiResponse updateSSODomainWithHttpInfo(String organization, String uuid, SSODomainConfig config) throws ApiException { - okhttp3.Call localVarCall = updateSSODomainValidateBeforeCall(organization, uuid, config, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Updates the configuration for the given SSO connection. - * @param organization organization name (required) - * @param uuid configuration ID (required) - * @param config The changes to make to the configuration. (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - -
Status Code Description Response Headers
200 The updated details about the SSO connection. -
0 error response -
- */ - public okhttp3.Call updateSSODomainAsync(String organization, String uuid, SSODomainConfig config, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = updateSSODomainValidateBeforeCall(organization, uuid, config, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for updateUserInOrganization - * @param organization organization name (required) - * @param username username to manipulate (required) - * @param user user details to update (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user update in organization successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateUserInOrganizationCall(String organization, String username, OrganizationUser user, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = user; - - // create path and map variables - String localVarPath = "/organizations/{organization}/{username}" - .replaceAll("\\{" + "organization" + "\\}", localVarApiClient.escapeString(organization.toString())) - .replaceAll("\\{" + "username" + "\\}", localVarApiClient.escapeString(username.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call updateUserInOrganizationValidateBeforeCall(String organization, String username, OrganizationUser user, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'organization' is set - if (organization == null) { - throw new ApiException("Missing the required parameter 'organization' when calling updateUserInOrganization(Async)"); - } - - // verify the required parameter 'username' is set - if (username == null) { - throw new ApiException("Missing the required parameter 'username' when calling updateUserInOrganization(Async)"); - } - - // verify the required parameter 'user' is set - if (user == null) { - throw new ApiException("Missing the required parameter 'user' when calling updateUserInOrganization(Async)"); - } - - - okhttp3.Call localVarCall = updateUserInOrganizationCall(organization, username, user, _callback); - return localVarCall; - - } - - /** - * - * update a user in an organization - * @param organization organization name (required) - * @param username username to manipulate (required) - * @param user user details to update (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user update in organization successfully -
502 Bad Gateway -
0 error response -
- */ - public void updateUserInOrganization(String organization, String username, OrganizationUser user) throws ApiException { - updateUserInOrganizationWithHttpInfo(organization, username, user); - } - - /** - * - * update a user in an organization - * @param organization organization name (required) - * @param username username to manipulate (required) - * @param user user details to update (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user update in organization successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse updateUserInOrganizationWithHttpInfo(String organization, String username, OrganizationUser user) throws ApiException { - okhttp3.Call localVarCall = updateUserInOrganizationValidateBeforeCall(organization, username, user, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * update a user in an organization - * @param organization organization name (required) - * @param username username to manipulate (required) - * @param user user details to update (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user update in organization successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateUserInOrganizationAsync(String organization, String username, OrganizationUser user, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = updateUserInOrganizationValidateBeforeCall(organization, username, user, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/api/QueryApi.java b/src/main/java/io/tiledb/cloud/rest_api/v1/api/QueryApi.java deleted file mode 100644 index 0a7fd2b..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/api/QueryApi.java +++ /dev/null @@ -1,1014 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.api; - -import io.tiledb.cloud.rest_api.v1.model.Query; -import io.tiledb.cloud.rest_api.v1.model.QueryJson; -import io.tiledb.cloud.rest_api.v1.ApiCallback; -import io.tiledb.cloud.rest_api.v1.ApiClient; -import io.tiledb.cloud.rest_api.v1.ApiException; -import io.tiledb.cloud.rest_api.v1.ApiResponse; -import io.tiledb.cloud.rest_api.v1.Configuration; -import io.tiledb.cloud.rest_api.v1.Pair; - -import com.google.gson.reflect.TypeToken; - - -import java.io.File; - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class QueryApi { - private ApiClient localVarApiClient; - private int localHostIndex; - private String localCustomBaseUrl; - - public QueryApi() { - this(Configuration.getDefaultApiClient()); - } - - public QueryApi(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public ApiClient getApiClient() { - return localVarApiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public int getHostIndex() { - return localHostIndex; - } - - public void setHostIndex(int hostIndex) { - this.localHostIndex = hostIndex; - } - - public String getCustomBaseUrl() { - return localCustomBaseUrl; - } - - public void setCustomBaseUrl(String customBaseUrl) { - this.localCustomBaseUrl = customBaseUrl; - } - - /** - * Build call for finalizeQuery - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param type type of query (required) - * @param contentType Content Type of input and return mime (required) - * @param query query to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param openAt open_at for array in unix epoch (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 query completed and results are returned in query object * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
204 query completed successfully with no return -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call finalizeQueryCall(String namespace, String array, String type, String contentType, Query query, String xPayer, Integer openAt, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = query; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/query/finalize" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (type != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("type", type)); - } - - if (openAt != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("open_at", openAt)); - } - - if (contentType != null) { - localVarHeaderParams.put("Content-Type", localVarApiClient.parameterToString(contentType)); - } - - if (xPayer != null) { - localVarHeaderParams.put("X-Payer", localVarApiClient.parameterToString(xPayer)); - } - - final String[] localVarAccepts = { - "application/json", "application/capnp" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json", "application/capnp" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call finalizeQueryValidateBeforeCall(String namespace, String array, String type, String contentType, Query query, String xPayer, Integer openAt, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling finalizeQuery(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling finalizeQuery(Async)"); - } - - // verify the required parameter 'type' is set - if (type == null) { - throw new ApiException("Missing the required parameter 'type' when calling finalizeQuery(Async)"); - } - - // verify the required parameter 'contentType' is set - if (contentType == null) { - throw new ApiException("Missing the required parameter 'contentType' when calling finalizeQuery(Async)"); - } - - // verify the required parameter 'query' is set - if (query == null) { - throw new ApiException("Missing the required parameter 'query' when calling finalizeQuery(Async)"); - } - - - okhttp3.Call localVarCall = finalizeQueryCall(namespace, array, type, contentType, query, xPayer, openAt, _callback); - return localVarCall; - - } - - /** - * - * send a query to run against a specified array/URI registered to a group/project - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param type type of query (required) - * @param contentType Content Type of input and return mime (required) - * @param query query to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param openAt open_at for array in unix epoch (optional) - * @return Query - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 query completed and results are returned in query object * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
204 query completed successfully with no return -
502 Bad Gateway -
0 error response -
- */ - public Query finalizeQuery(String namespace, String array, String type, String contentType, Query query, String xPayer, Integer openAt) throws ApiException { - ApiResponse localVarResp = finalizeQueryWithHttpInfo(namespace, array, type, contentType, query, xPayer, openAt); - return localVarResp.getData(); - } - - /** - * - * send a query to run against a specified array/URI registered to a group/project - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param type type of query (required) - * @param contentType Content Type of input and return mime (required) - * @param query query to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param openAt open_at for array in unix epoch (optional) - * @return ApiResponse<Query> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 query completed and results are returned in query object * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
204 query completed successfully with no return -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse finalizeQueryWithHttpInfo(String namespace, String array, String type, String contentType, Query query, String xPayer, Integer openAt) throws ApiException { - okhttp3.Call localVarCall = finalizeQueryValidateBeforeCall(namespace, array, type, contentType, query, xPayer, openAt, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * send a query to run against a specified array/URI registered to a group/project - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param type type of query (required) - * @param contentType Content Type of input and return mime (required) - * @param query query to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param openAt open_at for array in unix epoch (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 query completed and results are returned in query object * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
204 query completed successfully with no return -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call finalizeQueryAsync(String namespace, String array, String type, String contentType, Query query, String xPayer, Integer openAt, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = finalizeQueryValidateBeforeCall(namespace, array, type, contentType, query, xPayer, openAt, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getEstResultSizes - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param type type of query (required) - * @param contentType Content Type of input and return mime (required) - * @param query query to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param openAt open_at for array in unix epoch (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 query est result size computed and results are returned in query object * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
204 query completed successfully with no return -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getEstResultSizesCall(String namespace, String array, String type, String contentType, Query query, String xPayer, Integer openAt, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = query; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/query/est_result_sizes" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (type != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("type", type)); - } - - if (openAt != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("open_at", openAt)); - } - - if (contentType != null) { - localVarHeaderParams.put("Content-Type", localVarApiClient.parameterToString(contentType)); - } - - if (xPayer != null) { - localVarHeaderParams.put("X-Payer", localVarApiClient.parameterToString(xPayer)); - } - - final String[] localVarAccepts = { - "application/json", "application/capnp" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json", "application/capnp" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getEstResultSizesValidateBeforeCall(String namespace, String array, String type, String contentType, Query query, String xPayer, Integer openAt, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getEstResultSizes(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling getEstResultSizes(Async)"); - } - - // verify the required parameter 'type' is set - if (type == null) { - throw new ApiException("Missing the required parameter 'type' when calling getEstResultSizes(Async)"); - } - - // verify the required parameter 'contentType' is set - if (contentType == null) { - throw new ApiException("Missing the required parameter 'contentType' when calling getEstResultSizes(Async)"); - } - - // verify the required parameter 'query' is set - if (query == null) { - throw new ApiException("Missing the required parameter 'query' when calling getEstResultSizes(Async)"); - } - - - okhttp3.Call localVarCall = getEstResultSizesCall(namespace, array, type, contentType, query, xPayer, openAt, _callback); - return localVarCall; - - } - - /** - * - * send a query to run against a specified array/URI registered to a group/project - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param type type of query (required) - * @param contentType Content Type of input and return mime (required) - * @param query query to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param openAt open_at for array in unix epoch (optional) - * @return Query - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 query est result size computed and results are returned in query object * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
204 query completed successfully with no return -
502 Bad Gateway -
0 error response -
- */ - public Query getEstResultSizes(String namespace, String array, String type, String contentType, Query query, String xPayer, Integer openAt) throws ApiException { - ApiResponse localVarResp = getEstResultSizesWithHttpInfo(namespace, array, type, contentType, query, xPayer, openAt); - return localVarResp.getData(); - } - - /** - * - * send a query to run against a specified array/URI registered to a group/project - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param type type of query (required) - * @param contentType Content Type of input and return mime (required) - * @param query query to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param openAt open_at for array in unix epoch (optional) - * @return ApiResponse<Query> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 query est result size computed and results are returned in query object * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
204 query completed successfully with no return -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getEstResultSizesWithHttpInfo(String namespace, String array, String type, String contentType, Query query, String xPayer, Integer openAt) throws ApiException { - okhttp3.Call localVarCall = getEstResultSizesValidateBeforeCall(namespace, array, type, contentType, query, xPayer, openAt, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * send a query to run against a specified array/URI registered to a group/project - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param type type of query (required) - * @param contentType Content Type of input and return mime (required) - * @param query query to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param openAt open_at for array in unix epoch (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 query est result size computed and results are returned in query object * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
204 query completed successfully with no return -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getEstResultSizesAsync(String namespace, String array, String type, String contentType, Query query, String xPayer, Integer openAt, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getEstResultSizesValidateBeforeCall(namespace, array, type, contentType, query, xPayer, openAt, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getFile - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 query completed and result bytes are returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getFileCall(String namespace, String array, String contentType, String xPayer, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/query/get_file" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (contentType != null) { - localVarHeaderParams.put("Content-Type", localVarApiClient.parameterToString(contentType)); - } - - if (xPayer != null) { - localVarHeaderParams.put("X-Payer", localVarApiClient.parameterToString(xPayer)); - } - - final String[] localVarAccepts = { - "application/x-ipynb+json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getFileValidateBeforeCall(String namespace, String array, String contentType, String xPayer, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getFile(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling getFile(Async)"); - } - - // verify the required parameter 'contentType' is set - if (contentType == null) { - throw new ApiException("Missing the required parameter 'contentType' when calling getFile(Async)"); - } - - - okhttp3.Call localVarCall = getFileCall(namespace, array, contentType, xPayer, _callback); - return localVarCall; - - } - - /** - * - * send a query to run against a specified array/URI registered to a group/project, returns file bytes - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @return File - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 query completed and result bytes are returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response -
- */ - public File getFile(String namespace, String array, String contentType, String xPayer) throws ApiException { - ApiResponse localVarResp = getFileWithHttpInfo(namespace, array, contentType, xPayer); - return localVarResp.getData(); - } - - /** - * - * send a query to run against a specified array/URI registered to a group/project, returns file bytes - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @return ApiResponse<File> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 query completed and result bytes are returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getFileWithHttpInfo(String namespace, String array, String contentType, String xPayer) throws ApiException { - okhttp3.Call localVarCall = getFileValidateBeforeCall(namespace, array, contentType, xPayer, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * send a query to run against a specified array/URI registered to a group/project, returns file bytes - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 query completed and result bytes are returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getFileAsync(String namespace, String array, String contentType, String xPayer, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getFileValidateBeforeCall(namespace, array, contentType, xPayer, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for submitQuery - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param type type of query (required) - * @param contentType Content Type of input and return mime (required) - * @param query query to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param openAt open_at for array in unix epoch (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 query completed and results are returned in query object * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
204 query completed successfully with no return -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call submitQueryCall(String namespace, String array, String type, String contentType, Query query, String xPayer, Integer openAt, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = query; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/query/submit" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (type != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("type", type)); - } - - if (openAt != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("open_at", openAt)); - } - - if (contentType != null) { - localVarHeaderParams.put("Content-Type", localVarApiClient.parameterToString(contentType)); - } - - if (xPayer != null) { - localVarHeaderParams.put("X-Payer", localVarApiClient.parameterToString(xPayer)); - } - - final String[] localVarAccepts = { - "application/json", "application/capnp" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json", "application/capnp" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call submitQueryValidateBeforeCall(String namespace, String array, String type, String contentType, Query query, String xPayer, Integer openAt, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling submitQuery(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling submitQuery(Async)"); - } - - // verify the required parameter 'type' is set - if (type == null) { - throw new ApiException("Missing the required parameter 'type' when calling submitQuery(Async)"); - } - - // verify the required parameter 'contentType' is set - if (contentType == null) { - throw new ApiException("Missing the required parameter 'contentType' when calling submitQuery(Async)"); - } - - // verify the required parameter 'query' is set - if (query == null) { - throw new ApiException("Missing the required parameter 'query' when calling submitQuery(Async)"); - } - - - okhttp3.Call localVarCall = submitQueryCall(namespace, array, type, contentType, query, xPayer, openAt, _callback); - return localVarCall; - - } - - /** - * - * send a query to run against a specified array/URI registered to a group/project - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param type type of query (required) - * @param contentType Content Type of input and return mime (required) - * @param query query to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param openAt open_at for array in unix epoch (optional) - * @return Query - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 query completed and results are returned in query object * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
204 query completed successfully with no return -
502 Bad Gateway -
0 error response -
- */ - public Query submitQuery(String namespace, String array, String type, String contentType, Query query, String xPayer, Integer openAt) throws ApiException { - ApiResponse localVarResp = submitQueryWithHttpInfo(namespace, array, type, contentType, query, xPayer, openAt); - return localVarResp.getData(); - } - - /** - * - * send a query to run against a specified array/URI registered to a group/project - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param type type of query (required) - * @param contentType Content Type of input and return mime (required) - * @param query query to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param openAt open_at for array in unix epoch (optional) - * @return ApiResponse<Query> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 query completed and results are returned in query object * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
204 query completed successfully with no return -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse submitQueryWithHttpInfo(String namespace, String array, String type, String contentType, Query query, String xPayer, Integer openAt) throws ApiException { - okhttp3.Call localVarCall = submitQueryValidateBeforeCall(namespace, array, type, contentType, query, xPayer, openAt, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * send a query to run against a specified array/URI registered to a group/project - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param type type of query (required) - * @param contentType Content Type of input and return mime (required) - * @param query query to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param openAt open_at for array in unix epoch (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 query completed and results are returned in query object * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
204 query completed successfully with no return -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call submitQueryAsync(String namespace, String array, String type, String contentType, Query query, String xPayer, Integer openAt, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = submitQueryValidateBeforeCall(namespace, array, type, contentType, query, xPayer, openAt, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for submitQueryJson - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param queryJson query to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 query completed and results are returned in JSON format * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call submitQueryJsonCall(String namespace, String array, String contentType, QueryJson queryJson, String xPayer, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = queryJson; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/query/submit_query_json" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (contentType != null) { - localVarHeaderParams.put("Content-Type", localVarApiClient.parameterToString(contentType)); - } - - if (xPayer != null) { - localVarHeaderParams.put("X-Payer", localVarApiClient.parameterToString(xPayer)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call submitQueryJsonValidateBeforeCall(String namespace, String array, String contentType, QueryJson queryJson, String xPayer, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling submitQueryJson(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling submitQueryJson(Async)"); - } - - // verify the required parameter 'contentType' is set - if (contentType == null) { - throw new ApiException("Missing the required parameter 'contentType' when calling submitQueryJson(Async)"); - } - - // verify the required parameter 'queryJson' is set - if (queryJson == null) { - throw new ApiException("Missing the required parameter 'queryJson' when calling submitQueryJson(Async)"); - } - - - okhttp3.Call localVarCall = submitQueryJsonCall(namespace, array, contentType, queryJson, xPayer, _callback); - return localVarCall; - - } - - /** - * - * send a query to run against a specified array/URI registered to a group/project, returns JSON results - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param queryJson query to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @return Object - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 query completed and results are returned in JSON format * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response -
- */ - public Object submitQueryJson(String namespace, String array, String contentType, QueryJson queryJson, String xPayer) throws ApiException { - ApiResponse localVarResp = submitQueryJsonWithHttpInfo(namespace, array, contentType, queryJson, xPayer); - return localVarResp.getData(); - } - - /** - * - * send a query to run against a specified array/URI registered to a group/project, returns JSON results - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param queryJson query to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @return ApiResponse<Object> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 query completed and results are returned in JSON format * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response -
- */ - public ApiResponse submitQueryJsonWithHttpInfo(String namespace, String array, String contentType, QueryJson queryJson, String xPayer) throws ApiException { - okhttp3.Call localVarCall = submitQueryJsonValidateBeforeCall(namespace, array, contentType, queryJson, xPayer, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * send a query to run against a specified array/URI registered to a group/project, returns JSON results - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param contentType Content Type of input and return mime (required) - * @param queryJson query to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 query completed and results are returned in JSON format * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call submitQueryJsonAsync(String namespace, String array, String contentType, QueryJson queryJson, String xPayer, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = submitQueryJsonValidateBeforeCall(namespace, array, contentType, queryJson, xPayer, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/api/RegisteredTaskGraphsApi.java b/src/main/java/io/tiledb/cloud/rest_api/v1/api/RegisteredTaskGraphsApi.java deleted file mode 100644 index ef03052..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/api/RegisteredTaskGraphsApi.java +++ /dev/null @@ -1,950 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.api; - -import io.tiledb.cloud.rest_api.v1.model.RegisteredTaskGraph; -import io.tiledb.cloud.rest_api.v1.model.TaskGraphSharing; -import io.tiledb.cloud.rest_api.v1.ApiCallback; -import io.tiledb.cloud.rest_api.v1.ApiClient; -import io.tiledb.cloud.rest_api.v1.ApiException; -import io.tiledb.cloud.rest_api.v1.ApiResponse; -import io.tiledb.cloud.rest_api.v1.Configuration; -import io.tiledb.cloud.rest_api.v1.Pair; - -import com.google.gson.reflect.TypeToken; - - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class RegisteredTaskGraphsApi { - private ApiClient localVarApiClient; - private int localHostIndex; - private String localCustomBaseUrl; - - public RegisteredTaskGraphsApi() { - this(Configuration.getDefaultApiClient()); - } - - public RegisteredTaskGraphsApi(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public ApiClient getApiClient() { - return localVarApiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public int getHostIndex() { - return localHostIndex; - } - - public void setHostIndex(int hostIndex) { - this.localHostIndex = hostIndex; - } - - public String getCustomBaseUrl() { - return localCustomBaseUrl; - } - - public void setCustomBaseUrl(String customBaseUrl) { - this.localCustomBaseUrl = customBaseUrl; - } - - /** - * Build call for deleteRegisteredTaskGraph - * @param namespace The namespace that owns this registered UDF. (required) - * @param name The name of the registered task graph. (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Task graph successfully deleted. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteRegisteredTaskGraphCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/taskgraphs/{namespace}/registered/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call deleteRegisteredTaskGraphValidateBeforeCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling deleteRegisteredTaskGraph(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling deleteRegisteredTaskGraph(Async)"); - } - - - okhttp3.Call localVarCall = deleteRegisteredTaskGraphCall(namespace, name, _callback); - return localVarCall; - - } - - /** - * - * Delete the given registered task graph. - * @param namespace The namespace that owns this registered UDF. (required) - * @param name The name of the registered task graph. (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Task graph successfully deleted. -
502 Bad Gateway -
0 error response -
- */ - public void deleteRegisteredTaskGraph(String namespace, String name) throws ApiException { - deleteRegisteredTaskGraphWithHttpInfo(namespace, name); - } - - /** - * - * Delete the given registered task graph. - * @param namespace The namespace that owns this registered UDF. (required) - * @param name The name of the registered task graph. (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Task graph successfully deleted. -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse deleteRegisteredTaskGraphWithHttpInfo(String namespace, String name) throws ApiException { - okhttp3.Call localVarCall = deleteRegisteredTaskGraphValidateBeforeCall(namespace, name, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Delete the given registered task graph. - * @param namespace The namespace that owns this registered UDF. (required) - * @param name The name of the registered task graph. (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Task graph successfully deleted. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteRegisteredTaskGraphAsync(String namespace, String name, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = deleteRegisteredTaskGraphValidateBeforeCall(namespace, name, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for getRegisteredTaskGraph - * @param namespace The namespace that owns this registered UDF. (required) - * @param name The name of the registered task graph. (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 The contents of the registered task graph. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getRegisteredTaskGraphCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/taskgraphs/{namespace}/registered/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getRegisteredTaskGraphValidateBeforeCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getRegisteredTaskGraph(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling getRegisteredTaskGraph(Async)"); - } - - - okhttp3.Call localVarCall = getRegisteredTaskGraphCall(namespace, name, _callback); - return localVarCall; - - } - - /** - * - * Fetch the contents of this registered task graph. - * @param namespace The namespace that owns this registered UDF. (required) - * @param name The name of the registered task graph. (required) - * @return RegisteredTaskGraph - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 The contents of the registered task graph. -
502 Bad Gateway -
0 error response -
- */ - public RegisteredTaskGraph getRegisteredTaskGraph(String namespace, String name) throws ApiException { - ApiResponse localVarResp = getRegisteredTaskGraphWithHttpInfo(namespace, name); - return localVarResp.getData(); - } - - /** - * - * Fetch the contents of this registered task graph. - * @param namespace The namespace that owns this registered UDF. (required) - * @param name The name of the registered task graph. (required) - * @return ApiResponse<RegisteredTaskGraph> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 The contents of the registered task graph. -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getRegisteredTaskGraphWithHttpInfo(String namespace, String name) throws ApiException { - okhttp3.Call localVarCall = getRegisteredTaskGraphValidateBeforeCall(namespace, name, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch the contents of this registered task graph. - * @param namespace The namespace that owns this registered UDF. (required) - * @param name The name of the registered task graph. (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 The contents of the registered task graph. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getRegisteredTaskGraphAsync(String namespace, String name, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getRegisteredTaskGraphValidateBeforeCall(namespace, name, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getRegisteredTaskGraphSharingPolicies - * @param namespace The namespace that owns the registered task graph. (required) - * @param name The name of the task graph. (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 List of all specific sharing policies -
404 The task graph does not exist (or the user does not have permission to view policies) -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getRegisteredTaskGraphSharingPoliciesCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/taskgraphs/{namespace}/registered/{name}/share" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getRegisteredTaskGraphSharingPoliciesValidateBeforeCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getRegisteredTaskGraphSharingPolicies(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling getRegisteredTaskGraphSharingPolicies(Async)"); - } - - - okhttp3.Call localVarCall = getRegisteredTaskGraphSharingPoliciesCall(namespace, name, _callback); - return localVarCall; - - } - - /** - * - * Get sharing policies for the task graph. - * @param namespace The namespace that owns the registered task graph. (required) - * @param name The name of the task graph. (required) - * @return List<TaskGraphSharing> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 List of all specific sharing policies -
404 The task graph does not exist (or the user does not have permission to view policies) -
502 Bad Gateway -
0 error response -
- */ - public List getRegisteredTaskGraphSharingPolicies(String namespace, String name) throws ApiException { - ApiResponse> localVarResp = getRegisteredTaskGraphSharingPoliciesWithHttpInfo(namespace, name); - return localVarResp.getData(); - } - - /** - * - * Get sharing policies for the task graph. - * @param namespace The namespace that owns the registered task graph. (required) - * @param name The name of the task graph. (required) - * @return ApiResponse<List<TaskGraphSharing>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 List of all specific sharing policies -
404 The task graph does not exist (or the user does not have permission to view policies) -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse> getRegisteredTaskGraphSharingPoliciesWithHttpInfo(String namespace, String name) throws ApiException { - okhttp3.Call localVarCall = getRegisteredTaskGraphSharingPoliciesValidateBeforeCall(namespace, name, null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Get sharing policies for the task graph. - * @param namespace The namespace that owns the registered task graph. (required) - * @param name The name of the task graph. (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 List of all specific sharing policies -
404 The task graph does not exist (or the user does not have permission to view policies) -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getRegisteredTaskGraphSharingPoliciesAsync(String namespace, String name, final ApiCallback> _callback) throws ApiException { - - okhttp3.Call localVarCall = getRegisteredTaskGraphSharingPoliciesValidateBeforeCall(namespace, name, _callback); - Type localVarReturnType = new TypeToken>(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for registerRegisteredTaskGraph - * @param namespace The namespace that owns this registered UDF. (required) - * @param name The name of the registered task graph. (required) - * @param graph Task graph to register. (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Task graph registered successfully. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call registerRegisteredTaskGraphCall(String namespace, String name, RegisteredTaskGraph graph, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = graph; - - // create path and map variables - String localVarPath = "/taskgraphs/{namespace}/registered/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call registerRegisteredTaskGraphValidateBeforeCall(String namespace, String name, RegisteredTaskGraph graph, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling registerRegisteredTaskGraph(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling registerRegisteredTaskGraph(Async)"); - } - - - okhttp3.Call localVarCall = registerRegisteredTaskGraphCall(namespace, name, graph, _callback); - return localVarCall; - - } - - /** - * - * Register a task graph in the given namespace, with the given name. - * @param namespace The namespace that owns this registered UDF. (required) - * @param name The name of the registered task graph. (required) - * @param graph Task graph to register. (optional) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Task graph registered successfully. -
502 Bad Gateway -
0 error response -
- */ - public void registerRegisteredTaskGraph(String namespace, String name, RegisteredTaskGraph graph) throws ApiException { - registerRegisteredTaskGraphWithHttpInfo(namespace, name, graph); - } - - /** - * - * Register a task graph in the given namespace, with the given name. - * @param namespace The namespace that owns this registered UDF. (required) - * @param name The name of the registered task graph. (required) - * @param graph Task graph to register. (optional) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Task graph registered successfully. -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse registerRegisteredTaskGraphWithHttpInfo(String namespace, String name, RegisteredTaskGraph graph) throws ApiException { - okhttp3.Call localVarCall = registerRegisteredTaskGraphValidateBeforeCall(namespace, name, graph, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Register a task graph in the given namespace, with the given name. - * @param namespace The namespace that owns this registered UDF. (required) - * @param name The name of the registered task graph. (required) - * @param graph Task graph to register. (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Task graph registered successfully. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call registerRegisteredTaskGraphAsync(String namespace, String name, RegisteredTaskGraph graph, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = registerRegisteredTaskGraphValidateBeforeCall(namespace, name, graph, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for shareRegisteredTaskGraph - * @param namespace The namespace that owns the registered task graph. (required) - * @param name The name of the task graph. (required) - * @param taskGraphSharing Namespace and list of permissions to share with. An empty list of permissions will remove the namespace; if permissions already exist they will be deleted then new ones added. In the event of a failure, the new policies will be rolled back to prevent partial policies, and it's likely the UDF will not be shared with the namespace at all. (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 UDF shared successfully -
404 UDF does not exist or user does not have permissions to share UDF -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call shareRegisteredTaskGraphCall(String namespace, String name, TaskGraphSharing taskGraphSharing, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = taskGraphSharing; - - // create path and map variables - String localVarPath = "/taskgraphs/{namespace}/registered/{name}/share" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call shareRegisteredTaskGraphValidateBeforeCall(String namespace, String name, TaskGraphSharing taskGraphSharing, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling shareRegisteredTaskGraph(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling shareRegisteredTaskGraph(Async)"); - } - - // verify the required parameter 'taskGraphSharing' is set - if (taskGraphSharing == null) { - throw new ApiException("Missing the required parameter 'taskGraphSharing' when calling shareRegisteredTaskGraph(Async)"); - } - - - okhttp3.Call localVarCall = shareRegisteredTaskGraphCall(namespace, name, taskGraphSharing, _callback); - return localVarCall; - - } - - /** - * - * Share a task graph. - * @param namespace The namespace that owns the registered task graph. (required) - * @param name The name of the task graph. (required) - * @param taskGraphSharing Namespace and list of permissions to share with. An empty list of permissions will remove the namespace; if permissions already exist they will be deleted then new ones added. In the event of a failure, the new policies will be rolled back to prevent partial policies, and it's likely the UDF will not be shared with the namespace at all. (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 UDF shared successfully -
404 UDF does not exist or user does not have permissions to share UDF -
502 Bad Gateway -
0 error response -
- */ - public void shareRegisteredTaskGraph(String namespace, String name, TaskGraphSharing taskGraphSharing) throws ApiException { - shareRegisteredTaskGraphWithHttpInfo(namespace, name, taskGraphSharing); - } - - /** - * - * Share a task graph. - * @param namespace The namespace that owns the registered task graph. (required) - * @param name The name of the task graph. (required) - * @param taskGraphSharing Namespace and list of permissions to share with. An empty list of permissions will remove the namespace; if permissions already exist they will be deleted then new ones added. In the event of a failure, the new policies will be rolled back to prevent partial policies, and it's likely the UDF will not be shared with the namespace at all. (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 UDF shared successfully -
404 UDF does not exist or user does not have permissions to share UDF -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse shareRegisteredTaskGraphWithHttpInfo(String namespace, String name, TaskGraphSharing taskGraphSharing) throws ApiException { - okhttp3.Call localVarCall = shareRegisteredTaskGraphValidateBeforeCall(namespace, name, taskGraphSharing, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Share a task graph. - * @param namespace The namespace that owns the registered task graph. (required) - * @param name The name of the task graph. (required) - * @param taskGraphSharing Namespace and list of permissions to share with. An empty list of permissions will remove the namespace; if permissions already exist they will be deleted then new ones added. In the event of a failure, the new policies will be rolled back to prevent partial policies, and it's likely the UDF will not be shared with the namespace at all. (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 UDF shared successfully -
404 UDF does not exist or user does not have permissions to share UDF -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call shareRegisteredTaskGraphAsync(String namespace, String name, TaskGraphSharing taskGraphSharing, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = shareRegisteredTaskGraphValidateBeforeCall(namespace, name, taskGraphSharing, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for updateRegisteredTaskGraph - * @param namespace The namespace that owns this registered UDF. (required) - * @param name The name of the registered task graph. (required) - * @param graph The new contents of the task graph. (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Task graph updated successfully. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateRegisteredTaskGraphCall(String namespace, String name, RegisteredTaskGraph graph, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = graph; - - // create path and map variables - String localVarPath = "/taskgraphs/{namespace}/registered/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call updateRegisteredTaskGraphValidateBeforeCall(String namespace, String name, RegisteredTaskGraph graph, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling updateRegisteredTaskGraph(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling updateRegisteredTaskGraph(Async)"); - } - - - okhttp3.Call localVarCall = updateRegisteredTaskGraphCall(namespace, name, graph, _callback); - return localVarCall; - - } - - /** - * - * Update the contents of an existing registered task graph. - * @param namespace The namespace that owns this registered UDF. (required) - * @param name The name of the registered task graph. (required) - * @param graph The new contents of the task graph. (optional) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Task graph updated successfully. -
502 Bad Gateway -
0 error response -
- */ - public void updateRegisteredTaskGraph(String namespace, String name, RegisteredTaskGraph graph) throws ApiException { - updateRegisteredTaskGraphWithHttpInfo(namespace, name, graph); - } - - /** - * - * Update the contents of an existing registered task graph. - * @param namespace The namespace that owns this registered UDF. (required) - * @param name The name of the registered task graph. (required) - * @param graph The new contents of the task graph. (optional) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Task graph updated successfully. -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse updateRegisteredTaskGraphWithHttpInfo(String namespace, String name, RegisteredTaskGraph graph) throws ApiException { - okhttp3.Call localVarCall = updateRegisteredTaskGraphValidateBeforeCall(namespace, name, graph, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Update the contents of an existing registered task graph. - * @param namespace The namespace that owns this registered UDF. (required) - * @param name The name of the registered task graph. (required) - * @param graph The new contents of the task graph. (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Task graph updated successfully. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateRegisteredTaskGraphAsync(String namespace, String name, RegisteredTaskGraph graph, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = updateRegisteredTaskGraphValidateBeforeCall(namespace, name, graph, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/api/SqlApi.java b/src/main/java/io/tiledb/cloud/rest_api/v1/api/SqlApi.java deleted file mode 100644 index 249d5e6..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/api/SqlApi.java +++ /dev/null @@ -1,269 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.api; - -import io.tiledb.cloud.rest_api.v1.Configuration; -import io.tiledb.cloud.rest_api.v1.model.SQLParameters; -import io.tiledb.cloud.rest_api.v1.ApiCallback; -import io.tiledb.cloud.rest_api.v1.ApiClient; -import io.tiledb.cloud.rest_api.v1.ApiException; -import io.tiledb.cloud.rest_api.v1.ApiResponse; -import io.tiledb.cloud.rest_api.v1.Pair; - -import com.google.gson.reflect.TypeToken; - - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class SqlApi { - private ApiClient localVarApiClient; - private int localHostIndex; - private String localCustomBaseUrl; - - public SqlApi() { - this(Configuration.getDefaultApiClient()); - } - - public SqlApi(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public ApiClient getApiClient() { - return localVarApiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public int getHostIndex() { - return localHostIndex; - } - - public void setHostIndex(int hostIndex) { - this.localHostIndex = hostIndex; - } - - public String getCustomBaseUrl() { - return localCustomBaseUrl; - } - - public void setCustomBaseUrl(String customBaseUrl) { - this.localCustomBaseUrl = customBaseUrl; - } - - /** - * Build call for runSQL - * @param namespace namespace to run task under is in (an organization name or user's username) (required) - * @param sql sql being submitted (required) - * @param acceptEncoding Encoding to use (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 JSON results in array of objects form, if the query returns results * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
204 SQL executed successfully * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call runSQLCall(String namespace, SQLParameters sql, String acceptEncoding, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = sql; - - // create path and map variables - String localVarPath = "/sql/{namespace}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (acceptEncoding != null) { - localVarHeaderParams.put("Accept-Encoding", localVarApiClient.parameterToString(acceptEncoding)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call runSQLValidateBeforeCall(String namespace, SQLParameters sql, String acceptEncoding, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling runSQL(Async)"); - } - - // verify the required parameter 'sql' is set - if (sql == null) { - throw new ApiException("Missing the required parameter 'sql' when calling runSQL(Async)"); - } - - - okhttp3.Call localVarCall = runSQLCall(namespace, sql, acceptEncoding, _callback); - return localVarCall; - - } - - /** - * - * Run a sql query - * @param namespace namespace to run task under is in (an organization name or user's username) (required) - * @param sql sql being submitted (required) - * @param acceptEncoding Encoding to use (optional) - * @return ApiResponse with byte[] - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 JSON results in array of objects form, if the query returns results * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
204 SQL executed successfully * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
0 error response -
- */ - public ApiResponse runSQLWithHttpInfoBytes(String namespace, SQLParameters sql, String acceptEncoding) throws ApiException { - okhttp3.Call localVarCall = runSQLValidateBeforeCall(namespace, sql, acceptEncoding, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * - * Run a sql query - * @param namespace namespace to run task under is in (an organization name or user's username) (required) - * @param sql sql being submitted (required) - * @param acceptEncoding Encoding to use (optional) - * @return byte[] - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 JSON results in array of objects form, if the query returns results * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
204 SQL executed successfully * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
0 error response -
- */ - public byte[] runSQLBytes(String namespace, SQLParameters sql, String acceptEncoding) throws ApiException { - ApiResponse localVarResp = runSQLWithHttpInfoBytes(namespace, sql, acceptEncoding); - return localVarResp.getData(); - } - - /** - * - * Run a sql query - * @param namespace namespace to run task under is in (an organization name or user's username) (required) - * @param sql sql being submitted (required) - * @param acceptEncoding Encoding to use (optional) - * @return List<Object> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 JSON results in array of objects form, if the query returns results * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
204 SQL executed successfully * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response -
- */ - public List runSQL(String namespace, SQLParameters sql, String acceptEncoding) throws ApiException { - ApiResponse> localVarResp = runSQLWithHttpInfo(namespace, sql, acceptEncoding); - return localVarResp.getData(); - } - - /** - * - * Run a sql query - * @param namespace namespace to run task under is in (an organization name or user's username) (required) - * @param sql sql being submitted (required) - * @param acceptEncoding Encoding to use (optional) - * @return ApiResponse<List<Object>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 JSON results in array of objects form, if the query returns results * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
204 SQL executed successfully * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response -
- */ - public ApiResponse> runSQLWithHttpInfo(String namespace, SQLParameters sql, String acceptEncoding) throws ApiException { - okhttp3.Call localVarCall = runSQLValidateBeforeCall(namespace, sql, acceptEncoding, null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Run a sql query - * @param namespace namespace to run task under is in (an organization name or user's username) (required) - * @param sql sql being submitted (required) - * @param acceptEncoding Encoding to use (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 JSON results in array of objects form, if the query returns results * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
204 SQL executed successfully * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call runSQLAsync(String namespace, SQLParameters sql, String acceptEncoding, final ApiCallback> _callback) throws ApiException { - - okhttp3.Call localVarCall = runSQLValidateBeforeCall(namespace, sql, acceptEncoding, _callback); - Type localVarReturnType = new TypeToken>(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/api/StatsApi.java b/src/main/java/io/tiledb/cloud/rest_api/v1/api/StatsApi.java deleted file mode 100644 index f729178..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/api/StatsApi.java +++ /dev/null @@ -1,195 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.api; - -import io.tiledb.cloud.rest_api.v1.model.GetTiledbStats200Response; -import io.tiledb.cloud.rest_api.v1.ApiCallback; -import io.tiledb.cloud.rest_api.v1.ApiClient; -import io.tiledb.cloud.rest_api.v1.ApiException; -import io.tiledb.cloud.rest_api.v1.ApiResponse; -import io.tiledb.cloud.rest_api.v1.Configuration; -import io.tiledb.cloud.rest_api.v1.Pair; - -import com.google.gson.reflect.TypeToken; - - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class StatsApi { - private ApiClient localVarApiClient; - private int localHostIndex; - private String localCustomBaseUrl; - - public StatsApi() { - this(Configuration.getDefaultApiClient()); - } - - public StatsApi(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public ApiClient getApiClient() { - return localVarApiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public int getHostIndex() { - return localHostIndex; - } - - public void setHostIndex(int hostIndex) { - this.localHostIndex = hostIndex; - } - - public String getCustomBaseUrl() { - return localCustomBaseUrl; - } - - public void setCustomBaseUrl(String customBaseUrl) { - this.localCustomBaseUrl = customBaseUrl; - } - - /** - * Build call for getTiledbStats - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 stats -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getTiledbStatsCall(final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/.stats"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getTiledbStatsValidateBeforeCall(final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = getTiledbStatsCall(_callback); - return localVarCall; - - } - - /** - * - * Fetch libtiledb stat - * @return GetTiledbStats200Response - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 stats -
502 Bad Gateway -
0 error response -
- */ - public GetTiledbStats200Response getTiledbStats() throws ApiException { - ApiResponse localVarResp = getTiledbStatsWithHttpInfo(); - return localVarResp.getData(); - } - - /** - * - * Fetch libtiledb stat - * @return ApiResponse<GetTiledbStats200Response> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 stats -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getTiledbStatsWithHttpInfo() throws ApiException { - okhttp3.Call localVarCall = getTiledbStatsValidateBeforeCall(null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch libtiledb stat - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 stats -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getTiledbStatsAsync(final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getTiledbStatsValidateBeforeCall(_callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/api/TaskGraphLogsApi.java b/src/main/java/io/tiledb/cloud/rest_api/v1/api/TaskGraphLogsApi.java deleted file mode 100644 index b804e8b..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/api/TaskGraphLogsApi.java +++ /dev/null @@ -1,1424 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.api; - -import io.tiledb.cloud.rest_api.v1.model.TaskGraphClientNodeStatus; -import io.tiledb.cloud.rest_api.v1.model.TaskGraphLog; -import io.tiledb.cloud.rest_api.v1.model.TaskGraphLogsData; -import io.tiledb.cloud.rest_api.v1.ApiCallback; -import io.tiledb.cloud.rest_api.v1.ApiClient; -import io.tiledb.cloud.rest_api.v1.ApiException; -import io.tiledb.cloud.rest_api.v1.ApiResponse; -import io.tiledb.cloud.rest_api.v1.Configuration; -import io.tiledb.cloud.rest_api.v1.Pair; - -import com.google.gson.reflect.TypeToken; - - -import java.time.OffsetDateTime; - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class TaskGraphLogsApi { - private ApiClient localVarApiClient; - private int localHostIndex; - private String localCustomBaseUrl; - - public TaskGraphLogsApi() { - this(Configuration.getDefaultApiClient()); - } - - public TaskGraphLogsApi(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public ApiClient getApiClient() { - return localVarApiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public int getHostIndex() { - return localHostIndex; - } - - public void setHostIndex(int hostIndex) { - this.localHostIndex = hostIndex; - } - - public String getCustomBaseUrl() { - return localCustomBaseUrl; - } - - public void setCustomBaseUrl(String customBaseUrl) { - this.localCustomBaseUrl = customBaseUrl; - } - - /** - * Build call for createTaskGraphLog - * @param namespace The namespace that will own this task graph log. (required) - * @param log (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
201 The task graph was created. The returned TaskGraphLog will include the data the client sent, with the server-defined fields added in. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call createTaskGraphLogCall(String namespace, TaskGraphLog log, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = log; - - // create path and map variables - String localVarPath = "/taskgraphs/{namespace}/log" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call createTaskGraphLogValidateBeforeCall(String namespace, TaskGraphLog log, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling createTaskGraphLog(Async)"); - } - - // verify the required parameter 'log' is set - if (log == null) { - throw new ApiException("Missing the required parameter 'log' when calling createTaskGraphLog(Async)"); - } - - - okhttp3.Call localVarCall = createTaskGraphLogCall(namespace, log, _callback); - return localVarCall; - - } - - /** - * - * Create a task graph log. - * @param namespace The namespace that will own this task graph log. (required) - * @param log (required) - * @return TaskGraphLog - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
201 The task graph was created. The returned TaskGraphLog will include the data the client sent, with the server-defined fields added in. -
502 Bad Gateway -
0 error response -
- */ - public TaskGraphLog createTaskGraphLog(String namespace, TaskGraphLog log) throws ApiException { - ApiResponse localVarResp = createTaskGraphLogWithHttpInfo(namespace, log); - return localVarResp.getData(); - } - - /** - * - * Create a task graph log. - * @param namespace The namespace that will own this task graph log. (required) - * @param log (required) - * @return ApiResponse<TaskGraphLog> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
201 The task graph was created. The returned TaskGraphLog will include the data the client sent, with the server-defined fields added in. -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse createTaskGraphLogWithHttpInfo(String namespace, TaskGraphLog log) throws ApiException { - okhttp3.Call localVarCall = createTaskGraphLogValidateBeforeCall(namespace, log, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Create a task graph log. - * @param namespace The namespace that will own this task graph log. (required) - * @param log (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
201 The task graph was created. The returned TaskGraphLog will include the data the client sent, with the server-defined fields added in. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call createTaskGraphLogAsync(String namespace, TaskGraphLog log, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = createTaskGraphLogValidateBeforeCall(namespace, log, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getTaskGraphLog - * @param namespace The namespace that owns this task graph log. (required) - * @param id The UUID of the task graph log entry. (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Information about the execution of a single task graph. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getTaskGraphLogCall(String namespace, String id, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/taskgraphs/{namespace}/logs/{id}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "id" + "\\}", localVarApiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getTaskGraphLogValidateBeforeCall(String namespace, String id, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getTaskGraphLog(Async)"); - } - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getTaskGraphLog(Async)"); - } - - - okhttp3.Call localVarCall = getTaskGraphLogCall(namespace, id, _callback); - return localVarCall; - - } - - /** - * - * Fetch information about a single task graph execution. - * @param namespace The namespace that owns this task graph log. (required) - * @param id The UUID of the task graph log entry. (required) - * @return TaskGraphLog - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Information about the execution of a single task graph. -
502 Bad Gateway -
0 error response -
- */ - public TaskGraphLog getTaskGraphLog(String namespace, String id) throws ApiException { - ApiResponse localVarResp = getTaskGraphLogWithHttpInfo(namespace, id); - return localVarResp.getData(); - } - - /** - * - * Fetch information about a single task graph execution. - * @param namespace The namespace that owns this task graph log. (required) - * @param id The UUID of the task graph log entry. (required) - * @return ApiResponse<TaskGraphLog> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Information about the execution of a single task graph. -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getTaskGraphLogWithHttpInfo(String namespace, String id) throws ApiException { - okhttp3.Call localVarCall = getTaskGraphLogValidateBeforeCall(namespace, id, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch information about a single task graph execution. - * @param namespace The namespace that owns this task graph log. (required) - * @param id The UUID of the task graph log entry. (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Information about the execution of a single task graph. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getTaskGraphLogAsync(String namespace, String id, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getTaskGraphLogValidateBeforeCall(namespace, id, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for listTaskGraphLogs - * @param namespace Include logs for this namespace. (optional) - * @param createdBy Include logs from only this user. (optional) - * @param search search string that will look at name. (optional) - * @param startTime Include logs created after this time. (optional) - * @param endTime Include logs created before this time. (optional) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 The task graph logs that matched the user's query. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listTaskGraphLogsCall(String namespace, String createdBy, String search, OffsetDateTime startTime, OffsetDateTime endTime, Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/taskgraphs/logs"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (namespace != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("namespace", namespace)); - } - - if (createdBy != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("created_by", createdBy)); - } - - if (search != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("search", search)); - } - - if (startTime != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("start_time", startTime)); - } - - if (endTime != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("end_time", endTime)); - } - - if (page != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("page", page)); - } - - if (perPage != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("per_page", perPage)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call listTaskGraphLogsValidateBeforeCall(String namespace, String createdBy, String search, OffsetDateTime startTime, OffsetDateTime endTime, Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = listTaskGraphLogsCall(namespace, createdBy, search, startTime, endTime, page, perPage, _callback); - return localVarCall; - - } - - /** - * - * Fetch the task graph logs of a namespace the user has access to. The returned entries will include only summary data, and will not include information about the individual tasks that were executed. (This information is available when requesting an individual task graph log.) Entries in the response are ordered from newest to oldest. Pagination parameters work as in other API methods; see PaginationMetadata. - * @param namespace Include logs for this namespace. (optional) - * @param createdBy Include logs from only this user. (optional) - * @param search search string that will look at name. (optional) - * @param startTime Include logs created after this time. (optional) - * @param endTime Include logs created before this time. (optional) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @return TaskGraphLogsData - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 The task graph logs that matched the user's query. -
502 Bad Gateway -
0 error response -
- */ - public TaskGraphLogsData listTaskGraphLogs(String namespace, String createdBy, String search, OffsetDateTime startTime, OffsetDateTime endTime, Integer page, Integer perPage) throws ApiException { - ApiResponse localVarResp = listTaskGraphLogsWithHttpInfo(namespace, createdBy, search, startTime, endTime, page, perPage); - return localVarResp.getData(); - } - - /** - * - * Fetch the task graph logs of a namespace the user has access to. The returned entries will include only summary data, and will not include information about the individual tasks that were executed. (This information is available when requesting an individual task graph log.) Entries in the response are ordered from newest to oldest. Pagination parameters work as in other API methods; see PaginationMetadata. - * @param namespace Include logs for this namespace. (optional) - * @param createdBy Include logs from only this user. (optional) - * @param search search string that will look at name. (optional) - * @param startTime Include logs created after this time. (optional) - * @param endTime Include logs created before this time. (optional) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @return ApiResponse<TaskGraphLogsData> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 The task graph logs that matched the user's query. -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse listTaskGraphLogsWithHttpInfo(String namespace, String createdBy, String search, OffsetDateTime startTime, OffsetDateTime endTime, Integer page, Integer perPage) throws ApiException { - okhttp3.Call localVarCall = listTaskGraphLogsValidateBeforeCall(namespace, createdBy, search, startTime, endTime, page, perPage, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch the task graph logs of a namespace the user has access to. The returned entries will include only summary data, and will not include information about the individual tasks that were executed. (This information is available when requesting an individual task graph log.) Entries in the response are ordered from newest to oldest. Pagination parameters work as in other API methods; see PaginationMetadata. - * @param namespace Include logs for this namespace. (optional) - * @param createdBy Include logs from only this user. (optional) - * @param search search string that will look at name. (optional) - * @param startTime Include logs created after this time. (optional) - * @param endTime Include logs created before this time. (optional) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 The task graph logs that matched the user's query. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listTaskGraphLogsAsync(String namespace, String createdBy, String search, OffsetDateTime startTime, OffsetDateTime endTime, Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = listTaskGraphLogsValidateBeforeCall(namespace, createdBy, search, startTime, endTime, page, perPage, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for reportClientNode - * @param namespace The namespace that owns this task graph log. (required) - * @param id The UUID of the task graph log entry. (required) - * @param report The node status to report. (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Status reported successfully. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call reportClientNodeCall(String namespace, String id, TaskGraphClientNodeStatus report, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = report; - - // create path and map variables - String localVarPath = "/taskgraphs/{namespace}/logs/{id}/report_client_node" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "id" + "\\}", localVarApiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call reportClientNodeValidateBeforeCall(String namespace, String id, TaskGraphClientNodeStatus report, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling reportClientNode(Async)"); - } - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling reportClientNode(Async)"); - } - - // verify the required parameter 'report' is set - if (report == null) { - throw new ApiException("Missing the required parameter 'report' when calling reportClientNode(Async)"); - } - - - okhttp3.Call localVarCall = reportClientNodeCall(namespace, id, report, _callback); - return localVarCall; - - } - - /** - * - * - * @param namespace The namespace that owns this task graph log. (required) - * @param id The UUID of the task graph log entry. (required) - * @param report The node status to report. (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Status reported successfully. -
502 Bad Gateway -
0 error response -
- */ - public void reportClientNode(String namespace, String id, TaskGraphClientNodeStatus report) throws ApiException { - reportClientNodeWithHttpInfo(namespace, id, report); - } - - /** - * - * - * @param namespace The namespace that owns this task graph log. (required) - * @param id The UUID of the task graph log entry. (required) - * @param report The node status to report. (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Status reported successfully. -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse reportClientNodeWithHttpInfo(String namespace, String id, TaskGraphClientNodeStatus report) throws ApiException { - okhttp3.Call localVarCall = reportClientNodeValidateBeforeCall(namespace, id, report, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * - * @param namespace The namespace that owns this task graph log. (required) - * @param id The UUID of the task graph log entry. (required) - * @param report The node status to report. (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Status reported successfully. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call reportClientNodeAsync(String namespace, String id, TaskGraphClientNodeStatus report, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = reportClientNodeValidateBeforeCall(namespace, id, report, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for resubmitTaskGraphExecution - * @param namespace The namespace that owns this task graph execution. (required) - * @param id The UUID of the task graph execution (TaskGraphLog). (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
202 Information about the task graph execution. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call resubmitTaskGraphExecutionCall(String namespace, String id, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/taskgraphs/{namespace}/executions/{id}/resubmit" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "id" + "\\}", localVarApiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call resubmitTaskGraphExecutionValidateBeforeCall(String namespace, String id, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling resubmitTaskGraphExecution(Async)"); - } - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling resubmitTaskGraphExecution(Async)"); - } - - - okhttp3.Call localVarCall = resubmitTaskGraphExecutionCall(namespace, id, _callback); - return localVarCall; - - } - - /** - * - * Resubmits a task graph in the given namespace using the associated execution id. - * @param namespace The namespace that owns this task graph execution. (required) - * @param id The UUID of the task graph execution (TaskGraphLog). (required) - * @return TaskGraphLog - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
202 Information about the task graph execution. -
502 Bad Gateway -
0 error response -
- */ - public TaskGraphLog resubmitTaskGraphExecution(String namespace, String id) throws ApiException { - ApiResponse localVarResp = resubmitTaskGraphExecutionWithHttpInfo(namespace, id); - return localVarResp.getData(); - } - - /** - * - * Resubmits a task graph in the given namespace using the associated execution id. - * @param namespace The namespace that owns this task graph execution. (required) - * @param id The UUID of the task graph execution (TaskGraphLog). (required) - * @return ApiResponse<TaskGraphLog> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
202 Information about the task graph execution. -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse resubmitTaskGraphExecutionWithHttpInfo(String namespace, String id) throws ApiException { - okhttp3.Call localVarCall = resubmitTaskGraphExecutionValidateBeforeCall(namespace, id, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Resubmits a task graph in the given namespace using the associated execution id. - * @param namespace The namespace that owns this task graph execution. (required) - * @param id The UUID of the task graph execution (TaskGraphLog). (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
202 Information about the task graph execution. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call resubmitTaskGraphExecutionAsync(String namespace, String id, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = resubmitTaskGraphExecutionValidateBeforeCall(namespace, id, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for retryTaskGraphExecution - * @param namespace The namespace that owns this task graph execution. (required) - * @param id The UUID of the task graph execution (TaskGraphLog). (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
202 Information about the task graph execution. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call retryTaskGraphExecutionCall(String namespace, String id, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/taskgraphs/{namespace}/executions/{id}/retry" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "id" + "\\}", localVarApiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call retryTaskGraphExecutionValidateBeforeCall(String namespace, String id, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling retryTaskGraphExecution(Async)"); - } - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling retryTaskGraphExecution(Async)"); - } - - - okhttp3.Call localVarCall = retryTaskGraphExecutionCall(namespace, id, _callback); - return localVarCall; - - } - - /** - * - * Retries failed tasks of a task graph in the given namespace using the associated execution id. - * @param namespace The namespace that owns this task graph execution. (required) - * @param id The UUID of the task graph execution (TaskGraphLog). (required) - * @return TaskGraphLog - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
202 Information about the task graph execution. -
502 Bad Gateway -
0 error response -
- */ - public TaskGraphLog retryTaskGraphExecution(String namespace, String id) throws ApiException { - ApiResponse localVarResp = retryTaskGraphExecutionWithHttpInfo(namespace, id); - return localVarResp.getData(); - } - - /** - * - * Retries failed tasks of a task graph in the given namespace using the associated execution id. - * @param namespace The namespace that owns this task graph execution. (required) - * @param id The UUID of the task graph execution (TaskGraphLog). (required) - * @return ApiResponse<TaskGraphLog> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
202 Information about the task graph execution. -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse retryTaskGraphExecutionWithHttpInfo(String namespace, String id) throws ApiException { - okhttp3.Call localVarCall = retryTaskGraphExecutionValidateBeforeCall(namespace, id, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Retries failed tasks of a task graph in the given namespace using the associated execution id. - * @param namespace The namespace that owns this task graph execution. (required) - * @param id The UUID of the task graph execution (TaskGraphLog). (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
202 Information about the task graph execution. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call retryTaskGraphExecutionAsync(String namespace, String id, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = retryTaskGraphExecutionValidateBeforeCall(namespace, id, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for stopTaskGraphExecution - * @param namespace The namespace that owns this task graph execution. (required) - * @param id The UUID of the task graph execution (TaskGraphLog). (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
202 Information about the task graph execution. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call stopTaskGraphExecutionCall(String namespace, String id, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/taskgraphs/{namespace}/executions/{id}/stop" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "id" + "\\}", localVarApiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call stopTaskGraphExecutionValidateBeforeCall(String namespace, String id, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling stopTaskGraphExecution(Async)"); - } - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling stopTaskGraphExecution(Async)"); - } - - - okhttp3.Call localVarCall = stopTaskGraphExecutionCall(namespace, id, _callback); - return localVarCall; - - } - - /** - * - * Stops a task graph execution in the given namespace using the associated associated execution id. - * @param namespace The namespace that owns this task graph execution. (required) - * @param id The UUID of the task graph execution (TaskGraphLog). (required) - * @return TaskGraphLog - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
202 Information about the task graph execution. -
502 Bad Gateway -
0 error response -
- */ - public TaskGraphLog stopTaskGraphExecution(String namespace, String id) throws ApiException { - ApiResponse localVarResp = stopTaskGraphExecutionWithHttpInfo(namespace, id); - return localVarResp.getData(); - } - - /** - * - * Stops a task graph execution in the given namespace using the associated associated execution id. - * @param namespace The namespace that owns this task graph execution. (required) - * @param id The UUID of the task graph execution (TaskGraphLog). (required) - * @return ApiResponse<TaskGraphLog> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
202 Information about the task graph execution. -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse stopTaskGraphExecutionWithHttpInfo(String namespace, String id) throws ApiException { - okhttp3.Call localVarCall = stopTaskGraphExecutionValidateBeforeCall(namespace, id, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Stops a task graph execution in the given namespace using the associated associated execution id. - * @param namespace The namespace that owns this task graph execution. (required) - * @param id The UUID of the task graph execution (TaskGraphLog). (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
202 Information about the task graph execution. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call stopTaskGraphExecutionAsync(String namespace, String id, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = stopTaskGraphExecutionValidateBeforeCall(namespace, id, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for submitTaskGraph - * @param namespace The namespace that owns this task graph. (required) - * @param id The UUID of the task graph entry. (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
202 Information about the execution of a single task graph. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call submitTaskGraphCall(String namespace, String id, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/taskgraphs/{namespace}/graphs/{id}/submit" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "id" + "\\}", localVarApiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call submitTaskGraphValidateBeforeCall(String namespace, String id, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling submitTaskGraph(Async)"); - } - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling submitTaskGraph(Async)"); - } - - - okhttp3.Call localVarCall = submitTaskGraphCall(namespace, id, _callback); - return localVarCall; - - } - - /** - * - * Submit a single task graph for execution. - * @param namespace The namespace that owns this task graph. (required) - * @param id The UUID of the task graph entry. (required) - * @return TaskGraphLog - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
202 Information about the execution of a single task graph. -
502 Bad Gateway -
0 error response -
- */ - public TaskGraphLog submitTaskGraph(String namespace, String id) throws ApiException { - ApiResponse localVarResp = submitTaskGraphWithHttpInfo(namespace, id); - return localVarResp.getData(); - } - - /** - * - * Submit a single task graph for execution. - * @param namespace The namespace that owns this task graph. (required) - * @param id The UUID of the task graph entry. (required) - * @return ApiResponse<TaskGraphLog> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
202 Information about the execution of a single task graph. -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse submitTaskGraphWithHttpInfo(String namespace, String id) throws ApiException { - okhttp3.Call localVarCall = submitTaskGraphValidateBeforeCall(namespace, id, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Submit a single task graph for execution. - * @param namespace The namespace that owns this task graph. (required) - * @param id The UUID of the task graph entry. (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
202 Information about the execution of a single task graph. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call submitTaskGraphAsync(String namespace, String id, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = submitTaskGraphValidateBeforeCall(namespace, id, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for updateTaskGraphLog - * @param namespace The namespace that owns this task graph log. (required) - * @param id The UUID of the task graph log entry. (required) - * @param log Updates to make to the task graph log. The only manual update that a client should need to make to a task graph log is to update its completion status to `succeeded`, `failed`, or `cancelled`. (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Log entry updated successfully. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateTaskGraphLogCall(String namespace, String id, TaskGraphLog log, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = log; - - // create path and map variables - String localVarPath = "/taskgraphs/{namespace}/logs/{id}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "id" + "\\}", localVarApiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call updateTaskGraphLogValidateBeforeCall(String namespace, String id, TaskGraphLog log, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling updateTaskGraphLog(Async)"); - } - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling updateTaskGraphLog(Async)"); - } - - // verify the required parameter 'log' is set - if (log == null) { - throw new ApiException("Missing the required parameter 'log' when calling updateTaskGraphLog(Async)"); - } - - - okhttp3.Call localVarCall = updateTaskGraphLogCall(namespace, id, log, _callback); - return localVarCall; - - } - - /** - * - * Update information about a single task graph execution. - * @param namespace The namespace that owns this task graph log. (required) - * @param id The UUID of the task graph log entry. (required) - * @param log Updates to make to the task graph log. The only manual update that a client should need to make to a task graph log is to update its completion status to `succeeded`, `failed`, or `cancelled`. (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Log entry updated successfully. -
502 Bad Gateway -
0 error response -
- */ - public void updateTaskGraphLog(String namespace, String id, TaskGraphLog log) throws ApiException { - updateTaskGraphLogWithHttpInfo(namespace, id, log); - } - - /** - * - * Update information about a single task graph execution. - * @param namespace The namespace that owns this task graph log. (required) - * @param id The UUID of the task graph log entry. (required) - * @param log Updates to make to the task graph log. The only manual update that a client should need to make to a task graph log is to update its completion status to `succeeded`, `failed`, or `cancelled`. (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Log entry updated successfully. -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse updateTaskGraphLogWithHttpInfo(String namespace, String id, TaskGraphLog log) throws ApiException { - okhttp3.Call localVarCall = updateTaskGraphLogValidateBeforeCall(namespace, id, log, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Update information about a single task graph execution. - * @param namespace The namespace that owns this task graph log. (required) - * @param id The UUID of the task graph log entry. (required) - * @param log Updates to make to the task graph log. The only manual update that a client should need to make to a task graph log is to update its completion status to `succeeded`, `failed`, or `cancelled`. (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Log entry updated successfully. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateTaskGraphLogAsync(String namespace, String id, TaskGraphLog log, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = updateTaskGraphLogValidateBeforeCall(namespace, id, log, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/api/TaskGraphsApi.java b/src/main/java/io/tiledb/cloud/rest_api/v1/api/TaskGraphsApi.java deleted file mode 100644 index 3f06f37..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/api/TaskGraphsApi.java +++ /dev/null @@ -1,791 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.api; - -import io.tiledb.cloud.rest_api.v1.model.TaskGraph; -import io.tiledb.cloud.rest_api.v1.model.TaskGraphLog; -import io.tiledb.cloud.rest_api.v1.model.TaskGraphs; -import io.tiledb.cloud.rest_api.v1.ApiCallback; -import io.tiledb.cloud.rest_api.v1.ApiClient; -import io.tiledb.cloud.rest_api.v1.ApiException; -import io.tiledb.cloud.rest_api.v1.ApiResponse; -import io.tiledb.cloud.rest_api.v1.Configuration; -import io.tiledb.cloud.rest_api.v1.Pair; - -import com.google.gson.reflect.TypeToken; - - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class TaskGraphsApi { - private ApiClient localVarApiClient; - private int localHostIndex; - private String localCustomBaseUrl; - - public TaskGraphsApi() { - this(Configuration.getDefaultApiClient()); - } - - public TaskGraphsApi(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public ApiClient getApiClient() { - return localVarApiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public int getHostIndex() { - return localHostIndex; - } - - public void setHostIndex(int hostIndex) { - this.localHostIndex = hostIndex; - } - - public String getCustomBaseUrl() { - return localCustomBaseUrl; - } - - public void setCustomBaseUrl(String customBaseUrl) { - this.localCustomBaseUrl = customBaseUrl; - } - - /** - * Build call for createTaskGraph - * @param namespace Include graphs for this namespace. (required) - * @param graph Create the task graph. (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
201 Task graph created successfully. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call createTaskGraphCall(String namespace, TaskGraph graph, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = graph; - - // create path and map variables - String localVarPath = "/taskgraphs/{namespace}/graphs" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call createTaskGraphValidateBeforeCall(String namespace, TaskGraph graph, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling createTaskGraph(Async)"); - } - - // verify the required parameter 'graph' is set - if (graph == null) { - throw new ApiException("Missing the required parameter 'graph' when calling createTaskGraph(Async)"); - } - - - okhttp3.Call localVarCall = createTaskGraphCall(namespace, graph, _callback); - return localVarCall; - - } - - /** - * - * Create a single task graph for execution. - * @param namespace Include graphs for this namespace. (required) - * @param graph Create the task graph. (required) - * @return TaskGraph - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
201 Task graph created successfully. -
502 Bad Gateway -
0 error response -
- */ - public TaskGraph createTaskGraph(String namespace, TaskGraph graph) throws ApiException { - ApiResponse localVarResp = createTaskGraphWithHttpInfo(namespace, graph); - return localVarResp.getData(); - } - - /** - * - * Create a single task graph for execution. - * @param namespace Include graphs for this namespace. (required) - * @param graph Create the task graph. (required) - * @return ApiResponse<TaskGraph> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
201 Task graph created successfully. -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse createTaskGraphWithHttpInfo(String namespace, TaskGraph graph) throws ApiException { - okhttp3.Call localVarCall = createTaskGraphValidateBeforeCall(namespace, graph, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Create a single task graph for execution. - * @param namespace Include graphs for this namespace. (required) - * @param graph Create the task graph. (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
201 Task graph created successfully. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call createTaskGraphAsync(String namespace, TaskGraph graph, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = createTaskGraphValidateBeforeCall(namespace, graph, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getTaskGraph - * @param namespace The namespace that owns this task graph. (required) - * @param id The UUID of the task graph entry. (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Information about the single task graph. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getTaskGraphCall(String namespace, String id, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/taskgraphs/{namespace}/graphs/{id}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "id" + "\\}", localVarApiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getTaskGraphValidateBeforeCall(String namespace, String id, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getTaskGraph(Async)"); - } - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getTaskGraph(Async)"); - } - - - okhttp3.Call localVarCall = getTaskGraphCall(namespace, id, _callback); - return localVarCall; - - } - - /** - * - * Fetch information about a single task graph. - * @param namespace The namespace that owns this task graph. (required) - * @param id The UUID of the task graph entry. (required) - * @return TaskGraph - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Information about the single task graph. -
502 Bad Gateway -
0 error response -
- */ - public TaskGraph getTaskGraph(String namespace, String id) throws ApiException { - ApiResponse localVarResp = getTaskGraphWithHttpInfo(namespace, id); - return localVarResp.getData(); - } - - /** - * - * Fetch information about a single task graph. - * @param namespace The namespace that owns this task graph. (required) - * @param id The UUID of the task graph entry. (required) - * @return ApiResponse<TaskGraph> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Information about the single task graph. -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getTaskGraphWithHttpInfo(String namespace, String id) throws ApiException { - okhttp3.Call localVarCall = getTaskGraphValidateBeforeCall(namespace, id, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch information about a single task graph. - * @param namespace The namespace that owns this task graph. (required) - * @param id The UUID of the task graph entry. (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Information about the single task graph. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getTaskGraphAsync(String namespace, String id, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getTaskGraphValidateBeforeCall(namespace, id, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for listTaskGraphs - * @param namespace Namespace for graphs (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 The task graphs that matched the user's query. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listTaskGraphsCall(String namespace, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/taskgraphs/{namespace}/graphs" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call listTaskGraphsValidateBeforeCall(String namespace, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling listTaskGraphs(Async)"); - } - - - okhttp3.Call localVarCall = listTaskGraphsCall(namespace, _callback); - return localVarCall; - - } - - /** - * - * Fetch the task graphs of a namespace the user has access to. The returned entries will include only summary data, and will not include information about the individual tasks that were executed. (This information is available when requesting an individual task graph log.) Entries in the response are ordered from newest to oldest. Pagination parameters work as in other API methods; see PaginationMetadata. - * @param namespace Namespace for graphs (required) - * @return TaskGraphs - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 The task graphs that matched the user's query. -
502 Bad Gateway -
0 error response -
- */ - public TaskGraphs listTaskGraphs(String namespace) throws ApiException { - ApiResponse localVarResp = listTaskGraphsWithHttpInfo(namespace); - return localVarResp.getData(); - } - - /** - * - * Fetch the task graphs of a namespace the user has access to. The returned entries will include only summary data, and will not include information about the individual tasks that were executed. (This information is available when requesting an individual task graph log.) Entries in the response are ordered from newest to oldest. Pagination parameters work as in other API methods; see PaginationMetadata. - * @param namespace Namespace for graphs (required) - * @return ApiResponse<TaskGraphs> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 The task graphs that matched the user's query. -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse listTaskGraphsWithHttpInfo(String namespace) throws ApiException { - okhttp3.Call localVarCall = listTaskGraphsValidateBeforeCall(namespace, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch the task graphs of a namespace the user has access to. The returned entries will include only summary data, and will not include information about the individual tasks that were executed. (This information is available when requesting an individual task graph log.) Entries in the response are ordered from newest to oldest. Pagination parameters work as in other API methods; see PaginationMetadata. - * @param namespace Namespace for graphs (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 The task graphs that matched the user's query. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call listTaskGraphsAsync(String namespace, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = listTaskGraphsValidateBeforeCall(namespace, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for submitTaskGraph - * @param namespace The namespace that owns this task graph. (required) - * @param id The UUID of the task graph entry. (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
202 Information about the execution of a single task graph. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call submitTaskGraphCall(String namespace, String id, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/taskgraphs/{namespace}/graphs/{id}/submit" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "id" + "\\}", localVarApiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call submitTaskGraphValidateBeforeCall(String namespace, String id, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling submitTaskGraph(Async)"); - } - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling submitTaskGraph(Async)"); - } - - - okhttp3.Call localVarCall = submitTaskGraphCall(namespace, id, _callback); - return localVarCall; - - } - - /** - * - * Submit a single task graph for execution. - * @param namespace The namespace that owns this task graph. (required) - * @param id The UUID of the task graph entry. (required) - * @return TaskGraphLog - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
202 Information about the execution of a single task graph. -
502 Bad Gateway -
0 error response -
- */ - public TaskGraphLog submitTaskGraph(String namespace, String id) throws ApiException { - ApiResponse localVarResp = submitTaskGraphWithHttpInfo(namespace, id); - return localVarResp.getData(); - } - - /** - * - * Submit a single task graph for execution. - * @param namespace The namespace that owns this task graph. (required) - * @param id The UUID of the task graph entry. (required) - * @return ApiResponse<TaskGraphLog> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
202 Information about the execution of a single task graph. -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse submitTaskGraphWithHttpInfo(String namespace, String id) throws ApiException { - okhttp3.Call localVarCall = submitTaskGraphValidateBeforeCall(namespace, id, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Submit a single task graph for execution. - * @param namespace The namespace that owns this task graph. (required) - * @param id The UUID of the task graph entry. (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
202 Information about the execution of a single task graph. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call submitTaskGraphAsync(String namespace, String id, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = submitTaskGraphValidateBeforeCall(namespace, id, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for updateTaskGraph - * @param namespace The namespace that owns this task graph. (required) - * @param id The UUID of the task graph entry. (required) - * @param graph Updates to make to the task graph. (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Task graph created successfully. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateTaskGraphCall(String namespace, String id, TaskGraph graph, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = graph; - - // create path and map variables - String localVarPath = "/taskgraphs/{namespace}/graphs/{id}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "id" + "\\}", localVarApiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call updateTaskGraphValidateBeforeCall(String namespace, String id, TaskGraph graph, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling updateTaskGraph(Async)"); - } - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling updateTaskGraph(Async)"); - } - - // verify the required parameter 'graph' is set - if (graph == null) { - throw new ApiException("Missing the required parameter 'graph' when calling updateTaskGraph(Async)"); - } - - - okhttp3.Call localVarCall = updateTaskGraphCall(namespace, id, graph, _callback); - return localVarCall; - - } - - /** - * - * Update information about a single task graph execution. - * @param namespace The namespace that owns this task graph. (required) - * @param id The UUID of the task graph entry. (required) - * @param graph Updates to make to the task graph. (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Task graph created successfully. -
502 Bad Gateway -
0 error response -
- */ - public void updateTaskGraph(String namespace, String id, TaskGraph graph) throws ApiException { - updateTaskGraphWithHttpInfo(namespace, id, graph); - } - - /** - * - * Update information about a single task graph execution. - * @param namespace The namespace that owns this task graph. (required) - * @param id The UUID of the task graph entry. (required) - * @param graph Updates to make to the task graph. (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Task graph created successfully. -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse updateTaskGraphWithHttpInfo(String namespace, String id, TaskGraph graph) throws ApiException { - okhttp3.Call localVarCall = updateTaskGraphValidateBeforeCall(namespace, id, graph, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Update information about a single task graph execution. - * @param namespace The namespace that owns this task graph. (required) - * @param id The UUID of the task graph entry. (required) - * @param graph Updates to make to the task graph. (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 Task graph created successfully. -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateTaskGraphAsync(String namespace, String id, TaskGraph graph, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = updateTaskGraphValidateBeforeCall(namespace, id, graph, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/api/TasksApi.java b/src/main/java/io/tiledb/cloud/rest_api/v1/api/TasksApi.java deleted file mode 100644 index b8a6c0a..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/api/TasksApi.java +++ /dev/null @@ -1,751 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.api; - -import io.tiledb.cloud.rest_api.v1.model.ArrayTask; -import io.tiledb.cloud.rest_api.v1.model.ArrayTaskData; -import io.tiledb.cloud.rest_api.v1.model.SQLParameters; -import io.tiledb.cloud.rest_api.v1.ApiCallback; -import io.tiledb.cloud.rest_api.v1.ApiClient; -import io.tiledb.cloud.rest_api.v1.ApiException; -import io.tiledb.cloud.rest_api.v1.ApiResponse; -import io.tiledb.cloud.rest_api.v1.Configuration; -import io.tiledb.cloud.rest_api.v1.Pair; - -import com.google.gson.reflect.TypeToken; - - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class TasksApi { - private ApiClient localVarApiClient; - private int localHostIndex; - private String localCustomBaseUrl; - - public TasksApi() { - this(Configuration.getDefaultApiClient()); - } - - public TasksApi(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public ApiClient getApiClient() { - return localVarApiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public int getHostIndex() { - return localHostIndex; - } - - public void setHostIndex(int hostIndex) { - this.localHostIndex = hostIndex; - } - - public String getCustomBaseUrl() { - return localCustomBaseUrl; - } - - public void setCustomBaseUrl(String customBaseUrl) { - this.localCustomBaseUrl = customBaseUrl; - } - - /** - * Build call for runSQL - * @param namespace namespace to run task under is in (an organization name or user's username) (required) - * @param sql sql being submitted (required) - * @param acceptEncoding Encoding to use (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 JSON results in array of objects form, if the query returns results * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
204 SQL executed successfully * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call runSQLCall(String namespace, SQLParameters sql, String acceptEncoding, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = sql; - - // create path and map variables - String localVarPath = "/sql/{namespace}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (acceptEncoding != null) { - localVarHeaderParams.put("Accept-Encoding", localVarApiClient.parameterToString(acceptEncoding)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call runSQLValidateBeforeCall(String namespace, SQLParameters sql, String acceptEncoding, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling runSQL(Async)"); - } - - // verify the required parameter 'sql' is set - if (sql == null) { - throw new ApiException("Missing the required parameter 'sql' when calling runSQL(Async)"); - } - - - okhttp3.Call localVarCall = runSQLCall(namespace, sql, acceptEncoding, _callback); - return localVarCall; - - } - - /** - * - * Run a sql query - * @param namespace namespace to run task under is in (an organization name or user's username) (required) - * @param sql sql being submitted (required) - * @param acceptEncoding Encoding to use (optional) - * @return List<Object> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 JSON results in array of objects form, if the query returns results * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
204 SQL executed successfully * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response -
- */ - public List runSQL(String namespace, SQLParameters sql, String acceptEncoding) throws ApiException { - ApiResponse> localVarResp = runSQLWithHttpInfo(namespace, sql, acceptEncoding); - return localVarResp.getData(); - } - - /** - * - * Run a sql query - * @param namespace namespace to run task under is in (an organization name or user's username) (required) - * @param sql sql being submitted (required) - * @param acceptEncoding Encoding to use (optional) - * @return ApiResponse<List<Object>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 JSON results in array of objects form, if the query returns results * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
204 SQL executed successfully * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response -
- */ - public ApiResponse> runSQLWithHttpInfo(String namespace, SQLParameters sql, String acceptEncoding) throws ApiException { - okhttp3.Call localVarCall = runSQLValidateBeforeCall(namespace, sql, acceptEncoding, null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Run a sql query - * @param namespace namespace to run task under is in (an organization name or user's username) (required) - * @param sql sql being submitted (required) - * @param acceptEncoding Encoding to use (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 JSON results in array of objects form, if the query returns results * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
204 SQL executed successfully * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call runSQLAsync(String namespace, SQLParameters sql, String acceptEncoding, final ApiCallback> _callback) throws ApiException { - - okhttp3.Call localVarCall = runSQLValidateBeforeCall(namespace, sql, acceptEncoding, _callback); - Type localVarReturnType = new TypeToken>(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for taskIdGet - * @param id task ID to fetch (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array task -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call taskIdGetCall(String id, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/task/{id}" - .replaceAll("\\{" + "id" + "\\}", localVarApiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call taskIdGetValidateBeforeCall(String id, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling taskIdGet(Async)"); - } - - - okhttp3.Call localVarCall = taskIdGetCall(id, _callback); - return localVarCall; - - } - - /** - * - * Fetch an array task - * @param id task ID to fetch (required) - * @return ArrayTask - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array task -
502 Bad Gateway -
0 error response -
- */ - public ArrayTask taskIdGet(String id) throws ApiException { - ApiResponse localVarResp = taskIdGetWithHttpInfo(id); - return localVarResp.getData(); - } - - /** - * - * Fetch an array task - * @param id task ID to fetch (required) - * @return ApiResponse<ArrayTask> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array task -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse taskIdGetWithHttpInfo(String id) throws ApiException { - okhttp3.Call localVarCall = taskIdGetValidateBeforeCall(id, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch an array task - * @param id task ID to fetch (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array task -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call taskIdGetAsync(String id, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = taskIdGetValidateBeforeCall(id, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for taskIdResultGet - * @param id task ID to retrieve stored results (required) - * @param acceptEncoding Encoding to use (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - - -
Status Code Description Response Headers
200 output and format of originating request * Content-Type - format results are delivered in
202 task is still executing -
404 results were not saved, or results have expored -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call taskIdResultGetCall(String id, String acceptEncoding, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/task/{id}/result" - .replaceAll("\\{" + "id" + "\\}", localVarApiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (acceptEncoding != null) { - localVarHeaderParams.put("Accept-Encoding", localVarApiClient.parameterToString(acceptEncoding)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call taskIdResultGetValidateBeforeCall(String id, String acceptEncoding, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling taskIdResultGet(Async)"); - } - - - okhttp3.Call localVarCall = taskIdResultGetCall(id, acceptEncoding, _callback); - return localVarCall; - - } - - /** - * - * Retrieve results of an array task - * @param id task ID to retrieve stored results (required) - * @param acceptEncoding Encoding to use (optional) - * @return String - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - - -
Status Code Description Response Headers
200 output and format of originating request * Content-Type - format results are delivered in
202 task is still executing -
404 results were not saved, or results have expored -
502 Bad Gateway -
0 error response -
- */ - public String taskIdResultGet(String id, String acceptEncoding) throws ApiException { - ApiResponse localVarResp = taskIdResultGetWithHttpInfo(id, acceptEncoding); - return localVarResp.getData(); - } - - /** - * - * Retrieve results of an array task - * @param id task ID to retrieve stored results (required) - * @param acceptEncoding Encoding to use (optional) - * @return ApiResponse<String> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - - -
Status Code Description Response Headers
200 output and format of originating request * Content-Type - format results are delivered in
202 task is still executing -
404 results were not saved, or results have expored -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse taskIdResultGetWithHttpInfo(String id, String acceptEncoding) throws ApiException { - okhttp3.Call localVarCall = taskIdResultGetValidateBeforeCall(id, acceptEncoding, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Retrieve results of an array task - * @param id task ID to retrieve stored results (required) - * @param acceptEncoding Encoding to use (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - - -
Status Code Description Response Headers
200 output and format of originating request * Content-Type - format results are delivered in
202 task is still executing -
404 results were not saved, or results have expored -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call taskIdResultGetAsync(String id, String acceptEncoding, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = taskIdResultGetValidateBeforeCall(id, acceptEncoding, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for tasksGet - * @param namespace namespace to filter (optional) - * @param createdBy username to filter (optional) - * @param array name/uri of array that is url-encoded to filter (optional) - * @param start start time for tasks to filter by (optional) - * @param end end time for tasks to filter by (optional) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param type task type, \"QUERY\", \"SQL\", \"UDF\", \"GENERIC_UDF\" (optional) - * @param excludeType task_type to exclude matching array in results, more than one can be included (optional) - * @param fileType match file_type of task array, more than one can be included (optional) - * @param excludeFileType exclude file_type of task arrays, more than one can be included (optional) - * @param status Filter to only return these statuses (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param orderby sort by which field valid values include start_time, name (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of all tasks user has access too -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call tasksGetCall(String namespace, String createdBy, String array, Integer start, Integer end, Integer page, Integer perPage, String type, List excludeType, List fileType, List excludeFileType, String status, String search, String orderby, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/tasks"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (namespace != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("namespace", namespace)); - } - - if (createdBy != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("created_by", createdBy)); - } - - if (array != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("array", array)); - } - - if (start != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("start", start)); - } - - if (end != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("end", end)); - } - - if (page != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("page", page)); - } - - if (perPage != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("per_page", perPage)); - } - - if (type != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("type", type)); - } - - if (excludeType != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("csv", "exclude_type", excludeType)); - } - - if (fileType != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "file_type", fileType)); - } - - if (excludeFileType != null) { - localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "exclude_file_type", excludeFileType)); - } - - if (status != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("status", status)); - } - - if (search != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("search", search)); - } - - if (orderby != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("orderby", orderby)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call tasksGetValidateBeforeCall(String namespace, String createdBy, String array, Integer start, Integer end, Integer page, Integer perPage, String type, List excludeType, List fileType, List excludeFileType, String status, String search, String orderby, final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = tasksGetCall(namespace, createdBy, array, start, end, page, perPage, type, excludeType, fileType, excludeFileType, status, search, orderby, _callback); - return localVarCall; - - } - - /** - * - * Fetch a list of all array tasks a user has access to - * @param namespace namespace to filter (optional) - * @param createdBy username to filter (optional) - * @param array name/uri of array that is url-encoded to filter (optional) - * @param start start time for tasks to filter by (optional) - * @param end end time for tasks to filter by (optional) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param type task type, \"QUERY\", \"SQL\", \"UDF\", \"GENERIC_UDF\" (optional) - * @param excludeType task_type to exclude matching array in results, more than one can be included (optional) - * @param fileType match file_type of task array, more than one can be included (optional) - * @param excludeFileType exclude file_type of task arrays, more than one can be included (optional) - * @param status Filter to only return these statuses (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param orderby sort by which field valid values include start_time, name (optional) - * @return ArrayTaskData - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of all tasks user has access too -
502 Bad Gateway -
0 error response -
- */ - public ArrayTaskData tasksGet(String namespace, String createdBy, String array, Integer start, Integer end, Integer page, Integer perPage, String type, List excludeType, List fileType, List excludeFileType, String status, String search, String orderby) throws ApiException { - ApiResponse localVarResp = tasksGetWithHttpInfo(namespace, createdBy, array, start, end, page, perPage, type, excludeType, fileType, excludeFileType, status, search, orderby); - return localVarResp.getData(); - } - - /** - * - * Fetch a list of all array tasks a user has access to - * @param namespace namespace to filter (optional) - * @param createdBy username to filter (optional) - * @param array name/uri of array that is url-encoded to filter (optional) - * @param start start time for tasks to filter by (optional) - * @param end end time for tasks to filter by (optional) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param type task type, \"QUERY\", \"SQL\", \"UDF\", \"GENERIC_UDF\" (optional) - * @param excludeType task_type to exclude matching array in results, more than one can be included (optional) - * @param fileType match file_type of task array, more than one can be included (optional) - * @param excludeFileType exclude file_type of task arrays, more than one can be included (optional) - * @param status Filter to only return these statuses (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param orderby sort by which field valid values include start_time, name (optional) - * @return ApiResponse<ArrayTaskData> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of all tasks user has access too -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse tasksGetWithHttpInfo(String namespace, String createdBy, String array, Integer start, Integer end, Integer page, Integer perPage, String type, List excludeType, List fileType, List excludeFileType, String status, String search, String orderby) throws ApiException { - okhttp3.Call localVarCall = tasksGetValidateBeforeCall(namespace, createdBy, array, start, end, page, perPage, type, excludeType, fileType, excludeFileType, status, search, orderby, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch a list of all array tasks a user has access to - * @param namespace namespace to filter (optional) - * @param createdBy username to filter (optional) - * @param array name/uri of array that is url-encoded to filter (optional) - * @param start start time for tasks to filter by (optional) - * @param end end time for tasks to filter by (optional) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param type task type, \"QUERY\", \"SQL\", \"UDF\", \"GENERIC_UDF\" (optional) - * @param excludeType task_type to exclude matching array in results, more than one can be included (optional) - * @param fileType match file_type of task array, more than one can be included (optional) - * @param excludeFileType exclude file_type of task arrays, more than one can be included (optional) - * @param status Filter to only return these statuses (optional) - * @param search search string that will look at name, namespace or description fields (optional) - * @param orderby sort by which field valid values include start_time, name (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of all tasks user has access too -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call tasksGetAsync(String namespace, String createdBy, String array, Integer start, Integer end, Integer page, Integer perPage, String type, List excludeType, List fileType, List excludeFileType, String status, String search, String orderby, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = tasksGetValidateBeforeCall(namespace, createdBy, array, start, end, page, perPage, type, excludeType, fileType, excludeFileType, status, search, orderby, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/api/UdfApi.java b/src/main/java/io/tiledb/cloud/rest_api/v1/api/UdfApi.java deleted file mode 100644 index 7b299f0..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/api/UdfApi.java +++ /dev/null @@ -1,2085 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.api; - -import io.tiledb.cloud.rest_api.v1.ApiCallback; -import io.tiledb.cloud.rest_api.v1.ApiClient; -import io.tiledb.cloud.rest_api.v1.ApiException; -import io.tiledb.cloud.rest_api.v1.ApiResponse; -import io.tiledb.cloud.rest_api.v1.Configuration; -import io.tiledb.cloud.rest_api.v1.Pair; - -import com.google.gson.reflect.TypeToken; - - -import io.tiledb.cloud.rest_api.v1.model.ArrayEndTimestampData; - -import java.io.File; -import io.tiledb.cloud.rest_api.v1.model.GenericUDF; -import io.tiledb.cloud.rest_api.v1.model.MultiArrayUDF; -import io.tiledb.cloud.rest_api.v1.model.UDFCopied; -import io.tiledb.cloud.rest_api.v1.model.UDFCopy; -import io.tiledb.cloud.rest_api.v1.model.UDFInfo; -import io.tiledb.cloud.rest_api.v1.model.UDFInfoUpdate; -import io.tiledb.cloud.rest_api.v1.model.UDFSharing; - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class UdfApi { - private ApiClient localVarApiClient; - private int localHostIndex; - private String localCustomBaseUrl; - - public UdfApi() { - this(Configuration.getDefaultApiClient()); - } - - public UdfApi(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public ApiClient getApiClient() { - return localVarApiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public int getHostIndex() { - return localHostIndex; - } - - public void setHostIndex(int hostIndex) { - this.localHostIndex = hostIndex; - } - - public String getCustomBaseUrl() { - return localCustomBaseUrl; - } - - public void setCustomBaseUrl(String customBaseUrl) { - this.localCustomBaseUrl = customBaseUrl; - } - - /** - * Build call for deleteUDFInfo - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name to register UDF under (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 UDF deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteUDFInfoCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/udf/{namespace}/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call deleteUDFInfoValidateBeforeCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling deleteUDFInfo(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling deleteUDFInfo(Async)"); - } - - - okhttp3.Call localVarCall = deleteUDFInfoCall(namespace, name, _callback); - return localVarCall; - - } - - /** - * - * submit a generic UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param udf UDF to run (required) - * @param acceptEncoding Encoding to use (optional) - * @return byte[] - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public byte[] submitGenericUDFBytes(String namespace, GenericUDF udf, String acceptEncoding) throws ApiException { - ApiResponse localVarResp = submitGenericUDFWithHttpInfoBytes(namespace, udf, acceptEncoding); - return localVarResp.getData(); - } - - /** - * - * submit a generic UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param udf UDF to run (required) - * @param acceptEncoding Encoding to use (optional) - * @return ApiResponse<byte[]> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public ApiResponse submitGenericUDFWithHttpInfoBytes(String namespace, GenericUDF udf, String acceptEncoding) throws ApiException { - okhttp3.Call localVarCall = submitGenericUDFValidateBeforeCall(namespace, udf, acceptEncoding, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * - * submit a generic UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param udf UDF to run (required) - * @param acceptEncoding Encoding to use (optional) - * @return Object - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public Object submitGenericUDFObj(String namespace, GenericUDF udf, String acceptEncoding) throws ApiException { - ApiResponse localVarResp = submitGenericUDFWithHttpInfoObj(namespace, udf, acceptEncoding); - return localVarResp.getData(); - } - - /** - * - * submit a multi-array UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param udf UDF to run (required) - * @param acceptEncoding Encoding to use (optional) - * @return String - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public String submitMultiArrayUDFString(String namespace, MultiArrayUDF udf, String acceptEncoding) throws ApiException { - ApiResponse localVarResp = submitMultiArrayUDFWithHttpInfoString(namespace, udf, acceptEncoding); - return localVarResp.getData(); - } - - /** - * - * submit a multi-array UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param udf UDF to run (required) - * @param acceptEncoding Encoding to use (optional) - * @return ApiResponse<String> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public ApiResponse submitMultiArrayUDFWithHttpInfoString(String namespace, MultiArrayUDF udf, String acceptEncoding) throws ApiException { - okhttp3.Call localVarCall = submitMultiArrayUDFValidateBeforeCall(namespace, udf, acceptEncoding, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * - * submit a multi-array UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param udf UDF to run (required) - * @param acceptEncoding Encoding to use (optional) - * @return byte[] - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public byte[] submitMultiArrayUDFBytes(String namespace, MultiArrayUDF udf, String acceptEncoding) throws ApiException { - ApiResponse localVarResp = submitMultiArrayUDFWithHttpInfoBytes(namespace, udf, acceptEncoding); - return localVarResp.getData(); - } - - /** - * - * send a UDF to run against a specified array/URI registered to a group/project - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param udf UDF to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param acceptEncoding Encoding to use (optional) - * @param v2 flag to indicate if v2 array UDFs should be used, currently in beta testing. Setting any value will enable v2 array UDFs. (optional) - * @return String - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public String submitUDFString(String namespace, String array, MultiArrayUDF udf, String xPayer, String acceptEncoding, String v2) throws ApiException { - ApiResponse localVarResp = submitUDFWithHttpInfoString(namespace, array, udf, xPayer, acceptEncoding, v2); - return localVarResp.getData(); - } - - /** - * - * send a UDF to run against a specified array/URI registered to a group/project - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param udf UDF to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param acceptEncoding Encoding to use (optional) - * @param v2 flag to indicate if v2 array UDFs should be used, currently in beta testing. Setting any value will enable v2 array UDFs. (optional) - * @return ApiResponse<String> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public ApiResponse submitUDFWithHttpInfoString(String namespace, String array, MultiArrayUDF udf, String xPayer, String acceptEncoding, String v2) throws ApiException { - okhttp3.Call localVarCall = submitUDFValidateBeforeCall(namespace, array, udf, xPayer, acceptEncoding, v2, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * - * send a UDF to run against a specified array/URI registered to a group/project - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param udf UDF to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param acceptEncoding Encoding to use (optional) - * @param v2 flag to indicate if v2 array UDFs should be used, currently in beta testing. Setting any value will enable v2 array UDFs. (optional) - * @return byte[] - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public byte[] submitUDFBytes(String namespace, String array, MultiArrayUDF udf, String xPayer, String acceptEncoding, String v2) throws ApiException { - ApiResponse localVarResp = submitUDFWithHttpInfoBytes(namespace, array, udf, xPayer, acceptEncoding, v2); - return localVarResp.getData(); - } - - /** - * - * send a UDF to run against a specified array/URI registered to a group/project - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param udf UDF to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param acceptEncoding Encoding to use (optional) - * @param v2 flag to indicate if v2 array UDFs should be used, currently in beta testing. Setting any value will enable v2 array UDFs. (optional) - * @return ApiResponse<byte[]> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public ApiResponse submitUDFWithHttpInfoBytes(String namespace, String array, MultiArrayUDF udf, String xPayer, String acceptEncoding, String v2) throws ApiException { - okhttp3.Call localVarCall = submitUDFValidateBeforeCall(namespace, array, udf, xPayer, acceptEncoding, v2, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * - * submit a multi-array UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param udf UDF to run (required) - * @param acceptEncoding Encoding to use (optional) - * @return ApiResponse<byte[]> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public ApiResponse submitMultiArrayUDFWithHttpInfoBytes(String namespace, MultiArrayUDF udf, String acceptEncoding) throws ApiException { - okhttp3.Call localVarCall = submitMultiArrayUDFValidateBeforeCall(namespace, udf, acceptEncoding, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * - * submit a generic UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param udf UDF to run (required) - * @param acceptEncoding Encoding to use (optional) - * @return ApiResponse<Object> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public ApiResponse submitGenericUDFWithHttpInfoObj(String namespace, GenericUDF udf, String acceptEncoding) throws ApiException { - okhttp3.Call localVarCall = submitGenericUDFValidateBeforeCall(namespace, udf, acceptEncoding, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * - * delete a registered UDF -- this will remove all sharing and can not be undone - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name to register UDF under (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 UDF deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public void deleteUDFInfo(String namespace, String name) throws ApiException { - deleteUDFInfoWithHttpInfo(namespace, name); - } - - /** - * - * submit a generic UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param udf UDF to run (required) - * @param acceptEncoding Encoding to use (optional) - * @return ApiResponse<String> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public ApiResponse submitGenericUDFWithHttpInfoString(String namespace, GenericUDF udf, String acceptEncoding) throws ApiException { - okhttp3.Call localVarCall = submitGenericUDFValidateBeforeCall(namespace, udf, acceptEncoding, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * - * submit a generic UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param udf UDF to run (required) - * @param acceptEncoding Encoding to use (optional) - * @return String - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public String submitGenericUDFString(String namespace, GenericUDF udf, String acceptEncoding) throws ApiException { - ApiResponse localVarResp = submitGenericUDFWithHttpInfoString(namespace, udf, acceptEncoding); - return localVarResp.getData(); - } - - /** - * - * delete a registered UDF -- this will remove all sharing and can not be undone - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name to register UDF under (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 UDF deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse deleteUDFInfoWithHttpInfo(String namespace, String name) throws ApiException { - okhttp3.Call localVarCall = deleteUDFInfoValidateBeforeCall(namespace, name, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * delete a registered UDF -- this will remove all sharing and can not be undone - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name to register UDF under (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 UDF deleted successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteUDFInfoAsync(String namespace, String name, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = deleteUDFInfoValidateBeforeCall(namespace, name, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for getUDFInfo - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name to register UDF under (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 UDFInfo was retrieved successfully -
404 UDF not found -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getUDFInfoCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/udf/{namespace}/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getUDFInfoValidateBeforeCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getUDFInfo(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling getUDFInfo(Async)"); - } - - - okhttp3.Call localVarCall = getUDFInfoCall(namespace, name, _callback); - return localVarCall; - - } - - /** - * - * get a specific UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name to register UDF under (required) - * @return UDFInfo - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 UDFInfo was retrieved successfully -
404 UDF not found -
502 Bad Gateway -
0 error response -
- */ - public UDFInfo getUDFInfo(String namespace, String name) throws ApiException { - ApiResponse localVarResp = getUDFInfoWithHttpInfo(namespace, name); - return localVarResp.getData(); - } - - /** - * - * get a specific UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name to register UDF under (required) - * @return ApiResponse<UDFInfo> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 UDFInfo was retrieved successfully -
404 UDF not found -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getUDFInfoWithHttpInfo(String namespace, String name) throws ApiException { - okhttp3.Call localVarCall = getUDFInfoValidateBeforeCall(namespace, name, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * get a specific UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name to register UDF under (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 UDFInfo was retrieved successfully -
404 UDF not found -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getUDFInfoAsync(String namespace, String name, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getUDFInfoValidateBeforeCall(namespace, name, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getUDFInfoSharingPolicies - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name of UDFInfo (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 List of all specific sharing policies -
404 UDF does not exist or user does not have permissions to view array-sharing policies -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getUDFInfoSharingPoliciesCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/udf/{namespace}/{name}/share" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getUDFInfoSharingPoliciesValidateBeforeCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling getUDFInfoSharingPolicies(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling getUDFInfoSharingPolicies(Async)"); - } - - - okhttp3.Call localVarCall = getUDFInfoSharingPoliciesCall(namespace, name, _callback); - return localVarCall; - - } - - /** - * - * Get all sharing details of the UDF - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name of UDFInfo (required) - * @return List<UDFSharing> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 List of all specific sharing policies -
404 UDF does not exist or user does not have permissions to view array-sharing policies -
502 Bad Gateway -
0 error response -
- */ - public List getUDFInfoSharingPolicies(String namespace, String name) throws ApiException { - ApiResponse> localVarResp = getUDFInfoSharingPoliciesWithHttpInfo(namespace, name); - return localVarResp.getData(); - } - - /** - * - * Get all sharing details of the UDF - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name of UDFInfo (required) - * @return ApiResponse<List<UDFSharing>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 List of all specific sharing policies -
404 UDF does not exist or user does not have permissions to view array-sharing policies -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse> getUDFInfoSharingPoliciesWithHttpInfo(String namespace, String name) throws ApiException { - okhttp3.Call localVarCall = getUDFInfoSharingPoliciesValidateBeforeCall(namespace, name, null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Get all sharing details of the UDF - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name of UDFInfo (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 List of all specific sharing policies -
404 UDF does not exist or user does not have permissions to view array-sharing policies -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getUDFInfoSharingPoliciesAsync(String namespace, String name, final ApiCallback> _callback) throws ApiException { - - okhttp3.Call localVarCall = getUDFInfoSharingPoliciesValidateBeforeCall(namespace, name, _callback); - Type localVarReturnType = new TypeToken>(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for handleCopyUDF - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name of UDFInfo (required) - * @param udFCopy Input/Output information to copy a UDF (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @param endTimestamp Milliseconds since Unix epoch (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
201 UDF copied -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call handleCopyUDFCall(String namespace, String name, UDFCopy udFCopy, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, Integer endTimestamp, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = udFCopy; - - // create path and map variables - String localVarPath = "/udf/{namespace}/{name}/copy" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (endTimestamp != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("end_timestamp", endTimestamp)); - } - - if (X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME != null) { - localVarHeaderParams.put("X-TILEDB-CLOUD-ACCESS-CREDENTIALS-NAME", localVarApiClient.parameterToString(X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call handleCopyUDFValidateBeforeCall(String namespace, String name, UDFCopy udFCopy, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, Integer endTimestamp, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling handleCopyUDF(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling handleCopyUDF(Async)"); - } - - // verify the required parameter 'udFCopy' is set - if (udFCopy == null) { - throw new ApiException("Missing the required parameter 'udFCopy' when calling handleCopyUDF(Async)"); - } - - - okhttp3.Call localVarCall = handleCopyUDFCall(namespace, name, udFCopy, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, endTimestamp, _callback); - return localVarCall; - - } - - /** - * - * Copy a tiledb udf at the specified location - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name of UDFInfo (required) - * @param udFCopy Input/Output information to copy a UDF (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @param endTimestamp Milliseconds since Unix epoch (optional) - * @return UDFCopied - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
201 UDF copied -
502 Bad Gateway -
0 error response -
- */ - public UDFCopied handleCopyUDF(String namespace, String name, UDFCopy udFCopy, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, Integer endTimestamp) throws ApiException { - ApiResponse localVarResp = handleCopyUDFWithHttpInfo(namespace, name, udFCopy, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, endTimestamp); - return localVarResp.getData(); - } - - /** - * - * Copy a tiledb udf at the specified location - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name of UDFInfo (required) - * @param udFCopy Input/Output information to copy a UDF (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @param endTimestamp Milliseconds since Unix epoch (optional) - * @return ApiResponse<UDFCopied> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
201 UDF copied -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse handleCopyUDFWithHttpInfo(String namespace, String name, UDFCopy udFCopy, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, Integer endTimestamp) throws ApiException { - okhttp3.Call localVarCall = handleCopyUDFValidateBeforeCall(namespace, name, udFCopy, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, endTimestamp, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Copy a tiledb udf at the specified location - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name of UDFInfo (required) - * @param udFCopy Input/Output information to copy a UDF (required) - * @param X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME Optional registered access credentials to use for creation (optional) - * @param endTimestamp Milliseconds since Unix epoch (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
201 UDF copied -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call handleCopyUDFAsync(String namespace, String name, UDFCopy udFCopy, String X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, Integer endTimestamp, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = handleCopyUDFValidateBeforeCall(namespace, name, udFCopy, X_TILEDB_CLOUD_ACCESS_CREDENTIALS_NAME, endTimestamp, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for registerUDFInfo - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name to register UDF under (required) - * @param udf UDF to register (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 UDF registered successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call registerUDFInfoCall(String namespace, String name, UDFInfoUpdate udf, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = udf; - - // create path and map variables - String localVarPath = "/udf/{namespace}/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call registerUDFInfoValidateBeforeCall(String namespace, String name, UDFInfoUpdate udf, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling registerUDFInfo(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling registerUDFInfo(Async)"); - } - - // verify the required parameter 'udf' is set - if (udf == null) { - throw new ApiException("Missing the required parameter 'udf' when calling registerUDFInfo(Async)"); - } - - - okhttp3.Call localVarCall = registerUDFInfoCall(namespace, name, udf, _callback); - return localVarCall; - - } - - /** - * - * register a UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name to register UDF under (required) - * @param udf UDF to register (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 UDF registered successfully -
502 Bad Gateway -
0 error response -
- */ - public void registerUDFInfo(String namespace, String name, UDFInfoUpdate udf) throws ApiException { - registerUDFInfoWithHttpInfo(namespace, name, udf); - } - - /** - * - * register a UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name to register UDF under (required) - * @param udf UDF to register (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 UDF registered successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse registerUDFInfoWithHttpInfo(String namespace, String name, UDFInfoUpdate udf) throws ApiException { - okhttp3.Call localVarCall = registerUDFInfoValidateBeforeCall(namespace, name, udf, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * register a UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name to register UDF under (required) - * @param udf UDF to register (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 UDF registered successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call registerUDFInfoAsync(String namespace, String name, UDFInfoUpdate udf, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = registerUDFInfoValidateBeforeCall(namespace, name, udf, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for shareUDFInfo - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name of UDFInfo (required) - * @param udfSharing Namespace and list of permissions to share with. An empty list of permissions will remove the namespace; if permissions already exist they will be deleted then new ones added. In the event of a failure, the new policies will be rolled back to prevent partial policies, and it's likely the UDF will not be shared with the namespace at all. (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 UDF shared successfully -
404 UDF does not exist or user does not have permissions to share UDF -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call shareUDFInfoCall(String namespace, String name, UDFSharing udfSharing, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = udfSharing; - - // create path and map variables - String localVarPath = "/udf/{namespace}/{name}/share" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call shareUDFInfoValidateBeforeCall(String namespace, String name, UDFSharing udfSharing, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling shareUDFInfo(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling shareUDFInfo(Async)"); - } - - // verify the required parameter 'udfSharing' is set - if (udfSharing == null) { - throw new ApiException("Missing the required parameter 'udfSharing' when calling shareUDFInfo(Async)"); - } - - - okhttp3.Call localVarCall = shareUDFInfoCall(namespace, name, udfSharing, _callback); - return localVarCall; - - } - - /** - * - * Share a UDF with a user - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name of UDFInfo (required) - * @param udfSharing Namespace and list of permissions to share with. An empty list of permissions will remove the namespace; if permissions already exist they will be deleted then new ones added. In the event of a failure, the new policies will be rolled back to prevent partial policies, and it's likely the UDF will not be shared with the namespace at all. (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 UDF shared successfully -
404 UDF does not exist or user does not have permissions to share UDF -
502 Bad Gateway -
0 error response -
- */ - public void shareUDFInfo(String namespace, String name, UDFSharing udfSharing) throws ApiException { - shareUDFInfoWithHttpInfo(namespace, name, udfSharing); - } - - /** - * - * Share a UDF with a user - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name of UDFInfo (required) - * @param udfSharing Namespace and list of permissions to share with. An empty list of permissions will remove the namespace; if permissions already exist they will be deleted then new ones added. In the event of a failure, the new policies will be rolled back to prevent partial policies, and it's likely the UDF will not be shared with the namespace at all. (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 UDF shared successfully -
404 UDF does not exist or user does not have permissions to share UDF -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse shareUDFInfoWithHttpInfo(String namespace, String name, UDFSharing udfSharing) throws ApiException { - okhttp3.Call localVarCall = shareUDFInfoValidateBeforeCall(namespace, name, udfSharing, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Share a UDF with a user - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name of UDFInfo (required) - * @param udfSharing Namespace and list of permissions to share with. An empty list of permissions will remove the namespace; if permissions already exist they will be deleted then new ones added. In the event of a failure, the new policies will be rolled back to prevent partial policies, and it's likely the UDF will not be shared with the namespace at all. (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 UDF shared successfully -
404 UDF does not exist or user does not have permissions to share UDF -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call shareUDFInfoAsync(String namespace, String name, UDFSharing udfSharing, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = shareUDFInfoValidateBeforeCall(namespace, name, udfSharing, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for submitGenericUDF - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param udf UDF to run (required) - * @param acceptEncoding Encoding to use (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public okhttp3.Call submitGenericUDFCall(String namespace, GenericUDF udf, String acceptEncoding, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = udf; - - // create path and map variables - String localVarPath = "/udfs/generic/{namespace}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (acceptEncoding != null) { - localVarHeaderParams.put("Accept-Encoding", localVarApiClient.parameterToString(acceptEncoding)); - } - - final String[] localVarAccepts = { - "application/octet-stream" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call submitGenericUDFValidateBeforeCall(String namespace, GenericUDF udf, String acceptEncoding, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling submitGenericUDF(Async)"); - } - - // verify the required parameter 'udf' is set - if (udf == null) { - throw new ApiException("Missing the required parameter 'udf' when calling submitGenericUDF(Async)"); - } - - - okhttp3.Call localVarCall = submitGenericUDFCall(namespace, udf, acceptEncoding, _callback); - return localVarCall; - - } - - /** - * - * submit a generic UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param udf UDF to run (required) - * @param acceptEncoding Encoding to use (optional) - * @return File - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public File submitGenericUDF(String namespace, GenericUDF udf, String acceptEncoding) throws ApiException { - ApiResponse localVarResp = submitGenericUDFWithHttpInfo(namespace, udf, acceptEncoding); - return localVarResp.getData(); - } - - /** - * - * submit a generic UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param udf UDF to run (required) - * @param acceptEncoding Encoding to use (optional) - * @return ApiResponse<File> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public ApiResponse submitGenericUDFWithHttpInfo(String namespace, GenericUDF udf, String acceptEncoding) throws ApiException { - okhttp3.Call localVarCall = submitGenericUDFValidateBeforeCall(namespace, udf, acceptEncoding, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * submit a generic UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param udf UDF to run (required) - * @param acceptEncoding Encoding to use (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public okhttp3.Call submitGenericUDFAsync(String namespace, GenericUDF udf, String acceptEncoding, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = submitGenericUDFValidateBeforeCall(namespace, udf, acceptEncoding, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for submitMultiArrayUDF - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param udf UDF to run (required) - * @param acceptEncoding Encoding to use (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public okhttp3.Call submitMultiArrayUDFCall(String namespace, MultiArrayUDF udf, String acceptEncoding, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = udf; - - // create path and map variables - String localVarPath = "/udfs/arrays/{namespace}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (acceptEncoding != null) { - localVarHeaderParams.put("Accept-Encoding", localVarApiClient.parameterToString(acceptEncoding)); - } - - final String[] localVarAccepts = { - "application/octet-stream" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call submitMultiArrayUDFValidateBeforeCall(String namespace, MultiArrayUDF udf, String acceptEncoding, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling submitMultiArrayUDF(Async)"); - } - - // verify the required parameter 'udf' is set - if (udf == null) { - throw new ApiException("Missing the required parameter 'udf' when calling submitMultiArrayUDF(Async)"); - } - - - okhttp3.Call localVarCall = submitMultiArrayUDFCall(namespace, udf, acceptEncoding, _callback); - return localVarCall; - - } - - /** - * - * submit a multi-array UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param udf UDF to run (required) - * @param acceptEncoding Encoding to use (optional) - * @return File - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public File submitMultiArrayUDF(String namespace, MultiArrayUDF udf, String acceptEncoding) throws ApiException { - ApiResponse localVarResp = submitMultiArrayUDFWithHttpInfo(namespace, udf, acceptEncoding); - return localVarResp.getData(); - } - - /** - * - * submit a multi-array UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param udf UDF to run (required) - * @param acceptEncoding Encoding to use (optional) - * @return ApiResponse<File> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public ApiResponse submitMultiArrayUDFWithHttpInfo(String namespace, MultiArrayUDF udf, String acceptEncoding) throws ApiException { - okhttp3.Call localVarCall = submitMultiArrayUDFValidateBeforeCall(namespace, udf, acceptEncoding, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * submit a multi-array UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param udf UDF to run (required) - * @param acceptEncoding Encoding to use (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public okhttp3.Call submitMultiArrayUDFAsync(String namespace, MultiArrayUDF udf, String acceptEncoding, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = submitMultiArrayUDFValidateBeforeCall(namespace, udf, acceptEncoding, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for submitUDF - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param udf UDF to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param acceptEncoding Encoding to use (optional) - * @param v2 flag to indicate if v2 array UDFs should be used, currently in beta testing. Setting any value will enable v2 array UDFs. (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public okhttp3.Call submitUDFCall(String namespace, String array, MultiArrayUDF udf, String xPayer, String acceptEncoding, String v2, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = udf; - - // create path and map variables - String localVarPath = "/arrays/{namespace}/{array}/udf/submit" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (v2 != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("v2", v2)); - } - - if (xPayer != null) { - localVarHeaderParams.put("X-Payer", localVarApiClient.parameterToString(xPayer)); - } - - if (acceptEncoding != null) { - localVarHeaderParams.put("Accept-Encoding", localVarApiClient.parameterToString(acceptEncoding)); - } - - final String[] localVarAccepts = { - "application/octet-stream" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call submitUDFValidateBeforeCall(String namespace, String array, MultiArrayUDF udf, String xPayer, String acceptEncoding, String v2, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling submitUDF(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling submitUDF(Async)"); - } - - // verify the required parameter 'udf' is set - if (udf == null) { - throw new ApiException("Missing the required parameter 'udf' when calling submitUDF(Async)"); - } - - - okhttp3.Call localVarCall = submitUDFCall(namespace, array, udf, xPayer, acceptEncoding, v2, _callback); - return localVarCall; - - } - - /** - * - * send a UDF to run against a specified array/URI registered to a group/project - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param udf UDF to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param acceptEncoding Encoding to use (optional) - * @param v2 flag to indicate if v2 array UDFs should be used, currently in beta testing. Setting any value will enable v2 array UDFs. (optional) - * @return File - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public File submitUDF(String namespace, String array, MultiArrayUDF udf, String xPayer, String acceptEncoding, String v2) throws ApiException { - ApiResponse localVarResp = submitUDFWithHttpInfo(namespace, array, udf, xPayer, acceptEncoding, v2); - return localVarResp.getData(); - } - - /** - * - * send a UDF to run against a specified array/URI registered to a group/project - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param udf UDF to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param acceptEncoding Encoding to use (optional) - * @param v2 flag to indicate if v2 array UDFs should be used, currently in beta testing. Setting any value will enable v2 array UDFs. (optional) - * @return ApiResponse<File> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public ApiResponse submitUDFWithHttpInfo(String namespace, String array, MultiArrayUDF udf, String xPayer, String acceptEncoding, String v2) throws ApiException { - okhttp3.Call localVarCall = submitUDFValidateBeforeCall(namespace, array, udf, xPayer, acceptEncoding, v2, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * send a UDF to run against a specified array/URI registered to a group/project - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param udf UDF to run (required) - * @param xPayer Name of organization or user who should be charged for this request (optional) - * @param acceptEncoding Encoding to use (optional) - * @param v2 flag to indicate if v2 array UDFs should be used, currently in beta testing. Setting any value will enable v2 array UDFs. (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 UDF completed and the UDF-type specific result is returned * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
502 Bad Gateway -
0 error response * X-TILEDB-CLOUD-TASK-ID - Task ID for just completed request
- */ - public okhttp3.Call submitUDFAsync(String namespace, String array, MultiArrayUDF udf, String xPayer, String acceptEncoding, String v2, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = submitUDFValidateBeforeCall(namespace, array, udf, xPayer, acceptEncoding, v2, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for udfNamespaceArrayEndTimestampsGet - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 list of timestamps in milliseconds, paginated -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call udfNamespaceArrayEndTimestampsGetCall(String namespace, String array, Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/udf/{namespace}/{array}/end_timestamps" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "array" + "\\}", localVarApiClient.escapeString(array.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (page != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("page", page)); - } - - if (perPage != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("per_page", perPage)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call udfNamespaceArrayEndTimestampsGetValidateBeforeCall(String namespace, String array, Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling udfNamespaceArrayEndTimestampsGet(Async)"); - } - - // verify the required parameter 'array' is set - if (array == null) { - throw new ApiException("Missing the required parameter 'array' when calling udfNamespaceArrayEndTimestampsGet(Async)"); - } - - - okhttp3.Call localVarCall = udfNamespaceArrayEndTimestampsGetCall(namespace, array, page, perPage, _callback); - return localVarCall; - - } - - /** - * - * retrieve a list of timestamps from the array fragment info listing in milliseconds, paginated - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @return ArrayEndTimestampData - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 list of timestamps in milliseconds, paginated -
502 Bad Gateway -
0 error response -
- */ - public ArrayEndTimestampData udfNamespaceArrayEndTimestampsGet(String namespace, String array, Integer page, Integer perPage) throws ApiException { - ApiResponse localVarResp = udfNamespaceArrayEndTimestampsGetWithHttpInfo(namespace, array, page, perPage); - return localVarResp.getData(); - } - - /** - * - * retrieve a list of timestamps from the array fragment info listing in milliseconds, paginated - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @return ApiResponse<ArrayEndTimestampData> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 list of timestamps in milliseconds, paginated -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse udfNamespaceArrayEndTimestampsGetWithHttpInfo(String namespace, String array, Integer page, Integer perPage) throws ApiException { - okhttp3.Call localVarCall = udfNamespaceArrayEndTimestampsGetValidateBeforeCall(namespace, array, page, perPage, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * retrieve a list of timestamps from the array fragment info listing in milliseconds, paginated - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param array name/uri of array that is url-encoded (required) - * @param page pagination offset (optional) - * @param perPage pagination limit (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 list of timestamps in milliseconds, paginated -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call udfNamespaceArrayEndTimestampsGetAsync(String namespace, String array, Integer page, Integer perPage, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = udfNamespaceArrayEndTimestampsGetValidateBeforeCall(namespace, array, page, perPage, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for updateUDFInfo - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name to register UDF under (required) - * @param udf UDF to update (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 UDF updated successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateUDFInfoCall(String namespace, String name, UDFInfoUpdate udf, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = udf; - - // create path and map variables - String localVarPath = "/udf/{namespace}/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call updateUDFInfoValidateBeforeCall(String namespace, String name, UDFInfoUpdate udf, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling updateUDFInfo(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling updateUDFInfo(Async)"); - } - - // verify the required parameter 'udf' is set - if (udf == null) { - throw new ApiException("Missing the required parameter 'udf' when calling updateUDFInfo(Async)"); - } - - - okhttp3.Call localVarCall = updateUDFInfoCall(namespace, name, udf, _callback); - return localVarCall; - - } - - /** - * - * update an existing registered UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name to register UDF under (required) - * @param udf UDF to update (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 UDF updated successfully -
502 Bad Gateway -
0 error response -
- */ - public void updateUDFInfo(String namespace, String name, UDFInfoUpdate udf) throws ApiException { - updateUDFInfoWithHttpInfo(namespace, name, udf); - } - - /** - * - * update an existing registered UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name to register UDF under (required) - * @param udf UDF to update (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 UDF updated successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse updateUDFInfoWithHttpInfo(String namespace, String name, UDFInfoUpdate udf) throws ApiException { - okhttp3.Call localVarCall = updateUDFInfoValidateBeforeCall(namespace, name, udf, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * update an existing registered UDF in the given namespace - * @param namespace namespace array is in (an organization name or user's username) (required) - * @param name name to register UDF under (required) - * @param udf UDF to update (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 UDF updated successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateUDFInfoAsync(String namespace, String name, UDFInfoUpdate udf, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = updateUDFInfoValidateBeforeCall(namespace, name, udf, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/api/UserApi.java b/src/main/java/io/tiledb/cloud/rest_api/v1/api/UserApi.java deleted file mode 100644 index 0240609..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/api/UserApi.java +++ /dev/null @@ -1,3056 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.api; - -import io.tiledb.cloud.rest_api.v1.ApiCallback; -import io.tiledb.cloud.rest_api.v1.ApiClient; -import io.tiledb.cloud.rest_api.v1.ApiException; -import io.tiledb.cloud.rest_api.v1.ApiResponse; -import io.tiledb.cloud.rest_api.v1.Configuration; -import io.tiledb.cloud.rest_api.v1.Pair; - -import com.google.gson.reflect.TypeToken; - - -import io.tiledb.cloud.rest_api.v1.model.AWSAccessCredentials; -import io.tiledb.cloud.rest_api.v1.model.OrganizationUser; -import io.tiledb.cloud.rest_api.v1.model.ResetUserPasswordRequest; -import io.tiledb.cloud.rest_api.v1.model.Token; -import io.tiledb.cloud.rest_api.v1.model.TokenRequest; -import io.tiledb.cloud.rest_api.v1.model.TokenScope; -import io.tiledb.cloud.rest_api.v1.model.User; - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class UserApi { - private ApiClient localVarApiClient; - private int localHostIndex; - private String localCustomBaseUrl; - - public UserApi() { - this(Configuration.getDefaultApiClient()); - } - - public UserApi(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public ApiClient getApiClient() { - return localVarApiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.localVarApiClient = apiClient; - } - - public int getHostIndex() { - return localHostIndex; - } - - public void setHostIndex(int hostIndex) { - this.localHostIndex = hostIndex; - } - - public String getCustomBaseUrl() { - return localCustomBaseUrl; - } - - public void setCustomBaseUrl(String customBaseUrl) { - this.localCustomBaseUrl = customBaseUrl; - } - - /** - * Build call for addAWSAccessCredentials - * @param namespace namespace (required) - * @param awsAccessCredentials aws access credentials to store for a namespace (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS keys added successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call addAWSAccessCredentialsCall(String namespace, AWSAccessCredentials awsAccessCredentials, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = awsAccessCredentials; - - // create path and map variables - String localVarPath = "/credentials/{namespace}/aws" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call addAWSAccessCredentialsValidateBeforeCall(String namespace, AWSAccessCredentials awsAccessCredentials, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling addAWSAccessCredentials(Async)"); - } - - // verify the required parameter 'awsAccessCredentials' is set - if (awsAccessCredentials == null) { - throw new ApiException("Missing the required parameter 'awsAccessCredentials' when calling addAWSAccessCredentials(Async)"); - } - - - okhttp3.Call localVarCall = addAWSAccessCredentialsCall(namespace, awsAccessCredentials, _callback); - return localVarCall; - - } - - /** - * - * Add aws keys - * @param namespace namespace (required) - * @param awsAccessCredentials aws access credentials to store for a namespace (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS keys added successfully -
502 Bad Gateway -
0 error response -
- */ - public void addAWSAccessCredentials(String namespace, AWSAccessCredentials awsAccessCredentials) throws ApiException { - addAWSAccessCredentialsWithHttpInfo(namespace, awsAccessCredentials); - } - - /** - * - * Add aws keys - * @param namespace namespace (required) - * @param awsAccessCredentials aws access credentials to store for a namespace (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS keys added successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse addAWSAccessCredentialsWithHttpInfo(String namespace, AWSAccessCredentials awsAccessCredentials) throws ApiException { - okhttp3.Call localVarCall = addAWSAccessCredentialsValidateBeforeCall(namespace, awsAccessCredentials, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Add aws keys - * @param namespace namespace (required) - * @param awsAccessCredentials aws access credentials to store for a namespace (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS keys added successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call addAWSAccessCredentialsAsync(String namespace, AWSAccessCredentials awsAccessCredentials, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = addAWSAccessCredentialsValidateBeforeCall(namespace, awsAccessCredentials, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for addUserToOrganization - * @param organization organization name (required) - * @param user user to add (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user added to organization successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call addUserToOrganizationCall(String organization, OrganizationUser user, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = user; - - // create path and map variables - String localVarPath = "/organizations/{organization}/user" - .replaceAll("\\{" + "organization" + "\\}", localVarApiClient.escapeString(organization.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call addUserToOrganizationValidateBeforeCall(String organization, OrganizationUser user, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'organization' is set - if (organization == null) { - throw new ApiException("Missing the required parameter 'organization' when calling addUserToOrganization(Async)"); - } - - // verify the required parameter 'user' is set - if (user == null) { - throw new ApiException("Missing the required parameter 'user' when calling addUserToOrganization(Async)"); - } - - - okhttp3.Call localVarCall = addUserToOrganizationCall(organization, user, _callback); - return localVarCall; - - } - - /** - * - * add a user to an organization - * @param organization organization name (required) - * @param user user to add (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user added to organization successfully -
502 Bad Gateway -
0 error response -
- */ - public void addUserToOrganization(String organization, OrganizationUser user) throws ApiException { - addUserToOrganizationWithHttpInfo(organization, user); - } - - /** - * - * add a user to an organization - * @param organization organization name (required) - * @param user user to add (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user added to organization successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse addUserToOrganizationWithHttpInfo(String organization, OrganizationUser user) throws ApiException { - okhttp3.Call localVarCall = addUserToOrganizationValidateBeforeCall(organization, user, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * add a user to an organization - * @param organization organization name (required) - * @param user user to add (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user added to organization successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call addUserToOrganizationAsync(String organization, OrganizationUser user, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = addUserToOrganizationValidateBeforeCall(organization, user, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for checkAWSAccessCredentials - * @param namespace namespace (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 AWS keys are set -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call checkAWSAccessCredentialsCall(String namespace, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/credentials/{namespace}/aws" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call checkAWSAccessCredentialsValidateBeforeCall(String namespace, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling checkAWSAccessCredentials(Async)"); - } - - - okhttp3.Call localVarCall = checkAWSAccessCredentialsCall(namespace, _callback); - return localVarCall; - - } - - /** - * - * Check if aws keys are set - * @param namespace namespace (required) - * @return List<AWSAccessCredentials> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 AWS keys are set -
502 Bad Gateway -
0 error response -
- */ - public List checkAWSAccessCredentials(String namespace) throws ApiException { - ApiResponse> localVarResp = checkAWSAccessCredentialsWithHttpInfo(namespace); - return localVarResp.getData(); - } - - /** - * - * Check if aws keys are set - * @param namespace namespace (required) - * @return ApiResponse<List<AWSAccessCredentials>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 AWS keys are set -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse> checkAWSAccessCredentialsWithHttpInfo(String namespace) throws ApiException { - okhttp3.Call localVarCall = checkAWSAccessCredentialsValidateBeforeCall(namespace, null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Check if aws keys are set - * @param namespace namespace (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 AWS keys are set -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call checkAWSAccessCredentialsAsync(String namespace, final ApiCallback> _callback) throws ApiException { - - okhttp3.Call localVarCall = checkAWSAccessCredentialsValidateBeforeCall(namespace, _callback); - Type localVarReturnType = new TypeToken>(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for checkAWSAccessCredentialsByName - * @param namespace namespace (required) - * @param name name (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 AWS keys are set -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call checkAWSAccessCredentialsByNameCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/credentials/{namespace}/aws/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call checkAWSAccessCredentialsByNameValidateBeforeCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling checkAWSAccessCredentialsByName(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling checkAWSAccessCredentialsByName(Async)"); - } - - - okhttp3.Call localVarCall = checkAWSAccessCredentialsByNameCall(namespace, name, _callback); - return localVarCall; - - } - - /** - * - * Check if aws keys are set by name - * @param namespace namespace (required) - * @param name name (required) - * @return AWSAccessCredentials - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 AWS keys are set -
502 Bad Gateway -
0 error response -
- */ - public AWSAccessCredentials checkAWSAccessCredentialsByName(String namespace, String name) throws ApiException { - ApiResponse localVarResp = checkAWSAccessCredentialsByNameWithHttpInfo(namespace, name); - return localVarResp.getData(); - } - - /** - * - * Check if aws keys are set by name - * @param namespace namespace (required) - * @param name name (required) - * @return ApiResponse<AWSAccessCredentials> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 AWS keys are set -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse checkAWSAccessCredentialsByNameWithHttpInfo(String namespace, String name) throws ApiException { - okhttp3.Call localVarCall = checkAWSAccessCredentialsByNameValidateBeforeCall(namespace, name, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Check if aws keys are set by name - * @param namespace namespace (required) - * @param name name (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 AWS keys are set -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call checkAWSAccessCredentialsByNameAsync(String namespace, String name, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = checkAWSAccessCredentialsByNameValidateBeforeCall(namespace, name, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for confirmEmail - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 User email confirmed successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call confirmEmailCall(final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/user/confirm_email"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call confirmEmailValidateBeforeCall(final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = confirmEmailCall(_callback); - return localVarCall; - - } - - /** - * - * confirm user email - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 User email confirmed successfully -
502 Bad Gateway -
0 error response -
- */ - public void confirmEmail() throws ApiException { - confirmEmailWithHttpInfo(); - } - - /** - * - * confirm user email - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 User email confirmed successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse confirmEmailWithHttpInfo() throws ApiException { - okhttp3.Call localVarCall = confirmEmailValidateBeforeCall(null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * confirm user email - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 User email confirmed successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call confirmEmailAsync(final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = confirmEmailValidateBeforeCall(_callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for createUser - * @param user user to create (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user created successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call createUserCall(User user, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = user; - - // create path and map variables - String localVarPath = "/user"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call createUserValidateBeforeCall(User user, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'user' is set - if (user == null) { - throw new ApiException("Missing the required parameter 'user' when calling createUser(Async)"); - } - - - okhttp3.Call localVarCall = createUserCall(user, _callback); - return localVarCall; - - } - - /** - * - * create a user - * @param user user to create (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user created successfully -
502 Bad Gateway -
0 error response -
- */ - public void createUser(User user) throws ApiException { - createUserWithHttpInfo(user); - } - - /** - * - * create a user - * @param user user to create (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user created successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse createUserWithHttpInfo(User user) throws ApiException { - okhttp3.Call localVarCall = createUserValidateBeforeCall(user, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * create a user - * @param user user to create (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user created successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call createUserAsync(User user, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = createUserValidateBeforeCall(user, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for deleteAWSAccessCredentials - * @param namespace namespace (required) - * @param name name (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS credentials deleted -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteAWSAccessCredentialsCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/credentials/{namespace}/aws/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call deleteAWSAccessCredentialsValidateBeforeCall(String namespace, String name, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling deleteAWSAccessCredentials(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling deleteAWSAccessCredentials(Async)"); - } - - - okhttp3.Call localVarCall = deleteAWSAccessCredentialsCall(namespace, name, _callback); - return localVarCall; - - } - - /** - * - * delete a AWS Access credentials in a namespace. This will likely cause arrays to become unreachable - * @param namespace namespace (required) - * @param name name (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS credentials deleted -
502 Bad Gateway -
0 error response -
- */ - public void deleteAWSAccessCredentials(String namespace, String name) throws ApiException { - deleteAWSAccessCredentialsWithHttpInfo(namespace, name); - } - - /** - * - * delete a AWS Access credentials in a namespace. This will likely cause arrays to become unreachable - * @param namespace namespace (required) - * @param name name (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS credentials deleted -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse deleteAWSAccessCredentialsWithHttpInfo(String namespace, String name) throws ApiException { - okhttp3.Call localVarCall = deleteAWSAccessCredentialsValidateBeforeCall(namespace, name, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * delete a AWS Access credentials in a namespace. This will likely cause arrays to become unreachable - * @param namespace namespace (required) - * @param name name (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS credentials deleted -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteAWSAccessCredentialsAsync(String namespace, String name, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = deleteAWSAccessCredentialsValidateBeforeCall(namespace, name, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for deleteUser - * @param username username or ID (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user deleted -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteUserCall(String username, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/{username}" - .replaceAll("\\{" + "username" + "\\}", localVarApiClient.escapeString(username.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call deleteUserValidateBeforeCall(String username, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'username' is set - if (username == null) { - throw new ApiException("Missing the required parameter 'username' when calling deleteUser(Async)"); - } - - - okhttp3.Call localVarCall = deleteUserCall(username, _callback); - return localVarCall; - - } - - /** - * - * delete a user - * @param username username or ID (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user deleted -
502 Bad Gateway -
0 error response -
- */ - public void deleteUser(String username) throws ApiException { - deleteUserWithHttpInfo(username); - } - - /** - * - * delete a user - * @param username username or ID (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user deleted -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse deleteUserWithHttpInfo(String username) throws ApiException { - okhttp3.Call localVarCall = deleteUserValidateBeforeCall(username, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * delete a user - * @param username username or ID (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user deleted -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteUserAsync(String username, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = deleteUserValidateBeforeCall(username, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for deleteUserFromOrganization - * @param organization organization name (required) - * @param username username to manipulate (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user delete from organization successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteUserFromOrganizationCall(String organization, String username, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/organizations/{organization}/{username}" - .replaceAll("\\{" + "organization" + "\\}", localVarApiClient.escapeString(organization.toString())) - .replaceAll("\\{" + "username" + "\\}", localVarApiClient.escapeString(username.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call deleteUserFromOrganizationValidateBeforeCall(String organization, String username, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'organization' is set - if (organization == null) { - throw new ApiException("Missing the required parameter 'organization' when calling deleteUserFromOrganization(Async)"); - } - - // verify the required parameter 'username' is set - if (username == null) { - throw new ApiException("Missing the required parameter 'username' when calling deleteUserFromOrganization(Async)"); - } - - - okhttp3.Call localVarCall = deleteUserFromOrganizationCall(organization, username, _callback); - return localVarCall; - - } - - /** - * - * delete a user from an organization - * @param organization organization name (required) - * @param username username to manipulate (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user delete from organization successfully -
502 Bad Gateway -
0 error response -
- */ - public void deleteUserFromOrganization(String organization, String username) throws ApiException { - deleteUserFromOrganizationWithHttpInfo(organization, username); - } - - /** - * - * delete a user from an organization - * @param organization organization name (required) - * @param username username to manipulate (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user delete from organization successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse deleteUserFromOrganizationWithHttpInfo(String organization, String username) throws ApiException { - okhttp3.Call localVarCall = deleteUserFromOrganizationValidateBeforeCall(organization, username, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * delete a user from an organization - * @param organization organization name (required) - * @param username username to manipulate (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user delete from organization successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call deleteUserFromOrganizationAsync(String organization, String username, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = deleteUserFromOrganizationValidateBeforeCall(organization, username, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for getOrganizationUser - * @param organization organization name (required) - * @param username username to manipulate (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 user from organization -
404 User is not in organization -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getOrganizationUserCall(String organization, String username, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/organizations/{organization}/{username}" - .replaceAll("\\{" + "organization" + "\\}", localVarApiClient.escapeString(organization.toString())) - .replaceAll("\\{" + "username" + "\\}", localVarApiClient.escapeString(username.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getOrganizationUserValidateBeforeCall(String organization, String username, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'organization' is set - if (organization == null) { - throw new ApiException("Missing the required parameter 'organization' when calling getOrganizationUser(Async)"); - } - - // verify the required parameter 'username' is set - if (username == null) { - throw new ApiException("Missing the required parameter 'username' when calling getOrganizationUser(Async)"); - } - - - okhttp3.Call localVarCall = getOrganizationUserCall(organization, username, _callback); - return localVarCall; - - } - - /** - * - * get a user from an organization - * @param organization organization name (required) - * @param username username to manipulate (required) - * @return OrganizationUser - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 user from organization -
404 User is not in organization -
502 Bad Gateway -
0 error response -
- */ - public OrganizationUser getOrganizationUser(String organization, String username) throws ApiException { - ApiResponse localVarResp = getOrganizationUserWithHttpInfo(organization, username); - return localVarResp.getData(); - } - - /** - * - * get a user from an organization - * @param organization organization name (required) - * @param username username to manipulate (required) - * @return ApiResponse<OrganizationUser> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 user from organization -
404 User is not in organization -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getOrganizationUserWithHttpInfo(String organization, String username) throws ApiException { - okhttp3.Call localVarCall = getOrganizationUserValidateBeforeCall(organization, username, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * get a user from an organization - * @param organization organization name (required) - * @param username username to manipulate (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 user from organization -
404 User is not in organization -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getOrganizationUserAsync(String organization, String username, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getOrganizationUserValidateBeforeCall(organization, username, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getSession - * @param rememberMe flag to create a token with expiration of 30 days, default is false (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Session token -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getSessionCall(String rememberMe, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/session"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (rememberMe != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("remember_me", rememberMe)); - } - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getSessionValidateBeforeCall(String rememberMe, final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = getSessionCall(rememberMe, _callback); - return localVarCall; - - } - - /** - * - * Get session token for user - * @param rememberMe flag to create a token with expiration of 30 days, default is false (optional) - * @return Token - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Session token -
502 Bad Gateway -
0 error response -
- */ - public Token getSession(String rememberMe) throws ApiException { - ApiResponse localVarResp = getSessionWithHttpInfo(rememberMe); - return localVarResp.getData(); - } - - /** - * - * Get session token for user - * @param rememberMe flag to create a token with expiration of 30 days, default is false (optional) - * @return ApiResponse<Token> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Session token -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getSessionWithHttpInfo(String rememberMe) throws ApiException { - okhttp3.Call localVarCall = getSessionValidateBeforeCall(rememberMe, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Get session token for user - * @param rememberMe flag to create a token with expiration of 30 days, default is false (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Session token -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getSessionAsync(String rememberMe, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getSessionValidateBeforeCall(rememberMe, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getTokenScopes - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 available token scopes -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getTokenScopesCall(final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/tokens/scopes"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getTokenScopesValidateBeforeCall(final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = getTokenScopesCall(_callback); - return localVarCall; - - } - - /** - * - * retrieves available token scopes for a user - * @return List<TokenScope> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 available token scopes -
502 Bad Gateway -
0 error response -
- */ - public List getTokenScopes() throws ApiException { - ApiResponse> localVarResp = getTokenScopesWithHttpInfo(); - return localVarResp.getData(); - } - - /** - * - * retrieves available token scopes for a user - * @return ApiResponse<List<TokenScope>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 available token scopes -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse> getTokenScopesWithHttpInfo() throws ApiException { - okhttp3.Call localVarCall = getTokenScopesValidateBeforeCall(null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * retrieves available token scopes for a user - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 available token scopes -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getTokenScopesAsync(final ApiCallback> _callback) throws ApiException { - - okhttp3.Call localVarCall = getTokenScopesValidateBeforeCall(_callback); - Type localVarReturnType = new TypeToken>(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getUser - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 user details -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getUserCall(final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/user"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getUserValidateBeforeCall(final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = getUserCall(_callback); - return localVarCall; - - } - - /** - * - * get a user - * @return User - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 user details -
502 Bad Gateway -
0 error response -
- */ - public User getUser() throws ApiException { - ApiResponse localVarResp = getUserWithHttpInfo(); - return localVarResp.getData(); - } - - /** - * - * get a user - * @return ApiResponse<User> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 user details -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getUserWithHttpInfo() throws ApiException { - okhttp3.Call localVarCall = getUserValidateBeforeCall(null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * get a user - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 user details -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getUserAsync(final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getUserValidateBeforeCall(_callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getUserWithUsername - * @param username username or ID (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 user details -
404 User does not exist -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getUserWithUsernameCall(String username, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/{username}" - .replaceAll("\\{" + "username" + "\\}", localVarApiClient.escapeString(username.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getUserWithUsernameValidateBeforeCall(String username, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'username' is set - if (username == null) { - throw new ApiException("Missing the required parameter 'username' when calling getUserWithUsername(Async)"); - } - - - okhttp3.Call localVarCall = getUserWithUsernameCall(username, _callback); - return localVarCall; - - } - - /** - * - * get a user - * @param username username or ID (required) - * @return User - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 user details -
404 User does not exist -
502 Bad Gateway -
0 error response -
- */ - public User getUserWithUsername(String username) throws ApiException { - ApiResponse localVarResp = getUserWithUsernameWithHttpInfo(username); - return localVarResp.getData(); - } - - /** - * - * get a user - * @param username username or ID (required) - * @return ApiResponse<User> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 user details -
404 User does not exist -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse getUserWithUsernameWithHttpInfo(String username) throws ApiException { - okhttp3.Call localVarCall = getUserWithUsernameValidateBeforeCall(username, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * get a user - * @param username username or ID (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
200 user details -
404 User does not exist -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call getUserWithUsernameAsync(String username, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getUserWithUsernameValidateBeforeCall(username, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for requestToken - * @param tokenRequest token request object (optional) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 token -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call requestTokenCall(TokenRequest tokenRequest, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = tokenRequest; - - // create path and map variables - String localVarPath = "/token"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call requestTokenValidateBeforeCall(TokenRequest tokenRequest, final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = requestTokenCall(tokenRequest, _callback); - return localVarCall; - - } - - /** - * - * Request an authorization token, optionally taken a TokenRequest object to set parameters on the token - * @param tokenRequest token request object (optional) - * @return Token - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 token -
502 Bad Gateway -
0 error response -
- */ - public Token requestToken(TokenRequest tokenRequest) throws ApiException { - ApiResponse localVarResp = requestTokenWithHttpInfo(tokenRequest); - return localVarResp.getData(); - } - - /** - * - * Request an authorization token, optionally taken a TokenRequest object to set parameters on the token - * @param tokenRequest token request object (optional) - * @return ApiResponse<Token> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 token -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse requestTokenWithHttpInfo(TokenRequest tokenRequest) throws ApiException { - okhttp3.Call localVarCall = requestTokenValidateBeforeCall(tokenRequest, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Request an authorization token, optionally taken a TokenRequest object to set parameters on the token - * @param tokenRequest token request object (optional) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 token -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call requestTokenAsync(TokenRequest tokenRequest, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = requestTokenValidateBeforeCall(tokenRequest, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for resetUserPassword - * @param user password to update for user requesting update (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 User password updated successfully -
404 User not found -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call resetUserPasswordCall(ResetUserPasswordRequest user, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = user; - - // create path and map variables - String localVarPath = "/user/password_reset"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call resetUserPasswordValidateBeforeCall(ResetUserPasswordRequest user, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'user' is set - if (user == null) { - throw new ApiException("Missing the required parameter 'user' when calling resetUserPassword(Async)"); - } - - - okhttp3.Call localVarCall = resetUserPasswordCall(user, _callback); - return localVarCall; - - } - - /** - * - * reset user password - * @param user password to update for user requesting update (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 User password updated successfully -
404 User not found -
502 Bad Gateway -
0 error response -
- */ - public void resetUserPassword(ResetUserPasswordRequest user) throws ApiException { - resetUserPasswordWithHttpInfo(user); - } - - /** - * - * reset user password - * @param user password to update for user requesting update (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 User password updated successfully -
404 User not found -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse resetUserPasswordWithHttpInfo(ResetUserPasswordRequest user) throws ApiException { - okhttp3.Call localVarCall = resetUserPasswordValidateBeforeCall(user, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * reset user password - * @param user password to update for user requesting update (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - - -
Status Code Description Response Headers
204 User password updated successfully -
404 User not found -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call resetUserPasswordAsync(ResetUserPasswordRequest user, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = resetUserPasswordValidateBeforeCall(user, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for revokeToken - * @param token token name or token itself (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 revokation successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call revokeTokenCall(String token, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/tokens/{token}" - .replaceAll("\\{" + "token" + "\\}", localVarApiClient.escapeString(token.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call revokeTokenValidateBeforeCall(String token, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'token' is set - if (token == null) { - throw new ApiException("Missing the required parameter 'token' when calling revokeToken(Async)"); - } - - - okhttp3.Call localVarCall = revokeTokenCall(token, _callback); - return localVarCall; - - } - - /** - * - * revoke an authorization token - * @param token token name or token itself (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 revokation successfully -
502 Bad Gateway -
0 error response -
- */ - public void revokeToken(String token) throws ApiException { - revokeTokenWithHttpInfo(token); - } - - /** - * - * revoke an authorization token - * @param token token name or token itself (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 revokation successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse revokeTokenWithHttpInfo(String token) throws ApiException { - okhttp3.Call localVarCall = revokeTokenValidateBeforeCall(token, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * revoke an authorization token - * @param token token name or token itself (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 revokation successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call revokeTokenAsync(String token, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = revokeTokenValidateBeforeCall(token, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for tokensGet - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of user created non-session tokens -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call tokensGetCall(final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/tokens"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call tokensGetValidateBeforeCall(final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = tokensGetCall(_callback); - return localVarCall; - - } - - /** - * - * Fetch a list of user tokens - * @return List<Token> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of user created non-session tokens -
502 Bad Gateway -
0 error response -
- */ - public List tokensGet() throws ApiException { - ApiResponse> localVarResp = tokensGetWithHttpInfo(); - return localVarResp.getData(); - } - - /** - * - * Fetch a list of user tokens - * @return ApiResponse<List<Token>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of user created non-session tokens -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse> tokensGetWithHttpInfo() throws ApiException { - okhttp3.Call localVarCall = tokensGetValidateBeforeCall(null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch a list of user tokens - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of user created non-session tokens -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call tokensGetAsync(final ApiCallback> _callback) throws ApiException { - - okhttp3.Call localVarCall = tokensGetValidateBeforeCall(_callback); - Type localVarReturnType = new TypeToken>(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for tokensSessionGet - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of user created session tokens -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call tokensSessionGetCall(final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/tokens/session"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call tokensSessionGetValidateBeforeCall(final ApiCallback _callback) throws ApiException { - - - okhttp3.Call localVarCall = tokensSessionGetCall(_callback); - return localVarCall; - - } - - /** - * - * Fetch a list of user session tokens - * @return List<Token> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of user created session tokens -
502 Bad Gateway -
0 error response -
- */ - public List tokensSessionGet() throws ApiException { - ApiResponse> localVarResp = tokensSessionGetWithHttpInfo(); - return localVarResp.getData(); - } - - /** - * - * Fetch a list of user session tokens - * @return ApiResponse<List<Token>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of user created session tokens -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse> tokensSessionGetWithHttpInfo() throws ApiException { - okhttp3.Call localVarCall = tokensSessionGetValidateBeforeCall(null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * (asynchronously) - * Fetch a list of user session tokens - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
200 Array of user created session tokens -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call tokensSessionGetAsync(final ApiCallback> _callback) throws ApiException { - - okhttp3.Call localVarCall = tokensSessionGetValidateBeforeCall(_callback); - Type localVarReturnType = new TypeToken>(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for updateAWSAccessCredentials - * @param namespace namespace (required) - * @param name name (required) - * @param awsAccessCredentials aws credentials to update (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS keys updated successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateAWSAccessCredentialsCall(String namespace, String name, AWSAccessCredentials awsAccessCredentials, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = awsAccessCredentials; - - // create path and map variables - String localVarPath = "/credentials/{namespace}/aws/{name}" - .replaceAll("\\{" + "namespace" + "\\}", localVarApiClient.escapeString(namespace.toString())) - .replaceAll("\\{" + "name" + "\\}", localVarApiClient.escapeString(name.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call updateAWSAccessCredentialsValidateBeforeCall(String namespace, String name, AWSAccessCredentials awsAccessCredentials, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'namespace' is set - if (namespace == null) { - throw new ApiException("Missing the required parameter 'namespace' when calling updateAWSAccessCredentials(Async)"); - } - - // verify the required parameter 'name' is set - if (name == null) { - throw new ApiException("Missing the required parameter 'name' when calling updateAWSAccessCredentials(Async)"); - } - - // verify the required parameter 'awsAccessCredentials' is set - if (awsAccessCredentials == null) { - throw new ApiException("Missing the required parameter 'awsAccessCredentials' when calling updateAWSAccessCredentials(Async)"); - } - - - okhttp3.Call localVarCall = updateAWSAccessCredentialsCall(namespace, name, awsAccessCredentials, _callback); - return localVarCall; - - } - - /** - * - * Update aws keys or associated buckets. This will update the key associations for each array in the namespace - * @param namespace namespace (required) - * @param name name (required) - * @param awsAccessCredentials aws credentials to update (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS keys updated successfully -
502 Bad Gateway -
0 error response -
- */ - public void updateAWSAccessCredentials(String namespace, String name, AWSAccessCredentials awsAccessCredentials) throws ApiException { - updateAWSAccessCredentialsWithHttpInfo(namespace, name, awsAccessCredentials); - } - - /** - * - * Update aws keys or associated buckets. This will update the key associations for each array in the namespace - * @param namespace namespace (required) - * @param name name (required) - * @param awsAccessCredentials aws credentials to update (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS keys updated successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse updateAWSAccessCredentialsWithHttpInfo(String namespace, String name, AWSAccessCredentials awsAccessCredentials) throws ApiException { - okhttp3.Call localVarCall = updateAWSAccessCredentialsValidateBeforeCall(namespace, name, awsAccessCredentials, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * Update aws keys or associated buckets. This will update the key associations for each array in the namespace - * @param namespace namespace (required) - * @param name name (required) - * @param awsAccessCredentials aws credentials to update (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 AWS keys updated successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateAWSAccessCredentialsAsync(String namespace, String name, AWSAccessCredentials awsAccessCredentials, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = updateAWSAccessCredentialsValidateBeforeCall(namespace, name, awsAccessCredentials, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for updateUser - * @param username username or ID (required) - * @param user user details to update (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user updated successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateUserCall(String username, User user, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = user; - - // create path and map variables - String localVarPath = "/users/{username}" - .replaceAll("\\{" + "username" + "\\}", localVarApiClient.escapeString(username.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call updateUserValidateBeforeCall(String username, User user, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'username' is set - if (username == null) { - throw new ApiException("Missing the required parameter 'username' when calling updateUser(Async)"); - } - - // verify the required parameter 'user' is set - if (user == null) { - throw new ApiException("Missing the required parameter 'user' when calling updateUser(Async)"); - } - - - okhttp3.Call localVarCall = updateUserCall(username, user, _callback); - return localVarCall; - - } - - /** - * - * update a user - * @param username username or ID (required) - * @param user user details to update (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user updated successfully -
502 Bad Gateway -
0 error response -
- */ - public void updateUser(String username, User user) throws ApiException { - updateUserWithHttpInfo(username, user); - } - - /** - * - * update a user - * @param username username or ID (required) - * @param user user details to update (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user updated successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse updateUserWithHttpInfo(String username, User user) throws ApiException { - okhttp3.Call localVarCall = updateUserValidateBeforeCall(username, user, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * update a user - * @param username username or ID (required) - * @param user user details to update (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user updated successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateUserAsync(String username, User user, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = updateUserValidateBeforeCall(username, user, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } - /** - * Build call for updateUserInOrganization - * @param organization organization name (required) - * @param username username to manipulate (required) - * @param user user details to update (required) - * @param _callback Callback for upload/download progress - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user update in organization successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateUserInOrganizationCall(String organization, String username, OrganizationUser user, final ApiCallback _callback) throws ApiException { - String basePath = null; - // Operation Servers - String[] localBasePaths = new String[] { }; - - // Determine Base Path to Use - if (localCustomBaseUrl != null){ - basePath = localCustomBaseUrl; - } else if ( localBasePaths.length > 0 ) { - basePath = localBasePaths[localHostIndex]; - } else { - basePath = null; - } - - Object localVarPostBody = user; - - // create path and map variables - String localVarPath = "/organizations/{organization}/{username}" - .replaceAll("\\{" + "organization" + "\\}", localVarApiClient.escapeString(organization.toString())) - .replaceAll("\\{" + "username" + "\\}", localVarApiClient.escapeString(username.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - "application/json" - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - if (localVarContentType != null) { - localVarHeaderParams.put("Content-Type", localVarContentType); - } - - String[] localVarAuthNames = new String[] { "ApiKeyAuth", "BasicAuth" }; - return localVarApiClient.buildCall(basePath, localVarPath, "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call updateUserInOrganizationValidateBeforeCall(String organization, String username, OrganizationUser user, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'organization' is set - if (organization == null) { - throw new ApiException("Missing the required parameter 'organization' when calling updateUserInOrganization(Async)"); - } - - // verify the required parameter 'username' is set - if (username == null) { - throw new ApiException("Missing the required parameter 'username' when calling updateUserInOrganization(Async)"); - } - - // verify the required parameter 'user' is set - if (user == null) { - throw new ApiException("Missing the required parameter 'user' when calling updateUserInOrganization(Async)"); - } - - - okhttp3.Call localVarCall = updateUserInOrganizationCall(organization, username, user, _callback); - return localVarCall; - - } - - /** - * - * update a user in an organization - * @param organization organization name (required) - * @param username username to manipulate (required) - * @param user user details to update (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user update in organization successfully -
502 Bad Gateway -
0 error response -
- */ - public void updateUserInOrganization(String organization, String username, OrganizationUser user) throws ApiException { - updateUserInOrganizationWithHttpInfo(organization, username, user); - } - - /** - * - * update a user in an organization - * @param organization organization name (required) - * @param username username to manipulate (required) - * @param user user details to update (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user update in organization successfully -
502 Bad Gateway -
0 error response -
- */ - public ApiResponse updateUserInOrganizationWithHttpInfo(String organization, String username, OrganizationUser user) throws ApiException { - okhttp3.Call localVarCall = updateUserInOrganizationValidateBeforeCall(organization, username, user, null); - return localVarApiClient.execute(localVarCall); - } - - /** - * (asynchronously) - * update a user in an organization - * @param organization organization name (required) - * @param username username to manipulate (required) - * @param user user details to update (required) - * @param _callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - * @http.response.details - - - - - -
Status Code Description Response Headers
204 user update in organization successfully -
502 Bad Gateway -
0 error response -
- */ - public okhttp3.Call updateUserInOrganizationAsync(String organization, String username, OrganizationUser user, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = updateUserInOrganizationValidateBeforeCall(organization, username, user, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); - return localVarCall; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/auth/ApiKeyAuth.java b/src/main/java/io/tiledb/cloud/rest_api/v1/auth/ApiKeyAuth.java deleted file mode 100644 index c77833d..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/auth/ApiKeyAuth.java +++ /dev/null @@ -1,80 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.auth; - -import io.tiledb.cloud.rest_api.v1.ApiException; -import io.tiledb.cloud.rest_api.v1.Pair; - -import java.net.URI; -import java.util.Map; -import java.util.List; - -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ApiKeyAuth implements Authentication { - private final String location; - private final String paramName; - - private String apiKey; - private String apiKeyPrefix; - - public ApiKeyAuth(String location, String paramName) { - this.location = location; - this.paramName = paramName; - } - - public String getLocation() { - return location; - } - - public String getParamName() { - return paramName; - } - - public String getApiKey() { - return apiKey; - } - - public void setApiKey(String apiKey) { - this.apiKey = apiKey; - } - - public String getApiKeyPrefix() { - return apiKeyPrefix; - } - - public void setApiKeyPrefix(String apiKeyPrefix) { - this.apiKeyPrefix = apiKeyPrefix; - } - - @Override - public void applyToParams(List queryParams, Map headerParams, Map cookieParams, - String payload, String method, URI uri) throws ApiException { - if (apiKey == null) { - return; - } - String value; - if (apiKeyPrefix != null) { - value = apiKeyPrefix + " " + apiKey; - } else { - value = apiKey; - } - if ("query".equals(location)) { - queryParams.add(new Pair(paramName, value)); - } else if ("header".equals(location)) { - headerParams.put(paramName, value); - } else if ("cookie".equals(location)) { - cookieParams.put(paramName, value); - } - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/auth/Authentication.java b/src/main/java/io/tiledb/cloud/rest_api/v1/auth/Authentication.java deleted file mode 100644 index b706308..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/auth/Authentication.java +++ /dev/null @@ -1,36 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.auth; - -import io.tiledb.cloud.rest_api.v1.Pair; -import io.tiledb.cloud.rest_api.v1.ApiException; - -import java.net.URI; -import java.util.Map; -import java.util.List; - -public interface Authentication { - /** - * Apply authentication settings to header and query params. - * - * @param queryParams List of query parameters - * @param headerParams Map of header parameters - * @param cookieParams Map of cookie parameters - * @param payload HTTP request body - * @param method HTTP method - * @param uri URI - * @throws ApiException if failed to update the parameters - */ - void applyToParams(List queryParams, Map headerParams, Map cookieParams, String payload, String method, URI uri) throws ApiException; -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/auth/HttpBasicAuth.java b/src/main/java/io/tiledb/cloud/rest_api/v1/auth/HttpBasicAuth.java deleted file mode 100644 index 8861888..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/auth/HttpBasicAuth.java +++ /dev/null @@ -1,55 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.auth; - -import io.tiledb.cloud.rest_api.v1.Pair; -import io.tiledb.cloud.rest_api.v1.ApiException; - -import okhttp3.Credentials; - -import java.net.URI; -import java.util.Map; -import java.util.List; - -public class HttpBasicAuth implements Authentication { - private String username; - private String password; - - public String getUsername() { - return username; - } - - public void setUsername(String username) { - this.username = username; - } - - public String getPassword() { - return password; - } - - public void setPassword(String password) { - this.password = password; - } - - @Override - public void applyToParams(List queryParams, Map headerParams, Map cookieParams, - String payload, String method, URI uri) throws ApiException { - if (username == null && password == null) { - return; - } - headerParams.put("Authorization", Credentials.basic( - username == null ? "" : username, - password == null ? "" : password)); - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/auth/HttpBearerAuth.java b/src/main/java/io/tiledb/cloud/rest_api/v1/auth/HttpBearerAuth.java deleted file mode 100644 index d70dec1..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/auth/HttpBearerAuth.java +++ /dev/null @@ -1,63 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.auth; - -import io.tiledb.cloud.rest_api.v1.ApiException; -import io.tiledb.cloud.rest_api.v1.Pair; - -import java.net.URI; -import java.util.Map; -import java.util.List; - -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class HttpBearerAuth implements Authentication { - private final String scheme; - private String bearerToken; - - public HttpBearerAuth(String scheme) { - this.scheme = scheme; - } - - /** - * Gets the token, which together with the scheme, will be sent as the value of the Authorization header. - * - * @return The bearer token - */ - public String getBearerToken() { - return bearerToken; - } - - /** - * Sets the token, which together with the scheme, will be sent as the value of the Authorization header. - * - * @param bearerToken The bearer token to send in the Authorization header - */ - public void setBearerToken(String bearerToken) { - this.bearerToken = bearerToken; - } - - @Override - public void applyToParams(List queryParams, Map headerParams, Map cookieParams, - String payload, String method, URI uri) throws ApiException { - if (bearerToken == null) { - return; - } - - headerParams.put("Authorization", (scheme != null ? upperCaseBearer(scheme) + " " : "") + bearerToken); - } - - private static String upperCaseBearer(String scheme) { - return ("bearer".equalsIgnoreCase(scheme)) ? "Bearer" : scheme; - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/auth/OAuth.java b/src/main/java/io/tiledb/cloud/rest_api/v1/auth/OAuth.java deleted file mode 100644 index a234fa0..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/auth/OAuth.java +++ /dev/null @@ -1,42 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.auth; - -import io.tiledb.cloud.rest_api.v1.Pair; -import io.tiledb.cloud.rest_api.v1.ApiException; - -import java.net.URI; -import java.util.Map; -import java.util.List; - -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class OAuth implements Authentication { - private String accessToken; - - public String getAccessToken() { - return accessToken; - } - - public void setAccessToken(String accessToken) { - this.accessToken = accessToken; - } - - @Override - public void applyToParams(List queryParams, Map headerParams, Map cookieParams, - String payload, String method, URI uri) throws ApiException { - if (accessToken != null) { - headerParams.put("Authorization", "Bearer " + accessToken); - } - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/auth/OAuthFlow.java b/src/main/java/io/tiledb/cloud/rest_api/v1/auth/OAuthFlow.java deleted file mode 100644 index bd3e3b7..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/auth/OAuthFlow.java +++ /dev/null @@ -1,25 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.auth; - -/** - * OAuth flows that are supported by this client - */ -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public enum OAuthFlow { - ACCESS_CODE, //called authorizationCode in OpenAPI 3.0 - IMPLICIT, - PASSWORD, - APPLICATION //called clientCredentials in OpenAPI 3.0 -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/auth/OAuthOkHttpClient.java b/src/main/java/io/tiledb/cloud/rest_api/v1/auth/OAuthOkHttpClient.java deleted file mode 100644 index f877699..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/auth/OAuthOkHttpClient.java +++ /dev/null @@ -1,68 +0,0 @@ -package io.tiledb.cloud.rest_api.v1.auth; - -import okhttp3.OkHttpClient; -import okhttp3.MediaType; -import okhttp3.Request; -import okhttp3.RequestBody; -import okhttp3.Response; - -import org.apache.oltu.oauth2.client.HttpClient; -import org.apache.oltu.oauth2.client.request.OAuthClientRequest; -import org.apache.oltu.oauth2.client.response.OAuthClientResponse; -import org.apache.oltu.oauth2.client.response.OAuthClientResponseFactory; -import org.apache.oltu.oauth2.common.exception.OAuthProblemException; -import org.apache.oltu.oauth2.common.exception.OAuthSystemException; - -import java.io.IOException; -import java.util.Map; -import java.util.Map.Entry; - -public class OAuthOkHttpClient implements HttpClient { - private OkHttpClient client; - - public OAuthOkHttpClient() { - this.client = new OkHttpClient(); - } - - public OAuthOkHttpClient(OkHttpClient client) { - this.client = client; - } - - @Override - public T execute(OAuthClientRequest request, Map headers, - String requestMethod, Class responseClass) - throws OAuthSystemException, OAuthProblemException { - - MediaType mediaType = MediaType.parse("application/json"); - Request.Builder requestBuilder = new Request.Builder().url(request.getLocationUri()); - - if(headers != null) { - for (Entry entry : headers.entrySet()) { - if (entry.getKey().equalsIgnoreCase("Content-Type")) { - mediaType = MediaType.parse(entry.getValue()); - } else { - requestBuilder.addHeader(entry.getKey(), entry.getValue()); - } - } - } - - RequestBody body = request.getBody() != null ? RequestBody.create(request.getBody(), mediaType) : null; - requestBuilder.method(requestMethod, body); - - try { - Response response = client.newCall(requestBuilder.build()).execute(); - return OAuthClientResponseFactory.createCustomResponse( - response.body().string(), - response.body().contentType().toString(), - response.code(), - responseClass); - } catch (IOException e) { - throw new OAuthSystemException(e); - } - } - - @Override - public void shutdown() { - // Nothing to do here - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/auth/RetryingOAuth.java b/src/main/java/io/tiledb/cloud/rest_api/v1/auth/RetryingOAuth.java deleted file mode 100644 index 7db4c88..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/auth/RetryingOAuth.java +++ /dev/null @@ -1,210 +0,0 @@ -package io.tiledb.cloud.rest_api.v1.auth; - -import io.tiledb.cloud.rest_api.v1.ApiException; -import io.tiledb.cloud.rest_api.v1.Pair; - -import okhttp3.Interceptor; -import okhttp3.OkHttpClient; -import okhttp3.Request; -import okhttp3.Response; - -import org.apache.oltu.oauth2.client.OAuthClient; -import org.apache.oltu.oauth2.client.request.OAuthBearerClientRequest; -import org.apache.oltu.oauth2.client.request.OAuthClientRequest; -import org.apache.oltu.oauth2.client.request.OAuthClientRequest.TokenRequestBuilder; -import org.apache.oltu.oauth2.client.response.OAuthJSONAccessTokenResponse; -import org.apache.oltu.oauth2.common.exception.OAuthProblemException; -import org.apache.oltu.oauth2.common.exception.OAuthSystemException; -import org.apache.oltu.oauth2.common.message.types.GrantType; - -import java.io.IOException; -import java.net.HttpURLConnection; -import java.net.URI; -import java.util.Map; -import java.util.List; - -public class RetryingOAuth extends OAuth implements Interceptor { - private OAuthClient oAuthClient; - - private TokenRequestBuilder tokenRequestBuilder; - - /** - * @param client An OkHttp client - * @param tokenRequestBuilder A token request builder - */ - public RetryingOAuth(OkHttpClient client, TokenRequestBuilder tokenRequestBuilder) { - this.oAuthClient = new OAuthClient(new OAuthOkHttpClient(client)); - this.tokenRequestBuilder = tokenRequestBuilder; - } - - /** - * @param tokenRequestBuilder A token request builder - */ - public RetryingOAuth(TokenRequestBuilder tokenRequestBuilder) { - this(new OkHttpClient(), tokenRequestBuilder); - } - - /** - * @param tokenUrl The token URL to be used for this OAuth2 flow. - * Applicable to the following OAuth2 flows: "password", "clientCredentials" and "authorizationCode". - * The value must be an absolute URL. - * @param clientId The OAuth2 client ID for the "clientCredentials" flow. - * @param flow OAuth flow. - * @param clientSecret The OAuth2 client secret for the "clientCredentials" flow. - * @param parameters A map of string. - */ - public RetryingOAuth( - String tokenUrl, - String clientId, - OAuthFlow flow, - String clientSecret, - Map parameters - ) { - this(OAuthClientRequest.tokenLocation(tokenUrl) - .setClientId(clientId) - .setClientSecret(clientSecret)); - setFlow(flow); - if (parameters != null) { - for (String paramName : parameters.keySet()) { - tokenRequestBuilder.setParameter(paramName, parameters.get(paramName)); - } - } - } - - /** - * Set the OAuth flow - * - * @param flow The OAuth flow. - */ - public void setFlow(OAuthFlow flow) { - switch(flow) { - case ACCESS_CODE: - tokenRequestBuilder.setGrantType(GrantType.AUTHORIZATION_CODE); - break; - case IMPLICIT: - tokenRequestBuilder.setGrantType(GrantType.IMPLICIT); - break; - case PASSWORD: - tokenRequestBuilder.setGrantType(GrantType.PASSWORD); - break; - case APPLICATION: - tokenRequestBuilder.setGrantType(GrantType.CLIENT_CREDENTIALS); - break; - default: - break; - } - } - - @Override - public Response intercept(Chain chain) throws IOException { - return retryingIntercept(chain, true); - } - - private Response retryingIntercept(Chain chain, boolean updateTokenAndRetryOnAuthorizationFailure) throws IOException { - Request request = chain.request(); - - // If the request already has an authorization (e.g. Basic auth), proceed with the request as is - if (request.header("Authorization") != null) { - return chain.proceed(request); - } - - // Get the token if it has not yet been acquired - if (getAccessToken() == null) { - updateAccessToken(null); - } - - OAuthClientRequest oAuthRequest; - if (getAccessToken() != null) { - // Build the request - Request.Builder requestBuilder = request.newBuilder(); - - String requestAccessToken = getAccessToken(); - try { - oAuthRequest = - new OAuthBearerClientRequest(request.url().toString()). - setAccessToken(requestAccessToken). - buildHeaderMessage(); - } catch (OAuthSystemException e) { - throw new IOException(e); - } - - Map headers = oAuthRequest.getHeaders(); - for (String headerName : headers.keySet()) { - requestBuilder.addHeader(headerName, headers.get(headerName)); - } - requestBuilder.url(oAuthRequest.getLocationUri()); - - // Execute the request - Response response = chain.proceed(requestBuilder.build()); - - // 401/403 response codes most likely indicate an expired access token, unless it happens two times in a row - if ( - response != null && - ( response.code() == HttpURLConnection.HTTP_UNAUTHORIZED || - response.code() == HttpURLConnection.HTTP_FORBIDDEN ) && - updateTokenAndRetryOnAuthorizationFailure - ) { - try { - if (updateAccessToken(requestAccessToken)) { - response.body().close(); - return retryingIntercept(chain, false); - } - } catch (Exception e) { - response.body().close(); - throw e; - } - } - return response; - } - else { - return chain.proceed(chain.request()); - } - } - - /** - * Returns true if the access token has been updated - * - * @param requestAccessToken the request access token - * @return True if the update is successful - * @throws java.io.IOException If fail to update the access token - */ - public synchronized boolean updateAccessToken(String requestAccessToken) throws IOException { - if (getAccessToken() == null || getAccessToken().equals(requestAccessToken)) { - try { - OAuthJSONAccessTokenResponse accessTokenResponse = - oAuthClient.accessToken(tokenRequestBuilder.buildBodyMessage()); - if (accessTokenResponse != null && accessTokenResponse.getAccessToken() != null) { - setAccessToken(accessTokenResponse.getAccessToken()); - } - } catch (OAuthSystemException | OAuthProblemException e) { - throw new IOException(e); - } - } - return getAccessToken() == null || !getAccessToken().equals(requestAccessToken); - } - - /** - * Gets the token request builder - * - * @return A token request builder - */ - public TokenRequestBuilder getTokenRequestBuilder() { - return tokenRequestBuilder; - } - - /** - * Sets the token request builder - * - * @param tokenRequestBuilder Token request builder - */ - public void setTokenRequestBuilder(TokenRequestBuilder tokenRequestBuilder) { - this.tokenRequestBuilder = tokenRequestBuilder; - } - - // Applying authorization to parameters is performed in the retryingIntercept method - @Override - public void applyToParams(List queryParams, Map headerParams, Map cookieParams, - String payload, String method, URI uri) throws ApiException { - // No implementation necessary - } -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/AWSAccessCredentials.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/AWSAccessCredentials.java deleted file mode 100644 index adf201d..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/AWSAccessCredentials.java +++ /dev/null @@ -1,491 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.time.OffsetDateTime; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Model representing aws keys or service role, service roles are currently ignored, but will be preferred option in the future - */ -@ApiModel(description = "Model representing aws keys or service role, service roles are currently ignored, but will be preferred option in the future") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class AWSAccessCredentials { - public static final String SERIALIZED_NAME_SECRET_ACCESS_KEY = "secret_access_key"; - @SerializedName(SERIALIZED_NAME_SECRET_ACCESS_KEY) - private String secretAccessKey; - - public static final String SERIALIZED_NAME_ACCESS_KEY_ID = "access_key_id"; - @SerializedName(SERIALIZED_NAME_ACCESS_KEY_ID) - private String accessKeyId; - - public static final String SERIALIZED_NAME_SERVICE_ROLE_ARN = "service_role_arn"; - @SerializedName(SERIALIZED_NAME_SERVICE_ROLE_ARN) - private String serviceRoleArn; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_DEFAULT = "default"; - @SerializedName(SERIALIZED_NAME_DEFAULT) - private Boolean _default; - - public static final String SERIALIZED_NAME_BUCKETS = "buckets"; - @SerializedName(SERIALIZED_NAME_BUCKETS) - private List buckets = null; - - public static final String SERIALIZED_NAME_CREATED_AT = "created_at"; - @SerializedName(SERIALIZED_NAME_CREATED_AT) - private OffsetDateTime createdAt; - - public static final String SERIALIZED_NAME_UPDATED_AT = "updated_at"; - @SerializedName(SERIALIZED_NAME_UPDATED_AT) - private OffsetDateTime updatedAt; - - public AWSAccessCredentials() { - } - - - public AWSAccessCredentials( - OffsetDateTime createdAt, - OffsetDateTime updatedAt - ) { - this(); - this.createdAt = createdAt; - this.updatedAt = updatedAt; - } - - public AWSAccessCredentials secretAccessKey(String secretAccessKey) { - - this.secretAccessKey = secretAccessKey; - return this; - } - - /** - * aws secret access key, never returned in get requests - * @return secretAccessKey - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "aws secret access key, never returned in get requests") - - public String getSecretAccessKey() { - return secretAccessKey; - } - - - public void setSecretAccessKey(String secretAccessKey) { - this.secretAccessKey = secretAccessKey; - } - - - public AWSAccessCredentials accessKeyId(String accessKeyId) { - - this.accessKeyId = accessKeyId; - return this; - } - - /** - * aws access key - * @return accessKeyId - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "aws access key") - - public String getAccessKeyId() { - return accessKeyId; - } - - - public void setAccessKeyId(String accessKeyId) { - this.accessKeyId = accessKeyId; - } - - - public AWSAccessCredentials serviceRoleArn(String serviceRoleArn) { - - this.serviceRoleArn = serviceRoleArn; - return this; - } - - /** - * aws service role to use for access - * @return serviceRoleArn - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "aws service role to use for access") - - public String getServiceRoleArn() { - return serviceRoleArn; - } - - - public void setServiceRoleArn(String serviceRoleArn) { - this.serviceRoleArn = serviceRoleArn; - } - - - public AWSAccessCredentials name(String name) { - - this.name = name; - return this; - } - - /** - * human readable name - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "human readable name") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public AWSAccessCredentials _default(Boolean _default) { - - this._default = _default; - return this; - } - - /** - * true if this is the default credential to be used within this namespace - * @return _default - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "true if this is the default credential to be used within this namespace") - - public Boolean getDefault() { - return _default; - } - - - public void setDefault(Boolean _default) { - this._default = _default; - } - - - public AWSAccessCredentials buckets(List buckets) { - - this.buckets = buckets; - return this; - } - - public AWSAccessCredentials addBucketsItem(String bucketsItem) { - if (this.buckets == null) { - this.buckets = new ArrayList<>(); - } - this.buckets.add(bucketsItem); - return this; - } - - /** - * a whitelist of one or more buckets this key should access - * @return buckets - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "a whitelist of one or more buckets this key should access") - - public List getBuckets() { - return buckets; - } - - - public void setBuckets(List buckets) { - this.buckets = buckets; - } - - - /** - * Time when UDF dependencies were created (rfc3339) - * @return createdAt - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Time when UDF dependencies were created (rfc3339)") - - public OffsetDateTime getCreatedAt() { - return createdAt; - } - - - - - /** - * Time when UDF dependencies was last updated (rfc3339) - * @return updatedAt - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Time when UDF dependencies was last updated (rfc3339)") - - public OffsetDateTime getUpdatedAt() { - return updatedAt; - } - - - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public AWSAccessCredentials putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - AWSAccessCredentials awSAccessCredentials = (AWSAccessCredentials) o; - return Objects.equals(this.secretAccessKey, awSAccessCredentials.secretAccessKey) && - Objects.equals(this.accessKeyId, awSAccessCredentials.accessKeyId) && - Objects.equals(this.serviceRoleArn, awSAccessCredentials.serviceRoleArn) && - Objects.equals(this.name, awSAccessCredentials.name) && - Objects.equals(this._default, awSAccessCredentials._default) && - Objects.equals(this.buckets, awSAccessCredentials.buckets) && - Objects.equals(this.createdAt, awSAccessCredentials.createdAt) && - Objects.equals(this.updatedAt, awSAccessCredentials.updatedAt)&& - Objects.equals(this.additionalProperties, awSAccessCredentials.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(secretAccessKey, accessKeyId, serviceRoleArn, name, _default, buckets, createdAt, updatedAt, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class AWSAccessCredentials {\n"); - sb.append(" secretAccessKey: ").append(toIndentedString(secretAccessKey)).append("\n"); - sb.append(" accessKeyId: ").append(toIndentedString(accessKeyId)).append("\n"); - sb.append(" serviceRoleArn: ").append(toIndentedString(serviceRoleArn)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" _default: ").append(toIndentedString(_default)).append("\n"); - sb.append(" buckets: ").append(toIndentedString(buckets)).append("\n"); - sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); - sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("secret_access_key"); - openapiFields.add("access_key_id"); - openapiFields.add("service_role_arn"); - openapiFields.add("name"); - openapiFields.add("default"); - openapiFields.add("buckets"); - openapiFields.add("created_at"); - openapiFields.add("updated_at"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to AWSAccessCredentials - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (AWSAccessCredentials.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in AWSAccessCredentials is not found in the empty JSON string", AWSAccessCredentials.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("secret_access_key") != null && !jsonObj.get("secret_access_key").isJsonNull()) && !jsonObj.get("secret_access_key").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `secret_access_key` to be a primitive type in the JSON string but got `%s`", jsonObj.get("secret_access_key").toString())); - } - if ((jsonObj.get("access_key_id") != null && !jsonObj.get("access_key_id").isJsonNull()) && !jsonObj.get("access_key_id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `access_key_id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("access_key_id").toString())); - } - if ((jsonObj.get("service_role_arn") != null && !jsonObj.get("service_role_arn").isJsonNull()) && !jsonObj.get("service_role_arn").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `service_role_arn` to be a primitive type in the JSON string but got `%s`", jsonObj.get("service_role_arn").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("buckets") != null && !jsonObj.get("buckets").isJsonNull()) && !jsonObj.get("buckets").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `buckets` to be an array in the JSON string but got `%s`", jsonObj.get("buckets").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!AWSAccessCredentials.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'AWSAccessCredentials' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(AWSAccessCredentials.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, AWSAccessCredentials value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public AWSAccessCredentials read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - AWSAccessCredentials instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of AWSAccessCredentials given an JSON string - * - * @param jsonString JSON string - * @return An instance of AWSAccessCredentials - * @throws IOException if the JSON string is invalid with respect to AWSAccessCredentials - */ - public static AWSAccessCredentials fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, AWSAccessCredentials.class); - } - - /** - * Convert an instance of AWSAccessCredentials to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/AbstractOpenApiSchema.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/AbstractOpenApiSchema.java deleted file mode 100644 index 6b3c77b..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/AbstractOpenApiSchema.java +++ /dev/null @@ -1,147 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Map; -import javax.ws.rs.core.GenericType; - -//import com.fasterxml.jackson.annotation.JsonValue; - -/** - * Abstract class for oneOf,anyOf schemas defined in OpenAPI spec - */ -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public abstract class AbstractOpenApiSchema { - - // store the actual instance of the schema/object - private Object instance; - - // is nullable - private Boolean isNullable; - - // schema type (e.g. oneOf, anyOf) - private final String schemaType; - - public AbstractOpenApiSchema(String schemaType, Boolean isNullable) { - this.schemaType = schemaType; - this.isNullable = isNullable; - } - - /** - * Get the list of oneOf/anyOf composed schemas allowed to be stored in this object - * - * @return an instance of the actual schema/object - */ - public abstract Map getSchemas(); - - /** - * Get the actual instance - * - * @return an instance of the actual schema/object - */ - //@JsonValue - public Object getActualInstance() {return instance;} - - /** - * Set the actual instance - * - * @param instance the actual instance of the schema/object - */ - public void setActualInstance(Object instance) {this.instance = instance;} - - /** - * Get the instant recursively when the schemas defined in oneOf/anyof happen to be oneOf/anyOf schema as well - * - * @return an instance of the actual schema/object - */ - public Object getActualInstanceRecursively() { - return getActualInstanceRecursively(this); - } - - private Object getActualInstanceRecursively(AbstractOpenApiSchema object) { - if (object.getActualInstance() == null) { - return null; - } else if (object.getActualInstance() instanceof AbstractOpenApiSchema) { - return getActualInstanceRecursively((AbstractOpenApiSchema)object.getActualInstance()); - } else { - return object.getActualInstance(); - } - } - - /** - * Get the schema type (e.g. anyOf, oneOf) - * - * @return the schema type - */ - public String getSchemaType() { - return schemaType; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ").append(getClass()).append(" {\n"); - sb.append(" instance: ").append(toIndentedString(instance)).append("\n"); - sb.append(" isNullable: ").append(toIndentedString(isNullable)).append("\n"); - sb.append(" schemaType: ").append(toIndentedString(schemaType)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - AbstractOpenApiSchema a = (AbstractOpenApiSchema) o; - return Objects.equals(this.instance, a.instance) && - Objects.equals(this.isNullable, a.isNullable) && - Objects.equals(this.schemaType, a.schemaType); - } - - @Override - public int hashCode() { - return Objects.hash(instance, isNullable, schemaType); - } - - /** - * Is nullable - * - * @return true if it's nullable - */ - public Boolean isNullable() { - if (Boolean.TRUE.equals(isNullable)) { - return Boolean.TRUE; - } else { - return Boolean.FALSE; - } - } - - - -} diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ActivityEventType.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ActivityEventType.java deleted file mode 100644 index a0668a9..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ActivityEventType.java +++ /dev/null @@ -1,95 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * Type of activity logged - */ -@JsonAdapter(ActivityEventType.Adapter.class) -public enum ActivityEventType { - - READ_SCHEMA("read_schema"), - - MAX_BUFFER_SIZES("max_buffer_sizes"), - - NON_EMPTY_DOMAIN("non_empty_domain"), - - QUERY_READ("query_read"), - - QUERY_WRITE("query_write"), - - QUERY_DELETE("query_delete"), - - CREATE("create"), - - DELETE("delete"), - - REGISTER("register"), - - DEREGISTER("deregister"), - - UDF("udf"), - - ARRAY_METADATA_GET("array_metadata_get"), - - ARRAY_METADATA_UPDATE("array_metadata_update"), - - ESTIMATED_RESULT_SIZES("estimated_result_sizes"), - - READ_FRAGMENT_INFO("read_fragment_info"); - - private String value; - - ActivityEventType(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static ActivityEventType fromValue(String value) { - for (ActivityEventType b : ActivityEventType.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final ActivityEventType enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public ActivityEventType read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return ActivityEventType.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Array.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/Array.java deleted file mode 100644 index 69bb9b6..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Array.java +++ /dev/null @@ -1,336 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.math.BigDecimal; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Represents an open array - */ -@ApiModel(description = "Represents an open array") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class Array { - public static final String SERIALIZED_NAME_TIMESTAMP = "timestamp"; - @SerializedName(SERIALIZED_NAME_TIMESTAMP) - private BigDecimal timestamp; - - public static final String SERIALIZED_NAME_QUERY_TYPE = "queryType"; - @SerializedName(SERIALIZED_NAME_QUERY_TYPE) - private Querytype queryType; - - public static final String SERIALIZED_NAME_URI = "uri"; - @SerializedName(SERIALIZED_NAME_URI) - private String uri; - - public Array() { - } - - public Array timestamp(BigDecimal timestamp) { - - this.timestamp = timestamp; - return this; - } - - /** - * timestamp (epoch milliseconds) array is opened at - * @return timestamp - **/ - @javax.annotation.Nonnull - @ApiModelProperty(example = "1540471791873", required = true, value = "timestamp (epoch milliseconds) array is opened at") - - public BigDecimal getTimestamp() { - return timestamp; - } - - - public void setTimestamp(BigDecimal timestamp) { - this.timestamp = timestamp; - } - - - public Array queryType(Querytype queryType) { - - this.queryType = queryType; - return this; - } - - /** - * Get queryType - * @return queryType - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public Querytype getQueryType() { - return queryType; - } - - - public void setQueryType(Querytype queryType) { - this.queryType = queryType; - } - - - public Array uri(String uri) { - - this.uri = uri; - return this; - } - - /** - * Array uri - * @return uri - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "Array uri") - - public String getUri() { - return uri; - } - - - public void setUri(String uri) { - this.uri = uri; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public Array putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Array array = (Array) o; - return Objects.equals(this.timestamp, array.timestamp) && - Objects.equals(this.queryType, array.queryType) && - Objects.equals(this.uri, array.uri)&& - Objects.equals(this.additionalProperties, array.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(timestamp, queryType, uri, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Array {\n"); - sb.append(" timestamp: ").append(toIndentedString(timestamp)).append("\n"); - sb.append(" queryType: ").append(toIndentedString(queryType)).append("\n"); - sb.append(" uri: ").append(toIndentedString(uri)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("timestamp"); - openapiFields.add("queryType"); - openapiFields.add("uri"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - openapiRequiredFields.add("timestamp"); - openapiRequiredFields.add("queryType"); - openapiRequiredFields.add("uri"); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to Array - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (Array.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in Array is not found in the empty JSON string", Array.openapiRequiredFields.toString())); - } - } - - // check to make sure all required properties/fields are present in the JSON string - for (String requiredField : Array.openapiRequiredFields) { - if (jsonObj.get(requiredField) == null) { - throw new IllegalArgumentException(String.format("The required field `%s` is not found in the JSON string: %s", requiredField, jsonObj.toString())); - } - } - if ((jsonObj.get("uri") != null && !jsonObj.get("uri").isJsonNull()) && !jsonObj.get("uri").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `uri` to be a primitive type in the JSON string but got `%s`", jsonObj.get("uri").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!Array.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'Array' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(Array.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, Array value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public Array read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - Array instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of Array given an JSON string - * - * @param jsonString JSON string - * @return An instance of Array - * @throws IOException if the JSON string is invalid with respect to Array - */ - public static Array fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, Array.class); - } - - /** - * Convert an instance of Array to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayActions.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayActions.java deleted file mode 100644 index 8aa0047..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayActions.java +++ /dev/null @@ -1,77 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * actions a user can take on an array - */ -@JsonAdapter(ArrayActions.Adapter.class) -public enum ArrayActions { - - READ("read"), - - WRITE("write"), - - EDIT("edit"), - - READ_ARRAY_LOGS("read_array_logs"), - - READ_ARRAY_INFO("read_array_info"), - - READ_ARRAY_SCHEMA("read_array_schema"); - - private String value; - - ArrayActions(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static ArrayActions fromValue(String value) { - for (ArrayActions b : ArrayActions.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final ArrayActions enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public ArrayActions read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return ArrayActions.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayActivityLog.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayActivityLog.java deleted file mode 100644 index cf6baf4..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayActivityLog.java +++ /dev/null @@ -1,518 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.time.OffsetDateTime; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Actvity of an Array - */ -@ApiModel(description = "Actvity of an Array") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ArrayActivityLog { - public static final String SERIALIZED_NAME_EVENT_AT = "event_at"; - @SerializedName(SERIALIZED_NAME_EVENT_AT) - private OffsetDateTime eventAt; - - public static final String SERIALIZED_NAME_ACTION = "action"; - @SerializedName(SERIALIZED_NAME_ACTION) - private ActivityEventType action; - - public static final String SERIALIZED_NAME_USERNAME = "username"; - @SerializedName(SERIALIZED_NAME_USERNAME) - private String username; - - public static final String SERIALIZED_NAME_BYTES_SENT = "bytes_sent"; - @SerializedName(SERIALIZED_NAME_BYTES_SENT) - private Integer bytesSent; - - public static final String SERIALIZED_NAME_BYTES_RECEIVED = "bytes_received"; - @SerializedName(SERIALIZED_NAME_BYTES_RECEIVED) - private Integer bytesReceived; - - public static final String SERIALIZED_NAME_ARRAY_TASK_ID = "array_task_id"; - @SerializedName(SERIALIZED_NAME_ARRAY_TASK_ID) - private String arrayTaskId; - - public static final String SERIALIZED_NAME_ID = "id"; - @SerializedName(SERIALIZED_NAME_ID) - private String id; - - public static final String SERIALIZED_NAME_QUERY_RANGES = "query_ranges"; - @SerializedName(SERIALIZED_NAME_QUERY_RANGES) - private String queryRanges; - - public static final String SERIALIZED_NAME_QUERY_STATS = "query_stats"; - @SerializedName(SERIALIZED_NAME_QUERY_STATS) - private String queryStats; - - public ArrayActivityLog() { - } - - public ArrayActivityLog eventAt(OffsetDateTime eventAt) { - - this.eventAt = eventAt; - return this; - } - - /** - * time event took place (RFC3339) - * @return eventAt - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "time event took place (RFC3339)") - - public OffsetDateTime getEventAt() { - return eventAt; - } - - - public void setEventAt(OffsetDateTime eventAt) { - this.eventAt = eventAt; - } - - - public ArrayActivityLog action(ActivityEventType action) { - - this.action = action; - return this; - } - - /** - * Get action - * @return action - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public ActivityEventType getAction() { - return action; - } - - - public void setAction(ActivityEventType action) { - this.action = action; - } - - - public ArrayActivityLog username(String username) { - - this.username = username; - return this; - } - - /** - * User who performed action - * @return username - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "user1", value = "User who performed action") - - public String getUsername() { - return username; - } - - - public void setUsername(String username) { - this.username = username; - } - - - public ArrayActivityLog bytesSent(Integer bytesSent) { - - this.bytesSent = bytesSent; - return this; - } - - /** - * Bytes sent to client - * @return bytesSent - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "1073741824", value = "Bytes sent to client") - - public Integer getBytesSent() { - return bytesSent; - } - - - public void setBytesSent(Integer bytesSent) { - this.bytesSent = bytesSent; - } - - - public ArrayActivityLog bytesReceived(Integer bytesReceived) { - - this.bytesReceived = bytesReceived; - return this; - } - - /** - * Bytes recieved from client - * @return bytesReceived - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "1073741824", value = "Bytes recieved from client") - - public Integer getBytesReceived() { - return bytesReceived; - } - - - public void setBytesReceived(Integer bytesReceived) { - this.bytesReceived = bytesReceived; - } - - - public ArrayActivityLog arrayTaskId(String arrayTaskId) { - - this.arrayTaskId = arrayTaskId; - return this; - } - - /** - * UUID of associated array task - * @return arrayTaskId - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "UUID of associated array task") - - public String getArrayTaskId() { - return arrayTaskId; - } - - - public void setArrayTaskId(String arrayTaskId) { - this.arrayTaskId = arrayTaskId; - } - - - public ArrayActivityLog id(String id) { - - this.id = id; - return this; - } - - /** - * ID of the activity - * @return id - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "ID of the activity") - - public String getId() { - return id; - } - - - public void setId(String id) { - this.id = id; - } - - - public ArrayActivityLog queryRanges(String queryRanges) { - - this.queryRanges = queryRanges; - return this; - } - - /** - * ranges for query - * @return queryRanges - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "{\"rows\":[{\"start\": 1, \"end\": 1},{\"start\": 3, \"end\": 4}],\"cols\":[{\"start\": 1, \"end\": 4}]}", value = "ranges for query") - - public String getQueryRanges() { - return queryRanges; - } - - - public void setQueryRanges(String queryRanges) { - this.queryRanges = queryRanges; - } - - - public ArrayActivityLog queryStats(String queryStats) { - - this.queryStats = queryStats; - return this; - } - - /** - * stats for query - * @return queryStats - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "{\"timers\": {\"Context.StorageManager.read_load_array_schema_from_uri.sum\": 0.0255293, \"...\": \"...\"}, \"counters\": {\"Context.StorageManager.read_unfiltered_byte_num\": 191, \"...\": \"...\"}}", value = "stats for query") - - public String getQueryStats() { - return queryStats; - } - - - public void setQueryStats(String queryStats) { - this.queryStats = queryStats; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public ArrayActivityLog putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ArrayActivityLog arrayActivityLog = (ArrayActivityLog) o; - return Objects.equals(this.eventAt, arrayActivityLog.eventAt) && - Objects.equals(this.action, arrayActivityLog.action) && - Objects.equals(this.username, arrayActivityLog.username) && - Objects.equals(this.bytesSent, arrayActivityLog.bytesSent) && - Objects.equals(this.bytesReceived, arrayActivityLog.bytesReceived) && - Objects.equals(this.arrayTaskId, arrayActivityLog.arrayTaskId) && - Objects.equals(this.id, arrayActivityLog.id) && - Objects.equals(this.queryRanges, arrayActivityLog.queryRanges) && - Objects.equals(this.queryStats, arrayActivityLog.queryStats)&& - Objects.equals(this.additionalProperties, arrayActivityLog.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(eventAt, action, username, bytesSent, bytesReceived, arrayTaskId, id, queryRanges, queryStats, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ArrayActivityLog {\n"); - sb.append(" eventAt: ").append(toIndentedString(eventAt)).append("\n"); - sb.append(" action: ").append(toIndentedString(action)).append("\n"); - sb.append(" username: ").append(toIndentedString(username)).append("\n"); - sb.append(" bytesSent: ").append(toIndentedString(bytesSent)).append("\n"); - sb.append(" bytesReceived: ").append(toIndentedString(bytesReceived)).append("\n"); - sb.append(" arrayTaskId: ").append(toIndentedString(arrayTaskId)).append("\n"); - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" queryRanges: ").append(toIndentedString(queryRanges)).append("\n"); - sb.append(" queryStats: ").append(toIndentedString(queryStats)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("event_at"); - openapiFields.add("action"); - openapiFields.add("username"); - openapiFields.add("bytes_sent"); - openapiFields.add("bytes_received"); - openapiFields.add("array_task_id"); - openapiFields.add("id"); - openapiFields.add("query_ranges"); - openapiFields.add("query_stats"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to ArrayActivityLog - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (ArrayActivityLog.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in ArrayActivityLog is not found in the empty JSON string", ArrayActivityLog.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("username") != null && !jsonObj.get("username").isJsonNull()) && !jsonObj.get("username").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `username` to be a primitive type in the JSON string but got `%s`", jsonObj.get("username").toString())); - } - if ((jsonObj.get("array_task_id") != null && !jsonObj.get("array_task_id").isJsonNull()) && !jsonObj.get("array_task_id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `array_task_id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("array_task_id").toString())); - } - if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) && !jsonObj.get("id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("id").toString())); - } - if ((jsonObj.get("query_ranges") != null && !jsonObj.get("query_ranges").isJsonNull()) && !jsonObj.get("query_ranges").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `query_ranges` to be a primitive type in the JSON string but got `%s`", jsonObj.get("query_ranges").toString())); - } - if ((jsonObj.get("query_stats") != null && !jsonObj.get("query_stats").isJsonNull()) && !jsonObj.get("query_stats").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `query_stats` to be a primitive type in the JSON string but got `%s`", jsonObj.get("query_stats").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!ArrayActivityLog.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'ArrayActivityLog' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(ArrayActivityLog.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, ArrayActivityLog value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public ArrayActivityLog read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - ArrayActivityLog instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of ArrayActivityLog given an JSON string - * - * @param jsonString JSON string - * @return An instance of ArrayActivityLog - * @throws IOException if the JSON string is invalid with respect to ArrayActivityLog - */ - public static ArrayActivityLog fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, ArrayActivityLog.class); - } - - /** - * Convert an instance of ArrayActivityLog to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayBrowserData.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayBrowserData.java deleted file mode 100644 index 9872c44..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayBrowserData.java +++ /dev/null @@ -1,319 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Object including array info and pagination metadata - */ -@ApiModel(description = "Object including array info and pagination metadata") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ArrayBrowserData { - public static final String SERIALIZED_NAME_ARRAYS = "arrays"; - @SerializedName(SERIALIZED_NAME_ARRAYS) - private List arrays = null; - - public static final String SERIALIZED_NAME_PAGINATION_METADATA = "pagination_metadata"; - @SerializedName(SERIALIZED_NAME_PAGINATION_METADATA) - private PaginationMetadata paginationMetadata; - - public ArrayBrowserData() { - } - - public ArrayBrowserData arrays(List arrays) { - - this.arrays = arrays; - return this; - } - - public ArrayBrowserData addArraysItem(ArrayInfo arraysItem) { - if (this.arrays == null) { - this.arrays = new ArrayList<>(); - } - this.arrays.add(arraysItem); - return this; - } - - /** - * Array Info - * @return arrays - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Array Info") - - public List getArrays() { - return arrays; - } - - - public void setArrays(List arrays) { - this.arrays = arrays; - } - - - public ArrayBrowserData paginationMetadata(PaginationMetadata paginationMetadata) { - - this.paginationMetadata = paginationMetadata; - return this; - } - - /** - * Get paginationMetadata - * @return paginationMetadata - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public PaginationMetadata getPaginationMetadata() { - return paginationMetadata; - } - - - public void setPaginationMetadata(PaginationMetadata paginationMetadata) { - this.paginationMetadata = paginationMetadata; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public ArrayBrowserData putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ArrayBrowserData arrayBrowserData = (ArrayBrowserData) o; - return Objects.equals(this.arrays, arrayBrowserData.arrays) && - Objects.equals(this.paginationMetadata, arrayBrowserData.paginationMetadata)&& - Objects.equals(this.additionalProperties, arrayBrowserData.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(arrays, paginationMetadata, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ArrayBrowserData {\n"); - sb.append(" arrays: ").append(toIndentedString(arrays)).append("\n"); - sb.append(" paginationMetadata: ").append(toIndentedString(paginationMetadata)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("arrays"); - openapiFields.add("pagination_metadata"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to ArrayBrowserData - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (ArrayBrowserData.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in ArrayBrowserData is not found in the empty JSON string", ArrayBrowserData.openapiRequiredFields.toString())); - } - } - JsonArray jsonArrayarrays = jsonObj.getAsJsonArray("arrays"); - if (jsonArrayarrays != null) { - // ensure the json data is an array - if (!jsonObj.get("arrays").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `arrays` to be an array in the JSON string but got `%s`", jsonObj.get("arrays").toString())); - } - - // validate the optional field `arrays` (array) - for (int i = 0; i < jsonArrayarrays.size(); i++) { - ArrayInfo.validateJsonObject(jsonArrayarrays.get(i).getAsJsonObject()); - }; - } - // validate the optional field `pagination_metadata` - if (jsonObj.get("pagination_metadata") != null && !jsonObj.get("pagination_metadata").isJsonNull()) { - PaginationMetadata.validateJsonObject(jsonObj.getAsJsonObject("pagination_metadata")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!ArrayBrowserData.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'ArrayBrowserData' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(ArrayBrowserData.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, ArrayBrowserData value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public ArrayBrowserData read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - ArrayBrowserData instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of ArrayBrowserData given an JSON string - * - * @param jsonString JSON string - * @return An instance of ArrayBrowserData - * @throws IOException if the JSON string is invalid with respect to ArrayBrowserData - */ - public static ArrayBrowserData fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, ArrayBrowserData.class); - } - - /** - * Convert an instance of ArrayBrowserData to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayBrowserSidebar.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayBrowserSidebar.java deleted file mode 100644 index 4e26595..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayBrowserSidebar.java +++ /dev/null @@ -1,336 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Object for ui array tasks browser page - */ -@ApiModel(description = "Object for ui array tasks browser page") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ArrayBrowserSidebar { - public static final String SERIALIZED_NAME_NAMESPACES = "namespaces"; - @SerializedName(SERIALIZED_NAME_NAMESPACES) - private List namespaces = null; - - public static final String SERIALIZED_NAME_RESULT_COUNT_FOR_ALL = "result_count_for_all"; - @SerializedName(SERIALIZED_NAME_RESULT_COUNT_FOR_ALL) - private Integer resultCountForAll; - - public static final String SERIALIZED_NAME_RESULT_COUNT_BY_NAMESPACE = "result_count_by_namespace"; - @SerializedName(SERIALIZED_NAME_RESULT_COUNT_BY_NAMESPACE) - private Object resultCountByNamespace; - - public ArrayBrowserSidebar() { - } - - public ArrayBrowserSidebar namespaces(List namespaces) { - - this.namespaces = namespaces; - return this; - } - - public ArrayBrowserSidebar addNamespacesItem(String namespacesItem) { - if (this.namespaces == null) { - this.namespaces = new ArrayList<>(); - } - this.namespaces.add(namespacesItem); - return this; - } - - /** - * list of all unique namespaces to display - * @return namespaces - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "list of all unique namespaces to display") - - public List getNamespaces() { - return namespaces; - } - - - public void setNamespaces(List namespaces) { - this.namespaces = namespaces; - } - - - public ArrayBrowserSidebar resultCountForAll(Integer resultCountForAll) { - - this.resultCountForAll = resultCountForAll; - return this; - } - - /** - * A count of \"all\" of category - * @return resultCountForAll - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "A count of \"all\" of category") - - public Integer getResultCountForAll() { - return resultCountForAll; - } - - - public void setResultCountForAll(Integer resultCountForAll) { - this.resultCountForAll = resultCountForAll; - } - - - public ArrayBrowserSidebar resultCountByNamespace(Object resultCountByNamespace) { - - this.resultCountByNamespace = resultCountByNamespace; - return this; - } - - /** - * A map that includes the result count by namespace - * @return resultCountByNamespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "A map that includes the result count by namespace") - - public Object getResultCountByNamespace() { - return resultCountByNamespace; - } - - - public void setResultCountByNamespace(Object resultCountByNamespace) { - this.resultCountByNamespace = resultCountByNamespace; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public ArrayBrowserSidebar putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ArrayBrowserSidebar arrayBrowserSidebar = (ArrayBrowserSidebar) o; - return Objects.equals(this.namespaces, arrayBrowserSidebar.namespaces) && - Objects.equals(this.resultCountForAll, arrayBrowserSidebar.resultCountForAll) && - Objects.equals(this.resultCountByNamespace, arrayBrowserSidebar.resultCountByNamespace)&& - Objects.equals(this.additionalProperties, arrayBrowserSidebar.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(namespaces, resultCountForAll, resultCountByNamespace, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ArrayBrowserSidebar {\n"); - sb.append(" namespaces: ").append(toIndentedString(namespaces)).append("\n"); - sb.append(" resultCountForAll: ").append(toIndentedString(resultCountForAll)).append("\n"); - sb.append(" resultCountByNamespace: ").append(toIndentedString(resultCountByNamespace)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("namespaces"); - openapiFields.add("result_count_for_all"); - openapiFields.add("result_count_by_namespace"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to ArrayBrowserSidebar - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (ArrayBrowserSidebar.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in ArrayBrowserSidebar is not found in the empty JSON string", ArrayBrowserSidebar.openapiRequiredFields.toString())); - } - } - // ensure the json data is an array - if ((jsonObj.get("namespaces") != null && !jsonObj.get("namespaces").isJsonNull()) && !jsonObj.get("namespaces").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `namespaces` to be an array in the JSON string but got `%s`", jsonObj.get("namespaces").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!ArrayBrowserSidebar.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'ArrayBrowserSidebar' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(ArrayBrowserSidebar.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, ArrayBrowserSidebar value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public ArrayBrowserSidebar read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - ArrayBrowserSidebar instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of ArrayBrowserSidebar given an JSON string - * - * @param jsonString JSON string - * @return An instance of ArrayBrowserSidebar - * @throws IOException if the JSON string is invalid with respect to ArrayBrowserSidebar - */ - public static ArrayBrowserSidebar fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, ArrayBrowserSidebar.class); - } - - /** - * Convert an instance of ArrayBrowserSidebar to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayConsolidationRequest.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayConsolidationRequest.java deleted file mode 100644 index a5a6d1a..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayConsolidationRequest.java +++ /dev/null @@ -1,266 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Request to consolidate an array - */ -@ApiModel(description = "Request to consolidate an array") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ArrayConsolidationRequest { - public static final String SERIALIZED_NAME_CONFIG = "config"; - @SerializedName(SERIALIZED_NAME_CONFIG) - private TileDBConfig config; - - public ArrayConsolidationRequest() { - } - - public ArrayConsolidationRequest config(TileDBConfig config) { - - this.config = config; - return this; - } - - /** - * Get config - * @return config - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public TileDBConfig getConfig() { - return config; - } - - - public void setConfig(TileDBConfig config) { - this.config = config; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public ArrayConsolidationRequest putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ArrayConsolidationRequest arrayConsolidationRequest = (ArrayConsolidationRequest) o; - return Objects.equals(this.config, arrayConsolidationRequest.config)&& - Objects.equals(this.additionalProperties, arrayConsolidationRequest.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(config, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ArrayConsolidationRequest {\n"); - sb.append(" config: ").append(toIndentedString(config)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("config"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to ArrayConsolidationRequest - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (ArrayConsolidationRequest.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in ArrayConsolidationRequest is not found in the empty JSON string", ArrayConsolidationRequest.openapiRequiredFields.toString())); - } - } - // validate the optional field `config` - if (jsonObj.get("config") != null && !jsonObj.get("config").isJsonNull()) { - TileDBConfig.validateJsonObject(jsonObj.getAsJsonObject("config")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!ArrayConsolidationRequest.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'ArrayConsolidationRequest' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(ArrayConsolidationRequest.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, ArrayConsolidationRequest value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public ArrayConsolidationRequest read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - ArrayConsolidationRequest instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of ArrayConsolidationRequest given an JSON string - * - * @param jsonString JSON string - * @return An instance of ArrayConsolidationRequest - * @throws IOException if the JSON string is invalid with respect to ArrayConsolidationRequest - */ - public static ArrayConsolidationRequest fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, ArrayConsolidationRequest.class); - } - - /** - * Convert an instance of ArrayConsolidationRequest to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayEndTimestampData.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayEndTimestampData.java deleted file mode 100644 index 4abaccd..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayEndTimestampData.java +++ /dev/null @@ -1,310 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Object including array end_timestamps (list of Unix epoch timestamps in milliseconds) and pagination metadata - */ -@ApiModel(description = "Object including array end_timestamps (list of Unix epoch timestamps in milliseconds) and pagination metadata") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ArrayEndTimestampData { - public static final String SERIALIZED_NAME_END_TIMESTAMPS = "end_timestamps"; - @SerializedName(SERIALIZED_NAME_END_TIMESTAMPS) - private List endTimestamps = null; - - public static final String SERIALIZED_NAME_PAGINATION_METADATA = "pagination_metadata"; - @SerializedName(SERIALIZED_NAME_PAGINATION_METADATA) - private PaginationMetadata paginationMetadata; - - public ArrayEndTimestampData() { - } - - public ArrayEndTimestampData endTimestamps(List endTimestamps) { - - this.endTimestamps = endTimestamps; - return this; - } - - public ArrayEndTimestampData addEndTimestampsItem(Integer endTimestampsItem) { - if (this.endTimestamps == null) { - this.endTimestamps = new ArrayList<>(); - } - this.endTimestamps.add(endTimestampsItem); - return this; - } - - /** - * List of timestamps expressed in milliseconds since Unix epoch - * @return endTimestamps - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "List of timestamps expressed in milliseconds since Unix epoch") - - public List getEndTimestamps() { - return endTimestamps; - } - - - public void setEndTimestamps(List endTimestamps) { - this.endTimestamps = endTimestamps; - } - - - public ArrayEndTimestampData paginationMetadata(PaginationMetadata paginationMetadata) { - - this.paginationMetadata = paginationMetadata; - return this; - } - - /** - * Get paginationMetadata - * @return paginationMetadata - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public PaginationMetadata getPaginationMetadata() { - return paginationMetadata; - } - - - public void setPaginationMetadata(PaginationMetadata paginationMetadata) { - this.paginationMetadata = paginationMetadata; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public ArrayEndTimestampData putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ArrayEndTimestampData arrayEndTimestampData = (ArrayEndTimestampData) o; - return Objects.equals(this.endTimestamps, arrayEndTimestampData.endTimestamps) && - Objects.equals(this.paginationMetadata, arrayEndTimestampData.paginationMetadata)&& - Objects.equals(this.additionalProperties, arrayEndTimestampData.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(endTimestamps, paginationMetadata, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ArrayEndTimestampData {\n"); - sb.append(" endTimestamps: ").append(toIndentedString(endTimestamps)).append("\n"); - sb.append(" paginationMetadata: ").append(toIndentedString(paginationMetadata)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("end_timestamps"); - openapiFields.add("pagination_metadata"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to ArrayEndTimestampData - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (ArrayEndTimestampData.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in ArrayEndTimestampData is not found in the empty JSON string", ArrayEndTimestampData.openapiRequiredFields.toString())); - } - } - // ensure the json data is an array - if ((jsonObj.get("end_timestamps") != null && !jsonObj.get("end_timestamps").isJsonNull()) && !jsonObj.get("end_timestamps").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `end_timestamps` to be an array in the JSON string but got `%s`", jsonObj.get("end_timestamps").toString())); - } - // validate the optional field `pagination_metadata` - if (jsonObj.get("pagination_metadata") != null && !jsonObj.get("pagination_metadata").isJsonNull()) { - PaginationMetadata.validateJsonObject(jsonObj.getAsJsonObject("pagination_metadata")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!ArrayEndTimestampData.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'ArrayEndTimestampData' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(ArrayEndTimestampData.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, ArrayEndTimestampData value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public ArrayEndTimestampData read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - ArrayEndTimestampData instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of ArrayEndTimestampData given an JSON string - * - * @param jsonString JSON string - * @return An instance of ArrayEndTimestampData - * @throws IOException if the JSON string is invalid with respect to ArrayEndTimestampData - */ - public static ArrayEndTimestampData fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, ArrayEndTimestampData.class); - } - - /** - * Convert an instance of ArrayEndTimestampData to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayFavorite.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayFavorite.java deleted file mode 100644 index 9318836..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayFavorite.java +++ /dev/null @@ -1,331 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * A user-favorite array item - */ -@ApiModel(description = "A user-favorite array item") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ArrayFavorite { - public static final String SERIALIZED_NAME_ARRAY_UUID = "array_uuid"; - @SerializedName(SERIALIZED_NAME_ARRAY_UUID) - private String arrayUuid; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public ArrayFavorite() { - } - - public ArrayFavorite arrayUuid(String arrayUuid) { - - this.arrayUuid = arrayUuid; - return this; - } - - /** - * unique UUID of the array - * @return arrayUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "unique UUID of the array") - - public String getArrayUuid() { - return arrayUuid; - } - - - public void setArrayUuid(String arrayUuid) { - this.arrayUuid = arrayUuid; - } - - - public ArrayFavorite namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * the namespace of the array - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "the namespace of the array") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - - public ArrayFavorite name(String name) { - - this.name = name; - return this; - } - - /** - * the name of the array - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "the name of the array") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public ArrayFavorite putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ArrayFavorite arrayFavorite = (ArrayFavorite) o; - return Objects.equals(this.arrayUuid, arrayFavorite.arrayUuid) && - Objects.equals(this.namespace, arrayFavorite.namespace) && - Objects.equals(this.name, arrayFavorite.name)&& - Objects.equals(this.additionalProperties, arrayFavorite.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(arrayUuid, namespace, name, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ArrayFavorite {\n"); - sb.append(" arrayUuid: ").append(toIndentedString(arrayUuid)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("array_uuid"); - openapiFields.add("namespace"); - openapiFields.add("name"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to ArrayFavorite - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (ArrayFavorite.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in ArrayFavorite is not found in the empty JSON string", ArrayFavorite.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("array_uuid") != null && !jsonObj.get("array_uuid").isJsonNull()) && !jsonObj.get("array_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `array_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("array_uuid").toString())); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!ArrayFavorite.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'ArrayFavorite' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(ArrayFavorite.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, ArrayFavorite value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public ArrayFavorite read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - ArrayFavorite instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of ArrayFavorite given an JSON string - * - * @param jsonString JSON string - * @return An instance of ArrayFavorite - * @throws IOException if the JSON string is invalid with respect to ArrayFavorite - */ - public static ArrayFavorite fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, ArrayFavorite.class); - } - - /** - * Convert an instance of ArrayFavorite to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayFavoritesData.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayFavoritesData.java deleted file mode 100644 index 495db61..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayFavoritesData.java +++ /dev/null @@ -1,319 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Object including array favorites and pagination metadata - */ -@ApiModel(description = "Object including array favorites and pagination metadata") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ArrayFavoritesData { - public static final String SERIALIZED_NAME_ARRAYS = "arrays"; - @SerializedName(SERIALIZED_NAME_ARRAYS) - private List arrays = null; - - public static final String SERIALIZED_NAME_PAGINATION_METADATA = "pagination_metadata"; - @SerializedName(SERIALIZED_NAME_PAGINATION_METADATA) - private PaginationMetadata paginationMetadata; - - public ArrayFavoritesData() { - } - - public ArrayFavoritesData arrays(List arrays) { - - this.arrays = arrays; - return this; - } - - public ArrayFavoritesData addArraysItem(ArrayInfo arraysItem) { - if (this.arrays == null) { - this.arrays = new ArrayList<>(); - } - this.arrays.add(arraysItem); - return this; - } - - /** - * List of array infos - * @return arrays - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "List of array infos") - - public List getArrays() { - return arrays; - } - - - public void setArrays(List arrays) { - this.arrays = arrays; - } - - - public ArrayFavoritesData paginationMetadata(PaginationMetadata paginationMetadata) { - - this.paginationMetadata = paginationMetadata; - return this; - } - - /** - * Get paginationMetadata - * @return paginationMetadata - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public PaginationMetadata getPaginationMetadata() { - return paginationMetadata; - } - - - public void setPaginationMetadata(PaginationMetadata paginationMetadata) { - this.paginationMetadata = paginationMetadata; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public ArrayFavoritesData putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ArrayFavoritesData arrayFavoritesData = (ArrayFavoritesData) o; - return Objects.equals(this.arrays, arrayFavoritesData.arrays) && - Objects.equals(this.paginationMetadata, arrayFavoritesData.paginationMetadata)&& - Objects.equals(this.additionalProperties, arrayFavoritesData.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(arrays, paginationMetadata, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ArrayFavoritesData {\n"); - sb.append(" arrays: ").append(toIndentedString(arrays)).append("\n"); - sb.append(" paginationMetadata: ").append(toIndentedString(paginationMetadata)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("arrays"); - openapiFields.add("pagination_metadata"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to ArrayFavoritesData - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (ArrayFavoritesData.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in ArrayFavoritesData is not found in the empty JSON string", ArrayFavoritesData.openapiRequiredFields.toString())); - } - } - JsonArray jsonArrayarrays = jsonObj.getAsJsonArray("arrays"); - if (jsonArrayarrays != null) { - // ensure the json data is an array - if (!jsonObj.get("arrays").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `arrays` to be an array in the JSON string but got `%s`", jsonObj.get("arrays").toString())); - } - - // validate the optional field `arrays` (array) - for (int i = 0; i < jsonArrayarrays.size(); i++) { - ArrayInfo.validateJsonObject(jsonArrayarrays.get(i).getAsJsonObject()); - }; - } - // validate the optional field `pagination_metadata` - if (jsonObj.get("pagination_metadata") != null && !jsonObj.get("pagination_metadata").isJsonNull()) { - PaginationMetadata.validateJsonObject(jsonObj.getAsJsonObject("pagination_metadata")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!ArrayFavoritesData.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'ArrayFavoritesData' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(ArrayFavoritesData.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, ArrayFavoritesData value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public ArrayFavoritesData read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - ArrayFavoritesData instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of ArrayFavoritesData given an JSON string - * - * @param jsonString JSON string - * @return An instance of ArrayFavoritesData - * @throws IOException if the JSON string is invalid with respect to ArrayFavoritesData - */ - public static ArrayFavoritesData fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, ArrayFavoritesData.class); - } - - /** - * Convert an instance of ArrayFavoritesData to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayInfo.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayInfo.java deleted file mode 100644 index c555660..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayInfo.java +++ /dev/null @@ -1,1071 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.math.BigDecimal; -import java.time.OffsetDateTime; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import org.openapitools.jackson.nullable.JsonNullable; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashSet; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * metadata of an array - */ -@ApiModel(description = "metadata of an array") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ArrayInfo { - public static final String SERIALIZED_NAME_ID = "id"; - @SerializedName(SERIALIZED_NAME_ID) - private String id; - - public static final String SERIALIZED_NAME_FILE_TYPE = "file_type"; - @SerializedName(SERIALIZED_NAME_FILE_TYPE) - private FileType fileType; - - public static final String SERIALIZED_NAME_FILE_PROPERTIES = "file_properties"; - @SerializedName(SERIALIZED_NAME_FILE_PROPERTIES) - private Map fileProperties = null; - - public static final String SERIALIZED_NAME_URI = "uri"; - @SerializedName(SERIALIZED_NAME_URI) - private String uri; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public static final String SERIALIZED_NAME_SIZE = "size"; - @SerializedName(SERIALIZED_NAME_SIZE) - private BigDecimal size; - - public static final String SERIALIZED_NAME_LAST_ACCESSED = "last_accessed"; - @SerializedName(SERIALIZED_NAME_LAST_ACCESSED) - private OffsetDateTime lastAccessed; - - public static final String SERIALIZED_NAME_DESCRIPTION = "description"; - @SerializedName(SERIALIZED_NAME_DESCRIPTION) - private String description; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_ALLOWED_ACTIONS = "allowed_actions"; - @SerializedName(SERIALIZED_NAME_ALLOWED_ACTIONS) - private List allowedActions = null; - - public static final String SERIALIZED_NAME_PRICING = "pricing"; - @SerializedName(SERIALIZED_NAME_PRICING) - private List pricing = null; - - public static final String SERIALIZED_NAME_SUBSCRIPTIONS = "subscriptions"; - @SerializedName(SERIALIZED_NAME_SUBSCRIPTIONS) - private List subscriptions = null; - - public static final String SERIALIZED_NAME_LOGO = "logo"; - @SerializedName(SERIALIZED_NAME_LOGO) - private String logo; - - public static final String SERIALIZED_NAME_ACCESS_CREDENTIALS_NAME = "access_credentials_name"; - @SerializedName(SERIALIZED_NAME_ACCESS_CREDENTIALS_NAME) - private String accessCredentialsName; - - public static final String SERIALIZED_NAME_TYPE = "type"; - @SerializedName(SERIALIZED_NAME_TYPE) - private ArrayType type; - - public static final String SERIALIZED_NAME_SHARE_COUNT = "share_count"; - @SerializedName(SERIALIZED_NAME_SHARE_COUNT) - private BigDecimal shareCount; - - public static final String SERIALIZED_NAME_PUBLIC_SHARE = "public_share"; - @SerializedName(SERIALIZED_NAME_PUBLIC_SHARE) - private Boolean publicShare; - - public static final String SERIALIZED_NAME_NAMESPACE_SUBSCRIBED = "namespace_subscribed"; - @SerializedName(SERIALIZED_NAME_NAMESPACE_SUBSCRIBED) - private Boolean namespaceSubscribed; - - public static final String SERIALIZED_NAME_TILEDB_URI = "tiledb_uri"; - @SerializedName(SERIALIZED_NAME_TILEDB_URI) - private String tiledbUri; - - public static final String SERIALIZED_NAME_TAGS = "tags"; - @SerializedName(SERIALIZED_NAME_TAGS) - private List tags = null; - - public static final String SERIALIZED_NAME_LICENSE_ID = "license_id"; - @SerializedName(SERIALIZED_NAME_LICENSE_ID) - private String licenseId; - - public static final String SERIALIZED_NAME_LICENSE_TEXT = "license_text"; - @SerializedName(SERIALIZED_NAME_LICENSE_TEXT) - private String licenseText; - - public static final String SERIALIZED_NAME_READ_ONLY = "read_only"; - @SerializedName(SERIALIZED_NAME_READ_ONLY) - private Boolean readOnly; - - public static final String SERIALIZED_NAME_IS_FAVORITE = "is_favorite"; - @SerializedName(SERIALIZED_NAME_IS_FAVORITE) - private Boolean isFavorite; - - public ArrayInfo() { - } - - - public ArrayInfo( - Boolean namespaceSubscribed - ) { - this(); - this.namespaceSubscribed = namespaceSubscribed; - } - - public ArrayInfo id(String id) { - - this.id = id; - return this; - } - - /** - * unique ID of registered array - * @return id - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "unique ID of registered array") - - public String getId() { - return id; - } - - - public void setId(String id) { - this.id = id; - } - - - public ArrayInfo fileType(FileType fileType) { - - this.fileType = fileType; - return this; - } - - /** - * Get fileType - * @return fileType - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public FileType getFileType() { - return fileType; - } - - - public void setFileType(FileType fileType) { - this.fileType = fileType; - } - - - public ArrayInfo fileProperties(Map fileProperties) { - - this.fileProperties = fileProperties; - return this; - } - - public ArrayInfo putFilePropertiesItem(String key, String filePropertiesItem) { - if (this.fileProperties == null) { - this.fileProperties = new HashMap<>(); - } - this.fileProperties.put(key, filePropertiesItem); - return this; - } - - /** - * map of file properties created for this array - * @return fileProperties - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "map of file properties created for this array") - - public Map getFileProperties() { - return fileProperties; - } - - - public void setFileProperties(Map fileProperties) { - this.fileProperties = fileProperties; - } - - - public ArrayInfo uri(String uri) { - - this.uri = uri; - return this; - } - - /** - * uri of array - * @return uri - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "s3://bucket/array", value = "uri of array") - - public String getUri() { - return uri; - } - - - public void setUri(String uri) { - this.uri = uri; - } - - - public ArrayInfo namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * namespace array is in - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "user1", value = "namespace array is in") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - - public ArrayInfo size(BigDecimal size) { - - this.size = size; - return this; - } - - /** - * size in bytes of array - * @return size - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "1024.0", value = "size in bytes of array") - - public BigDecimal getSize() { - return size; - } - - - public void setSize(BigDecimal size) { - this.size = size; - } - - - public ArrayInfo lastAccessed(OffsetDateTime lastAccessed) { - - this.lastAccessed = lastAccessed; - return this; - } - - /** - * Datetime array was last accessed in UTC - * @return lastAccessed - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Datetime array was last accessed in UTC") - - public OffsetDateTime getLastAccessed() { - return lastAccessed; - } - - - public void setLastAccessed(OffsetDateTime lastAccessed) { - this.lastAccessed = lastAccessed; - } - - - public ArrayInfo description(String description) { - - this.description = description; - return this; - } - - /** - * description of array - * @return description - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "description of array") - - public String getDescription() { - return description; - } - - - public void setDescription(String description) { - this.description = description; - } - - - public ArrayInfo name(String name) { - - this.name = name; - return this; - } - - /** - * name of array - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "myarray1", value = "name of array") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public ArrayInfo allowedActions(List allowedActions) { - - this.allowedActions = allowedActions; - return this; - } - - public ArrayInfo addAllowedActionsItem(ArrayActions allowedActionsItem) { - if (this.allowedActions == null) { - this.allowedActions = new ArrayList<>(); - } - this.allowedActions.add(allowedActionsItem); - return this; - } - - /** - * list of actions user is allowed to do on this array - * @return allowedActions - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "list of actions user is allowed to do on this array") - - public List getAllowedActions() { - return allowedActions; - } - - - public void setAllowedActions(List allowedActions) { - this.allowedActions = allowedActions; - } - - - public ArrayInfo pricing(List pricing) { - - this.pricing = pricing; - return this; - } - - public ArrayInfo addPricingItem(Pricing pricingItem) { - if (this.pricing == null) { - this.pricing = new ArrayList<>(); - } - this.pricing.add(pricingItem); - return this; - } - - /** - * list of pricing created for this array - * @return pricing - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "list of pricing created for this array") - - public List getPricing() { - return pricing; - } - - - public void setPricing(List pricing) { - this.pricing = pricing; - } - - - public ArrayInfo subscriptions(List subscriptions) { - - this.subscriptions = subscriptions; - return this; - } - - public ArrayInfo addSubscriptionsItem(Subscription subscriptionsItem) { - if (this.subscriptions == null) { - this.subscriptions = new ArrayList<>(); - } - this.subscriptions.add(subscriptionsItem); - return this; - } - - /** - * list of subscriptions created for this array - * @return subscriptions - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "list of subscriptions created for this array") - - public List getSubscriptions() { - return subscriptions; - } - - - public void setSubscriptions(List subscriptions) { - this.subscriptions = subscriptions; - } - - - public ArrayInfo logo(String logo) { - - this.logo = logo; - return this; - } - - /** - * logo (base64 encoded) for the array. Optional - * @return logo - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "logo (base64 encoded) for the array. Optional") - - public String getLogo() { - return logo; - } - - - public void setLogo(String logo) { - this.logo = logo; - } - - - public ArrayInfo accessCredentialsName(String accessCredentialsName) { - - this.accessCredentialsName = accessCredentialsName; - return this; - } - - /** - * the name of the access credentials to use. if unset, the default credentials will be used - * @return accessCredentialsName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "the name of the access credentials to use. if unset, the default credentials will be used") - - public String getAccessCredentialsName() { - return accessCredentialsName; - } - - - public void setAccessCredentialsName(String accessCredentialsName) { - this.accessCredentialsName = accessCredentialsName; - } - - - public ArrayInfo type(ArrayType type) { - - this.type = type; - return this; - } - - /** - * Get type - * @return type - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public ArrayType getType() { - return type; - } - - - public void setType(ArrayType type) { - this.type = type; - } - - - public ArrayInfo shareCount(BigDecimal shareCount) { - - this.shareCount = shareCount; - return this; - } - - /** - * number of unique namespaces this array is shared with - * @return shareCount - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "number of unique namespaces this array is shared with") - - public BigDecimal getShareCount() { - return shareCount; - } - - - public void setShareCount(BigDecimal shareCount) { - this.shareCount = shareCount; - } - - - public ArrayInfo publicShare(Boolean publicShare) { - - this.publicShare = publicShare; - return this; - } - - /** - * Suggests if the array was shared to public by owner - * @return publicShare - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "true", value = "Suggests if the array was shared to public by owner") - - public Boolean getPublicShare() { - return publicShare; - } - - - public void setPublicShare(Boolean publicShare) { - this.publicShare = publicShare; - } - - - /** - * Depends on the namespace asking, denotes the existence of subscription of namespace to this array - * @return namespaceSubscribed - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "false", value = "Depends on the namespace asking, denotes the existence of subscription of namespace to this array") - - public Boolean getNamespaceSubscribed() { - return namespaceSubscribed; - } - - - - - public ArrayInfo tiledbUri(String tiledbUri) { - - this.tiledbUri = tiledbUri; - return this; - } - - /** - * uri for access through TileDB cloud - * @return tiledbUri - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "uri for access through TileDB cloud") - - public String getTiledbUri() { - return tiledbUri; - } - - - public void setTiledbUri(String tiledbUri) { - this.tiledbUri = tiledbUri; - } - - - public ArrayInfo tags(List tags) { - - this.tags = tags; - return this; - } - - public ArrayInfo addTagsItem(String tagsItem) { - if (this.tags == null) { - this.tags = new ArrayList<>(); - } - this.tags.add(tagsItem); - return this; - } - - /** - * optional tags for array - * @return tags - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "optional tags for array") - - public List getTags() { - return tags; - } - - - public void setTags(List tags) { - this.tags = tags; - } - - - public ArrayInfo licenseId(String licenseId) { - - this.licenseId = licenseId; - return this; - } - - /** - * License identifier from SPDX License List or Custom - * @return licenseId - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "License identifier from SPDX License List or Custom") - - public String getLicenseId() { - return licenseId; - } - - - public void setLicenseId(String licenseId) { - this.licenseId = licenseId; - } - - - public ArrayInfo licenseText(String licenseText) { - - this.licenseText = licenseText; - return this; - } - - /** - * License text - * @return licenseText - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "License text") - - public String getLicenseText() { - return licenseText; - } - - - public void setLicenseText(String licenseText) { - this.licenseText = licenseText; - } - - - public ArrayInfo readOnly(Boolean readOnly) { - - this.readOnly = readOnly; - return this; - } - - /** - * Suggests if the array is in read_only mode - * @return readOnly - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "false", value = "Suggests if the array is in read_only mode") - - public Boolean getReadOnly() { - return readOnly; - } - - - public void setReadOnly(Boolean readOnly) { - this.readOnly = readOnly; - } - - - public ArrayInfo isFavorite(Boolean isFavorite) { - - this.isFavorite = isFavorite; - return this; - } - - /** - * Indicates whether the array is in user favorites - * @return isFavorite - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "true", value = "Indicates whether the array is in user favorites") - - public Boolean getIsFavorite() { - return isFavorite; - } - - - public void setIsFavorite(Boolean isFavorite) { - this.isFavorite = isFavorite; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public ArrayInfo putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ArrayInfo arrayInfo = (ArrayInfo) o; - return Objects.equals(this.id, arrayInfo.id) && - Objects.equals(this.fileType, arrayInfo.fileType) && - Objects.equals(this.fileProperties, arrayInfo.fileProperties) && - Objects.equals(this.uri, arrayInfo.uri) && - Objects.equals(this.namespace, arrayInfo.namespace) && - Objects.equals(this.size, arrayInfo.size) && - Objects.equals(this.lastAccessed, arrayInfo.lastAccessed) && - Objects.equals(this.description, arrayInfo.description) && - Objects.equals(this.name, arrayInfo.name) && - Objects.equals(this.allowedActions, arrayInfo.allowedActions) && - Objects.equals(this.pricing, arrayInfo.pricing) && - Objects.equals(this.subscriptions, arrayInfo.subscriptions) && - Objects.equals(this.logo, arrayInfo.logo) && - Objects.equals(this.accessCredentialsName, arrayInfo.accessCredentialsName) && - Objects.equals(this.type, arrayInfo.type) && - Objects.equals(this.shareCount, arrayInfo.shareCount) && - Objects.equals(this.publicShare, arrayInfo.publicShare) && - Objects.equals(this.namespaceSubscribed, arrayInfo.namespaceSubscribed) && - Objects.equals(this.tiledbUri, arrayInfo.tiledbUri) && - Objects.equals(this.tags, arrayInfo.tags) && - Objects.equals(this.licenseId, arrayInfo.licenseId) && - Objects.equals(this.licenseText, arrayInfo.licenseText) && - Objects.equals(this.readOnly, arrayInfo.readOnly) && - Objects.equals(this.isFavorite, arrayInfo.isFavorite)&& - Objects.equals(this.additionalProperties, arrayInfo.additionalProperties); - } - - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); - } - - @Override - public int hashCode() { - return Objects.hash(id, fileType, fileProperties, uri, namespace, size, lastAccessed, description, name, allowedActions, pricing, subscriptions, logo, accessCredentialsName, type, shareCount, publicShare, namespaceSubscribed, tiledbUri, tags, licenseId, licenseText, readOnly, isFavorite, additionalProperties); - } - - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ArrayInfo {\n"); - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" fileType: ").append(toIndentedString(fileType)).append("\n"); - sb.append(" fileProperties: ").append(toIndentedString(fileProperties)).append("\n"); - sb.append(" uri: ").append(toIndentedString(uri)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" size: ").append(toIndentedString(size)).append("\n"); - sb.append(" lastAccessed: ").append(toIndentedString(lastAccessed)).append("\n"); - sb.append(" description: ").append(toIndentedString(description)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" allowedActions: ").append(toIndentedString(allowedActions)).append("\n"); - sb.append(" pricing: ").append(toIndentedString(pricing)).append("\n"); - sb.append(" subscriptions: ").append(toIndentedString(subscriptions)).append("\n"); - sb.append(" logo: ").append(toIndentedString(logo)).append("\n"); - sb.append(" accessCredentialsName: ").append(toIndentedString(accessCredentialsName)).append("\n"); - sb.append(" type: ").append(toIndentedString(type)).append("\n"); - sb.append(" shareCount: ").append(toIndentedString(shareCount)).append("\n"); - sb.append(" publicShare: ").append(toIndentedString(publicShare)).append("\n"); - sb.append(" namespaceSubscribed: ").append(toIndentedString(namespaceSubscribed)).append("\n"); - sb.append(" tiledbUri: ").append(toIndentedString(tiledbUri)).append("\n"); - sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); - sb.append(" licenseId: ").append(toIndentedString(licenseId)).append("\n"); - sb.append(" licenseText: ").append(toIndentedString(licenseText)).append("\n"); - sb.append(" readOnly: ").append(toIndentedString(readOnly)).append("\n"); - sb.append(" isFavorite: ").append(toIndentedString(isFavorite)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("id"); - openapiFields.add("file_type"); - openapiFields.add("file_properties"); - openapiFields.add("uri"); - openapiFields.add("namespace"); - openapiFields.add("size"); - openapiFields.add("last_accessed"); - openapiFields.add("description"); - openapiFields.add("name"); - openapiFields.add("allowed_actions"); - openapiFields.add("pricing"); - openapiFields.add("subscriptions"); - openapiFields.add("logo"); - openapiFields.add("access_credentials_name"); - openapiFields.add("type"); - openapiFields.add("share_count"); - openapiFields.add("public_share"); - openapiFields.add("namespace_subscribed"); - openapiFields.add("tiledb_uri"); - openapiFields.add("tags"); - openapiFields.add("license_id"); - openapiFields.add("license_text"); - openapiFields.add("read_only"); - openapiFields.add("is_favorite"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to ArrayInfo - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (ArrayInfo.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in ArrayInfo is not found in the empty JSON string", ArrayInfo.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) && !jsonObj.get("id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("id").toString())); - } - if ((jsonObj.get("uri") != null && !jsonObj.get("uri").isJsonNull()) && !jsonObj.get("uri").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `uri` to be a primitive type in the JSON string but got `%s`", jsonObj.get("uri").toString())); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - if ((jsonObj.get("description") != null && !jsonObj.get("description").isJsonNull()) && !jsonObj.get("description").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `description` to be a primitive type in the JSON string but got `%s`", jsonObj.get("description").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("allowed_actions") != null && !jsonObj.get("allowed_actions").isJsonNull()) && !jsonObj.get("allowed_actions").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `allowed_actions` to be an array in the JSON string but got `%s`", jsonObj.get("allowed_actions").toString())); - } - JsonArray jsonArraypricing = jsonObj.getAsJsonArray("pricing"); - if (jsonArraypricing != null) { - // ensure the json data is an array - if (!jsonObj.get("pricing").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `pricing` to be an array in the JSON string but got `%s`", jsonObj.get("pricing").toString())); - } - - // validate the optional field `pricing` (array) - for (int i = 0; i < jsonArraypricing.size(); i++) { - Pricing.validateJsonObject(jsonArraypricing.get(i).getAsJsonObject()); - }; - } - JsonArray jsonArraysubscriptions = jsonObj.getAsJsonArray("subscriptions"); - if (jsonArraysubscriptions != null) { - // ensure the json data is an array - if (!jsonObj.get("subscriptions").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `subscriptions` to be an array in the JSON string but got `%s`", jsonObj.get("subscriptions").toString())); - } - - // validate the optional field `subscriptions` (array) - for (int i = 0; i < jsonArraysubscriptions.size(); i++) { - Subscription.validateJsonObject(jsonArraysubscriptions.get(i).getAsJsonObject()); - }; - } - if ((jsonObj.get("logo") != null && !jsonObj.get("logo").isJsonNull()) && !jsonObj.get("logo").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `logo` to be a primitive type in the JSON string but got `%s`", jsonObj.get("logo").toString())); - } - if ((jsonObj.get("access_credentials_name") != null && !jsonObj.get("access_credentials_name").isJsonNull()) && !jsonObj.get("access_credentials_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `access_credentials_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("access_credentials_name").toString())); - } - if ((jsonObj.get("tiledb_uri") != null && !jsonObj.get("tiledb_uri").isJsonNull()) && !jsonObj.get("tiledb_uri").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `tiledb_uri` to be a primitive type in the JSON string but got `%s`", jsonObj.get("tiledb_uri").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("tags") != null && !jsonObj.get("tags").isJsonNull()) && !jsonObj.get("tags").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `tags` to be an array in the JSON string but got `%s`", jsonObj.get("tags").toString())); - } - if ((jsonObj.get("license_id") != null && !jsonObj.get("license_id").isJsonNull()) && !jsonObj.get("license_id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `license_id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("license_id").toString())); - } - if ((jsonObj.get("license_text") != null && !jsonObj.get("license_text").isJsonNull()) && !jsonObj.get("license_text").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `license_text` to be a primitive type in the JSON string but got `%s`", jsonObj.get("license_text").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!ArrayInfo.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'ArrayInfo' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(ArrayInfo.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, ArrayInfo value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public ArrayInfo read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - ArrayInfo instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of ArrayInfo given an JSON string - * - * @param jsonString JSON string - * @return An instance of ArrayInfo - * @throws IOException if the JSON string is invalid with respect to ArrayInfo - */ - public static ArrayInfo fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, ArrayInfo.class); - } - - /** - * Convert an instance of ArrayInfo to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayInfoUpdate.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayInfoUpdate.java deleted file mode 100644 index e418477..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayInfoUpdate.java +++ /dev/null @@ -1,618 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import org.openapitools.jackson.nullable.JsonNullable; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashSet; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * metadata of an array - */ -@ApiModel(description = "metadata of an array") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ArrayInfoUpdate { - public static final String SERIALIZED_NAME_DESCRIPTION = "description"; - @SerializedName(SERIALIZED_NAME_DESCRIPTION) - private String description; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_URI = "uri"; - @SerializedName(SERIALIZED_NAME_URI) - private String uri; - - public static final String SERIALIZED_NAME_FILE_TYPE = "file_type"; - @SerializedName(SERIALIZED_NAME_FILE_TYPE) - private FileType fileType; - - public static final String SERIALIZED_NAME_FILE_PROPERTIES = "file_properties"; - @SerializedName(SERIALIZED_NAME_FILE_PROPERTIES) - private Map fileProperties = null; - - public static final String SERIALIZED_NAME_ACCESS_CREDENTIALS_NAME = "access_credentials_name"; - @SerializedName(SERIALIZED_NAME_ACCESS_CREDENTIALS_NAME) - private String accessCredentialsName; - - public static final String SERIALIZED_NAME_LOGO = "logo"; - @SerializedName(SERIALIZED_NAME_LOGO) - private String logo; - - public static final String SERIALIZED_NAME_TAGS = "tags"; - @SerializedName(SERIALIZED_NAME_TAGS) - private List tags = null; - - public static final String SERIALIZED_NAME_LICENSE_ID = "license_id"; - @SerializedName(SERIALIZED_NAME_LICENSE_ID) - private String licenseId; - - public static final String SERIALIZED_NAME_LICENSE_TEXT = "license_text"; - @SerializedName(SERIALIZED_NAME_LICENSE_TEXT) - private String licenseText; - - public static final String SERIALIZED_NAME_READ_ONLY = "read_only"; - @SerializedName(SERIALIZED_NAME_READ_ONLY) - private Boolean readOnly; - - public ArrayInfoUpdate() { - } - - public ArrayInfoUpdate description(String description) { - - this.description = description; - return this; - } - - /** - * description of array - * @return description - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "description of array") - - public String getDescription() { - return description; - } - - - public void setDescription(String description) { - this.description = description; - } - - - public ArrayInfoUpdate name(String name) { - - this.name = name; - return this; - } - - /** - * description of array - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "myarray1", value = "description of array") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public ArrayInfoUpdate uri(String uri) { - - this.uri = uri; - return this; - } - - /** - * uri of array - * @return uri - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "s3://bucket/array", value = "uri of array") - - public String getUri() { - return uri; - } - - - public void setUri(String uri) { - this.uri = uri; - } - - - public ArrayInfoUpdate fileType(FileType fileType) { - - this.fileType = fileType; - return this; - } - - /** - * Get fileType - * @return fileType - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public FileType getFileType() { - return fileType; - } - - - public void setFileType(FileType fileType) { - this.fileType = fileType; - } - - - public ArrayInfoUpdate fileProperties(Map fileProperties) { - - this.fileProperties = fileProperties; - return this; - } - - public ArrayInfoUpdate putFilePropertiesItem(String key, String filePropertiesItem) { - if (this.fileProperties == null) { - this.fileProperties = new HashMap<>(); - } - this.fileProperties.put(key, filePropertiesItem); - return this; - } - - /** - * map of file properties created for this array - * @return fileProperties - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "map of file properties created for this array") - - public Map getFileProperties() { - return fileProperties; - } - - - public void setFileProperties(Map fileProperties) { - this.fileProperties = fileProperties; - } - - - public ArrayInfoUpdate accessCredentialsName(String accessCredentialsName) { - - this.accessCredentialsName = accessCredentialsName; - return this; - } - - /** - * the name of the access credentials to use. if unset, the default credentials will be used - * @return accessCredentialsName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "the name of the access credentials to use. if unset, the default credentials will be used") - - public String getAccessCredentialsName() { - return accessCredentialsName; - } - - - public void setAccessCredentialsName(String accessCredentialsName) { - this.accessCredentialsName = accessCredentialsName; - } - - - public ArrayInfoUpdate logo(String logo) { - - this.logo = logo; - return this; - } - - /** - * logo (base64 encoded) for the array. Optional - * @return logo - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "logo (base64 encoded) for the array. Optional") - - public String getLogo() { - return logo; - } - - - public void setLogo(String logo) { - this.logo = logo; - } - - - public ArrayInfoUpdate tags(List tags) { - - this.tags = tags; - return this; - } - - public ArrayInfoUpdate addTagsItem(String tagsItem) { - if (this.tags == null) { - this.tags = new ArrayList<>(); - } - this.tags.add(tagsItem); - return this; - } - - /** - * optional tags for array - * @return tags - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "optional tags for array") - - public List getTags() { - return tags; - } - - - public void setTags(List tags) { - this.tags = tags; - } - - - public ArrayInfoUpdate licenseId(String licenseId) { - - this.licenseId = licenseId; - return this; - } - - /** - * License identifier from SPDX License List or Custom - * @return licenseId - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "License identifier from SPDX License List or Custom") - - public String getLicenseId() { - return licenseId; - } - - - public void setLicenseId(String licenseId) { - this.licenseId = licenseId; - } - - - public ArrayInfoUpdate licenseText(String licenseText) { - - this.licenseText = licenseText; - return this; - } - - /** - * License text - * @return licenseText - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "License text") - - public String getLicenseText() { - return licenseText; - } - - - public void setLicenseText(String licenseText) { - this.licenseText = licenseText; - } - - - public ArrayInfoUpdate readOnly(Boolean readOnly) { - - this.readOnly = readOnly; - return this; - } - - /** - * Suggests if the array is in read_only mode - * @return readOnly - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "true", value = "Suggests if the array is in read_only mode") - - public Boolean getReadOnly() { - return readOnly; - } - - - public void setReadOnly(Boolean readOnly) { - this.readOnly = readOnly; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public ArrayInfoUpdate putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ArrayInfoUpdate arrayInfoUpdate = (ArrayInfoUpdate) o; - return Objects.equals(this.description, arrayInfoUpdate.description) && - Objects.equals(this.name, arrayInfoUpdate.name) && - Objects.equals(this.uri, arrayInfoUpdate.uri) && - Objects.equals(this.fileType, arrayInfoUpdate.fileType) && - Objects.equals(this.fileProperties, arrayInfoUpdate.fileProperties) && - Objects.equals(this.accessCredentialsName, arrayInfoUpdate.accessCredentialsName) && - Objects.equals(this.logo, arrayInfoUpdate.logo) && - Objects.equals(this.tags, arrayInfoUpdate.tags) && - Objects.equals(this.licenseId, arrayInfoUpdate.licenseId) && - Objects.equals(this.licenseText, arrayInfoUpdate.licenseText) && - Objects.equals(this.readOnly, arrayInfoUpdate.readOnly)&& - Objects.equals(this.additionalProperties, arrayInfoUpdate.additionalProperties); - } - - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); - } - - @Override - public int hashCode() { - return Objects.hash(description, name, uri, fileType, fileProperties, accessCredentialsName, logo, tags, licenseId, licenseText, readOnly, additionalProperties); - } - - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ArrayInfoUpdate {\n"); - sb.append(" description: ").append(toIndentedString(description)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" uri: ").append(toIndentedString(uri)).append("\n"); - sb.append(" fileType: ").append(toIndentedString(fileType)).append("\n"); - sb.append(" fileProperties: ").append(toIndentedString(fileProperties)).append("\n"); - sb.append(" accessCredentialsName: ").append(toIndentedString(accessCredentialsName)).append("\n"); - sb.append(" logo: ").append(toIndentedString(logo)).append("\n"); - sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); - sb.append(" licenseId: ").append(toIndentedString(licenseId)).append("\n"); - sb.append(" licenseText: ").append(toIndentedString(licenseText)).append("\n"); - sb.append(" readOnly: ").append(toIndentedString(readOnly)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("description"); - openapiFields.add("name"); - openapiFields.add("uri"); - openapiFields.add("file_type"); - openapiFields.add("file_properties"); - openapiFields.add("access_credentials_name"); - openapiFields.add("logo"); - openapiFields.add("tags"); - openapiFields.add("license_id"); - openapiFields.add("license_text"); - openapiFields.add("read_only"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to ArrayInfoUpdate - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (ArrayInfoUpdate.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in ArrayInfoUpdate is not found in the empty JSON string", ArrayInfoUpdate.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("description") != null && !jsonObj.get("description").isJsonNull()) && !jsonObj.get("description").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `description` to be a primitive type in the JSON string but got `%s`", jsonObj.get("description").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - if ((jsonObj.get("uri") != null && !jsonObj.get("uri").isJsonNull()) && !jsonObj.get("uri").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `uri` to be a primitive type in the JSON string but got `%s`", jsonObj.get("uri").toString())); - } - if ((jsonObj.get("access_credentials_name") != null && !jsonObj.get("access_credentials_name").isJsonNull()) && !jsonObj.get("access_credentials_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `access_credentials_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("access_credentials_name").toString())); - } - if ((jsonObj.get("logo") != null && !jsonObj.get("logo").isJsonNull()) && !jsonObj.get("logo").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `logo` to be a primitive type in the JSON string but got `%s`", jsonObj.get("logo").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("tags") != null && !jsonObj.get("tags").isJsonNull()) && !jsonObj.get("tags").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `tags` to be an array in the JSON string but got `%s`", jsonObj.get("tags").toString())); - } - if ((jsonObj.get("license_id") != null && !jsonObj.get("license_id").isJsonNull()) && !jsonObj.get("license_id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `license_id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("license_id").toString())); - } - if ((jsonObj.get("license_text") != null && !jsonObj.get("license_text").isJsonNull()) && !jsonObj.get("license_text").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `license_text` to be a primitive type in the JSON string but got `%s`", jsonObj.get("license_text").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!ArrayInfoUpdate.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'ArrayInfoUpdate' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(ArrayInfoUpdate.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, ArrayInfoUpdate value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public ArrayInfoUpdate read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - ArrayInfoUpdate instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of ArrayInfoUpdate given an JSON string - * - * @param jsonString JSON string - * @return An instance of ArrayInfoUpdate - * @throws IOException if the JSON string is invalid with respect to ArrayInfoUpdate - */ - public static ArrayInfoUpdate fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, ArrayInfoUpdate.class); - } - - /** - * Convert an instance of ArrayInfoUpdate to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayMetadata.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayMetadata.java deleted file mode 100644 index 5a97c58..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayMetadata.java +++ /dev/null @@ -1,285 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * user's TileDB array metadata - */ -@ApiModel(description = "user's TileDB array metadata") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ArrayMetadata { - public static final String SERIALIZED_NAME_ENTRIES = "entries"; - @SerializedName(SERIALIZED_NAME_ENTRIES) - private List entries = null; - - public ArrayMetadata() { - } - - public ArrayMetadata entries(List entries) { - - this.entries = entries; - return this; - } - - public ArrayMetadata addEntriesItem(ArrayMetadataEntry entriesItem) { - if (this.entries == null) { - this.entries = new ArrayList<>(); - } - this.entries.add(entriesItem); - return this; - } - - /** - * List of metadata entries - * @return entries - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "List of metadata entries") - - public List getEntries() { - return entries; - } - - - public void setEntries(List entries) { - this.entries = entries; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public ArrayMetadata putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ArrayMetadata arrayMetadata = (ArrayMetadata) o; - return Objects.equals(this.entries, arrayMetadata.entries)&& - Objects.equals(this.additionalProperties, arrayMetadata.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(entries, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ArrayMetadata {\n"); - sb.append(" entries: ").append(toIndentedString(entries)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("entries"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to ArrayMetadata - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (ArrayMetadata.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in ArrayMetadata is not found in the empty JSON string", ArrayMetadata.openapiRequiredFields.toString())); - } - } - JsonArray jsonArrayentries = jsonObj.getAsJsonArray("entries"); - if (jsonArrayentries != null) { - // ensure the json data is an array - if (!jsonObj.get("entries").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `entries` to be an array in the JSON string but got `%s`", jsonObj.get("entries").toString())); - } - - // validate the optional field `entries` (array) - for (int i = 0; i < jsonArrayentries.size(); i++) { - ArrayMetadataEntry.validateJsonObject(jsonArrayentries.get(i).getAsJsonObject()); - }; - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!ArrayMetadata.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'ArrayMetadata' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(ArrayMetadata.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, ArrayMetadata value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public ArrayMetadata read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - ArrayMetadata instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of ArrayMetadata given an JSON string - * - * @param jsonString JSON string - * @return An instance of ArrayMetadata - * @throws IOException if the JSON string is invalid with respect to ArrayMetadata - */ - public static ArrayMetadata fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, ArrayMetadata.class); - } - - /** - * Convert an instance of ArrayMetadata to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayMetadataEntry.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayMetadataEntry.java deleted file mode 100644 index 4a776fd..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayMetadataEntry.java +++ /dev/null @@ -1,402 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * key/value pair representing an array metadata map entry - */ -@ApiModel(description = "key/value pair representing an array metadata map entry") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ArrayMetadataEntry { - public static final String SERIALIZED_NAME_KEY = "key"; - @SerializedName(SERIALIZED_NAME_KEY) - private String key; - - public static final String SERIALIZED_NAME_TYPE = "type"; - @SerializedName(SERIALIZED_NAME_TYPE) - private String type; - - public static final String SERIALIZED_NAME_VALUE_NUM = "valueNum"; - @SerializedName(SERIALIZED_NAME_VALUE_NUM) - private Integer valueNum; - - public static final String SERIALIZED_NAME_VALUE = "value"; - @SerializedName(SERIALIZED_NAME_VALUE) - private List value = null; - - public static final String SERIALIZED_NAME_DEL = "del"; - @SerializedName(SERIALIZED_NAME_DEL) - private Boolean del; - - public ArrayMetadataEntry() { - } - - public ArrayMetadataEntry key(String key) { - - this.key = key; - return this; - } - - /** - * Get key - * @return key - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public String getKey() { - return key; - } - - - public void setKey(String key) { - this.key = key; - } - - - public ArrayMetadataEntry type(String type) { - - this.type = type; - return this; - } - - /** - * Get type - * @return type - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public String getType() { - return type; - } - - - public void setType(String type) { - this.type = type; - } - - - public ArrayMetadataEntry valueNum(Integer valueNum) { - - this.valueNum = valueNum; - return this; - } - - /** - * Get valueNum - * @return valueNum - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getValueNum() { - return valueNum; - } - - - public void setValueNum(Integer valueNum) { - this.valueNum = valueNum; - } - - - public ArrayMetadataEntry value(List value) { - - this.value = value; - return this; - } - - public ArrayMetadataEntry addValueItem(Integer valueItem) { - if (this.value == null) { - this.value = new ArrayList<>(); - } - this.value.add(valueItem); - return this; - } - - /** - * Get value - * @return value - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List getValue() { - return value; - } - - - public void setValue(List value) { - this.value = value; - } - - - public ArrayMetadataEntry del(Boolean del) { - - this.del = del; - return this; - } - - /** - * Get del - * @return del - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Boolean getDel() { - return del; - } - - - public void setDel(Boolean del) { - this.del = del; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public ArrayMetadataEntry putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ArrayMetadataEntry arrayMetadataEntry = (ArrayMetadataEntry) o; - return Objects.equals(this.key, arrayMetadataEntry.key) && - Objects.equals(this.type, arrayMetadataEntry.type) && - Objects.equals(this.valueNum, arrayMetadataEntry.valueNum) && - Objects.equals(this.value, arrayMetadataEntry.value) && - Objects.equals(this.del, arrayMetadataEntry.del)&& - Objects.equals(this.additionalProperties, arrayMetadataEntry.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(key, type, valueNum, value, del, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ArrayMetadataEntry {\n"); - sb.append(" key: ").append(toIndentedString(key)).append("\n"); - sb.append(" type: ").append(toIndentedString(type)).append("\n"); - sb.append(" valueNum: ").append(toIndentedString(valueNum)).append("\n"); - sb.append(" value: ").append(toIndentedString(value)).append("\n"); - sb.append(" del: ").append(toIndentedString(del)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("key"); - openapiFields.add("type"); - openapiFields.add("valueNum"); - openapiFields.add("value"); - openapiFields.add("del"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to ArrayMetadataEntry - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (ArrayMetadataEntry.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in ArrayMetadataEntry is not found in the empty JSON string", ArrayMetadataEntry.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("key") != null && !jsonObj.get("key").isJsonNull()) && !jsonObj.get("key").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `key` to be a primitive type in the JSON string but got `%s`", jsonObj.get("key").toString())); - } - if ((jsonObj.get("type") != null && !jsonObj.get("type").isJsonNull()) && !jsonObj.get("type").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `type` to be a primitive type in the JSON string but got `%s`", jsonObj.get("type").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("value") != null && !jsonObj.get("value").isJsonNull()) && !jsonObj.get("value").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `value` to be an array in the JSON string but got `%s`", jsonObj.get("value").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!ArrayMetadataEntry.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'ArrayMetadataEntry' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(ArrayMetadataEntry.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, ArrayMetadataEntry value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public ArrayMetadataEntry read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - ArrayMetadataEntry instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of ArrayMetadataEntry given an JSON string - * - * @param jsonString JSON string - * @return An instance of ArrayMetadataEntry - * @throws IOException if the JSON string is invalid with respect to ArrayMetadataEntry - */ - public static ArrayMetadataEntry fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, ArrayMetadataEntry.class); - } - - /** - * Convert an instance of ArrayMetadataEntry to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArraySample.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArraySample.java deleted file mode 100644 index 146a4db..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArraySample.java +++ /dev/null @@ -1,262 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Sample data from array - */ -@ApiModel(description = "Sample data from array") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ArraySample { - public static final String SERIALIZED_NAME_DATA = "data"; - @SerializedName(SERIALIZED_NAME_DATA) - private Object data; - - public ArraySample() { - } - - public ArraySample data(Object data) { - - this.data = data; - return this; - } - - /** - * Get data - * @return data - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Object getData() { - return data; - } - - - public void setData(Object data) { - this.data = data; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public ArraySample putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ArraySample arraySample = (ArraySample) o; - return Objects.equals(this.data, arraySample.data)&& - Objects.equals(this.additionalProperties, arraySample.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(data, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ArraySample {\n"); - sb.append(" data: ").append(toIndentedString(data)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("data"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to ArraySample - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (ArraySample.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in ArraySample is not found in the empty JSON string", ArraySample.openapiRequiredFields.toString())); - } - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!ArraySample.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'ArraySample' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(ArraySample.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, ArraySample value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public ArraySample read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - ArraySample instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of ArraySample given an JSON string - * - * @param jsonString JSON string - * @return An instance of ArraySample - * @throws IOException if the JSON string is invalid with respect to ArraySample - */ - public static ArraySample fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, ArraySample.class); - } - - /** - * Convert an instance of ArraySample to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArraySchema.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArraySchema.java deleted file mode 100644 index d9284e2..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArraySchema.java +++ /dev/null @@ -1,587 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * ArraySchema during creation or retrieval - */ -@ApiModel(description = "ArraySchema during creation or retrieval") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ArraySchema { - public static final String SERIALIZED_NAME_URI = "uri"; - @SerializedName(SERIALIZED_NAME_URI) - private String uri; - - public static final String SERIALIZED_NAME_VERSION = "version"; - @SerializedName(SERIALIZED_NAME_VERSION) - private List version = new ArrayList<>(); - - public static final String SERIALIZED_NAME_ARRAY_TYPE = "arrayType"; - @SerializedName(SERIALIZED_NAME_ARRAY_TYPE) - private ArrayType arrayType; - - public static final String SERIALIZED_NAME_TILE_ORDER = "tileOrder"; - @SerializedName(SERIALIZED_NAME_TILE_ORDER) - private Layout tileOrder; - - public static final String SERIALIZED_NAME_CELL_ORDER = "cellOrder"; - @SerializedName(SERIALIZED_NAME_CELL_ORDER) - private Layout cellOrder; - - public static final String SERIALIZED_NAME_CAPACITY = "capacity"; - @SerializedName(SERIALIZED_NAME_CAPACITY) - private Integer capacity; - - public static final String SERIALIZED_NAME_COORDS_FILTER_PIPELINE = "coordsFilterPipeline"; - @SerializedName(SERIALIZED_NAME_COORDS_FILTER_PIPELINE) - private FilterPipeline coordsFilterPipeline; - - public static final String SERIALIZED_NAME_OFFSET_FILTER_PIPELINE = "offsetFilterPipeline"; - @SerializedName(SERIALIZED_NAME_OFFSET_FILTER_PIPELINE) - private FilterPipeline offsetFilterPipeline; - - public static final String SERIALIZED_NAME_DOMAIN = "domain"; - @SerializedName(SERIALIZED_NAME_DOMAIN) - private Domain domain; - - public static final String SERIALIZED_NAME_ATTRIBUTES = "attributes"; - @SerializedName(SERIALIZED_NAME_ATTRIBUTES) - private List attributes = new ArrayList<>(); - - public static final String SERIALIZED_NAME_ALLOWS_DUPLICATES = "allowsDuplicates"; - @SerializedName(SERIALIZED_NAME_ALLOWS_DUPLICATES) - private Boolean allowsDuplicates; - - public ArraySchema() { - } - - public ArraySchema uri(String uri) { - - this.uri = uri; - return this; - } - - /** - * URI of schema - * @return uri - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "s3:///test_array", value = "URI of schema") - - public String getUri() { - return uri; - } - - - public void setUri(String uri) { - this.uri = uri; - } - - - public ArraySchema version(List version) { - - this.version = version; - return this; - } - - public ArraySchema addVersionItem(Integer versionItem) { - this.version.add(versionItem); - return this; - } - - /** - * file format version - * @return version - **/ - @javax.annotation.Nonnull - @ApiModelProperty(example = "[1, 3, 0]", required = true, value = "file format version") - - public List getVersion() { - return version; - } - - - public void setVersion(List version) { - this.version = version; - } - - - public ArraySchema arrayType(ArrayType arrayType) { - - this.arrayType = arrayType; - return this; - } - - /** - * Get arrayType - * @return arrayType - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public ArrayType getArrayType() { - return arrayType; - } - - - public void setArrayType(ArrayType arrayType) { - this.arrayType = arrayType; - } - - - public ArraySchema tileOrder(Layout tileOrder) { - - this.tileOrder = tileOrder; - return this; - } - - /** - * Get tileOrder - * @return tileOrder - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public Layout getTileOrder() { - return tileOrder; - } - - - public void setTileOrder(Layout tileOrder) { - this.tileOrder = tileOrder; - } - - - public ArraySchema cellOrder(Layout cellOrder) { - - this.cellOrder = cellOrder; - return this; - } - - /** - * Get cellOrder - * @return cellOrder - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public Layout getCellOrder() { - return cellOrder; - } - - - public void setCellOrder(Layout cellOrder) { - this.cellOrder = cellOrder; - } - - - public ArraySchema capacity(Integer capacity) { - - this.capacity = capacity; - return this; - } - - /** - * Capacity of array - * @return capacity - **/ - @javax.annotation.Nonnull - @ApiModelProperty(example = "100000", required = true, value = "Capacity of array") - - public Integer getCapacity() { - return capacity; - } - - - public void setCapacity(Integer capacity) { - this.capacity = capacity; - } - - - public ArraySchema coordsFilterPipeline(FilterPipeline coordsFilterPipeline) { - - this.coordsFilterPipeline = coordsFilterPipeline; - return this; - } - - /** - * Get coordsFilterPipeline - * @return coordsFilterPipeline - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public FilterPipeline getCoordsFilterPipeline() { - return coordsFilterPipeline; - } - - - public void setCoordsFilterPipeline(FilterPipeline coordsFilterPipeline) { - this.coordsFilterPipeline = coordsFilterPipeline; - } - - - public ArraySchema offsetFilterPipeline(FilterPipeline offsetFilterPipeline) { - - this.offsetFilterPipeline = offsetFilterPipeline; - return this; - } - - /** - * Get offsetFilterPipeline - * @return offsetFilterPipeline - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public FilterPipeline getOffsetFilterPipeline() { - return offsetFilterPipeline; - } - - - public void setOffsetFilterPipeline(FilterPipeline offsetFilterPipeline) { - this.offsetFilterPipeline = offsetFilterPipeline; - } - - - public ArraySchema domain(Domain domain) { - - this.domain = domain; - return this; - } - - /** - * Get domain - * @return domain - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public Domain getDomain() { - return domain; - } - - - public void setDomain(Domain domain) { - this.domain = domain; - } - - - public ArraySchema attributes(List attributes) { - - this.attributes = attributes; - return this; - } - - public ArraySchema addAttributesItem(Attribute attributesItem) { - this.attributes.add(attributesItem); - return this; - } - - /** - * Attributes of array - * @return attributes - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "Attributes of array") - - public List getAttributes() { - return attributes; - } - - - public void setAttributes(List attributes) { - this.attributes = attributes; - } - - - public ArraySchema allowsDuplicates(Boolean allowsDuplicates) { - - this.allowsDuplicates = allowsDuplicates; - return this; - } - - /** - * True if the array allows coordinate duplicates. Applicable only to sparse arrays. - * @return allowsDuplicates - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "True if the array allows coordinate duplicates. Applicable only to sparse arrays.") - - public Boolean getAllowsDuplicates() { - return allowsDuplicates; - } - - - public void setAllowsDuplicates(Boolean allowsDuplicates) { - this.allowsDuplicates = allowsDuplicates; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public ArraySchema putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ArraySchema arraySchema = (ArraySchema) o; - return Objects.equals(this.uri, arraySchema.uri) && - Objects.equals(this.version, arraySchema.version) && - Objects.equals(this.arrayType, arraySchema.arrayType) && - Objects.equals(this.tileOrder, arraySchema.tileOrder) && - Objects.equals(this.cellOrder, arraySchema.cellOrder) && - Objects.equals(this.capacity, arraySchema.capacity) && - Objects.equals(this.coordsFilterPipeline, arraySchema.coordsFilterPipeline) && - Objects.equals(this.offsetFilterPipeline, arraySchema.offsetFilterPipeline) && - Objects.equals(this.domain, arraySchema.domain) && - Objects.equals(this.attributes, arraySchema.attributes) && - Objects.equals(this.allowsDuplicates, arraySchema.allowsDuplicates)&& - Objects.equals(this.additionalProperties, arraySchema.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(uri, version, arrayType, tileOrder, cellOrder, capacity, coordsFilterPipeline, offsetFilterPipeline, domain, attributes, allowsDuplicates, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ArraySchema {\n"); - sb.append(" uri: ").append(toIndentedString(uri)).append("\n"); - sb.append(" version: ").append(toIndentedString(version)).append("\n"); - sb.append(" arrayType: ").append(toIndentedString(arrayType)).append("\n"); - sb.append(" tileOrder: ").append(toIndentedString(tileOrder)).append("\n"); - sb.append(" cellOrder: ").append(toIndentedString(cellOrder)).append("\n"); - sb.append(" capacity: ").append(toIndentedString(capacity)).append("\n"); - sb.append(" coordsFilterPipeline: ").append(toIndentedString(coordsFilterPipeline)).append("\n"); - sb.append(" offsetFilterPipeline: ").append(toIndentedString(offsetFilterPipeline)).append("\n"); - sb.append(" domain: ").append(toIndentedString(domain)).append("\n"); - sb.append(" attributes: ").append(toIndentedString(attributes)).append("\n"); - sb.append(" allowsDuplicates: ").append(toIndentedString(allowsDuplicates)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("uri"); - openapiFields.add("version"); - openapiFields.add("arrayType"); - openapiFields.add("tileOrder"); - openapiFields.add("cellOrder"); - openapiFields.add("capacity"); - openapiFields.add("coordsFilterPipeline"); - openapiFields.add("offsetFilterPipeline"); - openapiFields.add("domain"); - openapiFields.add("attributes"); - openapiFields.add("allowsDuplicates"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - openapiRequiredFields.add("version"); - openapiRequiredFields.add("arrayType"); - openapiRequiredFields.add("tileOrder"); - openapiRequiredFields.add("cellOrder"); - openapiRequiredFields.add("capacity"); - openapiRequiredFields.add("coordsFilterPipeline"); - openapiRequiredFields.add("offsetFilterPipeline"); - openapiRequiredFields.add("domain"); - openapiRequiredFields.add("attributes"); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to ArraySchema - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (ArraySchema.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in ArraySchema is not found in the empty JSON string", ArraySchema.openapiRequiredFields.toString())); - } - } - - // check to make sure all required properties/fields are present in the JSON string - for (String requiredField : ArraySchema.openapiRequiredFields) { - if (jsonObj.get(requiredField) == null) { - throw new IllegalArgumentException(String.format("The required field `%s` is not found in the JSON string: %s", requiredField, jsonObj.toString())); - } - } - if ((jsonObj.get("uri") != null && !jsonObj.get("uri").isJsonNull()) && !jsonObj.get("uri").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `uri` to be a primitive type in the JSON string but got `%s`", jsonObj.get("uri").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("version") != null && !jsonObj.get("version").isJsonNull()) && !jsonObj.get("version").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `version` to be an array in the JSON string but got `%s`", jsonObj.get("version").toString())); - } - // validate the optional field `coordsFilterPipeline` - if (jsonObj.get("coordsFilterPipeline") != null && !jsonObj.get("coordsFilterPipeline").isJsonNull()) { - FilterPipeline.validateJsonObject(jsonObj.getAsJsonObject("coordsFilterPipeline")); - } - // validate the optional field `offsetFilterPipeline` - if (jsonObj.get("offsetFilterPipeline") != null && !jsonObj.get("offsetFilterPipeline").isJsonNull()) { - FilterPipeline.validateJsonObject(jsonObj.getAsJsonObject("offsetFilterPipeline")); - } - // validate the optional field `domain` - if (jsonObj.get("domain") != null && !jsonObj.get("domain").isJsonNull()) { - Domain.validateJsonObject(jsonObj.getAsJsonObject("domain")); - } - JsonArray jsonArrayattributes = jsonObj.getAsJsonArray("attributes"); - if (jsonArrayattributes != null) { - // ensure the json data is an array - if (!jsonObj.get("attributes").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `attributes` to be an array in the JSON string but got `%s`", jsonObj.get("attributes").toString())); - } - - // validate the optional field `attributes` (array) - for (int i = 0; i < jsonArrayattributes.size(); i++) { - Attribute.validateJsonObject(jsonArrayattributes.get(i).getAsJsonObject()); - }; - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!ArraySchema.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'ArraySchema' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(ArraySchema.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, ArraySchema value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - elementAdapter.write(out, obj); - } - - @Override - public ArraySchema read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - return thisAdapter.fromJsonTree(jsonObj); - } - - }.nullSafe(); - } - } - - /** - * Create an instance of ArraySchema given an JSON string - * - * @param jsonString JSON string - * @return An instance of ArraySchema - * @throws IOException if the JSON string is invalid with respect to ArraySchema - */ - public static ArraySchema fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, ArraySchema.class); - } - - /** - * Convert an instance of ArraySchema to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArraySharing.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArraySharing.java deleted file mode 100644 index 8f95d4d..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArraySharing.java +++ /dev/null @@ -1,342 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * details for sharing a given array - */ -@ApiModel(description = "details for sharing a given array") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ArraySharing { - public static final String SERIALIZED_NAME_ACTIONS = "actions"; - @SerializedName(SERIALIZED_NAME_ACTIONS) - private List actions = null; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public static final String SERIALIZED_NAME_NAMESPACE_TYPE = "namespace_type"; - @SerializedName(SERIALIZED_NAME_NAMESPACE_TYPE) - private String namespaceType; - - public ArraySharing() { - } - - public ArraySharing actions(List actions) { - - this.actions = actions; - return this; - } - - public ArraySharing addActionsItem(ArrayActions actionsItem) { - if (this.actions == null) { - this.actions = new ArrayList<>(); - } - this.actions.add(actionsItem); - return this; - } - - /** - * List of permitted actions - * @return actions - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "[read, write]", value = "List of permitted actions") - - public List getActions() { - return actions; - } - - - public void setActions(List actions) { - this.actions = actions; - } - - - public ArraySharing namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * namespace being granted array access can be a user or organization - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "MyOrganization", value = "namespace being granted array access can be a user or organization") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - - public ArraySharing namespaceType(String namespaceType) { - - this.namespaceType = namespaceType; - return this; - } - - /** - * details on if the namespace is a organization or user - * @return namespaceType - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "organization", value = "details on if the namespace is a organization or user") - - public String getNamespaceType() { - return namespaceType; - } - - - public void setNamespaceType(String namespaceType) { - this.namespaceType = namespaceType; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public ArraySharing putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ArraySharing arraySharing = (ArraySharing) o; - return Objects.equals(this.actions, arraySharing.actions) && - Objects.equals(this.namespace, arraySharing.namespace) && - Objects.equals(this.namespaceType, arraySharing.namespaceType)&& - Objects.equals(this.additionalProperties, arraySharing.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(actions, namespace, namespaceType, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ArraySharing {\n"); - sb.append(" actions: ").append(toIndentedString(actions)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" namespaceType: ").append(toIndentedString(namespaceType)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("actions"); - openapiFields.add("namespace"); - openapiFields.add("namespace_type"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to ArraySharing - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (ArraySharing.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in ArraySharing is not found in the empty JSON string", ArraySharing.openapiRequiredFields.toString())); - } - } - // ensure the json data is an array - if ((jsonObj.get("actions") != null && !jsonObj.get("actions").isJsonNull()) && !jsonObj.get("actions").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `actions` to be an array in the JSON string but got `%s`", jsonObj.get("actions").toString())); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - if ((jsonObj.get("namespace_type") != null && !jsonObj.get("namespace_type").isJsonNull()) && !jsonObj.get("namespace_type").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace_type` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace_type").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!ArraySharing.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'ArraySharing' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(ArraySharing.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, ArraySharing value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public ArraySharing read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - ArraySharing instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of ArraySharing given an JSON string - * - * @param jsonString JSON string - * @return An instance of ArraySharing - * @throws IOException if the JSON string is invalid with respect to ArraySharing - */ - public static ArraySharing fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, ArraySharing.class); - } - - /** - * Convert an instance of ArraySharing to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayTask.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayTask.java deleted file mode 100644 index 64a3fe1..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayTask.java +++ /dev/null @@ -1,1208 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.math.BigDecimal; -import java.time.OffsetDateTime; -import java.util.ArrayList; -import java.util.List; - -import org.openapitools.jackson.nullable.JsonNullable; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Synchronous Task to Run - */ -@ApiModel(description = "Synchronous Task to Run") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ArrayTask { - public static final String SERIALIZED_NAME_ID = "id"; - @SerializedName(SERIALIZED_NAME_ID) - private String id; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_USERNAME = "username"; - @SerializedName(SERIALIZED_NAME_USERNAME) - private String username; - - public static final String SERIALIZED_NAME_DESCRIPTION = "description"; - @SerializedName(SERIALIZED_NAME_DESCRIPTION) - private String description; - - public static final String SERIALIZED_NAME_ARRAY_METADATA = "array_metadata"; - @SerializedName(SERIALIZED_NAME_ARRAY_METADATA) - private ArrayInfo arrayMetadata; - - public static final String SERIALIZED_NAME_SUBARRAY = "subarray"; - @SerializedName(SERIALIZED_NAME_SUBARRAY) - private DomainArray subarray; - - public static final String SERIALIZED_NAME_MEMORY = "memory"; - @SerializedName(SERIALIZED_NAME_MEMORY) - private Integer memory; - - public static final String SERIALIZED_NAME_CPU = "cpu"; - @SerializedName(SERIALIZED_NAME_CPU) - private Integer cpu; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public static final String SERIALIZED_NAME_STATUS = "status"; - @SerializedName(SERIALIZED_NAME_STATUS) - private ArrayTaskStatus status; - - public static final String SERIALIZED_NAME_STATUS_MESSAGE = "status_message"; - @SerializedName(SERIALIZED_NAME_STATUS_MESSAGE) - private String statusMessage; - - public static final String SERIALIZED_NAME_START_TIME = "start_time"; - @SerializedName(SERIALIZED_NAME_START_TIME) - private OffsetDateTime startTime; - - public static final String SERIALIZED_NAME_FINISH_TIME = "finish_time"; - @SerializedName(SERIALIZED_NAME_FINISH_TIME) - private OffsetDateTime finishTime; - - public static final String SERIALIZED_NAME_COST = "cost"; - @SerializedName(SERIALIZED_NAME_COST) - private Double cost; - - public static final String SERIALIZED_NAME_EGRESS_COST = "egress_cost"; - @SerializedName(SERIALIZED_NAME_EGRESS_COST) - private Double egressCost; - - public static final String SERIALIZED_NAME_ACCESS_COST = "access_cost"; - @SerializedName(SERIALIZED_NAME_ACCESS_COST) - private Double accessCost; - - public static final String SERIALIZED_NAME_QUERY_TYPE = "query_type"; - @SerializedName(SERIALIZED_NAME_QUERY_TYPE) - private Querytype queryType; - - public static final String SERIALIZED_NAME_UDF_CODE = "udf_code"; - @SerializedName(SERIALIZED_NAME_UDF_CODE) - private String udfCode; - - public static final String SERIALIZED_NAME_UDF_LANGUAGE = "udf_language"; - @SerializedName(SERIALIZED_NAME_UDF_LANGUAGE) - private String udfLanguage; - - public static final String SERIALIZED_NAME_SQL_QUERY = "sql_query"; - @SerializedName(SERIALIZED_NAME_SQL_QUERY) - private String sqlQuery; - - public static final String SERIALIZED_NAME_TYPE = "type"; - @SerializedName(SERIALIZED_NAME_TYPE) - private ArrayTaskType type; - - public static final String SERIALIZED_NAME_ACTIVITY = "activity"; - @SerializedName(SERIALIZED_NAME_ACTIVITY) - private List activity = null; - - public static final String SERIALIZED_NAME_LOGS = "logs"; - @SerializedName(SERIALIZED_NAME_LOGS) - private String logs; - - public static final String SERIALIZED_NAME_DURATION = "duration"; - @SerializedName(SERIALIZED_NAME_DURATION) - private BigDecimal duration; - - public static final String SERIALIZED_NAME_SQL_INIT_COMMANDS = "sql_init_commands"; - @SerializedName(SERIALIZED_NAME_SQL_INIT_COMMANDS) - private List sqlInitCommands = null; - - public static final String SERIALIZED_NAME_SQL_PARAMETERS = "sql_parameters"; - @SerializedName(SERIALIZED_NAME_SQL_PARAMETERS) - private List sqlParameters = null; - - public static final String SERIALIZED_NAME_RESULT_FORMAT = "result_format"; - @SerializedName(SERIALIZED_NAME_RESULT_FORMAT) - private ResultFormat resultFormat; - - public static final String SERIALIZED_NAME_TASK_GRAPH_UUID = "task_graph_uuid"; - @SerializedName(SERIALIZED_NAME_TASK_GRAPH_UUID) - private String taskGraphUuid; - - public static final String SERIALIZED_NAME_CLIENT_NODE_UUID = "client_node_uuid"; - @SerializedName(SERIALIZED_NAME_CLIENT_NODE_UUID) - private String clientNodeUuid; - - public ArrayTask() { - } - - public ArrayTask id(String id) { - - this.id = id; - return this; - } - - /** - * task ID - * @return id - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "task ID") - - public String getId() { - return id; - } - - - public void setId(String id) { - this.id = id; - } - - - public ArrayTask name(String name) { - - this.name = name; - return this; - } - - /** - * Optional task name - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "subarray-multiplier", value = "Optional task name") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public ArrayTask username(String username) { - - this.username = username; - return this; - } - - /** - * username that executed this task - * @return username - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "demo", value = "username that executed this task") - - public String getUsername() { - return username; - } - - - public void setUsername(String username) { - this.username = username; - } - - - public ArrayTask description(String description) { - - this.description = description; - return this; - } - - /** - * Optional task description (Tasks purpose) - * @return description - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "Return attr a1 in the subarray bounded by coordinates and multiply attr1 by 2", value = "Optional task description (Tasks purpose)") - - public String getDescription() { - return description; - } - - - public void setDescription(String description) { - this.description = description; - } - - - public ArrayTask arrayMetadata(ArrayInfo arrayMetadata) { - - this.arrayMetadata = arrayMetadata; - return this; - } - - /** - * Get arrayMetadata - * @return arrayMetadata - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public ArrayInfo getArrayMetadata() { - return arrayMetadata; - } - - - public void setArrayMetadata(ArrayInfo arrayMetadata) { - this.arrayMetadata = arrayMetadata; - } - - - public ArrayTask subarray(DomainArray subarray) { - - this.subarray = subarray; - return this; - } - - /** - * Get subarray - * @return subarray - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public DomainArray getSubarray() { - return subarray; - } - - - public void setSubarray(DomainArray subarray) { - this.subarray = subarray; - } - - - public ArrayTask memory(Integer memory) { - - this.memory = memory; - return this; - } - - /** - * memory allocated to task in bytes - * @return memory - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "1073741824", value = "memory allocated to task in bytes") - - public Integer getMemory() { - return memory; - } - - - public void setMemory(Integer memory) { - this.memory = memory; - } - - - public ArrayTask cpu(Integer cpu) { - - this.cpu = cpu; - return this; - } - - /** - * millicpu allocated to task - * @return cpu - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "4000", value = "millicpu allocated to task") - - public Integer getCpu() { - return cpu; - } - - - public void setCpu(Integer cpu) { - this.cpu = cpu; - } - - - public ArrayTask namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * namespace task is tied to - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "organization1", value = "namespace task is tied to") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - - public ArrayTask status(ArrayTaskStatus status) { - - this.status = status; - return this; - } - - /** - * Get status - * @return status - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public ArrayTaskStatus getStatus() { - return status; - } - - - public void setStatus(ArrayTaskStatus status) { - this.status = status; - } - - - public ArrayTask statusMessage(String statusMessage) { - - this.statusMessage = statusMessage; - return this; - } - - /** - * The reason the array task status is in the state - * @return statusMessage - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The reason the array task status is in the state") - - public String getStatusMessage() { - return statusMessage; - } - - - public void setStatusMessage(String statusMessage) { - this.statusMessage = statusMessage; - } - - - public ArrayTask startTime(OffsetDateTime startTime) { - - this.startTime = startTime; - return this; - } - - /** - * Start time RFC3339 for job - * @return startTime - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Start time RFC3339 for job") - - public OffsetDateTime getStartTime() { - return startTime; - } - - - public void setStartTime(OffsetDateTime startTime) { - this.startTime = startTime; - } - - - public ArrayTask finishTime(OffsetDateTime finishTime) { - - this.finishTime = finishTime; - return this; - } - - /** - * Finish time RFC3339 for job - * @return finishTime - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Finish time RFC3339 for job") - - public OffsetDateTime getFinishTime() { - return finishTime; - } - - - public void setFinishTime(OffsetDateTime finishTime) { - this.finishTime = finishTime; - } - - - public ArrayTask cost(Double cost) { - - this.cost = cost; - return this; - } - - /** - * Total accumulated for task in USD, example is $0.12 - * @return cost - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "0.12", value = "Total accumulated for task in USD, example is $0.12") - - public Double getCost() { - return cost; - } - - - public void setCost(Double cost) { - this.cost = cost; - } - - - public ArrayTask egressCost(Double egressCost) { - - this.egressCost = egressCost; - return this; - } - - /** - * Total accumulated for egress task in USD, example is $0.12 - * @return egressCost - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "0.12", value = "Total accumulated for egress task in USD, example is $0.12") - - public Double getEgressCost() { - return egressCost; - } - - - public void setEgressCost(Double egressCost) { - this.egressCost = egressCost; - } - - - public ArrayTask accessCost(Double accessCost) { - - this.accessCost = accessCost; - return this; - } - - /** - * Cost accumulated for access task in USD, example is $0.12 - * @return accessCost - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "0.12", value = "Cost accumulated for access task in USD, example is $0.12") - - public Double getAccessCost() { - return accessCost; - } - - - public void setAccessCost(Double accessCost) { - this.accessCost = accessCost; - } - - - public ArrayTask queryType(Querytype queryType) { - - this.queryType = queryType; - return this; - } - - /** - * Get queryType - * @return queryType - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Querytype getQueryType() { - return queryType; - } - - - public void setQueryType(Querytype queryType) { - this.queryType = queryType; - } - - - public ArrayTask udfCode(String udfCode) { - - this.udfCode = udfCode; - return this; - } - - /** - * Optional actual code that is going to be executed - * @return udfCode - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Optional actual code that is going to be executed") - - public String getUdfCode() { - return udfCode; - } - - - public void setUdfCode(String udfCode) { - this.udfCode = udfCode; - } - - - public ArrayTask udfLanguage(String udfLanguage) { - - this.udfLanguage = udfLanguage; - return this; - } - - /** - * Optional actual language used to express udf_code - * @return udfLanguage - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Optional actual language used to express udf_code") - - public String getUdfLanguage() { - return udfLanguage; - } - - - public void setUdfLanguage(String udfLanguage) { - this.udfLanguage = udfLanguage; - } - - - public ArrayTask sqlQuery(String sqlQuery) { - - this.sqlQuery = sqlQuery; - return this; - } - - /** - * Optional actual sql query that is going to be executed - * @return sqlQuery - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Optional actual sql query that is going to be executed") - - public String getSqlQuery() { - return sqlQuery; - } - - - public void setSqlQuery(String sqlQuery) { - this.sqlQuery = sqlQuery; - } - - - public ArrayTask type(ArrayTaskType type) { - - this.type = type; - return this; - } - - /** - * Get type - * @return type - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public ArrayTaskType getType() { - return type; - } - - - public void setType(ArrayTaskType type) { - this.type = type; - } - - - public ArrayTask activity(List activity) { - - this.activity = activity; - return this; - } - - public ArrayTask addActivityItem(ArrayActivityLog activityItem) { - if (this.activity == null) { - this.activity = new ArrayList<>(); - } - this.activity.add(activityItem); - return this; - } - - /** - * Array activity logs for task - * @return activity - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Array activity logs for task") - - public List getActivity() { - return activity; - } - - - public void setActivity(List activity) { - this.activity = activity; - } - - - public ArrayTask logs(String logs) { - - this.logs = logs; - return this; - } - - /** - * logs from array task - * @return logs - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "logs from array task") - - public String getLogs() { - return logs; - } - - - public void setLogs(String logs) { - this.logs = logs; - } - - - public ArrayTask duration(BigDecimal duration) { - - this.duration = duration; - return this; - } - - /** - * duration in nanoseconds of an array task - * @return duration - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "3.41E+11", value = "duration in nanoseconds of an array task") - - public BigDecimal getDuration() { - return duration; - } - - - public void setDuration(BigDecimal duration) { - this.duration = duration; - } - - - public ArrayTask sqlInitCommands(List sqlInitCommands) { - - this.sqlInitCommands = sqlInitCommands; - return this; - } - - public ArrayTask addSqlInitCommandsItem(String sqlInitCommandsItem) { - if (this.sqlInitCommands == null) { - this.sqlInitCommands = new ArrayList<>(); - } - this.sqlInitCommands.add(sqlInitCommandsItem); - return this; - } - - /** - * SQL queries or commands to run before main sql query - * @return sqlInitCommands - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "SQL queries or commands to run before main sql query") - - public List getSqlInitCommands() { - return sqlInitCommands; - } - - - public void setSqlInitCommands(List sqlInitCommands) { - this.sqlInitCommands = sqlInitCommands; - } - - - public ArrayTask sqlParameters(List sqlParameters) { - - this.sqlParameters = sqlParameters; - return this; - } - - public ArrayTask addSqlParametersItem(Object sqlParametersItem) { - if (this.sqlParameters == null) { - this.sqlParameters = new ArrayList<>(); - } - this.sqlParameters.add(sqlParametersItem); - return this; - } - - /** - * SQL query parameters - * @return sqlParameters - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "SQL query parameters") - - public List getSqlParameters() { - return sqlParameters; - } - - - public void setSqlParameters(List sqlParameters) { - this.sqlParameters = sqlParameters; - } - - - public ArrayTask resultFormat(ResultFormat resultFormat) { - - this.resultFormat = resultFormat; - return this; - } - - /** - * Get resultFormat - * @return resultFormat - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public ResultFormat getResultFormat() { - return resultFormat; - } - - - public void setResultFormat(ResultFormat resultFormat) { - this.resultFormat = resultFormat; - } - - - public ArrayTask taskGraphUuid(String taskGraphUuid) { - - this.taskGraphUuid = taskGraphUuid; - return this; - } - - /** - * If set, the ID of the log for the task graph that this was part of. - * @return taskGraphUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "If set, the ID of the log for the task graph that this was part of. ") - - public String getTaskGraphUuid() { - return taskGraphUuid; - } - - - public void setTaskGraphUuid(String taskGraphUuid) { - this.taskGraphUuid = taskGraphUuid; - } - - - public ArrayTask clientNodeUuid(String clientNodeUuid) { - - this.clientNodeUuid = clientNodeUuid; - return this; - } - - /** - * If set, the client-defined ID of the node within this task's graph. - * @return clientNodeUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "If set, the client-defined ID of the node within this task's graph. ") - - public String getClientNodeUuid() { - return clientNodeUuid; - } - - - public void setClientNodeUuid(String clientNodeUuid) { - this.clientNodeUuid = clientNodeUuid; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public ArrayTask putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ArrayTask arrayTask = (ArrayTask) o; - return Objects.equals(this.id, arrayTask.id) && - Objects.equals(this.name, arrayTask.name) && - Objects.equals(this.username, arrayTask.username) && - Objects.equals(this.description, arrayTask.description) && - Objects.equals(this.arrayMetadata, arrayTask.arrayMetadata) && - Objects.equals(this.subarray, arrayTask.subarray) && - Objects.equals(this.memory, arrayTask.memory) && - Objects.equals(this.cpu, arrayTask.cpu) && - Objects.equals(this.namespace, arrayTask.namespace) && - Objects.equals(this.status, arrayTask.status) && - Objects.equals(this.statusMessage, arrayTask.statusMessage) && - Objects.equals(this.startTime, arrayTask.startTime) && - Objects.equals(this.finishTime, arrayTask.finishTime) && - Objects.equals(this.cost, arrayTask.cost) && - Objects.equals(this.egressCost, arrayTask.egressCost) && - Objects.equals(this.accessCost, arrayTask.accessCost) && - Objects.equals(this.queryType, arrayTask.queryType) && - Objects.equals(this.udfCode, arrayTask.udfCode) && - Objects.equals(this.udfLanguage, arrayTask.udfLanguage) && - Objects.equals(this.sqlQuery, arrayTask.sqlQuery) && - Objects.equals(this.type, arrayTask.type) && - Objects.equals(this.activity, arrayTask.activity) && - Objects.equals(this.logs, arrayTask.logs) && - Objects.equals(this.duration, arrayTask.duration) && - Objects.equals(this.sqlInitCommands, arrayTask.sqlInitCommands) && - Objects.equals(this.sqlParameters, arrayTask.sqlParameters) && - Objects.equals(this.resultFormat, arrayTask.resultFormat) && - Objects.equals(this.taskGraphUuid, arrayTask.taskGraphUuid) && - Objects.equals(this.clientNodeUuid, arrayTask.clientNodeUuid)&& - Objects.equals(this.additionalProperties, arrayTask.additionalProperties); - } - - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); - } - - @Override - public int hashCode() { - return Objects.hash(id, name, username, description, arrayMetadata, subarray, memory, cpu, namespace, status, statusMessage, startTime, finishTime, cost, egressCost, accessCost, queryType, udfCode, udfLanguage, sqlQuery, type, activity, logs, duration, sqlInitCommands, sqlParameters, resultFormat, taskGraphUuid, clientNodeUuid, additionalProperties); - } - - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ArrayTask {\n"); - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" username: ").append(toIndentedString(username)).append("\n"); - sb.append(" description: ").append(toIndentedString(description)).append("\n"); - sb.append(" arrayMetadata: ").append(toIndentedString(arrayMetadata)).append("\n"); - sb.append(" subarray: ").append(toIndentedString(subarray)).append("\n"); - sb.append(" memory: ").append(toIndentedString(memory)).append("\n"); - sb.append(" cpu: ").append(toIndentedString(cpu)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" status: ").append(toIndentedString(status)).append("\n"); - sb.append(" statusMessage: ").append(toIndentedString(statusMessage)).append("\n"); - sb.append(" startTime: ").append(toIndentedString(startTime)).append("\n"); - sb.append(" finishTime: ").append(toIndentedString(finishTime)).append("\n"); - sb.append(" cost: ").append(toIndentedString(cost)).append("\n"); - sb.append(" egressCost: ").append(toIndentedString(egressCost)).append("\n"); - sb.append(" accessCost: ").append(toIndentedString(accessCost)).append("\n"); - sb.append(" queryType: ").append(toIndentedString(queryType)).append("\n"); - sb.append(" udfCode: ").append(toIndentedString(udfCode)).append("\n"); - sb.append(" udfLanguage: ").append(toIndentedString(udfLanguage)).append("\n"); - sb.append(" sqlQuery: ").append(toIndentedString(sqlQuery)).append("\n"); - sb.append(" type: ").append(toIndentedString(type)).append("\n"); - sb.append(" activity: ").append(toIndentedString(activity)).append("\n"); - sb.append(" logs: ").append(toIndentedString(logs)).append("\n"); - sb.append(" duration: ").append(toIndentedString(duration)).append("\n"); - sb.append(" sqlInitCommands: ").append(toIndentedString(sqlInitCommands)).append("\n"); - sb.append(" sqlParameters: ").append(toIndentedString(sqlParameters)).append("\n"); - sb.append(" resultFormat: ").append(toIndentedString(resultFormat)).append("\n"); - sb.append(" taskGraphUuid: ").append(toIndentedString(taskGraphUuid)).append("\n"); - sb.append(" clientNodeUuid: ").append(toIndentedString(clientNodeUuid)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("id"); - openapiFields.add("name"); - openapiFields.add("username"); - openapiFields.add("description"); - openapiFields.add("array_metadata"); - openapiFields.add("subarray"); - openapiFields.add("memory"); - openapiFields.add("cpu"); - openapiFields.add("namespace"); - openapiFields.add("status"); - openapiFields.add("status_message"); - openapiFields.add("start_time"); - openapiFields.add("finish_time"); - openapiFields.add("cost"); - openapiFields.add("egress_cost"); - openapiFields.add("access_cost"); - openapiFields.add("query_type"); - openapiFields.add("udf_code"); - openapiFields.add("udf_language"); - openapiFields.add("sql_query"); - openapiFields.add("type"); - openapiFields.add("activity"); - openapiFields.add("logs"); - openapiFields.add("duration"); - openapiFields.add("sql_init_commands"); - openapiFields.add("sql_parameters"); - openapiFields.add("result_format"); - openapiFields.add("task_graph_uuid"); - openapiFields.add("client_node_uuid"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to ArrayTask - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (ArrayTask.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in ArrayTask is not found in the empty JSON string", ArrayTask.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) && !jsonObj.get("id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("id").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - if ((jsonObj.get("username") != null && !jsonObj.get("username").isJsonNull()) && !jsonObj.get("username").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `username` to be a primitive type in the JSON string but got `%s`", jsonObj.get("username").toString())); - } - if ((jsonObj.get("description") != null && !jsonObj.get("description").isJsonNull()) && !jsonObj.get("description").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `description` to be a primitive type in the JSON string but got `%s`", jsonObj.get("description").toString())); - } - // validate the optional field `array_metadata` - if (jsonObj.get("array_metadata") != null && !jsonObj.get("array_metadata").isJsonNull()) { - ArrayInfo.validateJsonObject(jsonObj.getAsJsonObject("array_metadata")); - } - // validate the optional field `subarray` - if (jsonObj.get("subarray") != null && !jsonObj.get("subarray").isJsonNull()) { - DomainArray.validateJsonObject(jsonObj.getAsJsonObject("subarray")); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - if ((jsonObj.get("status_message") != null && !jsonObj.get("status_message").isJsonNull()) && !jsonObj.get("status_message").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `status_message` to be a primitive type in the JSON string but got `%s`", jsonObj.get("status_message").toString())); - } - if ((jsonObj.get("udf_code") != null && !jsonObj.get("udf_code").isJsonNull()) && !jsonObj.get("udf_code").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `udf_code` to be a primitive type in the JSON string but got `%s`", jsonObj.get("udf_code").toString())); - } - if ((jsonObj.get("udf_language") != null && !jsonObj.get("udf_language").isJsonNull()) && !jsonObj.get("udf_language").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `udf_language` to be a primitive type in the JSON string but got `%s`", jsonObj.get("udf_language").toString())); - } - if ((jsonObj.get("sql_query") != null && !jsonObj.get("sql_query").isJsonNull()) && !jsonObj.get("sql_query").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `sql_query` to be a primitive type in the JSON string but got `%s`", jsonObj.get("sql_query").toString())); - } - JsonArray jsonArrayactivity = jsonObj.getAsJsonArray("activity"); - if (jsonArrayactivity != null) { - // ensure the json data is an array - if (!jsonObj.get("activity").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `activity` to be an array in the JSON string but got `%s`", jsonObj.get("activity").toString())); - } - - // validate the optional field `activity` (array) - for (int i = 0; i < jsonArrayactivity.size(); i++) { - ArrayActivityLog.validateJsonObject(jsonArrayactivity.get(i).getAsJsonObject()); - }; - } - if ((jsonObj.get("logs") != null && !jsonObj.get("logs").isJsonNull()) && !jsonObj.get("logs").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `logs` to be a primitive type in the JSON string but got `%s`", jsonObj.get("logs").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("sql_init_commands") != null && !jsonObj.get("sql_init_commands").isJsonNull()) && !jsonObj.get("sql_init_commands").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `sql_init_commands` to be an array in the JSON string but got `%s`", jsonObj.get("sql_init_commands").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("sql_parameters") != null && !jsonObj.get("sql_parameters").isJsonNull()) && !jsonObj.get("sql_parameters").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `sql_parameters` to be an array in the JSON string but got `%s`", jsonObj.get("sql_parameters").toString())); - } - if ((jsonObj.get("task_graph_uuid") != null && !jsonObj.get("task_graph_uuid").isJsonNull()) && !jsonObj.get("task_graph_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `task_graph_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("task_graph_uuid").toString())); - } - if ((jsonObj.get("client_node_uuid") != null && !jsonObj.get("client_node_uuid").isJsonNull()) && !jsonObj.get("client_node_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `client_node_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("client_node_uuid").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!ArrayTask.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'ArrayTask' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(ArrayTask.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, ArrayTask value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public ArrayTask read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - ArrayTask instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of ArrayTask given an JSON string - * - * @param jsonString JSON string - * @return An instance of ArrayTask - * @throws IOException if the JSON string is invalid with respect to ArrayTask - */ - public static ArrayTask fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, ArrayTask.class); - } - - /** - * Convert an instance of ArrayTask to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayTaskBrowserSidebar.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayTaskBrowserSidebar.java deleted file mode 100644 index 2622189..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayTaskBrowserSidebar.java +++ /dev/null @@ -1,336 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Object for ui array tasks browser page - */ -@ApiModel(description = "Object for ui array tasks browser page") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ArrayTaskBrowserSidebar { - public static final String SERIALIZED_NAME_ORGANIZATIONS = "organizations"; - @SerializedName(SERIALIZED_NAME_ORGANIZATIONS) - private List organizations = null; - - public static final String SERIALIZED_NAME_RESULT_COUNT_FOR_ALL = "result_count_for_all"; - @SerializedName(SERIALIZED_NAME_RESULT_COUNT_FOR_ALL) - private Integer resultCountForAll; - - public static final String SERIALIZED_NAME_RESULT_COUNT_BY_NAMESPACE = "result_count_by_namespace"; - @SerializedName(SERIALIZED_NAME_RESULT_COUNT_BY_NAMESPACE) - private Object resultCountByNamespace; - - public ArrayTaskBrowserSidebar() { - } - - public ArrayTaskBrowserSidebar organizations(List organizations) { - - this.organizations = organizations; - return this; - } - - public ArrayTaskBrowserSidebar addOrganizationsItem(String organizationsItem) { - if (this.organizations == null) { - this.organizations = new ArrayList<>(); - } - this.organizations.add(organizationsItem); - return this; - } - - /** - * list of all unique organizations the user is part of that have array tasks - * @return organizations - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "list of all unique organizations the user is part of that have array tasks") - - public List getOrganizations() { - return organizations; - } - - - public void setOrganizations(List organizations) { - this.organizations = organizations; - } - - - public ArrayTaskBrowserSidebar resultCountForAll(Integer resultCountForAll) { - - this.resultCountForAll = resultCountForAll; - return this; - } - - /** - * A count of \"all\" - * @return resultCountForAll - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "A count of \"all\"") - - public Integer getResultCountForAll() { - return resultCountForAll; - } - - - public void setResultCountForAll(Integer resultCountForAll) { - this.resultCountForAll = resultCountForAll; - } - - - public ArrayTaskBrowserSidebar resultCountByNamespace(Object resultCountByNamespace) { - - this.resultCountByNamespace = resultCountByNamespace; - return this; - } - - /** - * A map that includes the result count by namespace - * @return resultCountByNamespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "A map that includes the result count by namespace") - - public Object getResultCountByNamespace() { - return resultCountByNamespace; - } - - - public void setResultCountByNamespace(Object resultCountByNamespace) { - this.resultCountByNamespace = resultCountByNamespace; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public ArrayTaskBrowserSidebar putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ArrayTaskBrowserSidebar arrayTaskBrowserSidebar = (ArrayTaskBrowserSidebar) o; - return Objects.equals(this.organizations, arrayTaskBrowserSidebar.organizations) && - Objects.equals(this.resultCountForAll, arrayTaskBrowserSidebar.resultCountForAll) && - Objects.equals(this.resultCountByNamespace, arrayTaskBrowserSidebar.resultCountByNamespace)&& - Objects.equals(this.additionalProperties, arrayTaskBrowserSidebar.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(organizations, resultCountForAll, resultCountByNamespace, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ArrayTaskBrowserSidebar {\n"); - sb.append(" organizations: ").append(toIndentedString(organizations)).append("\n"); - sb.append(" resultCountForAll: ").append(toIndentedString(resultCountForAll)).append("\n"); - sb.append(" resultCountByNamespace: ").append(toIndentedString(resultCountByNamespace)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("organizations"); - openapiFields.add("result_count_for_all"); - openapiFields.add("result_count_by_namespace"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to ArrayTaskBrowserSidebar - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (ArrayTaskBrowserSidebar.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in ArrayTaskBrowserSidebar is not found in the empty JSON string", ArrayTaskBrowserSidebar.openapiRequiredFields.toString())); - } - } - // ensure the json data is an array - if ((jsonObj.get("organizations") != null && !jsonObj.get("organizations").isJsonNull()) && !jsonObj.get("organizations").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `organizations` to be an array in the JSON string but got `%s`", jsonObj.get("organizations").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!ArrayTaskBrowserSidebar.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'ArrayTaskBrowserSidebar' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(ArrayTaskBrowserSidebar.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, ArrayTaskBrowserSidebar value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public ArrayTaskBrowserSidebar read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - ArrayTaskBrowserSidebar instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of ArrayTaskBrowserSidebar given an JSON string - * - * @param jsonString JSON string - * @return An instance of ArrayTaskBrowserSidebar - * @throws IOException if the JSON string is invalid with respect to ArrayTaskBrowserSidebar - */ - public static ArrayTaskBrowserSidebar fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, ArrayTaskBrowserSidebar.class); - } - - /** - * Convert an instance of ArrayTaskBrowserSidebar to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayTaskData.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayTaskData.java deleted file mode 100644 index 4d00bd5..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayTaskData.java +++ /dev/null @@ -1,319 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Object including array tasks and metadata - */ -@ApiModel(description = "Object including array tasks and metadata") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ArrayTaskData { - public static final String SERIALIZED_NAME_ARRAY_TASKS = "array_tasks"; - @SerializedName(SERIALIZED_NAME_ARRAY_TASKS) - private List arrayTasks = null; - - public static final String SERIALIZED_NAME_PAGINATION_METADATA = "pagination_metadata"; - @SerializedName(SERIALIZED_NAME_PAGINATION_METADATA) - private PaginationMetadata paginationMetadata; - - public ArrayTaskData() { - } - - public ArrayTaskData arrayTasks(List arrayTasks) { - - this.arrayTasks = arrayTasks; - return this; - } - - public ArrayTaskData addArrayTasksItem(ArrayTask arrayTasksItem) { - if (this.arrayTasks == null) { - this.arrayTasks = new ArrayList<>(); - } - this.arrayTasks.add(arrayTasksItem); - return this; - } - - /** - * Array Tasks - * @return arrayTasks - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Array Tasks") - - public List getArrayTasks() { - return arrayTasks; - } - - - public void setArrayTasks(List arrayTasks) { - this.arrayTasks = arrayTasks; - } - - - public ArrayTaskData paginationMetadata(PaginationMetadata paginationMetadata) { - - this.paginationMetadata = paginationMetadata; - return this; - } - - /** - * Get paginationMetadata - * @return paginationMetadata - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public PaginationMetadata getPaginationMetadata() { - return paginationMetadata; - } - - - public void setPaginationMetadata(PaginationMetadata paginationMetadata) { - this.paginationMetadata = paginationMetadata; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public ArrayTaskData putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ArrayTaskData arrayTaskData = (ArrayTaskData) o; - return Objects.equals(this.arrayTasks, arrayTaskData.arrayTasks) && - Objects.equals(this.paginationMetadata, arrayTaskData.paginationMetadata)&& - Objects.equals(this.additionalProperties, arrayTaskData.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(arrayTasks, paginationMetadata, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ArrayTaskData {\n"); - sb.append(" arrayTasks: ").append(toIndentedString(arrayTasks)).append("\n"); - sb.append(" paginationMetadata: ").append(toIndentedString(paginationMetadata)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("array_tasks"); - openapiFields.add("pagination_metadata"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to ArrayTaskData - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (ArrayTaskData.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in ArrayTaskData is not found in the empty JSON string", ArrayTaskData.openapiRequiredFields.toString())); - } - } - JsonArray jsonArrayarrayTasks = jsonObj.getAsJsonArray("array_tasks"); - if (jsonArrayarrayTasks != null) { - // ensure the json data is an array - if (!jsonObj.get("array_tasks").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `array_tasks` to be an array in the JSON string but got `%s`", jsonObj.get("array_tasks").toString())); - } - - // validate the optional field `array_tasks` (array) - for (int i = 0; i < jsonArrayarrayTasks.size(); i++) { - ArrayTask.validateJsonObject(jsonArrayarrayTasks.get(i).getAsJsonObject()); - }; - } - // validate the optional field `pagination_metadata` - if (jsonObj.get("pagination_metadata") != null && !jsonObj.get("pagination_metadata").isJsonNull()) { - PaginationMetadata.validateJsonObject(jsonObj.getAsJsonObject("pagination_metadata")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!ArrayTaskData.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'ArrayTaskData' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(ArrayTaskData.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, ArrayTaskData value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public ArrayTaskData read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - ArrayTaskData instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of ArrayTaskData given an JSON string - * - * @param jsonString JSON string - * @return An instance of ArrayTaskData - * @throws IOException if the JSON string is invalid with respect to ArrayTaskData - */ - public static ArrayTaskData fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, ArrayTaskData.class); - } - - /** - * Convert an instance of ArrayTaskData to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayTaskLog.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayTaskLog.java deleted file mode 100644 index 074b0e3..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayTaskLog.java +++ /dev/null @@ -1,298 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Array task stderr/stdout logs - */ -@ApiModel(description = "Array task stderr/stdout logs") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ArrayTaskLog { - public static final String SERIALIZED_NAME_ARRAY_TASK_ID = "array_task_id"; - @SerializedName(SERIALIZED_NAME_ARRAY_TASK_ID) - private String arrayTaskId; - - public static final String SERIALIZED_NAME_LOGS = "logs"; - @SerializedName(SERIALIZED_NAME_LOGS) - private String logs; - - public ArrayTaskLog() { - } - - public ArrayTaskLog arrayTaskId(String arrayTaskId) { - - this.arrayTaskId = arrayTaskId; - return this; - } - - /** - * ID of associated task - * @return arrayTaskId - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "ID of associated task") - - public String getArrayTaskId() { - return arrayTaskId; - } - - - public void setArrayTaskId(String arrayTaskId) { - this.arrayTaskId = arrayTaskId; - } - - - public ArrayTaskLog logs(String logs) { - - this.logs = logs; - return this; - } - - /** - * logs from array task - * @return logs - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "logs from array task") - - public String getLogs() { - return logs; - } - - - public void setLogs(String logs) { - this.logs = logs; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public ArrayTaskLog putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ArrayTaskLog arrayTaskLog = (ArrayTaskLog) o; - return Objects.equals(this.arrayTaskId, arrayTaskLog.arrayTaskId) && - Objects.equals(this.logs, arrayTaskLog.logs)&& - Objects.equals(this.additionalProperties, arrayTaskLog.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(arrayTaskId, logs, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ArrayTaskLog {\n"); - sb.append(" arrayTaskId: ").append(toIndentedString(arrayTaskId)).append("\n"); - sb.append(" logs: ").append(toIndentedString(logs)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("array_task_id"); - openapiFields.add("logs"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to ArrayTaskLog - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (ArrayTaskLog.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in ArrayTaskLog is not found in the empty JSON string", ArrayTaskLog.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("array_task_id") != null && !jsonObj.get("array_task_id").isJsonNull()) && !jsonObj.get("array_task_id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `array_task_id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("array_task_id").toString())); - } - if ((jsonObj.get("logs") != null && !jsonObj.get("logs").isJsonNull()) && !jsonObj.get("logs").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `logs` to be a primitive type in the JSON string but got `%s`", jsonObj.get("logs").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!ArrayTaskLog.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'ArrayTaskLog' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(ArrayTaskLog.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, ArrayTaskLog value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public ArrayTaskLog read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - ArrayTaskLog instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of ArrayTaskLog given an JSON string - * - * @param jsonString JSON string - * @return An instance of ArrayTaskLog - * @throws IOException if the JSON string is invalid with respect to ArrayTaskLog - */ - public static ArrayTaskLog fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, ArrayTaskLog.class); - } - - /** - * Convert an instance of ArrayTaskLog to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayTaskStatus.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayTaskStatus.java deleted file mode 100644 index bde4725..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayTaskStatus.java +++ /dev/null @@ -1,81 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * Status of array task - */ -@JsonAdapter(ArrayTaskStatus.Adapter.class) -public enum ArrayTaskStatus { - - QUEUED("QUEUED"), - - FAILED("FAILED"), - - COMPLETED("COMPLETED"), - - RUNNING("RUNNING"), - - RESOURCES_UNAVAILABLE("RESOURCES_UNAVAILABLE"), - - UNKNOWN("UNKNOWN"), - - CANCELLED("CANCELLED"), - - DENIED("DENIED"); - - private String value; - - ArrayTaskStatus(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static ArrayTaskStatus fromValue(String value) { - for (ArrayTaskStatus b : ArrayTaskStatus.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final ArrayTaskStatus enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public ArrayTaskStatus read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return ArrayTaskStatus.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayTaskType.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayTaskType.java deleted file mode 100644 index e8c0409..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayTaskType.java +++ /dev/null @@ -1,77 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * Synchronous Task Type - */ -@JsonAdapter(ArrayTaskType.Adapter.class) -public enum ArrayTaskType { - - SQL("SQL"), - - UDF("UDF"), - - QUERY("QUERY"), - - GENERIC_UDF("GENERIC_UDF"), - - BATCH_UDF("BATCH_UDF"), - - CLIENT_COMPUTATION("CLIENT_COMPUTATION"); - - private String value; - - ArrayTaskType(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static ArrayTaskType fromValue(String value) { - for (ArrayTaskType b : ArrayTaskType.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final ArrayTaskType enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public ArrayTaskType read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return ArrayTaskType.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayType.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayType.java deleted file mode 100644 index 72b5f09..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayType.java +++ /dev/null @@ -1,69 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * TileDB array type - */ -@JsonAdapter(ArrayType.Adapter.class) -public enum ArrayType { - - DENSE("dense"), - - SPARSE("sparse"); - - private String value; - - ArrayType(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static ArrayType fromValue(String value) { - for (ArrayType b : ArrayType.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final ArrayType enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public ArrayType read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return ArrayType.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayVacuumRequest.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayVacuumRequest.java deleted file mode 100644 index 7303e96..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ArrayVacuumRequest.java +++ /dev/null @@ -1,266 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Request to consolidate an array - */ -@ApiModel(description = "Request to consolidate an array") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ArrayVacuumRequest { - public static final String SERIALIZED_NAME_CONFIG = "config"; - @SerializedName(SERIALIZED_NAME_CONFIG) - private TileDBConfig config; - - public ArrayVacuumRequest() { - } - - public ArrayVacuumRequest config(TileDBConfig config) { - - this.config = config; - return this; - } - - /** - * Get config - * @return config - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public TileDBConfig getConfig() { - return config; - } - - - public void setConfig(TileDBConfig config) { - this.config = config; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public ArrayVacuumRequest putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ArrayVacuumRequest arrayVacuumRequest = (ArrayVacuumRequest) o; - return Objects.equals(this.config, arrayVacuumRequest.config)&& - Objects.equals(this.additionalProperties, arrayVacuumRequest.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(config, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ArrayVacuumRequest {\n"); - sb.append(" config: ").append(toIndentedString(config)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("config"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to ArrayVacuumRequest - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (ArrayVacuumRequest.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in ArrayVacuumRequest is not found in the empty JSON string", ArrayVacuumRequest.openapiRequiredFields.toString())); - } - } - // validate the optional field `config` - if (jsonObj.get("config") != null && !jsonObj.get("config").isJsonNull()) { - TileDBConfig.validateJsonObject(jsonObj.getAsJsonObject("config")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!ArrayVacuumRequest.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'ArrayVacuumRequest' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(ArrayVacuumRequest.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, ArrayVacuumRequest value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public ArrayVacuumRequest read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - ArrayVacuumRequest instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of ArrayVacuumRequest given an JSON string - * - * @param jsonString JSON string - * @return An instance of ArrayVacuumRequest - * @throws IOException if the JSON string is invalid with respect to ArrayVacuumRequest - */ - public static ArrayVacuumRequest fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, ArrayVacuumRequest.class); - } - - /** - * Convert an instance of ArrayVacuumRequest to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/AssetLocations.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/AssetLocations.java deleted file mode 100644 index 438aee8..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/AssetLocations.java +++ /dev/null @@ -1,470 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Custom storage locations on a per–asset type basis. If any is unset, a suffix of the owning (user/organization) `default_s3_path` is used. - */ -@ApiModel(description = "Custom storage locations on a per–asset type basis. If any is unset, a suffix of the owning (user/organization) `default_s3_path` is used. ") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class AssetLocations { - public static final String SERIALIZED_NAME_ARRAYS = "arrays"; - @SerializedName(SERIALIZED_NAME_ARRAYS) - private StorageLocation arrays; - - public static final String SERIALIZED_NAME_FILES = "files"; - @SerializedName(SERIALIZED_NAME_FILES) - private StorageLocation files; - - public static final String SERIALIZED_NAME_GROUPS = "groups"; - @SerializedName(SERIALIZED_NAME_GROUPS) - private StorageLocation groups; - - public static final String SERIALIZED_NAME_ML_MODELS = "ml_models"; - @SerializedName(SERIALIZED_NAME_ML_MODELS) - private StorageLocation mlModels; - - public static final String SERIALIZED_NAME_NOTEBOOKS = "notebooks"; - @SerializedName(SERIALIZED_NAME_NOTEBOOKS) - private StorageLocation notebooks; - - public static final String SERIALIZED_NAME_TASK_GRAPHS = "task_graphs"; - @SerializedName(SERIALIZED_NAME_TASK_GRAPHS) - private StorageLocation taskGraphs; - - public static final String SERIALIZED_NAME_UDFS = "udfs"; - @SerializedName(SERIALIZED_NAME_UDFS) - private StorageLocation udfs; - - public AssetLocations() { - } - - public AssetLocations arrays(StorageLocation arrays) { - - this.arrays = arrays; - return this; - } - - /** - * Get arrays - * @return arrays - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public StorageLocation getArrays() { - return arrays; - } - - - public void setArrays(StorageLocation arrays) { - this.arrays = arrays; - } - - - public AssetLocations files(StorageLocation files) { - - this.files = files; - return this; - } - - /** - * Get files - * @return files - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public StorageLocation getFiles() { - return files; - } - - - public void setFiles(StorageLocation files) { - this.files = files; - } - - - public AssetLocations groups(StorageLocation groups) { - - this.groups = groups; - return this; - } - - /** - * Get groups - * @return groups - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public StorageLocation getGroups() { - return groups; - } - - - public void setGroups(StorageLocation groups) { - this.groups = groups; - } - - - public AssetLocations mlModels(StorageLocation mlModels) { - - this.mlModels = mlModels; - return this; - } - - /** - * Get mlModels - * @return mlModels - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public StorageLocation getMlModels() { - return mlModels; - } - - - public void setMlModels(StorageLocation mlModels) { - this.mlModels = mlModels; - } - - - public AssetLocations notebooks(StorageLocation notebooks) { - - this.notebooks = notebooks; - return this; - } - - /** - * Get notebooks - * @return notebooks - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public StorageLocation getNotebooks() { - return notebooks; - } - - - public void setNotebooks(StorageLocation notebooks) { - this.notebooks = notebooks; - } - - - public AssetLocations taskGraphs(StorageLocation taskGraphs) { - - this.taskGraphs = taskGraphs; - return this; - } - - /** - * Get taskGraphs - * @return taskGraphs - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public StorageLocation getTaskGraphs() { - return taskGraphs; - } - - - public void setTaskGraphs(StorageLocation taskGraphs) { - this.taskGraphs = taskGraphs; - } - - - public AssetLocations udfs(StorageLocation udfs) { - - this.udfs = udfs; - return this; - } - - /** - * Get udfs - * @return udfs - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public StorageLocation getUdfs() { - return udfs; - } - - - public void setUdfs(StorageLocation udfs) { - this.udfs = udfs; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public AssetLocations putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - AssetLocations assetLocations = (AssetLocations) o; - return Objects.equals(this.arrays, assetLocations.arrays) && - Objects.equals(this.files, assetLocations.files) && - Objects.equals(this.groups, assetLocations.groups) && - Objects.equals(this.mlModels, assetLocations.mlModels) && - Objects.equals(this.notebooks, assetLocations.notebooks) && - Objects.equals(this.taskGraphs, assetLocations.taskGraphs) && - Objects.equals(this.udfs, assetLocations.udfs)&& - Objects.equals(this.additionalProperties, assetLocations.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(arrays, files, groups, mlModels, notebooks, taskGraphs, udfs, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class AssetLocations {\n"); - sb.append(" arrays: ").append(toIndentedString(arrays)).append("\n"); - sb.append(" files: ").append(toIndentedString(files)).append("\n"); - sb.append(" groups: ").append(toIndentedString(groups)).append("\n"); - sb.append(" mlModels: ").append(toIndentedString(mlModels)).append("\n"); - sb.append(" notebooks: ").append(toIndentedString(notebooks)).append("\n"); - sb.append(" taskGraphs: ").append(toIndentedString(taskGraphs)).append("\n"); - sb.append(" udfs: ").append(toIndentedString(udfs)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("arrays"); - openapiFields.add("files"); - openapiFields.add("groups"); - openapiFields.add("ml_models"); - openapiFields.add("notebooks"); - openapiFields.add("task_graphs"); - openapiFields.add("udfs"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to AssetLocations - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (AssetLocations.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in AssetLocations is not found in the empty JSON string", AssetLocations.openapiRequiredFields.toString())); - } - } - // validate the optional field `arrays` - if (jsonObj.get("arrays") != null && !jsonObj.get("arrays").isJsonNull()) { - StorageLocation.validateJsonObject(jsonObj.getAsJsonObject("arrays")); - } - // validate the optional field `files` - if (jsonObj.get("files") != null && !jsonObj.get("files").isJsonNull()) { - StorageLocation.validateJsonObject(jsonObj.getAsJsonObject("files")); - } - // validate the optional field `groups` - if (jsonObj.get("groups") != null && !jsonObj.get("groups").isJsonNull()) { - StorageLocation.validateJsonObject(jsonObj.getAsJsonObject("groups")); - } - // validate the optional field `ml_models` - if (jsonObj.get("ml_models") != null && !jsonObj.get("ml_models").isJsonNull()) { - StorageLocation.validateJsonObject(jsonObj.getAsJsonObject("ml_models")); - } - // validate the optional field `notebooks` - if (jsonObj.get("notebooks") != null && !jsonObj.get("notebooks").isJsonNull()) { - StorageLocation.validateJsonObject(jsonObj.getAsJsonObject("notebooks")); - } - // validate the optional field `task_graphs` - if (jsonObj.get("task_graphs") != null && !jsonObj.get("task_graphs").isJsonNull()) { - StorageLocation.validateJsonObject(jsonObj.getAsJsonObject("task_graphs")); - } - // validate the optional field `udfs` - if (jsonObj.get("udfs") != null && !jsonObj.get("udfs").isJsonNull()) { - StorageLocation.validateJsonObject(jsonObj.getAsJsonObject("udfs")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!AssetLocations.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'AssetLocations' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(AssetLocations.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, AssetLocations value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public AssetLocations read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - AssetLocations instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of AssetLocations given an JSON string - * - * @param jsonString JSON string - * @return An instance of AssetLocations - * @throws IOException if the JSON string is invalid with respect to AssetLocations - */ - public static AssetLocations fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, AssetLocations.class); - } - - /** - * Convert an instance of AssetLocations to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/AssetType.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/AssetType.java deleted file mode 100644 index 46388ed..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/AssetType.java +++ /dev/null @@ -1,95 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * Asset types represented as TileDB arrays - */ -@JsonAdapter(AssetType.Adapter.class) -public enum AssetType { - - ARRAY("array"), - - NOTEBOOK("notebook"), - - DASHBOARD("dashboard"), - - USER_DEFINED_FUNCTION("user_defined_function"), - - ML_MODEL("ml_model"), - - FILE("file"), - - REGISTERED_TASK_GRAPH("registered_task_graph"), - - GROUP("group"), - - VCF("vcf"), - - SOMA("soma"), - - POINTCLOUD("pointcloud"), - - BIOIMG("bioimg"), - - GEOMETRY("geometry"), - - RASTER("raster"), - - VECTOR_SEARCH("vector_search"); - - private String value; - - AssetType(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static AssetType fromValue(String value) { - for (AssetType b : AssetType.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final AssetType enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public AssetType read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return AssetType.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Attribute.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/Attribute.java deleted file mode 100644 index 1463043..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Attribute.java +++ /dev/null @@ -1,444 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Attribute of array - */ -@ApiModel(description = "Attribute of array") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class Attribute { - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_TYPE = "type"; - @SerializedName(SERIALIZED_NAME_TYPE) - private Datatype type; - - public static final String SERIALIZED_NAME_FILTER_PIPELINE = "filterPipeline"; - @SerializedName(SERIALIZED_NAME_FILTER_PIPELINE) - private FilterPipeline filterPipeline; - - public static final String SERIALIZED_NAME_CELL_VAL_NUM = "cellValNum"; - @SerializedName(SERIALIZED_NAME_CELL_VAL_NUM) - private Integer cellValNum; - - public static final String SERIALIZED_NAME_NULLABLE = "nullable"; - @SerializedName(SERIALIZED_NAME_NULLABLE) - private Boolean nullable; - - public static final String SERIALIZED_NAME_FILL_VALUE = "fillValue"; - @SerializedName(SERIALIZED_NAME_FILL_VALUE) - private List fillValue = null; - - public Attribute() { - } - - public Attribute name(String name) { - - this.name = name; - return this; - } - - /** - * Attribute name - * @return name - **/ - @javax.annotation.Nonnull - @ApiModelProperty(example = "attribute1", required = true, value = "Attribute name") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public Attribute type(Datatype type) { - - this.type = type; - return this; - } - - /** - * Get type - * @return type - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public Datatype getType() { - return type; - } - - - public void setType(Datatype type) { - this.type = type; - } - - - public Attribute filterPipeline(FilterPipeline filterPipeline) { - - this.filterPipeline = filterPipeline; - return this; - } - - /** - * Get filterPipeline - * @return filterPipeline - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public FilterPipeline getFilterPipeline() { - return filterPipeline; - } - - - public void setFilterPipeline(FilterPipeline filterPipeline) { - this.filterPipeline = filterPipeline; - } - - - public Attribute cellValNum(Integer cellValNum) { - - this.cellValNum = cellValNum; - return this; - } - - /** - * Attribute number of values per cell - * @return cellValNum - **/ - @javax.annotation.Nonnull - @ApiModelProperty(example = "1", required = true, value = "Attribute number of values per cell") - - public Integer getCellValNum() { - return cellValNum; - } - - - public void setCellValNum(Integer cellValNum) { - this.cellValNum = cellValNum; - } - - - public Attribute nullable(Boolean nullable) { - - this.nullable = nullable; - return this; - } - - /** - * Is attribute nullable - * @return nullable - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "true", value = "Is attribute nullable") - - public Boolean getNullable() { - return nullable; - } - - - public void setNullable(Boolean nullable) { - this.nullable = nullable; - } - - - public Attribute fillValue(List fillValue) { - - this.fillValue = fillValue; - return this; - } - - public Attribute addFillValueItem(Integer fillValueItem) { - if (this.fillValue == null) { - this.fillValue = new ArrayList<>(); - } - this.fillValue.add(fillValueItem); - return this; - } - - /** - * The default fill value - * @return fillValue - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The default fill value") - - public List getFillValue() { - return fillValue; - } - - - public void setFillValue(List fillValue) { - this.fillValue = fillValue; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public Attribute putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Attribute attribute = (Attribute) o; - return Objects.equals(this.name, attribute.name) && - Objects.equals(this.type, attribute.type) && - Objects.equals(this.filterPipeline, attribute.filterPipeline) && - Objects.equals(this.cellValNum, attribute.cellValNum) && - Objects.equals(this.nullable, attribute.nullable) && - Objects.equals(this.fillValue, attribute.fillValue)&& - Objects.equals(this.additionalProperties, attribute.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(name, type, filterPipeline, cellValNum, nullable, fillValue, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Attribute {\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" type: ").append(toIndentedString(type)).append("\n"); - sb.append(" filterPipeline: ").append(toIndentedString(filterPipeline)).append("\n"); - sb.append(" cellValNum: ").append(toIndentedString(cellValNum)).append("\n"); - sb.append(" nullable: ").append(toIndentedString(nullable)).append("\n"); - sb.append(" fillValue: ").append(toIndentedString(fillValue)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("name"); - openapiFields.add("type"); - openapiFields.add("filterPipeline"); - openapiFields.add("cellValNum"); - openapiFields.add("nullable"); - openapiFields.add("fillValue"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - openapiRequiredFields.add("name"); - openapiRequiredFields.add("type"); - openapiRequiredFields.add("filterPipeline"); - openapiRequiredFields.add("cellValNum"); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to Attribute - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (Attribute.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in Attribute is not found in the empty JSON string", Attribute.openapiRequiredFields.toString())); - } - } - - // check to make sure all required properties/fields are present in the JSON string - for (String requiredField : Attribute.openapiRequiredFields) { - if (jsonObj.get(requiredField) == null) { - throw new IllegalArgumentException(String.format("The required field `%s` is not found in the JSON string: %s", requiredField, jsonObj.toString())); - } - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - // validate the optional field `filterPipeline` - if (jsonObj.get("filterPipeline") != null && !jsonObj.get("filterPipeline").isJsonNull()) { - FilterPipeline.validateJsonObject(jsonObj.getAsJsonObject("filterPipeline")); - } - // ensure the json data is an array - if ((jsonObj.get("fillValue") != null && !jsonObj.get("fillValue").isJsonNull()) && !jsonObj.get("fillValue").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `fillValue` to be an array in the JSON string but got `%s`", jsonObj.get("fillValue").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!Attribute.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'Attribute' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(Attribute.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, Attribute value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public Attribute read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - Attribute instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of Attribute given an JSON string - * - * @param jsonString JSON string - * @return An instance of Attribute - * @throws IOException if the JSON string is invalid with respect to Attribute - */ - public static Attribute fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, Attribute.class); - } - - /** - * Convert an instance of Attribute to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/AttributeBufferHeader.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/AttributeBufferHeader.java deleted file mode 100644 index f9fe7df..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/AttributeBufferHeader.java +++ /dev/null @@ -1,335 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Represents an attribute buffer header information - */ -@ApiModel(description = "Represents an attribute buffer header information") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class AttributeBufferHeader { - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_FIXED_LEN_BUFFER_SIZE_IN_BYTES = "fixedLenBufferSizeInBytes"; - @SerializedName(SERIALIZED_NAME_FIXED_LEN_BUFFER_SIZE_IN_BYTES) - private Integer fixedLenBufferSizeInBytes; - - public static final String SERIALIZED_NAME_VAR_LEN_BUFFER_SIZE_IN_BYTES = "varLenBufferSizeInBytes"; - @SerializedName(SERIALIZED_NAME_VAR_LEN_BUFFER_SIZE_IN_BYTES) - private Integer varLenBufferSizeInBytes; - - public AttributeBufferHeader() { - } - - public AttributeBufferHeader name(String name) { - - this.name = name; - return this; - } - - /** - * Attribute name - * @return name - **/ - @javax.annotation.Nonnull - @ApiModelProperty(example = "attribute1", required = true, value = "Attribute name") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public AttributeBufferHeader fixedLenBufferSizeInBytes(Integer fixedLenBufferSizeInBytes) { - - this.fixedLenBufferSizeInBytes = fixedLenBufferSizeInBytes; - return this; - } - - /** - * Number of bytes in the fixed-length attribute data buffer (offsets for var-len attributes) - * @return fixedLenBufferSizeInBytes - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "Number of bytes in the fixed-length attribute data buffer (offsets for var-len attributes)") - - public Integer getFixedLenBufferSizeInBytes() { - return fixedLenBufferSizeInBytes; - } - - - public void setFixedLenBufferSizeInBytes(Integer fixedLenBufferSizeInBytes) { - this.fixedLenBufferSizeInBytes = fixedLenBufferSizeInBytes; - } - - - public AttributeBufferHeader varLenBufferSizeInBytes(Integer varLenBufferSizeInBytes) { - - this.varLenBufferSizeInBytes = varLenBufferSizeInBytes; - return this; - } - - /** - * Number of bytes in the var-length attribute data buffer - * @return varLenBufferSizeInBytes - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "Number of bytes in the var-length attribute data buffer") - - public Integer getVarLenBufferSizeInBytes() { - return varLenBufferSizeInBytes; - } - - - public void setVarLenBufferSizeInBytes(Integer varLenBufferSizeInBytes) { - this.varLenBufferSizeInBytes = varLenBufferSizeInBytes; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public AttributeBufferHeader putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - AttributeBufferHeader attributeBufferHeader = (AttributeBufferHeader) o; - return Objects.equals(this.name, attributeBufferHeader.name) && - Objects.equals(this.fixedLenBufferSizeInBytes, attributeBufferHeader.fixedLenBufferSizeInBytes) && - Objects.equals(this.varLenBufferSizeInBytes, attributeBufferHeader.varLenBufferSizeInBytes)&& - Objects.equals(this.additionalProperties, attributeBufferHeader.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(name, fixedLenBufferSizeInBytes, varLenBufferSizeInBytes, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class AttributeBufferHeader {\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" fixedLenBufferSizeInBytes: ").append(toIndentedString(fixedLenBufferSizeInBytes)).append("\n"); - sb.append(" varLenBufferSizeInBytes: ").append(toIndentedString(varLenBufferSizeInBytes)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("name"); - openapiFields.add("fixedLenBufferSizeInBytes"); - openapiFields.add("varLenBufferSizeInBytes"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - openapiRequiredFields.add("name"); - openapiRequiredFields.add("fixedLenBufferSizeInBytes"); - openapiRequiredFields.add("varLenBufferSizeInBytes"); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to AttributeBufferHeader - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (AttributeBufferHeader.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in AttributeBufferHeader is not found in the empty JSON string", AttributeBufferHeader.openapiRequiredFields.toString())); - } - } - - // check to make sure all required properties/fields are present in the JSON string - for (String requiredField : AttributeBufferHeader.openapiRequiredFields) { - if (jsonObj.get(requiredField) == null) { - throw new IllegalArgumentException(String.format("The required field `%s` is not found in the JSON string: %s", requiredField, jsonObj.toString())); - } - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!AttributeBufferHeader.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'AttributeBufferHeader' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(AttributeBufferHeader.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, AttributeBufferHeader value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public AttributeBufferHeader read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - AttributeBufferHeader instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of AttributeBufferHeader given an JSON string - * - * @param jsonString JSON string - * @return An instance of AttributeBufferHeader - * @throws IOException if the JSON string is invalid with respect to AttributeBufferHeader - */ - public static AttributeBufferHeader fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, AttributeBufferHeader.class); - } - - /** - * Convert an instance of AttributeBufferHeader to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/AttributeBufferSize.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/AttributeBufferSize.java deleted file mode 100644 index 6ca35d2..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/AttributeBufferSize.java +++ /dev/null @@ -1,335 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * object representing buffer size of an attribute - */ -@ApiModel(description = "object representing buffer size of an attribute") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class AttributeBufferSize { - public static final String SERIALIZED_NAME_ATTRIBUTE = "attribute"; - @SerializedName(SERIALIZED_NAME_ATTRIBUTE) - private String attribute; - - public static final String SERIALIZED_NAME_OFFSET_BYTES = "offsetBytes"; - @SerializedName(SERIALIZED_NAME_OFFSET_BYTES) - private Integer offsetBytes; - - public static final String SERIALIZED_NAME_DATA_BYTES = "dataBytes"; - @SerializedName(SERIALIZED_NAME_DATA_BYTES) - private Integer dataBytes; - - public AttributeBufferSize() { - } - - public AttributeBufferSize attribute(String attribute) { - - this.attribute = attribute; - return this; - } - - /** - * name of attribute - * @return attribute - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "name of attribute") - - public String getAttribute() { - return attribute; - } - - - public void setAttribute(String attribute) { - this.attribute = attribute; - } - - - public AttributeBufferSize offsetBytes(Integer offsetBytes) { - - this.offsetBytes = offsetBytes; - return this; - } - - /** - * buffer size (in bytes) of offset buffer - * @return offsetBytes - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "buffer size (in bytes) of offset buffer") - - public Integer getOffsetBytes() { - return offsetBytes; - } - - - public void setOffsetBytes(Integer offsetBytes) { - this.offsetBytes = offsetBytes; - } - - - public AttributeBufferSize dataBytes(Integer dataBytes) { - - this.dataBytes = dataBytes; - return this; - } - - /** - * buffer size (in bytes) of data buffer - * @return dataBytes - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "buffer size (in bytes) of data buffer") - - public Integer getDataBytes() { - return dataBytes; - } - - - public void setDataBytes(Integer dataBytes) { - this.dataBytes = dataBytes; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public AttributeBufferSize putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - AttributeBufferSize attributeBufferSize = (AttributeBufferSize) o; - return Objects.equals(this.attribute, attributeBufferSize.attribute) && - Objects.equals(this.offsetBytes, attributeBufferSize.offsetBytes) && - Objects.equals(this.dataBytes, attributeBufferSize.dataBytes)&& - Objects.equals(this.additionalProperties, attributeBufferSize.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(attribute, offsetBytes, dataBytes, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class AttributeBufferSize {\n"); - sb.append(" attribute: ").append(toIndentedString(attribute)).append("\n"); - sb.append(" offsetBytes: ").append(toIndentedString(offsetBytes)).append("\n"); - sb.append(" dataBytes: ").append(toIndentedString(dataBytes)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("attribute"); - openapiFields.add("offsetBytes"); - openapiFields.add("dataBytes"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - openapiRequiredFields.add("attribute"); - openapiRequiredFields.add("offsetBytes"); - openapiRequiredFields.add("dataBytes"); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to AttributeBufferSize - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (AttributeBufferSize.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in AttributeBufferSize is not found in the empty JSON string", AttributeBufferSize.openapiRequiredFields.toString())); - } - } - - // check to make sure all required properties/fields are present in the JSON string - for (String requiredField : AttributeBufferSize.openapiRequiredFields) { - if (jsonObj.get(requiredField) == null) { - throw new IllegalArgumentException(String.format("The required field `%s` is not found in the JSON string: %s", requiredField, jsonObj.toString())); - } - } - if ((jsonObj.get("attribute") != null && !jsonObj.get("attribute").isJsonNull()) && !jsonObj.get("attribute").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `attribute` to be a primitive type in the JSON string but got `%s`", jsonObj.get("attribute").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!AttributeBufferSize.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'AttributeBufferSize' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(AttributeBufferSize.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, AttributeBufferSize value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public AttributeBufferSize read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - AttributeBufferSize instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of AttributeBufferSize given an JSON string - * - * @param jsonString JSON string - * @return An instance of AttributeBufferSize - * @throws IOException if the JSON string is invalid with respect to AttributeBufferSize - */ - public static AttributeBufferSize fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, AttributeBufferSize.class); - } - - /** - * Convert an instance of AttributeBufferSize to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Backoff.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/Backoff.java deleted file mode 100644 index 392d5f6..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Backoff.java +++ /dev/null @@ -1,328 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Backoff is a backoff strategy to use within retryStrategy - */ -@ApiModel(description = "Backoff is a backoff strategy to use within retryStrategy") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class Backoff { - public static final String SERIALIZED_NAME_DURATION = "duration"; - @SerializedName(SERIALIZED_NAME_DURATION) - private String duration; - - public static final String SERIALIZED_NAME_FACTOR = "factor"; - @SerializedName(SERIALIZED_NAME_FACTOR) - private Integer factor; - - public static final String SERIALIZED_NAME_MAX_DURATION = "maxDuration"; - @SerializedName(SERIALIZED_NAME_MAX_DURATION) - private String maxDuration; - - public Backoff() { - } - - public Backoff duration(String duration) { - - this.duration = duration; - return this; - } - - /** - * Duration is the amount to back off. Default unit is seconds, but could also be a duration (e.g. \"2m\", \"1h\") - * @return duration - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Duration is the amount to back off. Default unit is seconds, but could also be a duration (e.g. \"2m\", \"1h\")") - - public String getDuration() { - return duration; - } - - - public void setDuration(String duration) { - this.duration = duration; - } - - - public Backoff factor(Integer factor) { - - this.factor = factor; - return this; - } - - /** - * Factor is a factor to multiply the base duration after each failed retry - * @return factor - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Factor is a factor to multiply the base duration after each failed retry") - - public Integer getFactor() { - return factor; - } - - - public void setFactor(Integer factor) { - this.factor = factor; - } - - - public Backoff maxDuration(String maxDuration) { - - this.maxDuration = maxDuration; - return this; - } - - /** - * MaxDuration is the maximum amount of time allowed for the backoff strategy - * @return maxDuration - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "MaxDuration is the maximum amount of time allowed for the backoff strategy") - - public String getMaxDuration() { - return maxDuration; - } - - - public void setMaxDuration(String maxDuration) { - this.maxDuration = maxDuration; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public Backoff putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Backoff backoff = (Backoff) o; - return Objects.equals(this.duration, backoff.duration) && - Objects.equals(this.factor, backoff.factor) && - Objects.equals(this.maxDuration, backoff.maxDuration)&& - Objects.equals(this.additionalProperties, backoff.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(duration, factor, maxDuration, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Backoff {\n"); - sb.append(" duration: ").append(toIndentedString(duration)).append("\n"); - sb.append(" factor: ").append(toIndentedString(factor)).append("\n"); - sb.append(" maxDuration: ").append(toIndentedString(maxDuration)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("duration"); - openapiFields.add("factor"); - openapiFields.add("maxDuration"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to Backoff - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (Backoff.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in Backoff is not found in the empty JSON string", Backoff.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("duration") != null && !jsonObj.get("duration").isJsonNull()) && !jsonObj.get("duration").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `duration` to be a primitive type in the JSON string but got `%s`", jsonObj.get("duration").toString())); - } - if ((jsonObj.get("maxDuration") != null && !jsonObj.get("maxDuration").isJsonNull()) && !jsonObj.get("maxDuration").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `maxDuration` to be a primitive type in the JSON string but got `%s`", jsonObj.get("maxDuration").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!Backoff.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'Backoff' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(Backoff.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, Backoff value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public Backoff read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - Backoff instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of Backoff given an JSON string - * - * @param jsonString JSON string - * @return An instance of Backoff - * @throws IOException if the JSON string is invalid with respect to Backoff - */ - public static Backoff fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, Backoff.class); - } - - /** - * Convert an instance of Backoff to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Datatype.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/Datatype.java deleted file mode 100644 index 6bc53e7..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Datatype.java +++ /dev/null @@ -1,147 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * TileDB data type - */ -@JsonAdapter(Datatype.Adapter.class) -public enum Datatype { - - INT32("INT32"), - - INT64("INT64"), - - FLOAT32("FLOAT32"), - - FLOAT64("FLOAT64"), - - CHAR("CHAR"), - - INT8("INT8"), - - UINT8("UINT8"), - - INT16("INT16"), - - UINT16("UINT16"), - - UINT32("UINT32"), - - UINT64("UINT64"), - - STRING_ASCII("STRING_ASCII"), - - STRING_UTF8("STRING_UTF8"), - - STRING_UTF16("STRING_UTF16"), - - STRING_UTF32("STRING_UTF32"), - - STRING_UCS2("STRING_UCS2"), - - STRING_UCS4("STRING_UCS4"), - - DATETIME_YEAR("DATETIME_YEAR"), - - DATETIME_MONTH("DATETIME_MONTH"), - - DATETIME_WEEK("DATETIME_WEEK"), - - DATETIME_DAY("DATETIME_DAY"), - - DATETIME_HR("DATETIME_HR"), - - DATETIME_MIN("DATETIME_MIN"), - - DATETIME_SEC("DATETIME_SEC"), - - DATETIME_MS("DATETIME_MS"), - - DATETIME_US("DATETIME_US"), - - DATETIME_NS("DATETIME_NS"), - - DATETIME_PS("DATETIME_PS"), - - DATETIME_FS("DATETIME_FS"), - - DATETIME_AS("DATETIME_AS"), - - TIME_HR("TIME_HR"), - - TIME_MIN("TIME_MIN"), - - TIME_SEC("TIME_SEC"), - - TIME_MS("TIME_MS"), - - TIME_US("TIME_US"), - - TIME_NS("TIME_NS"), - - TIME_PS("TIME_PS"), - - TIME_FS("TIME_FS"), - - TIME_AS("TIME_AS"), - - BOOL("BOOL"), - - ANY("ANY"); - - private String value; - - Datatype(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static Datatype fromValue(String value) { - for (Datatype b : Datatype.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final Datatype enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public Datatype read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return Datatype.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Dimension.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/Dimension.java deleted file mode 100644 index 3a86432..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Dimension.java +++ /dev/null @@ -1,437 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Dimension of array - */ -@ApiModel(description = "Dimension of array") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class Dimension { - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_TYPE = "type"; - @SerializedName(SERIALIZED_NAME_TYPE) - private Datatype type; - - public static final String SERIALIZED_NAME_DOMAIN = "domain"; - @SerializedName(SERIALIZED_NAME_DOMAIN) - private DomainArray domain; - - public static final String SERIALIZED_NAME_NULL_TILE_EXTENT = "nullTileExtent"; - @SerializedName(SERIALIZED_NAME_NULL_TILE_EXTENT) - private Boolean nullTileExtent; - - public static final String SERIALIZED_NAME_TILE_EXTENT = "tileExtent"; - @SerializedName(SERIALIZED_NAME_TILE_EXTENT) - private DimensionTileExtent tileExtent; - - public static final String SERIALIZED_NAME_FILTER_PIPELINE = "filterPipeline"; - @SerializedName(SERIALIZED_NAME_FILTER_PIPELINE) - private FilterPipeline filterPipeline; - - public Dimension() { - } - - public Dimension name(String name) { - - this.name = name; - return this; - } - - /** - * Dimension name - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "row", value = "Dimension name") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public Dimension type(Datatype type) { - - this.type = type; - return this; - } - - /** - * Get type - * @return type - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public Datatype getType() { - return type; - } - - - public void setType(Datatype type) { - this.type = type; - } - - - public Dimension domain(DomainArray domain) { - - this.domain = domain; - return this; - } - - /** - * Get domain - * @return domain - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public DomainArray getDomain() { - return domain; - } - - - public void setDomain(DomainArray domain) { - this.domain = domain; - } - - - public Dimension nullTileExtent(Boolean nullTileExtent) { - - this.nullTileExtent = nullTileExtent; - return this; - } - - /** - * Is tile extent null - * @return nullTileExtent - **/ - @javax.annotation.Nonnull - @ApiModelProperty(example = "true", required = true, value = "Is tile extent null") - - public Boolean getNullTileExtent() { - return nullTileExtent; - } - - - public void setNullTileExtent(Boolean nullTileExtent) { - this.nullTileExtent = nullTileExtent; - } - - - public Dimension tileExtent(DimensionTileExtent tileExtent) { - - this.tileExtent = tileExtent; - return this; - } - - /** - * Get tileExtent - * @return tileExtent - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public DimensionTileExtent getTileExtent() { - return tileExtent; - } - - - public void setTileExtent(DimensionTileExtent tileExtent) { - this.tileExtent = tileExtent; - } - - - public Dimension filterPipeline(FilterPipeline filterPipeline) { - - this.filterPipeline = filterPipeline; - return this; - } - - /** - * Get filterPipeline - * @return filterPipeline - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public FilterPipeline getFilterPipeline() { - return filterPipeline; - } - - - public void setFilterPipeline(FilterPipeline filterPipeline) { - this.filterPipeline = filterPipeline; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public Dimension putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Dimension dimension = (Dimension) o; - return Objects.equals(this.name, dimension.name) && - Objects.equals(this.type, dimension.type) && - Objects.equals(this.domain, dimension.domain) && - Objects.equals(this.nullTileExtent, dimension.nullTileExtent) && - Objects.equals(this.tileExtent, dimension.tileExtent) && - Objects.equals(this.filterPipeline, dimension.filterPipeline)&& - Objects.equals(this.additionalProperties, dimension.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(name, type, domain, nullTileExtent, tileExtent, filterPipeline, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Dimension {\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" type: ").append(toIndentedString(type)).append("\n"); - sb.append(" domain: ").append(toIndentedString(domain)).append("\n"); - sb.append(" nullTileExtent: ").append(toIndentedString(nullTileExtent)).append("\n"); - sb.append(" tileExtent: ").append(toIndentedString(tileExtent)).append("\n"); - sb.append(" filterPipeline: ").append(toIndentedString(filterPipeline)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("name"); - openapiFields.add("type"); - openapiFields.add("domain"); - openapiFields.add("nullTileExtent"); - openapiFields.add("tileExtent"); - openapiFields.add("filterPipeline"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - openapiRequiredFields.add("type"); - openapiRequiredFields.add("domain"); - openapiRequiredFields.add("nullTileExtent"); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to Dimension - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (Dimension.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in Dimension is not found in the empty JSON string", Dimension.openapiRequiredFields.toString())); - } - } - - // check to make sure all required properties/fields are present in the JSON string - for (String requiredField : Dimension.openapiRequiredFields) { - if (jsonObj.get(requiredField) == null) { - throw new IllegalArgumentException(String.format("The required field `%s` is not found in the JSON string: %s", requiredField, jsonObj.toString())); - } - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - // validate the optional field `domain` - if (jsonObj.get("domain") != null && !jsonObj.get("domain").isJsonNull()) { - DomainArray.validateJsonObject(jsonObj.getAsJsonObject("domain")); - } - // validate the optional field `tileExtent` - if (jsonObj.get("tileExtent") != null && !jsonObj.get("tileExtent").isJsonNull()) { - DimensionTileExtent.validateJsonObject(jsonObj.getAsJsonObject("tileExtent")); - } - // validate the optional field `filterPipeline` - if (jsonObj.get("filterPipeline") != null && !jsonObj.get("filterPipeline").isJsonNull()) { - FilterPipeline.validateJsonObject(jsonObj.getAsJsonObject("filterPipeline")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!Dimension.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'Dimension' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(Dimension.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, Dimension value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public Dimension read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - Dimension instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of Dimension given an JSON string - * - * @param jsonString JSON string - * @return An instance of Dimension - * @throws IOException if the JSON string is invalid with respect to Dimension - */ - public static Dimension fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, Dimension.class); - } - - /** - * Convert an instance of Dimension to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/DimensionCoordinate.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/DimensionCoordinate.java deleted file mode 100644 index c8b7bfc..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/DimensionCoordinate.java +++ /dev/null @@ -1,532 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * A single, typed coordinate for a dimension - */ -@ApiModel(description = "A single, typed coordinate for a dimension") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class DimensionCoordinate { - public static final String SERIALIZED_NAME_INT8 = "int8"; - @SerializedName(SERIALIZED_NAME_INT8) - private Integer int8; - - public static final String SERIALIZED_NAME_UINT8 = "uint8"; - @SerializedName(SERIALIZED_NAME_UINT8) - private Integer uint8; - - public static final String SERIALIZED_NAME_INT16 = "int16"; - @SerializedName(SERIALIZED_NAME_INT16) - private Integer int16; - - public static final String SERIALIZED_NAME_UINT16 = "uint16"; - @SerializedName(SERIALIZED_NAME_UINT16) - private Integer uint16; - - public static final String SERIALIZED_NAME_INT32 = "int32"; - @SerializedName(SERIALIZED_NAME_INT32) - private Integer int32; - - public static final String SERIALIZED_NAME_UINT32 = "uint32"; - @SerializedName(SERIALIZED_NAME_UINT32) - private Integer uint32; - - public static final String SERIALIZED_NAME_INT64 = "int64"; - @SerializedName(SERIALIZED_NAME_INT64) - private Long int64; - - public static final String SERIALIZED_NAME_UINT64 = "uint64"; - @SerializedName(SERIALIZED_NAME_UINT64) - private Integer uint64; - - public static final String SERIALIZED_NAME_FLOAT32 = "float32"; - @SerializedName(SERIALIZED_NAME_FLOAT32) - private Float float32; - - public static final String SERIALIZED_NAME_FLOAT64 = "float64"; - @SerializedName(SERIALIZED_NAME_FLOAT64) - private Double float64; - - public DimensionCoordinate() { - } - - public DimensionCoordinate int8(Integer int8) { - - this.int8 = int8; - return this; - } - - /** - * Get int8 - * @return int8 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getInt8() { - return int8; - } - - - public void setInt8(Integer int8) { - this.int8 = int8; - } - - - public DimensionCoordinate uint8(Integer uint8) { - - this.uint8 = uint8; - return this; - } - - /** - * Get uint8 - * @return uint8 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getUint8() { - return uint8; - } - - - public void setUint8(Integer uint8) { - this.uint8 = uint8; - } - - - public DimensionCoordinate int16(Integer int16) { - - this.int16 = int16; - return this; - } - - /** - * Get int16 - * @return int16 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getInt16() { - return int16; - } - - - public void setInt16(Integer int16) { - this.int16 = int16; - } - - - public DimensionCoordinate uint16(Integer uint16) { - - this.uint16 = uint16; - return this; - } - - /** - * Get uint16 - * @return uint16 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getUint16() { - return uint16; - } - - - public void setUint16(Integer uint16) { - this.uint16 = uint16; - } - - - public DimensionCoordinate int32(Integer int32) { - - this.int32 = int32; - return this; - } - - /** - * Get int32 - * @return int32 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getInt32() { - return int32; - } - - - public void setInt32(Integer int32) { - this.int32 = int32; - } - - - public DimensionCoordinate uint32(Integer uint32) { - - this.uint32 = uint32; - return this; - } - - /** - * Get uint32 - * @return uint32 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getUint32() { - return uint32; - } - - - public void setUint32(Integer uint32) { - this.uint32 = uint32; - } - - - public DimensionCoordinate int64(Long int64) { - - this.int64 = int64; - return this; - } - - /** - * Get int64 - * @return int64 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Long getInt64() { - return int64; - } - - - public void setInt64(Long int64) { - this.int64 = int64; - } - - - public DimensionCoordinate uint64(Integer uint64) { - - this.uint64 = uint64; - return this; - } - - /** - * Get uint64 - * @return uint64 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getUint64() { - return uint64; - } - - - public void setUint64(Integer uint64) { - this.uint64 = uint64; - } - - - public DimensionCoordinate float32(Float float32) { - - this.float32 = float32; - return this; - } - - /** - * Get float32 - * @return float32 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Float getFloat32() { - return float32; - } - - - public void setFloat32(Float float32) { - this.float32 = float32; - } - - - public DimensionCoordinate float64(Double float64) { - - this.float64 = float64; - return this; - } - - /** - * Get float64 - * @return float64 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Double getFloat64() { - return float64; - } - - - public void setFloat64(Double float64) { - this.float64 = float64; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public DimensionCoordinate putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - DimensionCoordinate dimensionCoordinate = (DimensionCoordinate) o; - return Objects.equals(this.int8, dimensionCoordinate.int8) && - Objects.equals(this.uint8, dimensionCoordinate.uint8) && - Objects.equals(this.int16, dimensionCoordinate.int16) && - Objects.equals(this.uint16, dimensionCoordinate.uint16) && - Objects.equals(this.int32, dimensionCoordinate.int32) && - Objects.equals(this.uint32, dimensionCoordinate.uint32) && - Objects.equals(this.int64, dimensionCoordinate.int64) && - Objects.equals(this.uint64, dimensionCoordinate.uint64) && - Objects.equals(this.float32, dimensionCoordinate.float32) && - Objects.equals(this.float64, dimensionCoordinate.float64)&& - Objects.equals(this.additionalProperties, dimensionCoordinate.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(int8, uint8, int16, uint16, int32, uint32, int64, uint64, float32, float64, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class DimensionCoordinate {\n"); - sb.append(" int8: ").append(toIndentedString(int8)).append("\n"); - sb.append(" uint8: ").append(toIndentedString(uint8)).append("\n"); - sb.append(" int16: ").append(toIndentedString(int16)).append("\n"); - sb.append(" uint16: ").append(toIndentedString(uint16)).append("\n"); - sb.append(" int32: ").append(toIndentedString(int32)).append("\n"); - sb.append(" uint32: ").append(toIndentedString(uint32)).append("\n"); - sb.append(" int64: ").append(toIndentedString(int64)).append("\n"); - sb.append(" uint64: ").append(toIndentedString(uint64)).append("\n"); - sb.append(" float32: ").append(toIndentedString(float32)).append("\n"); - sb.append(" float64: ").append(toIndentedString(float64)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("int8"); - openapiFields.add("uint8"); - openapiFields.add("int16"); - openapiFields.add("uint16"); - openapiFields.add("int32"); - openapiFields.add("uint32"); - openapiFields.add("int64"); - openapiFields.add("uint64"); - openapiFields.add("float32"); - openapiFields.add("float64"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to DimensionCoordinate - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (DimensionCoordinate.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in DimensionCoordinate is not found in the empty JSON string", DimensionCoordinate.openapiRequiredFields.toString())); - } - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!DimensionCoordinate.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'DimensionCoordinate' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(DimensionCoordinate.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, DimensionCoordinate value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public DimensionCoordinate read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - DimensionCoordinate instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of DimensionCoordinate given an JSON string - * - * @param jsonString JSON string - * @return An instance of DimensionCoordinate - * @throws IOException if the JSON string is invalid with respect to DimensionCoordinate - */ - public static DimensionCoordinate fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, DimensionCoordinate.class); - } - - /** - * Convert an instance of DimensionCoordinate to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/DimensionTileExtent.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/DimensionTileExtent.java deleted file mode 100644 index 8de1ca6..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/DimensionTileExtent.java +++ /dev/null @@ -1,532 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Extent of tile - */ -@ApiModel(description = "Extent of tile") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class DimensionTileExtent { - public static final String SERIALIZED_NAME_INT8 = "int8"; - @SerializedName(SERIALIZED_NAME_INT8) - private Integer int8; - - public static final String SERIALIZED_NAME_UINT8 = "uint8"; - @SerializedName(SERIALIZED_NAME_UINT8) - private Integer uint8; - - public static final String SERIALIZED_NAME_INT16 = "int16"; - @SerializedName(SERIALIZED_NAME_INT16) - private Integer int16; - - public static final String SERIALIZED_NAME_UINT16 = "uint16"; - @SerializedName(SERIALIZED_NAME_UINT16) - private Integer uint16; - - public static final String SERIALIZED_NAME_INT32 = "int32"; - @SerializedName(SERIALIZED_NAME_INT32) - private Integer int32; - - public static final String SERIALIZED_NAME_UINT32 = "uint32"; - @SerializedName(SERIALIZED_NAME_UINT32) - private Integer uint32; - - public static final String SERIALIZED_NAME_INT64 = "int64"; - @SerializedName(SERIALIZED_NAME_INT64) - private Long int64; - - public static final String SERIALIZED_NAME_UINT64 = "uint64"; - @SerializedName(SERIALIZED_NAME_UINT64) - private Integer uint64; - - public static final String SERIALIZED_NAME_FLOAT32 = "float32"; - @SerializedName(SERIALIZED_NAME_FLOAT32) - private Integer float32; - - public static final String SERIALIZED_NAME_FLOAT64 = "float64"; - @SerializedName(SERIALIZED_NAME_FLOAT64) - private Integer float64; - - public DimensionTileExtent() { - } - - public DimensionTileExtent int8(Integer int8) { - - this.int8 = int8; - return this; - } - - /** - * Get int8 - * @return int8 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getInt8() { - return int8; - } - - - public void setInt8(Integer int8) { - this.int8 = int8; - } - - - public DimensionTileExtent uint8(Integer uint8) { - - this.uint8 = uint8; - return this; - } - - /** - * Get uint8 - * @return uint8 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getUint8() { - return uint8; - } - - - public void setUint8(Integer uint8) { - this.uint8 = uint8; - } - - - public DimensionTileExtent int16(Integer int16) { - - this.int16 = int16; - return this; - } - - /** - * Get int16 - * @return int16 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getInt16() { - return int16; - } - - - public void setInt16(Integer int16) { - this.int16 = int16; - } - - - public DimensionTileExtent uint16(Integer uint16) { - - this.uint16 = uint16; - return this; - } - - /** - * Get uint16 - * @return uint16 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getUint16() { - return uint16; - } - - - public void setUint16(Integer uint16) { - this.uint16 = uint16; - } - - - public DimensionTileExtent int32(Integer int32) { - - this.int32 = int32; - return this; - } - - /** - * Get int32 - * @return int32 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getInt32() { - return int32; - } - - - public void setInt32(Integer int32) { - this.int32 = int32; - } - - - public DimensionTileExtent uint32(Integer uint32) { - - this.uint32 = uint32; - return this; - } - - /** - * Get uint32 - * @return uint32 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getUint32() { - return uint32; - } - - - public void setUint32(Integer uint32) { - this.uint32 = uint32; - } - - - public DimensionTileExtent int64(Long int64) { - - this.int64 = int64; - return this; - } - - /** - * Get int64 - * @return int64 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Long getInt64() { - return int64; - } - - - public void setInt64(Long int64) { - this.int64 = int64; - } - - - public DimensionTileExtent uint64(Integer uint64) { - - this.uint64 = uint64; - return this; - } - - /** - * Get uint64 - * @return uint64 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getUint64() { - return uint64; - } - - - public void setUint64(Integer uint64) { - this.uint64 = uint64; - } - - - public DimensionTileExtent float32(Integer float32) { - - this.float32 = float32; - return this; - } - - /** - * Get float32 - * @return float32 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getFloat32() { - return float32; - } - - - public void setFloat32(Integer float32) { - this.float32 = float32; - } - - - public DimensionTileExtent float64(Integer float64) { - - this.float64 = float64; - return this; - } - - /** - * Get float64 - * @return float64 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getFloat64() { - return float64; - } - - - public void setFloat64(Integer float64) { - this.float64 = float64; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public DimensionTileExtent putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - DimensionTileExtent dimensionTileExtent = (DimensionTileExtent) o; - return Objects.equals(this.int8, dimensionTileExtent.int8) && - Objects.equals(this.uint8, dimensionTileExtent.uint8) && - Objects.equals(this.int16, dimensionTileExtent.int16) && - Objects.equals(this.uint16, dimensionTileExtent.uint16) && - Objects.equals(this.int32, dimensionTileExtent.int32) && - Objects.equals(this.uint32, dimensionTileExtent.uint32) && - Objects.equals(this.int64, dimensionTileExtent.int64) && - Objects.equals(this.uint64, dimensionTileExtent.uint64) && - Objects.equals(this.float32, dimensionTileExtent.float32) && - Objects.equals(this.float64, dimensionTileExtent.float64)&& - Objects.equals(this.additionalProperties, dimensionTileExtent.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(int8, uint8, int16, uint16, int32, uint32, int64, uint64, float32, float64, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class DimensionTileExtent {\n"); - sb.append(" int8: ").append(toIndentedString(int8)).append("\n"); - sb.append(" uint8: ").append(toIndentedString(uint8)).append("\n"); - sb.append(" int16: ").append(toIndentedString(int16)).append("\n"); - sb.append(" uint16: ").append(toIndentedString(uint16)).append("\n"); - sb.append(" int32: ").append(toIndentedString(int32)).append("\n"); - sb.append(" uint32: ").append(toIndentedString(uint32)).append("\n"); - sb.append(" int64: ").append(toIndentedString(int64)).append("\n"); - sb.append(" uint64: ").append(toIndentedString(uint64)).append("\n"); - sb.append(" float32: ").append(toIndentedString(float32)).append("\n"); - sb.append(" float64: ").append(toIndentedString(float64)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("int8"); - openapiFields.add("uint8"); - openapiFields.add("int16"); - openapiFields.add("uint16"); - openapiFields.add("int32"); - openapiFields.add("uint32"); - openapiFields.add("int64"); - openapiFields.add("uint64"); - openapiFields.add("float32"); - openapiFields.add("float64"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to DimensionTileExtent - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (DimensionTileExtent.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in DimensionTileExtent is not found in the empty JSON string", DimensionTileExtent.openapiRequiredFields.toString())); - } - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!DimensionTileExtent.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'DimensionTileExtent' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(DimensionTileExtent.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, DimensionTileExtent value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public DimensionTileExtent read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - DimensionTileExtent instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of DimensionTileExtent given an JSON string - * - * @param jsonString JSON string - * @return An instance of DimensionTileExtent - * @throws IOException if the JSON string is invalid with respect to DimensionTileExtent - */ - public static DimensionTileExtent fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, DimensionTileExtent.class); - } - - /** - * Convert an instance of DimensionTileExtent to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Domain.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/Domain.java deleted file mode 100644 index e58b4f5..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Domain.java +++ /dev/null @@ -1,383 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Domain of array - */ -@ApiModel(description = "Domain of array") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class Domain { - public static final String SERIALIZED_NAME_TYPE = "type"; - @SerializedName(SERIALIZED_NAME_TYPE) - private Datatype type; - - public static final String SERIALIZED_NAME_TILE_ORDER = "tileOrder"; - @SerializedName(SERIALIZED_NAME_TILE_ORDER) - private Layout tileOrder; - - public static final String SERIALIZED_NAME_CELL_ORDER = "cellOrder"; - @SerializedName(SERIALIZED_NAME_CELL_ORDER) - private Layout cellOrder; - - public static final String SERIALIZED_NAME_DIMENSIONS = "dimensions"; - @SerializedName(SERIALIZED_NAME_DIMENSIONS) - private List dimensions = new ArrayList<>(); - - public Domain() { - } - - public Domain type(Datatype type) { - - this.type = type; - return this; - } - - /** - * Get type - * @return type - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public Datatype getType() { - return type; - } - - - public void setType(Datatype type) { - this.type = type; - } - - - public Domain tileOrder(Layout tileOrder) { - - this.tileOrder = tileOrder; - return this; - } - - /** - * Get tileOrder - * @return tileOrder - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public Layout getTileOrder() { - return tileOrder; - } - - - public void setTileOrder(Layout tileOrder) { - this.tileOrder = tileOrder; - } - - - public Domain cellOrder(Layout cellOrder) { - - this.cellOrder = cellOrder; - return this; - } - - /** - * Get cellOrder - * @return cellOrder - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public Layout getCellOrder() { - return cellOrder; - } - - - public void setCellOrder(Layout cellOrder) { - this.cellOrder = cellOrder; - } - - - public Domain dimensions(List dimensions) { - - this.dimensions = dimensions; - return this; - } - - public Domain addDimensionsItem(Dimension dimensionsItem) { - this.dimensions.add(dimensionsItem); - return this; - } - - /** - * Array of dimensions - * @return dimensions - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "Array of dimensions") - - public List getDimensions() { - return dimensions; - } - - - public void setDimensions(List dimensions) { - this.dimensions = dimensions; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public Domain putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Domain domain = (Domain) o; - return Objects.equals(this.type, domain.type) && - Objects.equals(this.tileOrder, domain.tileOrder) && - Objects.equals(this.cellOrder, domain.cellOrder) && - Objects.equals(this.dimensions, domain.dimensions)&& - Objects.equals(this.additionalProperties, domain.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(type, tileOrder, cellOrder, dimensions, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Domain {\n"); - sb.append(" type: ").append(toIndentedString(type)).append("\n"); - sb.append(" tileOrder: ").append(toIndentedString(tileOrder)).append("\n"); - sb.append(" cellOrder: ").append(toIndentedString(cellOrder)).append("\n"); - sb.append(" dimensions: ").append(toIndentedString(dimensions)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("type"); - openapiFields.add("tileOrder"); - openapiFields.add("cellOrder"); - openapiFields.add("dimensions"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - openapiRequiredFields.add("type"); - openapiRequiredFields.add("tileOrder"); - openapiRequiredFields.add("cellOrder"); - openapiRequiredFields.add("dimensions"); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to Domain - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (Domain.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in Domain is not found in the empty JSON string", Domain.openapiRequiredFields.toString())); - } - } - - // check to make sure all required properties/fields are present in the JSON string - for (String requiredField : Domain.openapiRequiredFields) { - if (jsonObj.get(requiredField) == null) { - throw new IllegalArgumentException(String.format("The required field `%s` is not found in the JSON string: %s", requiredField, jsonObj.toString())); - } - } - JsonArray jsonArraydimensions = jsonObj.getAsJsonArray("dimensions"); - if (jsonArraydimensions != null) { - // ensure the json data is an array - if (!jsonObj.get("dimensions").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `dimensions` to be an array in the JSON string but got `%s`", jsonObj.get("dimensions").toString())); - } - - // validate the optional field `dimensions` (array) - for (int i = 0; i < jsonArraydimensions.size(); i++) { - Dimension.validateJsonObject(jsonArraydimensions.get(i).getAsJsonObject()); - }; - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!Domain.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'Domain' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(Domain.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, Domain value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public Domain read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - Domain instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of Domain given an JSON string - * - * @param jsonString JSON string - * @return An instance of Domain - * @throws IOException if the JSON string is invalid with respect to Domain - */ - public static Domain fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, Domain.class); - } - - /** - * Convert an instance of Domain to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/DomainArray.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/DomainArray.java deleted file mode 100644 index d34c557..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/DomainArray.java +++ /dev/null @@ -1,654 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Domain object for an array of each type - */ -@ApiModel(description = "Domain object for an array of each type") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class DomainArray { - public static final String SERIALIZED_NAME_INT8 = "int8"; - @SerializedName(SERIALIZED_NAME_INT8) - private List int8 = null; - - public static final String SERIALIZED_NAME_UINT8 = "uint8"; - @SerializedName(SERIALIZED_NAME_UINT8) - private List uint8 = null; - - public static final String SERIALIZED_NAME_INT16 = "int16"; - @SerializedName(SERIALIZED_NAME_INT16) - private List int16 = null; - - public static final String SERIALIZED_NAME_UINT16 = "uint16"; - @SerializedName(SERIALIZED_NAME_UINT16) - private List uint16 = null; - - public static final String SERIALIZED_NAME_INT32 = "int32"; - @SerializedName(SERIALIZED_NAME_INT32) - private List int32 = null; - - public static final String SERIALIZED_NAME_UINT32 = "uint32"; - @SerializedName(SERIALIZED_NAME_UINT32) - private List uint32 = null; - - public static final String SERIALIZED_NAME_INT64 = "int64"; - @SerializedName(SERIALIZED_NAME_INT64) - private List int64 = null; - - public static final String SERIALIZED_NAME_UINT64 = "uint64"; - @SerializedName(SERIALIZED_NAME_UINT64) - private List uint64 = null; - - public static final String SERIALIZED_NAME_FLOAT32 = "float32"; - @SerializedName(SERIALIZED_NAME_FLOAT32) - private List float32 = null; - - public static final String SERIALIZED_NAME_FLOAT64 = "float64"; - @SerializedName(SERIALIZED_NAME_FLOAT64) - private List float64 = null; - - public DomainArray() { - } - - public DomainArray int8(List int8) { - - this.int8 = int8; - return this; - } - - public DomainArray addInt8Item(Integer int8Item) { - if (this.int8 == null) { - this.int8 = new ArrayList<>(); - } - this.int8.add(int8Item); - return this; - } - - /** - * Get int8 - * @return int8 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List getInt8() { - return int8; - } - - - public void setInt8(List int8) { - this.int8 = int8; - } - - - public DomainArray uint8(List uint8) { - - this.uint8 = uint8; - return this; - } - - public DomainArray addUint8Item(Integer uint8Item) { - if (this.uint8 == null) { - this.uint8 = new ArrayList<>(); - } - this.uint8.add(uint8Item); - return this; - } - - /** - * Get uint8 - * @return uint8 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List getUint8() { - return uint8; - } - - - public void setUint8(List uint8) { - this.uint8 = uint8; - } - - - public DomainArray int16(List int16) { - - this.int16 = int16; - return this; - } - - public DomainArray addInt16Item(Integer int16Item) { - if (this.int16 == null) { - this.int16 = new ArrayList<>(); - } - this.int16.add(int16Item); - return this; - } - - /** - * Get int16 - * @return int16 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List getInt16() { - return int16; - } - - - public void setInt16(List int16) { - this.int16 = int16; - } - - - public DomainArray uint16(List uint16) { - - this.uint16 = uint16; - return this; - } - - public DomainArray addUint16Item(Integer uint16Item) { - if (this.uint16 == null) { - this.uint16 = new ArrayList<>(); - } - this.uint16.add(uint16Item); - return this; - } - - /** - * Get uint16 - * @return uint16 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List getUint16() { - return uint16; - } - - - public void setUint16(List uint16) { - this.uint16 = uint16; - } - - - public DomainArray int32(List int32) { - - this.int32 = int32; - return this; - } - - public DomainArray addInt32Item(Integer int32Item) { - if (this.int32 == null) { - this.int32 = new ArrayList<>(); - } - this.int32.add(int32Item); - return this; - } - - /** - * Get int32 - * @return int32 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List getInt32() { - return int32; - } - - - public void setInt32(List int32) { - this.int32 = int32; - } - - - public DomainArray uint32(List uint32) { - - this.uint32 = uint32; - return this; - } - - public DomainArray addUint32Item(Integer uint32Item) { - if (this.uint32 == null) { - this.uint32 = new ArrayList<>(); - } - this.uint32.add(uint32Item); - return this; - } - - /** - * Get uint32 - * @return uint32 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List getUint32() { - return uint32; - } - - - public void setUint32(List uint32) { - this.uint32 = uint32; - } - - - public DomainArray int64(List int64) { - - this.int64 = int64; - return this; - } - - public DomainArray addInt64Item(Long int64Item) { - if (this.int64 == null) { - this.int64 = new ArrayList<>(); - } - this.int64.add(int64Item); - return this; - } - - /** - * Get int64 - * @return int64 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List getInt64() { - return int64; - } - - - public void setInt64(List int64) { - this.int64 = int64; - } - - - public DomainArray uint64(List uint64) { - - this.uint64 = uint64; - return this; - } - - public DomainArray addUint64Item(Integer uint64Item) { - if (this.uint64 == null) { - this.uint64 = new ArrayList<>(); - } - this.uint64.add(uint64Item); - return this; - } - - /** - * Get uint64 - * @return uint64 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List getUint64() { - return uint64; - } - - - public void setUint64(List uint64) { - this.uint64 = uint64; - } - - - public DomainArray float32(List float32) { - - this.float32 = float32; - return this; - } - - public DomainArray addFloat32Item(Float float32Item) { - if (this.float32 == null) { - this.float32 = new ArrayList<>(); - } - this.float32.add(float32Item); - return this; - } - - /** - * Get float32 - * @return float32 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List getFloat32() { - return float32; - } - - - public void setFloat32(List float32) { - this.float32 = float32; - } - - - public DomainArray float64(List float64) { - - this.float64 = float64; - return this; - } - - public DomainArray addFloat64Item(Double float64Item) { - if (this.float64 == null) { - this.float64 = new ArrayList<>(); - } - this.float64.add(float64Item); - return this; - } - - /** - * Get float64 - * @return float64 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List getFloat64() { - return float64; - } - - - public void setFloat64(List float64) { - this.float64 = float64; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public DomainArray putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - DomainArray domainArray = (DomainArray) o; - return Objects.equals(this.int8, domainArray.int8) && - Objects.equals(this.uint8, domainArray.uint8) && - Objects.equals(this.int16, domainArray.int16) && - Objects.equals(this.uint16, domainArray.uint16) && - Objects.equals(this.int32, domainArray.int32) && - Objects.equals(this.uint32, domainArray.uint32) && - Objects.equals(this.int64, domainArray.int64) && - Objects.equals(this.uint64, domainArray.uint64) && - Objects.equals(this.float32, domainArray.float32) && - Objects.equals(this.float64, domainArray.float64)&& - Objects.equals(this.additionalProperties, domainArray.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(int8, uint8, int16, uint16, int32, uint32, int64, uint64, float32, float64, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class DomainArray {\n"); - sb.append(" int8: ").append(toIndentedString(int8)).append("\n"); - sb.append(" uint8: ").append(toIndentedString(uint8)).append("\n"); - sb.append(" int16: ").append(toIndentedString(int16)).append("\n"); - sb.append(" uint16: ").append(toIndentedString(uint16)).append("\n"); - sb.append(" int32: ").append(toIndentedString(int32)).append("\n"); - sb.append(" uint32: ").append(toIndentedString(uint32)).append("\n"); - sb.append(" int64: ").append(toIndentedString(int64)).append("\n"); - sb.append(" uint64: ").append(toIndentedString(uint64)).append("\n"); - sb.append(" float32: ").append(toIndentedString(float32)).append("\n"); - sb.append(" float64: ").append(toIndentedString(float64)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("int8"); - openapiFields.add("uint8"); - openapiFields.add("int16"); - openapiFields.add("uint16"); - openapiFields.add("int32"); - openapiFields.add("uint32"); - openapiFields.add("int64"); - openapiFields.add("uint64"); - openapiFields.add("float32"); - openapiFields.add("float64"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to DomainArray - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (DomainArray.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in DomainArray is not found in the empty JSON string", DomainArray.openapiRequiredFields.toString())); - } - } - // ensure the json data is an array - if ((jsonObj.get("int8") != null && !jsonObj.get("int8").isJsonNull()) && !jsonObj.get("int8").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `int8` to be an array in the JSON string but got `%s`", jsonObj.get("int8").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("uint8") != null && !jsonObj.get("uint8").isJsonNull()) && !jsonObj.get("uint8").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `uint8` to be an array in the JSON string but got `%s`", jsonObj.get("uint8").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("int16") != null && !jsonObj.get("int16").isJsonNull()) && !jsonObj.get("int16").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `int16` to be an array in the JSON string but got `%s`", jsonObj.get("int16").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("uint16") != null && !jsonObj.get("uint16").isJsonNull()) && !jsonObj.get("uint16").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `uint16` to be an array in the JSON string but got `%s`", jsonObj.get("uint16").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("int32") != null && !jsonObj.get("int32").isJsonNull()) && !jsonObj.get("int32").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `int32` to be an array in the JSON string but got `%s`", jsonObj.get("int32").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("uint32") != null && !jsonObj.get("uint32").isJsonNull()) && !jsonObj.get("uint32").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `uint32` to be an array in the JSON string but got `%s`", jsonObj.get("uint32").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("int64") != null && !jsonObj.get("int64").isJsonNull()) && !jsonObj.get("int64").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `int64` to be an array in the JSON string but got `%s`", jsonObj.get("int64").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("uint64") != null && !jsonObj.get("uint64").isJsonNull()) && !jsonObj.get("uint64").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `uint64` to be an array in the JSON string but got `%s`", jsonObj.get("uint64").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("float32") != null && !jsonObj.get("float32").isJsonNull()) && !jsonObj.get("float32").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `float32` to be an array in the JSON string but got `%s`", jsonObj.get("float32").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("float64") != null && !jsonObj.get("float64").isJsonNull()) && !jsonObj.get("float64").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `float64` to be an array in the JSON string but got `%s`", jsonObj.get("float64").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!DomainArray.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'DomainArray' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(DomainArray.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, DomainArray value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public DomainArray read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - DomainArray instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of DomainArray given an JSON string - * - * @param jsonString JSON string - * @return An instance of DomainArray - * @throws IOException if the JSON string is invalid with respect to DomainArray - */ - public static DomainArray fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, DomainArray.class); - } - - /** - * Convert an instance of DomainArray to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/DomainCheckResult.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/DomainCheckResult.java deleted file mode 100644 index cafcc92..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/DomainCheckResult.java +++ /dev/null @@ -1,293 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.time.OffsetDateTime; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * The record of a check of a single domain's status. - */ -@ApiModel(description = "The record of a check of a single domain's status.") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class DomainCheckResult { - public static final String SERIALIZED_NAME_TIME = "time"; - @SerializedName(SERIALIZED_NAME_TIME) - private OffsetDateTime time; - - public static final String SERIALIZED_NAME_STATUS = "status"; - @SerializedName(SERIALIZED_NAME_STATUS) - private DomainCheckStatus status; - - public DomainCheckResult() { - } - - public DomainCheckResult time(OffsetDateTime time) { - - this.time = time; - return this; - } - - /** - * The timestamp when the check was performed. - * @return time - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The timestamp when the check was performed.") - - public OffsetDateTime getTime() { - return time; - } - - - public void setTime(OffsetDateTime time) { - this.time = time; - } - - - public DomainCheckResult status(DomainCheckStatus status) { - - this.status = status; - return this; - } - - /** - * Get status - * @return status - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public DomainCheckStatus getStatus() { - return status; - } - - - public void setStatus(DomainCheckStatus status) { - this.status = status; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public DomainCheckResult putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - DomainCheckResult domainCheckResult = (DomainCheckResult) o; - return Objects.equals(this.time, domainCheckResult.time) && - Objects.equals(this.status, domainCheckResult.status)&& - Objects.equals(this.additionalProperties, domainCheckResult.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(time, status, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class DomainCheckResult {\n"); - sb.append(" time: ").append(toIndentedString(time)).append("\n"); - sb.append(" status: ").append(toIndentedString(status)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("time"); - openapiFields.add("status"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to DomainCheckResult - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (DomainCheckResult.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in DomainCheckResult is not found in the empty JSON string", DomainCheckResult.openapiRequiredFields.toString())); - } - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!DomainCheckResult.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'DomainCheckResult' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(DomainCheckResult.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, DomainCheckResult value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public DomainCheckResult read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - DomainCheckResult instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of DomainCheckResult given an JSON string - * - * @param jsonString JSON string - * @return An instance of DomainCheckResult - * @throws IOException if the JSON string is invalid with respect to DomainCheckResult - */ - public static DomainCheckResult fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, DomainCheckResult.class); - } - - /** - * Convert an instance of DomainCheckResult to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/DomainCheckStatus.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/DomainCheckStatus.java deleted file mode 100644 index 685c052..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/DomainCheckStatus.java +++ /dev/null @@ -1,71 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * The status of a single check on a domain's status. - */ -@JsonAdapter(DomainCheckStatus.Adapter.class) -public enum DomainCheckStatus { - - VERIFIED("verified"), - - FAILED("failed"), - - ERROR("error"); - - private String value; - - DomainCheckStatus(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static DomainCheckStatus fromValue(String value) { - for (DomainCheckStatus b : DomainCheckStatus.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final DomainCheckStatus enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public DomainCheckStatus read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return DomainCheckStatus.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/DomainVerificationStatus.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/DomainVerificationStatus.java deleted file mode 100644 index c2c0e8c..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/DomainVerificationStatus.java +++ /dev/null @@ -1,73 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * The current status of the claim on the domain. - */ -@JsonAdapter(DomainVerificationStatus.Adapter.class) -public enum DomainVerificationStatus { - - UNVERIFIED("unverified"), - - VERIFIED("verified"), - - GRACE_PERIOD("grace_period"), - - FAILED("failed"); - - private String value; - - DomainVerificationStatus(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static DomainVerificationStatus fromValue(String value) { - for (DomainVerificationStatus b : DomainVerificationStatus.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final DomainVerificationStatus enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public DomainVerificationStatus read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return DomainVerificationStatus.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Error.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/Error.java deleted file mode 100644 index 7998fdf..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Error.java +++ /dev/null @@ -1,326 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Error - */ -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class Error { - public static final String SERIALIZED_NAME_CODE = "code"; - @SerializedName(SERIALIZED_NAME_CODE) - private Long code; - - public static final String SERIALIZED_NAME_MESSAGE = "message"; - @SerializedName(SERIALIZED_NAME_MESSAGE) - private String message; - - public static final String SERIALIZED_NAME_REQUEST_ID = "request_id"; - @SerializedName(SERIALIZED_NAME_REQUEST_ID) - private String requestId; - - public Error() { - } - - public Error code(Long code) { - - this.code = code; - return this; - } - - /** - * Get code - * @return code - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Long getCode() { - return code; - } - - - public void setCode(Long code) { - this.code = code; - } - - - public Error message(String message) { - - this.message = message; - return this; - } - - /** - * Get message - * @return message - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public String getMessage() { - return message; - } - - - public void setMessage(String message) { - this.message = message; - } - - - public Error requestId(String requestId) { - - this.requestId = requestId; - return this; - } - - /** - * Get requestId - * @return requestId - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public String getRequestId() { - return requestId; - } - - - public void setRequestId(String requestId) { - this.requestId = requestId; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public Error putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Error error = (Error) o; - return Objects.equals(this.code, error.code) && - Objects.equals(this.message, error.message) && - Objects.equals(this.requestId, error.requestId)&& - Objects.equals(this.additionalProperties, error.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(code, message, requestId, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Error {\n"); - sb.append(" code: ").append(toIndentedString(code)).append("\n"); - sb.append(" message: ").append(toIndentedString(message)).append("\n"); - sb.append(" requestId: ").append(toIndentedString(requestId)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("code"); - openapiFields.add("message"); - openapiFields.add("request_id"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to Error - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (Error.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in Error is not found in the empty JSON string", Error.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("message") != null && !jsonObj.get("message").isJsonNull()) && !jsonObj.get("message").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `message` to be a primitive type in the JSON string but got `%s`", jsonObj.get("message").toString())); - } - if ((jsonObj.get("request_id") != null && !jsonObj.get("request_id").isJsonNull()) && !jsonObj.get("request_id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `request_id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("request_id").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!Error.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'Error' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(Error.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, Error value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public Error read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - Error instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of Error given an JSON string - * - * @param jsonString JSON string - * @return An instance of Error - * @throws IOException if the JSON string is invalid with respect to Error - */ - public static Error fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, Error.class); - } - - /** - * Convert an instance of Error to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FileCreate.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/FileCreate.java deleted file mode 100644 index 53dab94..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FileCreate.java +++ /dev/null @@ -1,331 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Input/Output information required to create a new file - */ -@ApiModel(description = "Input/Output information required to create a new file") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class FileCreate { - public static final String SERIALIZED_NAME_INPUT_URI = "input_uri"; - @SerializedName(SERIALIZED_NAME_INPUT_URI) - private String inputUri; - - public static final String SERIALIZED_NAME_OUTPUT_URI = "output_uri"; - @SerializedName(SERIALIZED_NAME_OUTPUT_URI) - private String outputUri; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public FileCreate() { - } - - public FileCreate inputUri(String inputUri) { - - this.inputUri = inputUri; - return this; - } - - /** - * storage URI of the input file - * @return inputUri - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "storage URI of the input file") - - public String getInputUri() { - return inputUri; - } - - - public void setInputUri(String inputUri) { - this.inputUri = inputUri; - } - - - public FileCreate outputUri(String outputUri) { - - this.outputUri = outputUri; - return this; - } - - /** - * output location of the TileDB File - * @return outputUri - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "output location of the TileDB File") - - public String getOutputUri() { - return outputUri; - } - - - public void setOutputUri(String outputUri) { - this.outputUri = outputUri; - } - - - public FileCreate name(String name) { - - this.name = name; - return this; - } - - /** - * name to set for registered file - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "name to set for registered file") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public FileCreate putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - FileCreate fileCreate = (FileCreate) o; - return Objects.equals(this.inputUri, fileCreate.inputUri) && - Objects.equals(this.outputUri, fileCreate.outputUri) && - Objects.equals(this.name, fileCreate.name)&& - Objects.equals(this.additionalProperties, fileCreate.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(inputUri, outputUri, name, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class FileCreate {\n"); - sb.append(" inputUri: ").append(toIndentedString(inputUri)).append("\n"); - sb.append(" outputUri: ").append(toIndentedString(outputUri)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("input_uri"); - openapiFields.add("output_uri"); - openapiFields.add("name"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to FileCreate - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (FileCreate.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in FileCreate is not found in the empty JSON string", FileCreate.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("input_uri") != null && !jsonObj.get("input_uri").isJsonNull()) && !jsonObj.get("input_uri").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `input_uri` to be a primitive type in the JSON string but got `%s`", jsonObj.get("input_uri").toString())); - } - if ((jsonObj.get("output_uri") != null && !jsonObj.get("output_uri").isJsonNull()) && !jsonObj.get("output_uri").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `output_uri` to be a primitive type in the JSON string but got `%s`", jsonObj.get("output_uri").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!FileCreate.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'FileCreate' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(FileCreate.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, FileCreate value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public FileCreate read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - FileCreate instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of FileCreate given an JSON string - * - * @param jsonString JSON string - * @return An instance of FileCreate - * @throws IOException if the JSON string is invalid with respect to FileCreate - */ - public static FileCreate fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, FileCreate.class); - } - - /** - * Convert an instance of FileCreate to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FileCreated.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/FileCreated.java deleted file mode 100644 index 2f2e63d..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FileCreated.java +++ /dev/null @@ -1,298 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Created file name and information - */ -@ApiModel(description = "Created file name and information") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class FileCreated { - public static final String SERIALIZED_NAME_OUTPUT_URI = "output_uri"; - @SerializedName(SERIALIZED_NAME_OUTPUT_URI) - private String outputUri; - - public static final String SERIALIZED_NAME_FILE_NAME = "file_name"; - @SerializedName(SERIALIZED_NAME_FILE_NAME) - private String fileName; - - public FileCreated() { - } - - public FileCreated outputUri(String outputUri) { - - this.outputUri = outputUri; - return this; - } - - /** - * output location of the TileDB File - * @return outputUri - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "output location of the TileDB File") - - public String getOutputUri() { - return outputUri; - } - - - public void setOutputUri(String outputUri) { - this.outputUri = outputUri; - } - - - public FileCreated fileName(String fileName) { - - this.fileName = fileName; - return this; - } - - /** - * name of the file created - * @return fileName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "name of the file created") - - public String getFileName() { - return fileName; - } - - - public void setFileName(String fileName) { - this.fileName = fileName; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public FileCreated putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - FileCreated fileCreated = (FileCreated) o; - return Objects.equals(this.outputUri, fileCreated.outputUri) && - Objects.equals(this.fileName, fileCreated.fileName)&& - Objects.equals(this.additionalProperties, fileCreated.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(outputUri, fileName, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class FileCreated {\n"); - sb.append(" outputUri: ").append(toIndentedString(outputUri)).append("\n"); - sb.append(" fileName: ").append(toIndentedString(fileName)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("output_uri"); - openapiFields.add("file_name"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to FileCreated - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (FileCreated.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in FileCreated is not found in the empty JSON string", FileCreated.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("output_uri") != null && !jsonObj.get("output_uri").isJsonNull()) && !jsonObj.get("output_uri").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `output_uri` to be a primitive type in the JSON string but got `%s`", jsonObj.get("output_uri").toString())); - } - if ((jsonObj.get("file_name") != null && !jsonObj.get("file_name").isJsonNull()) && !jsonObj.get("file_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `file_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("file_name").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!FileCreated.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'FileCreated' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(FileCreated.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, FileCreated value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public FileCreated read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - FileCreated instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of FileCreated given an JSON string - * - * @param jsonString JSON string - * @return An instance of FileCreated - * @throws IOException if the JSON string is invalid with respect to FileCreated - */ - public static FileCreated fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, FileCreated.class); - } - - /** - * Convert an instance of FileCreated to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FileExport.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/FileExport.java deleted file mode 100644 index f9d39f4..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FileExport.java +++ /dev/null @@ -1,265 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Output information required to export a file - */ -@ApiModel(description = "Output information required to export a file") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class FileExport { - public static final String SERIALIZED_NAME_OUTPUT_URI = "output_uri"; - @SerializedName(SERIALIZED_NAME_OUTPUT_URI) - private String outputUri; - - public FileExport() { - } - - public FileExport outputUri(String outputUri) { - - this.outputUri = outputUri; - return this; - } - - /** - * output location of the TileDB File - * @return outputUri - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "output location of the TileDB File") - - public String getOutputUri() { - return outputUri; - } - - - public void setOutputUri(String outputUri) { - this.outputUri = outputUri; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public FileExport putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - FileExport fileExport = (FileExport) o; - return Objects.equals(this.outputUri, fileExport.outputUri)&& - Objects.equals(this.additionalProperties, fileExport.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(outputUri, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class FileExport {\n"); - sb.append(" outputUri: ").append(toIndentedString(outputUri)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("output_uri"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to FileExport - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (FileExport.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in FileExport is not found in the empty JSON string", FileExport.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("output_uri") != null && !jsonObj.get("output_uri").isJsonNull()) && !jsonObj.get("output_uri").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `output_uri` to be a primitive type in the JSON string but got `%s`", jsonObj.get("output_uri").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!FileExport.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'FileExport' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(FileExport.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, FileExport value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public FileExport read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - FileExport instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of FileExport given an JSON string - * - * @param jsonString JSON string - * @return An instance of FileExport - * @throws IOException if the JSON string is invalid with respect to FileExport - */ - public static FileExport fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, FileExport.class); - } - - /** - * Convert an instance of FileExport to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FileExported.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/FileExported.java deleted file mode 100644 index 27c7c63..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FileExported.java +++ /dev/null @@ -1,265 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Output uri of the exported file - */ -@ApiModel(description = "Output uri of the exported file") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class FileExported { - public static final String SERIALIZED_NAME_OUTPUT_URI = "output_uri"; - @SerializedName(SERIALIZED_NAME_OUTPUT_URI) - private String outputUri; - - public FileExported() { - } - - public FileExported outputUri(String outputUri) { - - this.outputUri = outputUri; - return this; - } - - /** - * output location of the exported file - * @return outputUri - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "output location of the exported file") - - public String getOutputUri() { - return outputUri; - } - - - public void setOutputUri(String outputUri) { - this.outputUri = outputUri; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public FileExported putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - FileExported fileExported = (FileExported) o; - return Objects.equals(this.outputUri, fileExported.outputUri)&& - Objects.equals(this.additionalProperties, fileExported.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(outputUri, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class FileExported {\n"); - sb.append(" outputUri: ").append(toIndentedString(outputUri)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("output_uri"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to FileExported - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (FileExported.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in FileExported is not found in the empty JSON string", FileExported.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("output_uri") != null && !jsonObj.get("output_uri").isJsonNull()) && !jsonObj.get("output_uri").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `output_uri` to be a primitive type in the JSON string but got `%s`", jsonObj.get("output_uri").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!FileExported.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'FileExported' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(FileExported.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, FileExported value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public FileExported read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - FileExported instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of FileExported given an JSON string - * - * @param jsonString JSON string - * @return An instance of FileExported - * @throws IOException if the JSON string is invalid with respect to FileExported - */ - public static FileExported fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, FileExported.class); - } - - /** - * Convert an instance of FileExported to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FilePropertyName.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/FilePropertyName.java deleted file mode 100644 index 8526de7..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FilePropertyName.java +++ /dev/null @@ -1,79 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * File property assigned to a specific file (array) - */ -@JsonAdapter(FilePropertyName.Adapter.class) -public enum FilePropertyName { - - IMAGE("image"), - - SIZE("size"), - - CODE_BLOCK("code_block"), - - UDF_LANGUAGE("udf_language"), - - IS_DASHBOARD("is_dashboard"), - - VERSION_PRUNING_LIMIT("version_pruning_limit"), - - VERSION_PRUNING_ENABLED("version_pruning_enabled"); - - private String value; - - FilePropertyName(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static FilePropertyName fromValue(String value) { - for (FilePropertyName b : FilePropertyName.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final FilePropertyName enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public FilePropertyName read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return FilePropertyName.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FileType.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/FileType.java deleted file mode 100644 index 1929e97..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FileType.java +++ /dev/null @@ -1,75 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * File types represented as TileDB arrays - */ -@JsonAdapter(FileType.Adapter.class) -public enum FileType { - - NOTEBOOK("notebook"), - - USER_DEFINED_FUNCTION("user_defined_function"), - - ML_MODEL("ml_model"), - - FILE("file"), - - REGISTERED_TASK_GRAPH("registered_task_graph"); - - private String value; - - FileType(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static FileType fromValue(String value) { - for (FileType b : FileType.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final FileType enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public FileType read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return FileType.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FileUploaded.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/FileUploaded.java deleted file mode 100644 index f4968fb..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FileUploaded.java +++ /dev/null @@ -1,339 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Uploaded file name and information - */ -@ApiModel(description = "Uploaded file name and information") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class FileUploaded { - public static final String SERIALIZED_NAME_OUTPUT_URI = "output_uri"; - @SerializedName(SERIALIZED_NAME_OUTPUT_URI) - private String outputUri; - - public static final String SERIALIZED_NAME_FILE_NAME = "file_name"; - @SerializedName(SERIALIZED_NAME_FILE_NAME) - private String fileName; - - public static final String SERIALIZED_NAME_ID = "id"; - @SerializedName(SERIALIZED_NAME_ID) - private String id; - - public FileUploaded() { - } - - public FileUploaded outputUri(String outputUri) { - - this.outputUri = outputUri; - return this; - } - - /** - * output location of the TileDB File - * @return outputUri - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "output location of the TileDB File") - - public String getOutputUri() { - return outputUri; - } - - - public void setOutputUri(String outputUri) { - this.outputUri = outputUri; - } - - - public FileUploaded fileName(String fileName) { - - this.fileName = fileName; - return this; - } - - /** - * name of the file uploaded - * @return fileName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "name of the file uploaded") - - public String getFileName() { - return fileName; - } - - - public void setFileName(String fileName) { - this.fileName = fileName; - } - - - public FileUploaded id(String id) { - - this.id = id; - return this; - } - - /** - * unique ID of the uploaded file - * @return id - **/ - @javax.annotation.Nonnull - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", required = true, value = "unique ID of the uploaded file") - - public String getId() { - return id; - } - - - public void setId(String id) { - this.id = id; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public FileUploaded putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - FileUploaded fileUploaded = (FileUploaded) o; - return Objects.equals(this.outputUri, fileUploaded.outputUri) && - Objects.equals(this.fileName, fileUploaded.fileName) && - Objects.equals(this.id, fileUploaded.id)&& - Objects.equals(this.additionalProperties, fileUploaded.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(outputUri, fileName, id, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class FileUploaded {\n"); - sb.append(" outputUri: ").append(toIndentedString(outputUri)).append("\n"); - sb.append(" fileName: ").append(toIndentedString(fileName)).append("\n"); - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("output_uri"); - openapiFields.add("file_name"); - openapiFields.add("id"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - openapiRequiredFields.add("id"); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to FileUploaded - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (FileUploaded.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in FileUploaded is not found in the empty JSON string", FileUploaded.openapiRequiredFields.toString())); - } - } - - // check to make sure all required properties/fields are present in the JSON string - for (String requiredField : FileUploaded.openapiRequiredFields) { - if (jsonObj.get(requiredField) == null) { - throw new IllegalArgumentException(String.format("The required field `%s` is not found in the JSON string: %s", requiredField, jsonObj.toString())); - } - } - if ((jsonObj.get("output_uri") != null && !jsonObj.get("output_uri").isJsonNull()) && !jsonObj.get("output_uri").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `output_uri` to be a primitive type in the JSON string but got `%s`", jsonObj.get("output_uri").toString())); - } - if ((jsonObj.get("file_name") != null && !jsonObj.get("file_name").isJsonNull()) && !jsonObj.get("file_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `file_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("file_name").toString())); - } - if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) && !jsonObj.get("id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("id").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!FileUploaded.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'FileUploaded' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(FileUploaded.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, FileUploaded value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public FileUploaded read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - FileUploaded instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of FileUploaded given an JSON string - * - * @param jsonString JSON string - * @return An instance of FileUploaded - * @throws IOException if the JSON string is invalid with respect to FileUploaded - */ - public static FileUploaded fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, FileUploaded.class); - } - - /** - * Convert an instance of FileUploaded to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Filter.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/Filter.java deleted file mode 100644 index 72b409f..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Filter.java +++ /dev/null @@ -1,304 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Filter - */ -@ApiModel(description = "Filter") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class Filter { - public static final String SERIALIZED_NAME_TYPE = "type"; - @SerializedName(SERIALIZED_NAME_TYPE) - private FilterType type; - - public static final String SERIALIZED_NAME_DATA = "data"; - @SerializedName(SERIALIZED_NAME_DATA) - private FilterData data; - - public Filter() { - } - - public Filter type(FilterType type) { - - this.type = type; - return this; - } - - /** - * Get type - * @return type - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public FilterType getType() { - return type; - } - - - public void setType(FilterType type) { - this.type = type; - } - - - public Filter data(FilterData data) { - - this.data = data; - return this; - } - - /** - * Get data - * @return data - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public FilterData getData() { - return data; - } - - - public void setData(FilterData data) { - this.data = data; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public Filter putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Filter filter = (Filter) o; - return Objects.equals(this.type, filter.type) && - Objects.equals(this.data, filter.data)&& - Objects.equals(this.additionalProperties, filter.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(type, data, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Filter {\n"); - sb.append(" type: ").append(toIndentedString(type)).append("\n"); - sb.append(" data: ").append(toIndentedString(data)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("type"); - openapiFields.add("data"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - openapiRequiredFields.add("type"); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to Filter - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (Filter.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in Filter is not found in the empty JSON string", Filter.openapiRequiredFields.toString())); - } - } - - // check to make sure all required properties/fields are present in the JSON string - for (String requiredField : Filter.openapiRequiredFields) { - if (jsonObj.get(requiredField) == null) { - throw new IllegalArgumentException(String.format("The required field `%s` is not found in the JSON string: %s", requiredField, jsonObj.toString())); - } - } - // validate the optional field `data` - if (jsonObj.get("data") != null && !jsonObj.get("data").isJsonNull()) { - FilterData.validateJsonObject(jsonObj.getAsJsonObject("data")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!Filter.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'Filter' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(Filter.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, Filter value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public Filter read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - Filter instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of Filter given an JSON string - * - * @param jsonString JSON string - * @return An instance of Filter - * @throws IOException if the JSON string is invalid with respect to Filter - */ - public static Filter fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, Filter.class); - } - - /** - * Convert an instance of Filter to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FilterData.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/FilterData.java deleted file mode 100644 index fe07914..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FilterData.java +++ /dev/null @@ -1,532 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Filter data - */ -@ApiModel(description = "Filter data") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class FilterData { - public static final String SERIALIZED_NAME_INT8 = "int8"; - @SerializedName(SERIALIZED_NAME_INT8) - private Integer int8; - - public static final String SERIALIZED_NAME_UINT8 = "uint8"; - @SerializedName(SERIALIZED_NAME_UINT8) - private Integer uint8; - - public static final String SERIALIZED_NAME_INT16 = "int16"; - @SerializedName(SERIALIZED_NAME_INT16) - private Integer int16; - - public static final String SERIALIZED_NAME_UINT16 = "uint16"; - @SerializedName(SERIALIZED_NAME_UINT16) - private Integer uint16; - - public static final String SERIALIZED_NAME_INT32 = "int32"; - @SerializedName(SERIALIZED_NAME_INT32) - private Integer int32; - - public static final String SERIALIZED_NAME_UINT32 = "uint32"; - @SerializedName(SERIALIZED_NAME_UINT32) - private Integer uint32; - - public static final String SERIALIZED_NAME_INT64 = "int64"; - @SerializedName(SERIALIZED_NAME_INT64) - private Long int64; - - public static final String SERIALIZED_NAME_UINT64 = "uint64"; - @SerializedName(SERIALIZED_NAME_UINT64) - private Integer uint64; - - public static final String SERIALIZED_NAME_FLOAT32 = "float32"; - @SerializedName(SERIALIZED_NAME_FLOAT32) - private Integer float32; - - public static final String SERIALIZED_NAME_FLOAT64 = "float64"; - @SerializedName(SERIALIZED_NAME_FLOAT64) - private Integer float64; - - public FilterData() { - } - - public FilterData int8(Integer int8) { - - this.int8 = int8; - return this; - } - - /** - * Get int8 - * @return int8 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getInt8() { - return int8; - } - - - public void setInt8(Integer int8) { - this.int8 = int8; - } - - - public FilterData uint8(Integer uint8) { - - this.uint8 = uint8; - return this; - } - - /** - * Get uint8 - * @return uint8 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getUint8() { - return uint8; - } - - - public void setUint8(Integer uint8) { - this.uint8 = uint8; - } - - - public FilterData int16(Integer int16) { - - this.int16 = int16; - return this; - } - - /** - * Get int16 - * @return int16 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getInt16() { - return int16; - } - - - public void setInt16(Integer int16) { - this.int16 = int16; - } - - - public FilterData uint16(Integer uint16) { - - this.uint16 = uint16; - return this; - } - - /** - * Get uint16 - * @return uint16 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getUint16() { - return uint16; - } - - - public void setUint16(Integer uint16) { - this.uint16 = uint16; - } - - - public FilterData int32(Integer int32) { - - this.int32 = int32; - return this; - } - - /** - * Get int32 - * @return int32 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getInt32() { - return int32; - } - - - public void setInt32(Integer int32) { - this.int32 = int32; - } - - - public FilterData uint32(Integer uint32) { - - this.uint32 = uint32; - return this; - } - - /** - * Get uint32 - * @return uint32 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getUint32() { - return uint32; - } - - - public void setUint32(Integer uint32) { - this.uint32 = uint32; - } - - - public FilterData int64(Long int64) { - - this.int64 = int64; - return this; - } - - /** - * Get int64 - * @return int64 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Long getInt64() { - return int64; - } - - - public void setInt64(Long int64) { - this.int64 = int64; - } - - - public FilterData uint64(Integer uint64) { - - this.uint64 = uint64; - return this; - } - - /** - * Get uint64 - * @return uint64 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getUint64() { - return uint64; - } - - - public void setUint64(Integer uint64) { - this.uint64 = uint64; - } - - - public FilterData float32(Integer float32) { - - this.float32 = float32; - return this; - } - - /** - * Get float32 - * @return float32 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getFloat32() { - return float32; - } - - - public void setFloat32(Integer float32) { - this.float32 = float32; - } - - - public FilterData float64(Integer float64) { - - this.float64 = float64; - return this; - } - - /** - * Get float64 - * @return float64 - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getFloat64() { - return float64; - } - - - public void setFloat64(Integer float64) { - this.float64 = float64; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public FilterData putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - FilterData filterData = (FilterData) o; - return Objects.equals(this.int8, filterData.int8) && - Objects.equals(this.uint8, filterData.uint8) && - Objects.equals(this.int16, filterData.int16) && - Objects.equals(this.uint16, filterData.uint16) && - Objects.equals(this.int32, filterData.int32) && - Objects.equals(this.uint32, filterData.uint32) && - Objects.equals(this.int64, filterData.int64) && - Objects.equals(this.uint64, filterData.uint64) && - Objects.equals(this.float32, filterData.float32) && - Objects.equals(this.float64, filterData.float64)&& - Objects.equals(this.additionalProperties, filterData.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(int8, uint8, int16, uint16, int32, uint32, int64, uint64, float32, float64, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class FilterData {\n"); - sb.append(" int8: ").append(toIndentedString(int8)).append("\n"); - sb.append(" uint8: ").append(toIndentedString(uint8)).append("\n"); - sb.append(" int16: ").append(toIndentedString(int16)).append("\n"); - sb.append(" uint16: ").append(toIndentedString(uint16)).append("\n"); - sb.append(" int32: ").append(toIndentedString(int32)).append("\n"); - sb.append(" uint32: ").append(toIndentedString(uint32)).append("\n"); - sb.append(" int64: ").append(toIndentedString(int64)).append("\n"); - sb.append(" uint64: ").append(toIndentedString(uint64)).append("\n"); - sb.append(" float32: ").append(toIndentedString(float32)).append("\n"); - sb.append(" float64: ").append(toIndentedString(float64)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("int8"); - openapiFields.add("uint8"); - openapiFields.add("int16"); - openapiFields.add("uint16"); - openapiFields.add("int32"); - openapiFields.add("uint32"); - openapiFields.add("int64"); - openapiFields.add("uint64"); - openapiFields.add("float32"); - openapiFields.add("float64"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to FilterData - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (FilterData.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in FilterData is not found in the empty JSON string", FilterData.openapiRequiredFields.toString())); - } - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!FilterData.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'FilterData' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(FilterData.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, FilterData value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public FilterData read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - FilterData instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of FilterData given an JSON string - * - * @param jsonString JSON string - * @return An instance of FilterData - * @throws IOException if the JSON string is invalid with respect to FilterData - */ - public static FilterData fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, FilterData.class); - } - - /** - * Convert an instance of FilterData to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FilterOption.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/FilterOption.java deleted file mode 100644 index 178cdcb..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FilterOption.java +++ /dev/null @@ -1,71 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * TileDB filter option - */ -@JsonAdapter(FilterOption.Adapter.class) -public enum FilterOption { - - COMPRESSION_LEVEL("COMPRESSION_LEVEL"), - - BIT_WIDTH_MAX_WINDOW("BIT_WIDTH_MAX_WINDOW"), - - POSITIVE_DELTA_MAX_WINDOW("POSITIVE_DELTA_MAX_WINDOW"); - - private String value; - - FilterOption(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static FilterOption fromValue(String value) { - for (FilterOption b : FilterOption.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final FilterOption enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public FilterOption read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return FilterOption.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FilterPipeline.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/FilterPipeline.java deleted file mode 100644 index bece38f..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FilterPipeline.java +++ /dev/null @@ -1,285 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * One or more filters to apply - */ -@ApiModel(description = "One or more filters to apply") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class FilterPipeline { - public static final String SERIALIZED_NAME_FILTERS = "filters"; - @SerializedName(SERIALIZED_NAME_FILTERS) - private List filters = null; - - public FilterPipeline() { - } - - public FilterPipeline filters(List filters) { - - this.filters = filters; - return this; - } - - public FilterPipeline addFiltersItem(Filter filtersItem) { - if (this.filters == null) { - this.filters = new ArrayList<>(); - } - this.filters.add(filtersItem); - return this; - } - - /** - * Get filters - * @return filters - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List getFilters() { - return filters; - } - - - public void setFilters(List filters) { - this.filters = filters; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public FilterPipeline putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - FilterPipeline filterPipeline = (FilterPipeline) o; - return Objects.equals(this.filters, filterPipeline.filters)&& - Objects.equals(this.additionalProperties, filterPipeline.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(filters, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class FilterPipeline {\n"); - sb.append(" filters: ").append(toIndentedString(filters)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("filters"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to FilterPipeline - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (FilterPipeline.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in FilterPipeline is not found in the empty JSON string", FilterPipeline.openapiRequiredFields.toString())); - } - } - JsonArray jsonArrayfilters = jsonObj.getAsJsonArray("filters"); - if (jsonArrayfilters != null) { - // ensure the json data is an array - if (!jsonObj.get("filters").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `filters` to be an array in the JSON string but got `%s`", jsonObj.get("filters").toString())); - } - - // validate the optional field `filters` (array) - for (int i = 0; i < jsonArrayfilters.size(); i++) { - Filter.validateJsonObject(jsonArrayfilters.get(i).getAsJsonObject()); - }; - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!FilterPipeline.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'FilterPipeline' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(FilterPipeline.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, FilterPipeline value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public FilterPipeline read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - FilterPipeline instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of FilterPipeline given an JSON string - * - * @param jsonString JSON string - * @return An instance of FilterPipeline - * @throws IOException if the JSON string is invalid with respect to FilterPipeline - */ - public static FilterPipeline fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, FilterPipeline.class); - } - - /** - * Convert an instance of FilterPipeline to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FilterType.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/FilterType.java deleted file mode 100644 index bd67de4..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FilterType.java +++ /dev/null @@ -1,87 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * TileDB filter types - */ -@JsonAdapter(FilterType.Adapter.class) -public enum FilterType { - - NONE("NONE"), - - GZIP("GZIP"), - - ZSTD("ZSTD"), - - LZ4("LZ4"), - - RLE("RLE"), - - BZIP2("BZIP2"), - - DOUBLE_DELTA("DOUBLE_DELTA"), - - BIT_WIDTH_REDUCTION("BIT_WIDTH_REDUCTION"), - - BITSHUFFLE("BITSHUFFLE"), - - BYTESHUFFLE("BYTESHUFFLE"), - - POSITIVE_DELTA("POSITIVE_DELTA"); - - private String value; - - FilterType(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static FilterType fromValue(String value) { - for (FilterType b : FilterType.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final FilterType enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public FilterType read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return FilterType.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FragmentInfo.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/FragmentInfo.java deleted file mode 100644 index 0c0272b..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FragmentInfo.java +++ /dev/null @@ -1,365 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashSet; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Fragment info of an array - */ -@ApiModel(description = "Fragment info of an array") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class FragmentInfo { - public static final String SERIALIZED_NAME_ARRAY_SCHEMA_ALL = "arraySchemaAll"; - @SerializedName(SERIALIZED_NAME_ARRAY_SCHEMA_ALL) - private Map arraySchemaAll = null; - - public static final String SERIALIZED_NAME_FRAGMENT_INFO = "fragmentInfo"; - @SerializedName(SERIALIZED_NAME_FRAGMENT_INFO) - private List fragmentInfo = null; - - public static final String SERIALIZED_NAME_TO_VACUUM = "toVacuum"; - @SerializedName(SERIALIZED_NAME_TO_VACUUM) - private List toVacuum = null; - - public FragmentInfo() { - } - - public FragmentInfo arraySchemaAll(Map arraySchemaAll) { - - this.arraySchemaAll = arraySchemaAll; - return this; - } - - public FragmentInfo putArraySchemaAllItem(String key, ArraySchema arraySchemaAllItem) { - if (this.arraySchemaAll == null) { - this.arraySchemaAll = new HashMap<>(); - } - this.arraySchemaAll.put(key, arraySchemaAllItem); - return this; - } - - /** - * map of all array schemas - * @return arraySchemaAll - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "map of all array schemas") - - public Map getArraySchemaAll() { - return arraySchemaAll; - } - - - public void setArraySchemaAll(Map arraySchemaAll) { - this.arraySchemaAll = arraySchemaAll; - } - - - public FragmentInfo fragmentInfo(List fragmentInfo) { - - this.fragmentInfo = fragmentInfo; - return this; - } - - public FragmentInfo addFragmentInfoItem(SingleFragmentInfo fragmentInfoItem) { - if (this.fragmentInfo == null) { - this.fragmentInfo = new ArrayList<>(); - } - this.fragmentInfo.add(fragmentInfoItem); - return this; - } - - /** - * information about fragments in the array - * @return fragmentInfo - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "information about fragments in the array") - - public List getFragmentInfo() { - return fragmentInfo; - } - - - public void setFragmentInfo(List fragmentInfo) { - this.fragmentInfo = fragmentInfo; - } - - - public FragmentInfo toVacuum(List toVacuum) { - - this.toVacuum = toVacuum; - return this; - } - - public FragmentInfo addToVacuumItem(String toVacuumItem) { - if (this.toVacuum == null) { - this.toVacuum = new ArrayList<>(); - } - this.toVacuum.add(toVacuumItem); - return this; - } - - /** - * the URIs of the fragments to vacuum - * @return toVacuum - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "the URIs of the fragments to vacuum") - - public List getToVacuum() { - return toVacuum; - } - - - public void setToVacuum(List toVacuum) { - this.toVacuum = toVacuum; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public FragmentInfo putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - FragmentInfo fragmentInfo = (FragmentInfo) o; - return Objects.equals(this.arraySchemaAll, fragmentInfo.arraySchemaAll) && - Objects.equals(this.fragmentInfo, fragmentInfo.fragmentInfo) && - Objects.equals(this.toVacuum, fragmentInfo.toVacuum)&& - Objects.equals(this.additionalProperties, fragmentInfo.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(arraySchemaAll, fragmentInfo, toVacuum, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class FragmentInfo {\n"); - sb.append(" arraySchemaAll: ").append(toIndentedString(arraySchemaAll)).append("\n"); - sb.append(" fragmentInfo: ").append(toIndentedString(fragmentInfo)).append("\n"); - sb.append(" toVacuum: ").append(toIndentedString(toVacuum)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("arraySchemaAll"); - openapiFields.add("fragmentInfo"); - openapiFields.add("toVacuum"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to FragmentInfo - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (FragmentInfo.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in FragmentInfo is not found in the empty JSON string", FragmentInfo.openapiRequiredFields.toString())); - } - } - JsonArray jsonArrayfragmentInfo = jsonObj.getAsJsonArray("fragmentInfo"); - if (jsonArrayfragmentInfo != null) { - // ensure the json data is an array - if (!jsonObj.get("fragmentInfo").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `fragmentInfo` to be an array in the JSON string but got `%s`", jsonObj.get("fragmentInfo").toString())); - } - - // validate the optional field `fragmentInfo` (array) - for (int i = 0; i < jsonArrayfragmentInfo.size(); i++) { - SingleFragmentInfo.validateJsonObject(jsonArrayfragmentInfo.get(i).getAsJsonObject()); - }; - } - // ensure the json data is an array - if ((jsonObj.get("toVacuum") != null && !jsonObj.get("toVacuum").isJsonNull()) && !jsonObj.get("toVacuum").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `toVacuum` to be an array in the JSON string but got `%s`", jsonObj.get("toVacuum").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!FragmentInfo.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'FragmentInfo' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(FragmentInfo.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, FragmentInfo value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public FragmentInfo read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - FragmentInfo instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of FragmentInfo given an JSON string - * - * @param jsonString JSON string - * @return An instance of FragmentInfo - * @throws IOException if the JSON string is invalid with respect to FragmentInfo - */ - public static FragmentInfo fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, FragmentInfo.class); - } - - /** - * Convert an instance of FragmentInfo to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FragmentInfoRequest.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/FragmentInfoRequest.java deleted file mode 100644 index 2eb0f67..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FragmentInfoRequest.java +++ /dev/null @@ -1,266 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Fragment info request - */ -@ApiModel(description = "Fragment info request") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class FragmentInfoRequest { - public static final String SERIALIZED_NAME_CONFIG = "config"; - @SerializedName(SERIALIZED_NAME_CONFIG) - private TileDBConfig config; - - public FragmentInfoRequest() { - } - - public FragmentInfoRequest config(TileDBConfig config) { - - this.config = config; - return this; - } - - /** - * Get config - * @return config - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public TileDBConfig getConfig() { - return config; - } - - - public void setConfig(TileDBConfig config) { - this.config = config; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public FragmentInfoRequest putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - FragmentInfoRequest fragmentInfoRequest = (FragmentInfoRequest) o; - return Objects.equals(this.config, fragmentInfoRequest.config)&& - Objects.equals(this.additionalProperties, fragmentInfoRequest.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(config, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class FragmentInfoRequest {\n"); - sb.append(" config: ").append(toIndentedString(config)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("config"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to FragmentInfoRequest - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (FragmentInfoRequest.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in FragmentInfoRequest is not found in the empty JSON string", FragmentInfoRequest.openapiRequiredFields.toString())); - } - } - // validate the optional field `config` - if (jsonObj.get("config") != null && !jsonObj.get("config").isJsonNull()) { - TileDBConfig.validateJsonObject(jsonObj.getAsJsonObject("config")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!FragmentInfoRequest.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'FragmentInfoRequest' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(FragmentInfoRequest.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, FragmentInfoRequest value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public FragmentInfoRequest read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - FragmentInfoRequest instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of FragmentInfoRequest given an JSON string - * - * @param jsonString JSON string - * @return An instance of FragmentInfoRequest - * @throws IOException if the JSON string is invalid with respect to FragmentInfoRequest - */ - public static FragmentInfoRequest fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, FragmentInfoRequest.class); - } - - /** - * Convert an instance of FragmentInfoRequest to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FragmentMetadata.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/FragmentMetadata.java deleted file mode 100644 index 21ebb00..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/FragmentMetadata.java +++ /dev/null @@ -1,1203 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Fragment Metadata - */ -@ApiModel(description = "Fragment Metadata") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class FragmentMetadata { - public static final String SERIALIZED_NAME_FILE_SIZES = "fileSizes"; - @SerializedName(SERIALIZED_NAME_FILE_SIZES) - private List fileSizes = null; - - public static final String SERIALIZED_NAME_FILE_VAR_SIZES = "fileVarSizes"; - @SerializedName(SERIALIZED_NAME_FILE_VAR_SIZES) - private List fileVarSizes = null; - - public static final String SERIALIZED_NAME_FILE_VALIDITY_SIZES = "fileValiditySizes"; - @SerializedName(SERIALIZED_NAME_FILE_VALIDITY_SIZES) - private List fileValiditySizes = null; - - public static final String SERIALIZED_NAME_FRAGMENT_URI = "fragmentUri"; - @SerializedName(SERIALIZED_NAME_FRAGMENT_URI) - private String fragmentUri; - - public static final String SERIALIZED_NAME_HAS_TIMESTAMPS = "hasTimestamps"; - @SerializedName(SERIALIZED_NAME_HAS_TIMESTAMPS) - private Boolean hasTimestamps; - - public static final String SERIALIZED_NAME_HAS_DELETE_META = "hasDeleteMeta"; - @SerializedName(SERIALIZED_NAME_HAS_DELETE_META) - private Boolean hasDeleteMeta; - - public static final String SERIALIZED_NAME_SPARSE_TILE_NUM = "sparseTileNum"; - @SerializedName(SERIALIZED_NAME_SPARSE_TILE_NUM) - private Integer sparseTileNum; - - public static final String SERIALIZED_NAME_TILE_INDEX_BASE = "tileIndexBase"; - @SerializedName(SERIALIZED_NAME_TILE_INDEX_BASE) - private Integer tileIndexBase; - - public static final String SERIALIZED_NAME_TILE_OFFSETS = "tileOffsets"; - @SerializedName(SERIALIZED_NAME_TILE_OFFSETS) - private List> tileOffsets = null; - - public static final String SERIALIZED_NAME_TILE_VAR_OFFSETS = "tileVarOffsets"; - @SerializedName(SERIALIZED_NAME_TILE_VAR_OFFSETS) - private List> tileVarOffsets = null; - - public static final String SERIALIZED_NAME_TILE_VAR_SIZES = "tileVarSizes"; - @SerializedName(SERIALIZED_NAME_TILE_VAR_SIZES) - private List> tileVarSizes = null; - - public static final String SERIALIZED_NAME_TILE_VALIDITY_OFFSETS = "tileValidityOffsets"; - @SerializedName(SERIALIZED_NAME_TILE_VALIDITY_OFFSETS) - private List> tileValidityOffsets = null; - - public static final String SERIALIZED_NAME_TILE_MIN_BUFFER = "tileMinBuffer"; - @SerializedName(SERIALIZED_NAME_TILE_MIN_BUFFER) - private List> tileMinBuffer = null; - - public static final String SERIALIZED_NAME_TILE_MIN_VAR_BUFFER = "tileMinVarBuffer"; - @SerializedName(SERIALIZED_NAME_TILE_MIN_VAR_BUFFER) - private List> tileMinVarBuffer = null; - - public static final String SERIALIZED_NAME_TILE_MAX_BUFFER = "tileMaxBuffer"; - @SerializedName(SERIALIZED_NAME_TILE_MAX_BUFFER) - private List> tileMaxBuffer = null; - - public static final String SERIALIZED_NAME_TILE_MAX_VAR_BUFFER = "tileMaxVarBuffer"; - @SerializedName(SERIALIZED_NAME_TILE_MAX_VAR_BUFFER) - private List> tileMaxVarBuffer = null; - - public static final String SERIALIZED_NAME_TILE_SUMS = "tileSums"; - @SerializedName(SERIALIZED_NAME_TILE_SUMS) - private List> tileSums = null; - - public static final String SERIALIZED_NAME_TILE_NULL_COUNTS = "tileNullCounts"; - @SerializedName(SERIALIZED_NAME_TILE_NULL_COUNTS) - private List> tileNullCounts = null; - - public static final String SERIALIZED_NAME_FRAGMENT_MINS = "fragmentMins"; - @SerializedName(SERIALIZED_NAME_FRAGMENT_MINS) - private List> fragmentMins = null; - - public static final String SERIALIZED_NAME_FRAGMENT_MAXS = "fragmentMaxs"; - @SerializedName(SERIALIZED_NAME_FRAGMENT_MAXS) - private List> fragmentMaxs = null; - - public static final String SERIALIZED_NAME_FRAGMENT_SUMS = "fragmentSums"; - @SerializedName(SERIALIZED_NAME_FRAGMENT_SUMS) - private List fragmentSums = null; - - public static final String SERIALIZED_NAME_FRAGMENT_NULL_COUNTS = "fragmentNullCounts"; - @SerializedName(SERIALIZED_NAME_FRAGMENT_NULL_COUNTS) - private List fragmentNullCounts = null; - - public static final String SERIALIZED_NAME_VERSION = "version"; - @SerializedName(SERIALIZED_NAME_VERSION) - private Integer version; - - public static final String SERIALIZED_NAME_TIMESTAMP_RANGE = "timestampRange"; - @SerializedName(SERIALIZED_NAME_TIMESTAMP_RANGE) - private List timestampRange = null; - - public static final String SERIALIZED_NAME_LAST_TILE_CELL_NUM = "lastTileCellNum"; - @SerializedName(SERIALIZED_NAME_LAST_TILE_CELL_NUM) - private Integer lastTileCellNum; - - public FragmentMetadata() { - } - - public FragmentMetadata fileSizes(List fileSizes) { - - this.fileSizes = fileSizes; - return this; - } - - public FragmentMetadata addFileSizesItem(Integer fileSizesItem) { - if (this.fileSizes == null) { - this.fileSizes = new ArrayList<>(); - } - this.fileSizes.add(fileSizesItem); - return this; - } - - /** - * fixed sizes - * @return fileSizes - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "fixed sizes") - - public List getFileSizes() { - return fileSizes; - } - - - public void setFileSizes(List fileSizes) { - this.fileSizes = fileSizes; - } - - - public FragmentMetadata fileVarSizes(List fileVarSizes) { - - this.fileVarSizes = fileVarSizes; - return this; - } - - public FragmentMetadata addFileVarSizesItem(Integer fileVarSizesItem) { - if (this.fileVarSizes == null) { - this.fileVarSizes = new ArrayList<>(); - } - this.fileVarSizes.add(fileVarSizesItem); - return this; - } - - /** - * var length sizes - * @return fileVarSizes - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "var length sizes") - - public List getFileVarSizes() { - return fileVarSizes; - } - - - public void setFileVarSizes(List fileVarSizes) { - this.fileVarSizes = fileVarSizes; - } - - - public FragmentMetadata fileValiditySizes(List fileValiditySizes) { - - this.fileValiditySizes = fileValiditySizes; - return this; - } - - public FragmentMetadata addFileValiditySizesItem(Integer fileValiditySizesItem) { - if (this.fileValiditySizes == null) { - this.fileValiditySizes = new ArrayList<>(); - } - this.fileValiditySizes.add(fileValiditySizesItem); - return this; - } - - /** - * validity sizes - * @return fileValiditySizes - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "validity sizes") - - public List getFileValiditySizes() { - return fileValiditySizes; - } - - - public void setFileValiditySizes(List fileValiditySizes) { - this.fileValiditySizes = fileValiditySizes; - } - - - public FragmentMetadata fragmentUri(String fragmentUri) { - - this.fragmentUri = fragmentUri; - return this; - } - - /** - * Get fragmentUri - * @return fragmentUri - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public String getFragmentUri() { - return fragmentUri; - } - - - public void setFragmentUri(String fragmentUri) { - this.fragmentUri = fragmentUri; - } - - - public FragmentMetadata hasTimestamps(Boolean hasTimestamps) { - - this.hasTimestamps = hasTimestamps; - return this; - } - - /** - * Get hasTimestamps - * @return hasTimestamps - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Boolean getHasTimestamps() { - return hasTimestamps; - } - - - public void setHasTimestamps(Boolean hasTimestamps) { - this.hasTimestamps = hasTimestamps; - } - - - public FragmentMetadata hasDeleteMeta(Boolean hasDeleteMeta) { - - this.hasDeleteMeta = hasDeleteMeta; - return this; - } - - /** - * Get hasDeleteMeta - * @return hasDeleteMeta - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Boolean getHasDeleteMeta() { - return hasDeleteMeta; - } - - - public void setHasDeleteMeta(Boolean hasDeleteMeta) { - this.hasDeleteMeta = hasDeleteMeta; - } - - - public FragmentMetadata sparseTileNum(Integer sparseTileNum) { - - this.sparseTileNum = sparseTileNum; - return this; - } - - /** - * Get sparseTileNum - * @return sparseTileNum - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getSparseTileNum() { - return sparseTileNum; - } - - - public void setSparseTileNum(Integer sparseTileNum) { - this.sparseTileNum = sparseTileNum; - } - - - public FragmentMetadata tileIndexBase(Integer tileIndexBase) { - - this.tileIndexBase = tileIndexBase; - return this; - } - - /** - * Get tileIndexBase - * @return tileIndexBase - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getTileIndexBase() { - return tileIndexBase; - } - - - public void setTileIndexBase(Integer tileIndexBase) { - this.tileIndexBase = tileIndexBase; - } - - - public FragmentMetadata tileOffsets(List> tileOffsets) { - - this.tileOffsets = tileOffsets; - return this; - } - - public FragmentMetadata addTileOffsetsItem(List tileOffsetsItem) { - if (this.tileOffsets == null) { - this.tileOffsets = new ArrayList<>(); - } - this.tileOffsets.add(tileOffsetsItem); - return this; - } - - /** - * Get tileOffsets - * @return tileOffsets - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List> getTileOffsets() { - return tileOffsets; - } - - - public void setTileOffsets(List> tileOffsets) { - this.tileOffsets = tileOffsets; - } - - - public FragmentMetadata tileVarOffsets(List> tileVarOffsets) { - - this.tileVarOffsets = tileVarOffsets; - return this; - } - - public FragmentMetadata addTileVarOffsetsItem(List tileVarOffsetsItem) { - if (this.tileVarOffsets == null) { - this.tileVarOffsets = new ArrayList<>(); - } - this.tileVarOffsets.add(tileVarOffsetsItem); - return this; - } - - /** - * Get tileVarOffsets - * @return tileVarOffsets - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List> getTileVarOffsets() { - return tileVarOffsets; - } - - - public void setTileVarOffsets(List> tileVarOffsets) { - this.tileVarOffsets = tileVarOffsets; - } - - - public FragmentMetadata tileVarSizes(List> tileVarSizes) { - - this.tileVarSizes = tileVarSizes; - return this; - } - - public FragmentMetadata addTileVarSizesItem(List tileVarSizesItem) { - if (this.tileVarSizes == null) { - this.tileVarSizes = new ArrayList<>(); - } - this.tileVarSizes.add(tileVarSizesItem); - return this; - } - - /** - * Get tileVarSizes - * @return tileVarSizes - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List> getTileVarSizes() { - return tileVarSizes; - } - - - public void setTileVarSizes(List> tileVarSizes) { - this.tileVarSizes = tileVarSizes; - } - - - public FragmentMetadata tileValidityOffsets(List> tileValidityOffsets) { - - this.tileValidityOffsets = tileValidityOffsets; - return this; - } - - public FragmentMetadata addTileValidityOffsetsItem(List tileValidityOffsetsItem) { - if (this.tileValidityOffsets == null) { - this.tileValidityOffsets = new ArrayList<>(); - } - this.tileValidityOffsets.add(tileValidityOffsetsItem); - return this; - } - - /** - * Get tileValidityOffsets - * @return tileValidityOffsets - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List> getTileValidityOffsets() { - return tileValidityOffsets; - } - - - public void setTileValidityOffsets(List> tileValidityOffsets) { - this.tileValidityOffsets = tileValidityOffsets; - } - - - public FragmentMetadata tileMinBuffer(List> tileMinBuffer) { - - this.tileMinBuffer = tileMinBuffer; - return this; - } - - public FragmentMetadata addTileMinBufferItem(List tileMinBufferItem) { - if (this.tileMinBuffer == null) { - this.tileMinBuffer = new ArrayList<>(); - } - this.tileMinBuffer.add(tileMinBufferItem); - return this; - } - - /** - * Get tileMinBuffer - * @return tileMinBuffer - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List> getTileMinBuffer() { - return tileMinBuffer; - } - - - public void setTileMinBuffer(List> tileMinBuffer) { - this.tileMinBuffer = tileMinBuffer; - } - - - public FragmentMetadata tileMinVarBuffer(List> tileMinVarBuffer) { - - this.tileMinVarBuffer = tileMinVarBuffer; - return this; - } - - public FragmentMetadata addTileMinVarBufferItem(List tileMinVarBufferItem) { - if (this.tileMinVarBuffer == null) { - this.tileMinVarBuffer = new ArrayList<>(); - } - this.tileMinVarBuffer.add(tileMinVarBufferItem); - return this; - } - - /** - * Get tileMinVarBuffer - * @return tileMinVarBuffer - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List> getTileMinVarBuffer() { - return tileMinVarBuffer; - } - - - public void setTileMinVarBuffer(List> tileMinVarBuffer) { - this.tileMinVarBuffer = tileMinVarBuffer; - } - - - public FragmentMetadata tileMaxBuffer(List> tileMaxBuffer) { - - this.tileMaxBuffer = tileMaxBuffer; - return this; - } - - public FragmentMetadata addTileMaxBufferItem(List tileMaxBufferItem) { - if (this.tileMaxBuffer == null) { - this.tileMaxBuffer = new ArrayList<>(); - } - this.tileMaxBuffer.add(tileMaxBufferItem); - return this; - } - - /** - * Get tileMaxBuffer - * @return tileMaxBuffer - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List> getTileMaxBuffer() { - return tileMaxBuffer; - } - - - public void setTileMaxBuffer(List> tileMaxBuffer) { - this.tileMaxBuffer = tileMaxBuffer; - } - - - public FragmentMetadata tileMaxVarBuffer(List> tileMaxVarBuffer) { - - this.tileMaxVarBuffer = tileMaxVarBuffer; - return this; - } - - public FragmentMetadata addTileMaxVarBufferItem(List tileMaxVarBufferItem) { - if (this.tileMaxVarBuffer == null) { - this.tileMaxVarBuffer = new ArrayList<>(); - } - this.tileMaxVarBuffer.add(tileMaxVarBufferItem); - return this; - } - - /** - * Get tileMaxVarBuffer - * @return tileMaxVarBuffer - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List> getTileMaxVarBuffer() { - return tileMaxVarBuffer; - } - - - public void setTileMaxVarBuffer(List> tileMaxVarBuffer) { - this.tileMaxVarBuffer = tileMaxVarBuffer; - } - - - public FragmentMetadata tileSums(List> tileSums) { - - this.tileSums = tileSums; - return this; - } - - public FragmentMetadata addTileSumsItem(List tileSumsItem) { - if (this.tileSums == null) { - this.tileSums = new ArrayList<>(); - } - this.tileSums.add(tileSumsItem); - return this; - } - - /** - * Get tileSums - * @return tileSums - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List> getTileSums() { - return tileSums; - } - - - public void setTileSums(List> tileSums) { - this.tileSums = tileSums; - } - - - public FragmentMetadata tileNullCounts(List> tileNullCounts) { - - this.tileNullCounts = tileNullCounts; - return this; - } - - public FragmentMetadata addTileNullCountsItem(List tileNullCountsItem) { - if (this.tileNullCounts == null) { - this.tileNullCounts = new ArrayList<>(); - } - this.tileNullCounts.add(tileNullCountsItem); - return this; - } - - /** - * Get tileNullCounts - * @return tileNullCounts - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List> getTileNullCounts() { - return tileNullCounts; - } - - - public void setTileNullCounts(List> tileNullCounts) { - this.tileNullCounts = tileNullCounts; - } - - - public FragmentMetadata fragmentMins(List> fragmentMins) { - - this.fragmentMins = fragmentMins; - return this; - } - - public FragmentMetadata addFragmentMinsItem(List fragmentMinsItem) { - if (this.fragmentMins == null) { - this.fragmentMins = new ArrayList<>(); - } - this.fragmentMins.add(fragmentMinsItem); - return this; - } - - /** - * Get fragmentMins - * @return fragmentMins - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List> getFragmentMins() { - return fragmentMins; - } - - - public void setFragmentMins(List> fragmentMins) { - this.fragmentMins = fragmentMins; - } - - - public FragmentMetadata fragmentMaxs(List> fragmentMaxs) { - - this.fragmentMaxs = fragmentMaxs; - return this; - } - - public FragmentMetadata addFragmentMaxsItem(List fragmentMaxsItem) { - if (this.fragmentMaxs == null) { - this.fragmentMaxs = new ArrayList<>(); - } - this.fragmentMaxs.add(fragmentMaxsItem); - return this; - } - - /** - * Get fragmentMaxs - * @return fragmentMaxs - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List> getFragmentMaxs() { - return fragmentMaxs; - } - - - public void setFragmentMaxs(List> fragmentMaxs) { - this.fragmentMaxs = fragmentMaxs; - } - - - public FragmentMetadata fragmentSums(List fragmentSums) { - - this.fragmentSums = fragmentSums; - return this; - } - - public FragmentMetadata addFragmentSumsItem(Integer fragmentSumsItem) { - if (this.fragmentSums == null) { - this.fragmentSums = new ArrayList<>(); - } - this.fragmentSums.add(fragmentSumsItem); - return this; - } - - /** - * Get fragmentSums - * @return fragmentSums - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List getFragmentSums() { - return fragmentSums; - } - - - public void setFragmentSums(List fragmentSums) { - this.fragmentSums = fragmentSums; - } - - - public FragmentMetadata fragmentNullCounts(List fragmentNullCounts) { - - this.fragmentNullCounts = fragmentNullCounts; - return this; - } - - public FragmentMetadata addFragmentNullCountsItem(Integer fragmentNullCountsItem) { - if (this.fragmentNullCounts == null) { - this.fragmentNullCounts = new ArrayList<>(); - } - this.fragmentNullCounts.add(fragmentNullCountsItem); - return this; - } - - /** - * Get fragmentNullCounts - * @return fragmentNullCounts - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List getFragmentNullCounts() { - return fragmentNullCounts; - } - - - public void setFragmentNullCounts(List fragmentNullCounts) { - this.fragmentNullCounts = fragmentNullCounts; - } - - - public FragmentMetadata version(Integer version) { - - this.version = version; - return this; - } - - /** - * Get version - * @return version - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getVersion() { - return version; - } - - - public void setVersion(Integer version) { - this.version = version; - } - - - public FragmentMetadata timestampRange(List timestampRange) { - - this.timestampRange = timestampRange; - return this; - } - - public FragmentMetadata addTimestampRangeItem(Integer timestampRangeItem) { - if (this.timestampRange == null) { - this.timestampRange = new ArrayList<>(); - } - this.timestampRange.add(timestampRangeItem); - return this; - } - - /** - * Get timestampRange - * @return timestampRange - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List getTimestampRange() { - return timestampRange; - } - - - public void setTimestampRange(List timestampRange) { - this.timestampRange = timestampRange; - } - - - public FragmentMetadata lastTileCellNum(Integer lastTileCellNum) { - - this.lastTileCellNum = lastTileCellNum; - return this; - } - - /** - * Get lastTileCellNum - * @return lastTileCellNum - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Integer getLastTileCellNum() { - return lastTileCellNum; - } - - - public void setLastTileCellNum(Integer lastTileCellNum) { - this.lastTileCellNum = lastTileCellNum; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public FragmentMetadata putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - FragmentMetadata fragmentMetadata = (FragmentMetadata) o; - return Objects.equals(this.fileSizes, fragmentMetadata.fileSizes) && - Objects.equals(this.fileVarSizes, fragmentMetadata.fileVarSizes) && - Objects.equals(this.fileValiditySizes, fragmentMetadata.fileValiditySizes) && - Objects.equals(this.fragmentUri, fragmentMetadata.fragmentUri) && - Objects.equals(this.hasTimestamps, fragmentMetadata.hasTimestamps) && - Objects.equals(this.hasDeleteMeta, fragmentMetadata.hasDeleteMeta) && - Objects.equals(this.sparseTileNum, fragmentMetadata.sparseTileNum) && - Objects.equals(this.tileIndexBase, fragmentMetadata.tileIndexBase) && - Objects.equals(this.tileOffsets, fragmentMetadata.tileOffsets) && - Objects.equals(this.tileVarOffsets, fragmentMetadata.tileVarOffsets) && - Objects.equals(this.tileVarSizes, fragmentMetadata.tileVarSizes) && - Objects.equals(this.tileValidityOffsets, fragmentMetadata.tileValidityOffsets) && - Objects.equals(this.tileMinBuffer, fragmentMetadata.tileMinBuffer) && - Objects.equals(this.tileMinVarBuffer, fragmentMetadata.tileMinVarBuffer) && - Objects.equals(this.tileMaxBuffer, fragmentMetadata.tileMaxBuffer) && - Objects.equals(this.tileMaxVarBuffer, fragmentMetadata.tileMaxVarBuffer) && - Objects.equals(this.tileSums, fragmentMetadata.tileSums) && - Objects.equals(this.tileNullCounts, fragmentMetadata.tileNullCounts) && - Objects.equals(this.fragmentMins, fragmentMetadata.fragmentMins) && - Objects.equals(this.fragmentMaxs, fragmentMetadata.fragmentMaxs) && - Objects.equals(this.fragmentSums, fragmentMetadata.fragmentSums) && - Objects.equals(this.fragmentNullCounts, fragmentMetadata.fragmentNullCounts) && - Objects.equals(this.version, fragmentMetadata.version) && - Objects.equals(this.timestampRange, fragmentMetadata.timestampRange) && - Objects.equals(this.lastTileCellNum, fragmentMetadata.lastTileCellNum)&& - Objects.equals(this.additionalProperties, fragmentMetadata.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(fileSizes, fileVarSizes, fileValiditySizes, fragmentUri, hasTimestamps, hasDeleteMeta, sparseTileNum, tileIndexBase, tileOffsets, tileVarOffsets, tileVarSizes, tileValidityOffsets, tileMinBuffer, tileMinVarBuffer, tileMaxBuffer, tileMaxVarBuffer, tileSums, tileNullCounts, fragmentMins, fragmentMaxs, fragmentSums, fragmentNullCounts, version, timestampRange, lastTileCellNum, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class FragmentMetadata {\n"); - sb.append(" fileSizes: ").append(toIndentedString(fileSizes)).append("\n"); - sb.append(" fileVarSizes: ").append(toIndentedString(fileVarSizes)).append("\n"); - sb.append(" fileValiditySizes: ").append(toIndentedString(fileValiditySizes)).append("\n"); - sb.append(" fragmentUri: ").append(toIndentedString(fragmentUri)).append("\n"); - sb.append(" hasTimestamps: ").append(toIndentedString(hasTimestamps)).append("\n"); - sb.append(" hasDeleteMeta: ").append(toIndentedString(hasDeleteMeta)).append("\n"); - sb.append(" sparseTileNum: ").append(toIndentedString(sparseTileNum)).append("\n"); - sb.append(" tileIndexBase: ").append(toIndentedString(tileIndexBase)).append("\n"); - sb.append(" tileOffsets: ").append(toIndentedString(tileOffsets)).append("\n"); - sb.append(" tileVarOffsets: ").append(toIndentedString(tileVarOffsets)).append("\n"); - sb.append(" tileVarSizes: ").append(toIndentedString(tileVarSizes)).append("\n"); - sb.append(" tileValidityOffsets: ").append(toIndentedString(tileValidityOffsets)).append("\n"); - sb.append(" tileMinBuffer: ").append(toIndentedString(tileMinBuffer)).append("\n"); - sb.append(" tileMinVarBuffer: ").append(toIndentedString(tileMinVarBuffer)).append("\n"); - sb.append(" tileMaxBuffer: ").append(toIndentedString(tileMaxBuffer)).append("\n"); - sb.append(" tileMaxVarBuffer: ").append(toIndentedString(tileMaxVarBuffer)).append("\n"); - sb.append(" tileSums: ").append(toIndentedString(tileSums)).append("\n"); - sb.append(" tileNullCounts: ").append(toIndentedString(tileNullCounts)).append("\n"); - sb.append(" fragmentMins: ").append(toIndentedString(fragmentMins)).append("\n"); - sb.append(" fragmentMaxs: ").append(toIndentedString(fragmentMaxs)).append("\n"); - sb.append(" fragmentSums: ").append(toIndentedString(fragmentSums)).append("\n"); - sb.append(" fragmentNullCounts: ").append(toIndentedString(fragmentNullCounts)).append("\n"); - sb.append(" version: ").append(toIndentedString(version)).append("\n"); - sb.append(" timestampRange: ").append(toIndentedString(timestampRange)).append("\n"); - sb.append(" lastTileCellNum: ").append(toIndentedString(lastTileCellNum)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("fileSizes"); - openapiFields.add("fileVarSizes"); - openapiFields.add("fileValiditySizes"); - openapiFields.add("fragmentUri"); - openapiFields.add("hasTimestamps"); - openapiFields.add("hasDeleteMeta"); - openapiFields.add("sparseTileNum"); - openapiFields.add("tileIndexBase"); - openapiFields.add("tileOffsets"); - openapiFields.add("tileVarOffsets"); - openapiFields.add("tileVarSizes"); - openapiFields.add("tileValidityOffsets"); - openapiFields.add("tileMinBuffer"); - openapiFields.add("tileMinVarBuffer"); - openapiFields.add("tileMaxBuffer"); - openapiFields.add("tileMaxVarBuffer"); - openapiFields.add("tileSums"); - openapiFields.add("tileNullCounts"); - openapiFields.add("fragmentMins"); - openapiFields.add("fragmentMaxs"); - openapiFields.add("fragmentSums"); - openapiFields.add("fragmentNullCounts"); - openapiFields.add("version"); - openapiFields.add("timestampRange"); - openapiFields.add("lastTileCellNum"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to FragmentMetadata - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (FragmentMetadata.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in FragmentMetadata is not found in the empty JSON string", FragmentMetadata.openapiRequiredFields.toString())); - } - } - // ensure the json data is an array - if ((jsonObj.get("fileSizes") != null && !jsonObj.get("fileSizes").isJsonNull()) && !jsonObj.get("fileSizes").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `fileSizes` to be an array in the JSON string but got `%s`", jsonObj.get("fileSizes").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("fileVarSizes") != null && !jsonObj.get("fileVarSizes").isJsonNull()) && !jsonObj.get("fileVarSizes").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `fileVarSizes` to be an array in the JSON string but got `%s`", jsonObj.get("fileVarSizes").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("fileValiditySizes") != null && !jsonObj.get("fileValiditySizes").isJsonNull()) && !jsonObj.get("fileValiditySizes").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `fileValiditySizes` to be an array in the JSON string but got `%s`", jsonObj.get("fileValiditySizes").toString())); - } - if ((jsonObj.get("fragmentUri") != null && !jsonObj.get("fragmentUri").isJsonNull()) && !jsonObj.get("fragmentUri").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `fragmentUri` to be a primitive type in the JSON string but got `%s`", jsonObj.get("fragmentUri").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("tileOffsets") != null && !jsonObj.get("tileOffsets").isJsonNull()) && !jsonObj.get("tileOffsets").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `tileOffsets` to be an array in the JSON string but got `%s`", jsonObj.get("tileOffsets").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("tileVarOffsets") != null && !jsonObj.get("tileVarOffsets").isJsonNull()) && !jsonObj.get("tileVarOffsets").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `tileVarOffsets` to be an array in the JSON string but got `%s`", jsonObj.get("tileVarOffsets").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("tileVarSizes") != null && !jsonObj.get("tileVarSizes").isJsonNull()) && !jsonObj.get("tileVarSizes").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `tileVarSizes` to be an array in the JSON string but got `%s`", jsonObj.get("tileVarSizes").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("tileValidityOffsets") != null && !jsonObj.get("tileValidityOffsets").isJsonNull()) && !jsonObj.get("tileValidityOffsets").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `tileValidityOffsets` to be an array in the JSON string but got `%s`", jsonObj.get("tileValidityOffsets").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("tileMinBuffer") != null && !jsonObj.get("tileMinBuffer").isJsonNull()) && !jsonObj.get("tileMinBuffer").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `tileMinBuffer` to be an array in the JSON string but got `%s`", jsonObj.get("tileMinBuffer").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("tileMinVarBuffer") != null && !jsonObj.get("tileMinVarBuffer").isJsonNull()) && !jsonObj.get("tileMinVarBuffer").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `tileMinVarBuffer` to be an array in the JSON string but got `%s`", jsonObj.get("tileMinVarBuffer").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("tileMaxBuffer") != null && !jsonObj.get("tileMaxBuffer").isJsonNull()) && !jsonObj.get("tileMaxBuffer").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `tileMaxBuffer` to be an array in the JSON string but got `%s`", jsonObj.get("tileMaxBuffer").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("tileMaxVarBuffer") != null && !jsonObj.get("tileMaxVarBuffer").isJsonNull()) && !jsonObj.get("tileMaxVarBuffer").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `tileMaxVarBuffer` to be an array in the JSON string but got `%s`", jsonObj.get("tileMaxVarBuffer").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("tileSums") != null && !jsonObj.get("tileSums").isJsonNull()) && !jsonObj.get("tileSums").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `tileSums` to be an array in the JSON string but got `%s`", jsonObj.get("tileSums").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("tileNullCounts") != null && !jsonObj.get("tileNullCounts").isJsonNull()) && !jsonObj.get("tileNullCounts").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `tileNullCounts` to be an array in the JSON string but got `%s`", jsonObj.get("tileNullCounts").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("fragmentMins") != null && !jsonObj.get("fragmentMins").isJsonNull()) && !jsonObj.get("fragmentMins").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `fragmentMins` to be an array in the JSON string but got `%s`", jsonObj.get("fragmentMins").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("fragmentMaxs") != null && !jsonObj.get("fragmentMaxs").isJsonNull()) && !jsonObj.get("fragmentMaxs").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `fragmentMaxs` to be an array in the JSON string but got `%s`", jsonObj.get("fragmentMaxs").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("fragmentSums") != null && !jsonObj.get("fragmentSums").isJsonNull()) && !jsonObj.get("fragmentSums").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `fragmentSums` to be an array in the JSON string but got `%s`", jsonObj.get("fragmentSums").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("fragmentNullCounts") != null && !jsonObj.get("fragmentNullCounts").isJsonNull()) && !jsonObj.get("fragmentNullCounts").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `fragmentNullCounts` to be an array in the JSON string but got `%s`", jsonObj.get("fragmentNullCounts").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("timestampRange") != null && !jsonObj.get("timestampRange").isJsonNull()) && !jsonObj.get("timestampRange").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `timestampRange` to be an array in the JSON string but got `%s`", jsonObj.get("timestampRange").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!FragmentMetadata.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'FragmentMetadata' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(FragmentMetadata.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, FragmentMetadata value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public FragmentMetadata read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - FragmentMetadata instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of FragmentMetadata given an JSON string - * - * @param jsonString JSON string - * @return An instance of FragmentMetadata - * @throws IOException if the JSON string is invalid with respect to FragmentMetadata - */ - public static FragmentMetadata fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, FragmentMetadata.class); - } - - /** - * Convert an instance of FragmentMetadata to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GenericUDF.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GenericUDF.java deleted file mode 100644 index 2a01f4f..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GenericUDF.java +++ /dev/null @@ -1,789 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * User-defined function - */ -@ApiModel(description = "User-defined function") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class GenericUDF { - public static final String SERIALIZED_NAME_UDF_INFO_NAME = "udf_info_name"; - @SerializedName(SERIALIZED_NAME_UDF_INFO_NAME) - private String udfInfoName; - - public static final String SERIALIZED_NAME_LANGUAGE = "language"; - @SerializedName(SERIALIZED_NAME_LANGUAGE) - private UDFLanguage language; - - public static final String SERIALIZED_NAME_VERSION = "version"; - @SerializedName(SERIALIZED_NAME_VERSION) - private String version; - - public static final String SERIALIZED_NAME_IMAGE_NAME = "image_name"; - @SerializedName(SERIALIZED_NAME_IMAGE_NAME) - private String imageName; - - public static final String SERIALIZED_NAME_ACCESS_CREDENTIALS_NAME = "access_credentials_name"; - @SerializedName(SERIALIZED_NAME_ACCESS_CREDENTIALS_NAME) - private String accessCredentialsName; - - public static final String SERIALIZED_NAME_RESOURCE_CLASS = "resource_class"; - @SerializedName(SERIALIZED_NAME_RESOURCE_CLASS) - private String resourceClass; - - public static final String SERIALIZED_NAME_EXEC = "exec"; - @SerializedName(SERIALIZED_NAME_EXEC) - private String exec; - - public static final String SERIALIZED_NAME_EXEC_RAW = "exec_raw"; - @SerializedName(SERIALIZED_NAME_EXEC_RAW) - private String execRaw; - - public static final String SERIALIZED_NAME_ARGUMENT = "argument"; - @SerializedName(SERIALIZED_NAME_ARGUMENT) - private String argument; - - public static final String SERIALIZED_NAME_STORED_PARAM_UUIDS = "stored_param_uuids"; - @SerializedName(SERIALIZED_NAME_STORED_PARAM_UUIDS) - private List storedParamUuids = null; - - public static final String SERIALIZED_NAME_RESULT_FORMAT = "result_format"; - @SerializedName(SERIALIZED_NAME_RESULT_FORMAT) - private ResultFormat resultFormat; - - public static final String SERIALIZED_NAME_TASK_NAME = "task_name"; - @SerializedName(SERIALIZED_NAME_TASK_NAME) - private String taskName; - - public static final String SERIALIZED_NAME_STORE_RESULTS = "store_results"; - @SerializedName(SERIALIZED_NAME_STORE_RESULTS) - private Boolean storeResults; - - public static final String SERIALIZED_NAME_TIMEOUT = "timeout"; - @SerializedName(SERIALIZED_NAME_TIMEOUT) - private Integer timeout; - - public static final String SERIALIZED_NAME_DONT_DOWNLOAD_RESULTS = "dont_download_results"; - @SerializedName(SERIALIZED_NAME_DONT_DOWNLOAD_RESULTS) - private Boolean dontDownloadResults; - - public static final String SERIALIZED_NAME_TASK_GRAPH_UUID = "task_graph_uuid"; - @SerializedName(SERIALIZED_NAME_TASK_GRAPH_UUID) - private String taskGraphUuid; - - public static final String SERIALIZED_NAME_CLIENT_NODE_UUID = "client_node_uuid"; - @SerializedName(SERIALIZED_NAME_CLIENT_NODE_UUID) - private String clientNodeUuid; - - public GenericUDF() { - } - - public GenericUDF udfInfoName(String udfInfoName) { - - this.udfInfoName = udfInfoName; - return this; - } - - /** - * name of UDFInfo to run, format is {namespace}/{udf_name}. Can not be used with exec - * @return udfInfoName - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "TileDB-Inc/csv_ingestor", value = "name of UDFInfo to run, format is {namespace}/{udf_name}. Can not be used with exec") - - public String getUdfInfoName() { - return udfInfoName; - } - - - public void setUdfInfoName(String udfInfoName) { - this.udfInfoName = udfInfoName; - } - - - public GenericUDF language(UDFLanguage language) { - - this.language = language; - return this; - } - - /** - * Get language - * @return language - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public UDFLanguage getLanguage() { - return language; - } - - - public void setLanguage(UDFLanguage language) { - this.language = language; - } - - - public GenericUDF version(String version) { - - this.version = version; - return this; - } - - /** - * Type-specific version - * @return version - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Type-specific version") - - public String getVersion() { - return version; - } - - - public void setVersion(String version) { - this.version = version; - } - - - public GenericUDF imageName(String imageName) { - - this.imageName = imageName; - return this; - } - - /** - * Docker image name to use for UDF - * @return imageName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Docker image name to use for UDF") - - public String getImageName() { - return imageName; - } - - - public void setImageName(String imageName) { - this.imageName = imageName; - } - - - public GenericUDF accessCredentialsName(String accessCredentialsName) { - - this.accessCredentialsName = accessCredentialsName; - return this; - } - - /** - * The name of the access credentials to use. if unset, no credentials will be configured in the environment. - * @return accessCredentialsName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The name of the access credentials to use. if unset, no credentials will be configured in the environment.") - - public String getAccessCredentialsName() { - return accessCredentialsName; - } - - - public void setAccessCredentialsName(String accessCredentialsName) { - this.accessCredentialsName = accessCredentialsName; - } - - - public GenericUDF resourceClass(String resourceClass) { - - this.resourceClass = resourceClass; - return this; - } - - /** - * The resource class to use for the UDF execution. Resource classes define resource limits for memory and CPUs. If this is empty, then the UDF will execute in the standard resource class of the TileDB Cloud provider. - * @return resourceClass - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "standard", value = "The resource class to use for the UDF execution. Resource classes define resource limits for memory and CPUs. If this is empty, then the UDF will execute in the standard resource class of the TileDB Cloud provider. ") - - public String getResourceClass() { - return resourceClass; - } - - - public void setResourceClass(String resourceClass) { - this.resourceClass = resourceClass; - } - - - public GenericUDF exec(String exec) { - - this.exec = exec; - return this; - } - - /** - * Type-specific executable text - * @return exec - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Type-specific executable text") - - public String getExec() { - return exec; - } - - - public void setExec(String exec) { - this.exec = exec; - } - - - public GenericUDF execRaw(String execRaw) { - - this.execRaw = execRaw; - return this; - } - - /** - * optional raw text to store of serialized function, used for showing in UI - * @return execRaw - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "optional raw text to store of serialized function, used for showing in UI") - - public String getExecRaw() { - return execRaw; - } - - - public void setExecRaw(String execRaw) { - this.execRaw = execRaw; - } - - - public GenericUDF argument(String argument) { - - this.argument = argument; - return this; - } - - /** - * Argument(s) to pass to UDF function, tuple or list of args/kwargs which can be in native or JSON format - * @return argument - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Argument(s) to pass to UDF function, tuple or list of args/kwargs which can be in native or JSON format") - - public String getArgument() { - return argument; - } - - - public void setArgument(String argument) { - this.argument = argument; - } - - - public GenericUDF storedParamUuids(List storedParamUuids) { - - this.storedParamUuids = storedParamUuids; - return this; - } - - public GenericUDF addStoredParamUuidsItem(String storedParamUuidsItem) { - if (this.storedParamUuids == null) { - this.storedParamUuids = new ArrayList<>(); - } - this.storedParamUuids.add(storedParamUuidsItem); - return this; - } - - /** - * The UUIDs of stored input parameters (passed in a language-specific format within \"argument\") to be retrieved from the server-side cache. Serialized in standard hex format with no {}. - * @return storedParamUuids - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The UUIDs of stored input parameters (passed in a language-specific format within \"argument\") to be retrieved from the server-side cache. Serialized in standard hex format with no {}.") - - public List getStoredParamUuids() { - return storedParamUuids; - } - - - public void setStoredParamUuids(List storedParamUuids) { - this.storedParamUuids = storedParamUuids; - } - - - public GenericUDF resultFormat(ResultFormat resultFormat) { - - this.resultFormat = resultFormat; - return this; - } - - /** - * Get resultFormat - * @return resultFormat - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public ResultFormat getResultFormat() { - return resultFormat; - } - - - public void setResultFormat(ResultFormat resultFormat) { - this.resultFormat = resultFormat; - } - - - public GenericUDF taskName(String taskName) { - - this.taskName = taskName; - return this; - } - - /** - * name of task, optional - * @return taskName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "name of task, optional") - - public String getTaskName() { - return taskName; - } - - - public void setTaskName(String taskName) { - this.taskName = taskName; - } - - - public GenericUDF storeResults(Boolean storeResults) { - - this.storeResults = storeResults; - return this; - } - - /** - * store results for later retrieval - * @return storeResults - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "store results for later retrieval") - - public Boolean getStoreResults() { - return storeResults; - } - - - public void setStoreResults(Boolean storeResults) { - this.storeResults = storeResults; - } - - - public GenericUDF timeout(Integer timeout) { - - this.timeout = timeout; - return this; - } - - /** - * UDF-type timeout in seconds (default: 900) - * @return timeout - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "UDF-type timeout in seconds (default: 900)") - - public Integer getTimeout() { - return timeout; - } - - - public void setTimeout(Integer timeout) { - this.timeout = timeout; - } - - - public GenericUDF dontDownloadResults(Boolean dontDownloadResults) { - - this.dontDownloadResults = dontDownloadResults; - return this; - } - - /** - * Set to true to avoid downloading the results of this UDF. Useful for intermediate nodes in a task graph where you will not be using the results of your function. Defaults to false (\"yes download results\"). - * @return dontDownloadResults - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Set to true to avoid downloading the results of this UDF. Useful for intermediate nodes in a task graph where you will not be using the results of your function. Defaults to false (\"yes download results\").") - - public Boolean getDontDownloadResults() { - return dontDownloadResults; - } - - - public void setDontDownloadResults(Boolean dontDownloadResults) { - this.dontDownloadResults = dontDownloadResults; - } - - - public GenericUDF taskGraphUuid(String taskGraphUuid) { - - this.taskGraphUuid = taskGraphUuid; - return this; - } - - /** - * If set, the ID of the log for the task graph that this was part of. - * @return taskGraphUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "If set, the ID of the log for the task graph that this was part of. ") - - public String getTaskGraphUuid() { - return taskGraphUuid; - } - - - public void setTaskGraphUuid(String taskGraphUuid) { - this.taskGraphUuid = taskGraphUuid; - } - - - public GenericUDF clientNodeUuid(String clientNodeUuid) { - - this.clientNodeUuid = clientNodeUuid; - return this; - } - - /** - * If set, the client-defined ID of the node within this task's graph. - * @return clientNodeUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "If set, the client-defined ID of the node within this task's graph. ") - - public String getClientNodeUuid() { - return clientNodeUuid; - } - - - public void setClientNodeUuid(String clientNodeUuid) { - this.clientNodeUuid = clientNodeUuid; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public GenericUDF putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - GenericUDF genericUDF = (GenericUDF) o; - return Objects.equals(this.udfInfoName, genericUDF.udfInfoName) && - Objects.equals(this.language, genericUDF.language) && - Objects.equals(this.version, genericUDF.version) && - Objects.equals(this.imageName, genericUDF.imageName) && - Objects.equals(this.accessCredentialsName, genericUDF.accessCredentialsName) && - Objects.equals(this.resourceClass, genericUDF.resourceClass) && - Objects.equals(this.exec, genericUDF.exec) && - Objects.equals(this.execRaw, genericUDF.execRaw) && - Objects.equals(this.argument, genericUDF.argument) && - Objects.equals(this.storedParamUuids, genericUDF.storedParamUuids) && - Objects.equals(this.resultFormat, genericUDF.resultFormat) && - Objects.equals(this.taskName, genericUDF.taskName) && - Objects.equals(this.storeResults, genericUDF.storeResults) && - Objects.equals(this.timeout, genericUDF.timeout) && - Objects.equals(this.dontDownloadResults, genericUDF.dontDownloadResults) && - Objects.equals(this.taskGraphUuid, genericUDF.taskGraphUuid) && - Objects.equals(this.clientNodeUuid, genericUDF.clientNodeUuid)&& - Objects.equals(this.additionalProperties, genericUDF.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(udfInfoName, language, version, imageName, accessCredentialsName, resourceClass, exec, execRaw, argument, storedParamUuids, resultFormat, taskName, storeResults, timeout, dontDownloadResults, taskGraphUuid, clientNodeUuid, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class GenericUDF {\n"); - sb.append(" udfInfoName: ").append(toIndentedString(udfInfoName)).append("\n"); - sb.append(" language: ").append(toIndentedString(language)).append("\n"); - sb.append(" version: ").append(toIndentedString(version)).append("\n"); - sb.append(" imageName: ").append(toIndentedString(imageName)).append("\n"); - sb.append(" accessCredentialsName: ").append(toIndentedString(accessCredentialsName)).append("\n"); - sb.append(" resourceClass: ").append(toIndentedString(resourceClass)).append("\n"); - sb.append(" exec: ").append(toIndentedString(exec)).append("\n"); - sb.append(" execRaw: ").append(toIndentedString(execRaw)).append("\n"); - sb.append(" argument: ").append(toIndentedString(argument)).append("\n"); - sb.append(" storedParamUuids: ").append(toIndentedString(storedParamUuids)).append("\n"); - sb.append(" resultFormat: ").append(toIndentedString(resultFormat)).append("\n"); - sb.append(" taskName: ").append(toIndentedString(taskName)).append("\n"); - sb.append(" storeResults: ").append(toIndentedString(storeResults)).append("\n"); - sb.append(" timeout: ").append(toIndentedString(timeout)).append("\n"); - sb.append(" dontDownloadResults: ").append(toIndentedString(dontDownloadResults)).append("\n"); - sb.append(" taskGraphUuid: ").append(toIndentedString(taskGraphUuid)).append("\n"); - sb.append(" clientNodeUuid: ").append(toIndentedString(clientNodeUuid)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("udf_info_name"); - openapiFields.add("language"); - openapiFields.add("version"); - openapiFields.add("image_name"); - openapiFields.add("access_credentials_name"); - openapiFields.add("resource_class"); - openapiFields.add("exec"); - openapiFields.add("exec_raw"); - openapiFields.add("argument"); - openapiFields.add("stored_param_uuids"); - openapiFields.add("result_format"); - openapiFields.add("task_name"); - openapiFields.add("store_results"); - openapiFields.add("timeout"); - openapiFields.add("dont_download_results"); - openapiFields.add("task_graph_uuid"); - openapiFields.add("client_node_uuid"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to GenericUDF - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (GenericUDF.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in GenericUDF is not found in the empty JSON string", GenericUDF.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("udf_info_name") != null && !jsonObj.get("udf_info_name").isJsonNull()) && !jsonObj.get("udf_info_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `udf_info_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("udf_info_name").toString())); - } - if ((jsonObj.get("version") != null && !jsonObj.get("version").isJsonNull()) && !jsonObj.get("version").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `version` to be a primitive type in the JSON string but got `%s`", jsonObj.get("version").toString())); - } - if ((jsonObj.get("image_name") != null && !jsonObj.get("image_name").isJsonNull()) && !jsonObj.get("image_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `image_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("image_name").toString())); - } - if ((jsonObj.get("access_credentials_name") != null && !jsonObj.get("access_credentials_name").isJsonNull()) && !jsonObj.get("access_credentials_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `access_credentials_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("access_credentials_name").toString())); - } - if ((jsonObj.get("resource_class") != null && !jsonObj.get("resource_class").isJsonNull()) && !jsonObj.get("resource_class").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `resource_class` to be a primitive type in the JSON string but got `%s`", jsonObj.get("resource_class").toString())); - } - if ((jsonObj.get("exec") != null && !jsonObj.get("exec").isJsonNull()) && !jsonObj.get("exec").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `exec` to be a primitive type in the JSON string but got `%s`", jsonObj.get("exec").toString())); - } - if ((jsonObj.get("exec_raw") != null && !jsonObj.get("exec_raw").isJsonNull()) && !jsonObj.get("exec_raw").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `exec_raw` to be a primitive type in the JSON string but got `%s`", jsonObj.get("exec_raw").toString())); - } - if ((jsonObj.get("argument") != null && !jsonObj.get("argument").isJsonNull()) && !jsonObj.get("argument").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `argument` to be a primitive type in the JSON string but got `%s`", jsonObj.get("argument").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("stored_param_uuids") != null && !jsonObj.get("stored_param_uuids").isJsonNull()) && !jsonObj.get("stored_param_uuids").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `stored_param_uuids` to be an array in the JSON string but got `%s`", jsonObj.get("stored_param_uuids").toString())); - } - if ((jsonObj.get("task_name") != null && !jsonObj.get("task_name").isJsonNull()) && !jsonObj.get("task_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `task_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("task_name").toString())); - } - if ((jsonObj.get("task_graph_uuid") != null && !jsonObj.get("task_graph_uuid").isJsonNull()) && !jsonObj.get("task_graph_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `task_graph_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("task_graph_uuid").toString())); - } - if ((jsonObj.get("client_node_uuid") != null && !jsonObj.get("client_node_uuid").isJsonNull()) && !jsonObj.get("client_node_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `client_node_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("client_node_uuid").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!GenericUDF.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'GenericUDF' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(GenericUDF.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, GenericUDF value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public GenericUDF read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - GenericUDF instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of GenericUDF given an JSON string - * - * @param jsonString JSON string - * @return An instance of GenericUDF - * @throws IOException if the JSON string is invalid with respect to GenericUDF - */ - public static GenericUDF fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, GenericUDF.class); - } - - /** - * Convert an instance of GenericUDF to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GetTiledbStats200Response.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GetTiledbStats200Response.java deleted file mode 100644 index 234fadd..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GetTiledbStats200Response.java +++ /dev/null @@ -1,263 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * GetTiledbStats200Response - */ -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class GetTiledbStats200Response { - public static final String SERIALIZED_NAME_STATS = "stats"; - @SerializedName(SERIALIZED_NAME_STATS) - private String stats; - - public GetTiledbStats200Response() { - } - - public GetTiledbStats200Response stats(String stats) { - - this.stats = stats; - return this; - } - - /** - * string of stats from tiledb - * @return stats - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "123", value = "string of stats from tiledb") - - public String getStats() { - return stats; - } - - - public void setStats(String stats) { - this.stats = stats; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public GetTiledbStats200Response putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - GetTiledbStats200Response getTiledbStats200Response = (GetTiledbStats200Response) o; - return Objects.equals(this.stats, getTiledbStats200Response.stats)&& - Objects.equals(this.additionalProperties, getTiledbStats200Response.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(stats, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class GetTiledbStats200Response {\n"); - sb.append(" stats: ").append(toIndentedString(stats)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("stats"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to GetTiledbStats200Response - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (GetTiledbStats200Response.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in GetTiledbStats200Response is not found in the empty JSON string", GetTiledbStats200Response.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("stats") != null && !jsonObj.get("stats").isJsonNull()) && !jsonObj.get("stats").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `stats` to be a primitive type in the JSON string but got `%s`", jsonObj.get("stats").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!GetTiledbStats200Response.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'GetTiledbStats200Response' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(GetTiledbStats200Response.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, GetTiledbStats200Response value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public GetTiledbStats200Response read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - GetTiledbStats200Response instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of GetTiledbStats200Response given an JSON string - * - * @param jsonString JSON string - * @return An instance of GetTiledbStats200Response - * @throws IOException if the JSON string is invalid with respect to GetTiledbStats200Response - */ - public static GetTiledbStats200Response fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, GetTiledbStats200Response.class); - } - - /** - * Convert an instance of GetTiledbStats200Response to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupActions.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupActions.java deleted file mode 100644 index aed69b6..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupActions.java +++ /dev/null @@ -1,71 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * actions a user can take on a group - */ -@JsonAdapter(GroupActions.Adapter.class) -public enum GroupActions { - - READ("read"), - - WRITE("write"), - - EDIT("edit"); - - private String value; - - GroupActions(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static GroupActions fromValue(String value) { - for (GroupActions b : GroupActions.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final GroupActions enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public GroupActions read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return GroupActions.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupActivity.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupActivity.java deleted file mode 100644 index 36e762c..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupActivity.java +++ /dev/null @@ -1,300 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Object containing activity of an asset of a group - */ -@ApiModel(description = "Object containing activity of an asset of a group") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class GroupActivity { - public static final String SERIALIZED_NAME_ASSET = "asset"; - @SerializedName(SERIALIZED_NAME_ASSET) - private GroupActivityAsset asset; - - public static final String SERIALIZED_NAME_ACTIVITY_LOG = "activity_log"; - @SerializedName(SERIALIZED_NAME_ACTIVITY_LOG) - private ArrayActivityLog activityLog; - - public GroupActivity() { - } - - public GroupActivity asset(GroupActivityAsset asset) { - - this.asset = asset; - return this; - } - - /** - * Get asset - * @return asset - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public GroupActivityAsset getAsset() { - return asset; - } - - - public void setAsset(GroupActivityAsset asset) { - this.asset = asset; - } - - - public GroupActivity activityLog(ArrayActivityLog activityLog) { - - this.activityLog = activityLog; - return this; - } - - /** - * Get activityLog - * @return activityLog - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public ArrayActivityLog getActivityLog() { - return activityLog; - } - - - public void setActivityLog(ArrayActivityLog activityLog) { - this.activityLog = activityLog; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public GroupActivity putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - GroupActivity groupActivity = (GroupActivity) o; - return Objects.equals(this.asset, groupActivity.asset) && - Objects.equals(this.activityLog, groupActivity.activityLog)&& - Objects.equals(this.additionalProperties, groupActivity.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(asset, activityLog, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class GroupActivity {\n"); - sb.append(" asset: ").append(toIndentedString(asset)).append("\n"); - sb.append(" activityLog: ").append(toIndentedString(activityLog)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("asset"); - openapiFields.add("activity_log"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to GroupActivity - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (GroupActivity.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in GroupActivity is not found in the empty JSON string", GroupActivity.openapiRequiredFields.toString())); - } - } - // validate the optional field `asset` - if (jsonObj.get("asset") != null && !jsonObj.get("asset").isJsonNull()) { - GroupActivityAsset.validateJsonObject(jsonObj.getAsJsonObject("asset")); - } - // validate the optional field `activity_log` - if (jsonObj.get("activity_log") != null && !jsonObj.get("activity_log").isJsonNull()) { - ArrayActivityLog.validateJsonObject(jsonObj.getAsJsonObject("activity_log")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!GroupActivity.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'GroupActivity' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(GroupActivity.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, GroupActivity value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public GroupActivity read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - GroupActivity instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of GroupActivity given an JSON string - * - * @param jsonString JSON string - * @return An instance of GroupActivity - * @throws IOException if the JSON string is invalid with respect to GroupActivity - */ - public static GroupActivity fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, GroupActivity.class); - } - - /** - * Convert an instance of GroupActivity to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupActivityAsset.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupActivityAsset.java deleted file mode 100644 index c3ef9db..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupActivityAsset.java +++ /dev/null @@ -1,361 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * The asset details - */ -@ApiModel(description = "The asset details") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class GroupActivityAsset { - public static final String SERIALIZED_NAME_ID = "id"; - @SerializedName(SERIALIZED_NAME_ID) - private String id; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public static final String SERIALIZED_NAME_ASSET_TYPE = "asset_type"; - @SerializedName(SERIALIZED_NAME_ASSET_TYPE) - private AssetType assetType; - - public GroupActivityAsset() { - } - - public GroupActivityAsset id(String id) { - - this.id = id; - return this; - } - - /** - * The asset ID - * @return id - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The asset ID") - - public String getId() { - return id; - } - - - public void setId(String id) { - this.id = id; - } - - - public GroupActivityAsset name(String name) { - - this.name = name; - return this; - } - - /** - * The asset name - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The asset name") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public GroupActivityAsset namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * The namespace that the asset belongs to - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The namespace that the asset belongs to") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - - public GroupActivityAsset assetType(AssetType assetType) { - - this.assetType = assetType; - return this; - } - - /** - * Get assetType - * @return assetType - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public AssetType getAssetType() { - return assetType; - } - - - public void setAssetType(AssetType assetType) { - this.assetType = assetType; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public GroupActivityAsset putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - GroupActivityAsset groupActivityAsset = (GroupActivityAsset) o; - return Objects.equals(this.id, groupActivityAsset.id) && - Objects.equals(this.name, groupActivityAsset.name) && - Objects.equals(this.namespace, groupActivityAsset.namespace) && - Objects.equals(this.assetType, groupActivityAsset.assetType)&& - Objects.equals(this.additionalProperties, groupActivityAsset.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(id, name, namespace, assetType, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class GroupActivityAsset {\n"); - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" assetType: ").append(toIndentedString(assetType)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("id"); - openapiFields.add("name"); - openapiFields.add("namespace"); - openapiFields.add("asset_type"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to GroupActivityAsset - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (GroupActivityAsset.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in GroupActivityAsset is not found in the empty JSON string", GroupActivityAsset.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) && !jsonObj.get("id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("id").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!GroupActivityAsset.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'GroupActivityAsset' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(GroupActivityAsset.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, GroupActivityAsset value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public GroupActivityAsset read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - GroupActivityAsset instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of GroupActivityAsset given an JSON string - * - * @param jsonString JSON string - * @return An instance of GroupActivityAsset - * @throws IOException if the JSON string is invalid with respect to GroupActivityAsset - */ - public static GroupActivityAsset fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, GroupActivityAsset.class); - } - - /** - * Convert an instance of GroupActivityAsset to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupActivityResponse.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupActivityResponse.java deleted file mode 100644 index 861fb16..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupActivityResponse.java +++ /dev/null @@ -1,319 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Object containing activity logs of group content along with the pagination metadata - */ -@ApiModel(description = "Object containing activity logs of group content along with the pagination metadata") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class GroupActivityResponse { - public static final String SERIALIZED_NAME_ACTIVITY = "activity"; - @SerializedName(SERIALIZED_NAME_ACTIVITY) - private List activity = null; - - public static final String SERIALIZED_NAME_PAGINATION_METADATA = "pagination_metadata"; - @SerializedName(SERIALIZED_NAME_PAGINATION_METADATA) - private PaginationMetadata paginationMetadata; - - public GroupActivityResponse() { - } - - public GroupActivityResponse activity(List activity) { - - this.activity = activity; - return this; - } - - public GroupActivityResponse addActivityItem(GroupActivity activityItem) { - if (this.activity == null) { - this.activity = new ArrayList<>(); - } - this.activity.add(activityItem); - return this; - } - - /** - * Activity of a group's content - * @return activity - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Activity of a group's content") - - public List getActivity() { - return activity; - } - - - public void setActivity(List activity) { - this.activity = activity; - } - - - public GroupActivityResponse paginationMetadata(PaginationMetadata paginationMetadata) { - - this.paginationMetadata = paginationMetadata; - return this; - } - - /** - * Get paginationMetadata - * @return paginationMetadata - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public PaginationMetadata getPaginationMetadata() { - return paginationMetadata; - } - - - public void setPaginationMetadata(PaginationMetadata paginationMetadata) { - this.paginationMetadata = paginationMetadata; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public GroupActivityResponse putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - GroupActivityResponse groupActivityResponse = (GroupActivityResponse) o; - return Objects.equals(this.activity, groupActivityResponse.activity) && - Objects.equals(this.paginationMetadata, groupActivityResponse.paginationMetadata)&& - Objects.equals(this.additionalProperties, groupActivityResponse.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(activity, paginationMetadata, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class GroupActivityResponse {\n"); - sb.append(" activity: ").append(toIndentedString(activity)).append("\n"); - sb.append(" paginationMetadata: ").append(toIndentedString(paginationMetadata)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("activity"); - openapiFields.add("pagination_metadata"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to GroupActivityResponse - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (GroupActivityResponse.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in GroupActivityResponse is not found in the empty JSON string", GroupActivityResponse.openapiRequiredFields.toString())); - } - } - JsonArray jsonArrayactivity = jsonObj.getAsJsonArray("activity"); - if (jsonArrayactivity != null) { - // ensure the json data is an array - if (!jsonObj.get("activity").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `activity` to be an array in the JSON string but got `%s`", jsonObj.get("activity").toString())); - } - - // validate the optional field `activity` (array) - for (int i = 0; i < jsonArrayactivity.size(); i++) { - GroupActivity.validateJsonObject(jsonArrayactivity.get(i).getAsJsonObject()); - }; - } - // validate the optional field `pagination_metadata` - if (jsonObj.get("pagination_metadata") != null && !jsonObj.get("pagination_metadata").isJsonNull()) { - PaginationMetadata.validateJsonObject(jsonObj.getAsJsonObject("pagination_metadata")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!GroupActivityResponse.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'GroupActivityResponse' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(GroupActivityResponse.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, GroupActivityResponse value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public GroupActivityResponse read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - GroupActivityResponse instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of GroupActivityResponse given an JSON string - * - * @param jsonString JSON string - * @return An instance of GroupActivityResponse - * @throws IOException if the JSON string is invalid with respect to GroupActivityResponse - */ - public static GroupActivityResponse fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, GroupActivityResponse.class); - } - - /** - * Convert an instance of GroupActivityResponse to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupBrowserData.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupBrowserData.java deleted file mode 100644 index 28b7bba..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupBrowserData.java +++ /dev/null @@ -1,319 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Object including group info and pagination metadata - */ -@ApiModel(description = "Object including group info and pagination metadata") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class GroupBrowserData { - public static final String SERIALIZED_NAME_GROUPS = "groups"; - @SerializedName(SERIALIZED_NAME_GROUPS) - private List groups = null; - - public static final String SERIALIZED_NAME_PAGINATION_METADATA = "pagination_metadata"; - @SerializedName(SERIALIZED_NAME_PAGINATION_METADATA) - private PaginationMetadata paginationMetadata; - - public GroupBrowserData() { - } - - public GroupBrowserData groups(List groups) { - - this.groups = groups; - return this; - } - - public GroupBrowserData addGroupsItem(GroupInfo groupsItem) { - if (this.groups == null) { - this.groups = new ArrayList<>(); - } - this.groups.add(groupsItem); - return this; - } - - /** - * Groups Info - * @return groups - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Groups Info") - - public List getGroups() { - return groups; - } - - - public void setGroups(List groups) { - this.groups = groups; - } - - - public GroupBrowserData paginationMetadata(PaginationMetadata paginationMetadata) { - - this.paginationMetadata = paginationMetadata; - return this; - } - - /** - * Get paginationMetadata - * @return paginationMetadata - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public PaginationMetadata getPaginationMetadata() { - return paginationMetadata; - } - - - public void setPaginationMetadata(PaginationMetadata paginationMetadata) { - this.paginationMetadata = paginationMetadata; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public GroupBrowserData putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - GroupBrowserData groupBrowserData = (GroupBrowserData) o; - return Objects.equals(this.groups, groupBrowserData.groups) && - Objects.equals(this.paginationMetadata, groupBrowserData.paginationMetadata)&& - Objects.equals(this.additionalProperties, groupBrowserData.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(groups, paginationMetadata, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class GroupBrowserData {\n"); - sb.append(" groups: ").append(toIndentedString(groups)).append("\n"); - sb.append(" paginationMetadata: ").append(toIndentedString(paginationMetadata)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("groups"); - openapiFields.add("pagination_metadata"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to GroupBrowserData - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (GroupBrowserData.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in GroupBrowserData is not found in the empty JSON string", GroupBrowserData.openapiRequiredFields.toString())); - } - } - JsonArray jsonArraygroups = jsonObj.getAsJsonArray("groups"); - if (jsonArraygroups != null) { - // ensure the json data is an array - if (!jsonObj.get("groups").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `groups` to be an array in the JSON string but got `%s`", jsonObj.get("groups").toString())); - } - - // validate the optional field `groups` (array) - for (int i = 0; i < jsonArraygroups.size(); i++) { - GroupInfo.validateJsonObject(jsonArraygroups.get(i).getAsJsonObject()); - }; - } - // validate the optional field `pagination_metadata` - if (jsonObj.get("pagination_metadata") != null && !jsonObj.get("pagination_metadata").isJsonNull()) { - PaginationMetadata.validateJsonObject(jsonObj.getAsJsonObject("pagination_metadata")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!GroupBrowserData.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'GroupBrowserData' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(GroupBrowserData.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, GroupBrowserData value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public GroupBrowserData read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - GroupBrowserData instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of GroupBrowserData given an JSON string - * - * @param jsonString JSON string - * @return An instance of GroupBrowserData - * @throws IOException if the JSON string is invalid with respect to GroupBrowserData - */ - public static GroupBrowserData fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, GroupBrowserData.class); - } - - /** - * Convert an instance of GroupBrowserData to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupBrowserFilterData.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupBrowserFilterData.java deleted file mode 100644 index 4334887..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupBrowserFilterData.java +++ /dev/null @@ -1,318 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Object with data to fill browser filter - */ -@ApiModel(description = "Object with data to fill browser filter") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class GroupBrowserFilterData { - public static final String SERIALIZED_NAME_NAMESPACES = "namespaces"; - @SerializedName(SERIALIZED_NAME_NAMESPACES) - private List namespaces = null; - - public static final String SERIALIZED_NAME_GROUP_TYPES = "group_types"; - @SerializedName(SERIALIZED_NAME_GROUP_TYPES) - private List groupTypes = null; - - public GroupBrowserFilterData() { - } - - public GroupBrowserFilterData namespaces(List namespaces) { - - this.namespaces = namespaces; - return this; - } - - public GroupBrowserFilterData addNamespacesItem(String namespacesItem) { - if (this.namespaces == null) { - this.namespaces = new ArrayList<>(); - } - this.namespaces.add(namespacesItem); - return this; - } - - /** - * list of all unique namespaces to display - * @return namespaces - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "list of all unique namespaces to display") - - public List getNamespaces() { - return namespaces; - } - - - public void setNamespaces(List namespaces) { - this.namespaces = namespaces; - } - - - public GroupBrowserFilterData groupTypes(List groupTypes) { - - this.groupTypes = groupTypes; - return this; - } - - public GroupBrowserFilterData addGroupTypesItem(GroupType groupTypesItem) { - if (this.groupTypes == null) { - this.groupTypes = new ArrayList<>(); - } - this.groupTypes.add(groupTypesItem); - return this; - } - - /** - * list of all available group types to display - * @return groupTypes - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "list of all available group types to display") - - public List getGroupTypes() { - return groupTypes; - } - - - public void setGroupTypes(List groupTypes) { - this.groupTypes = groupTypes; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public GroupBrowserFilterData putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - GroupBrowserFilterData groupBrowserFilterData = (GroupBrowserFilterData) o; - return Objects.equals(this.namespaces, groupBrowserFilterData.namespaces) && - Objects.equals(this.groupTypes, groupBrowserFilterData.groupTypes)&& - Objects.equals(this.additionalProperties, groupBrowserFilterData.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(namespaces, groupTypes, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class GroupBrowserFilterData {\n"); - sb.append(" namespaces: ").append(toIndentedString(namespaces)).append("\n"); - sb.append(" groupTypes: ").append(toIndentedString(groupTypes)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("namespaces"); - openapiFields.add("group_types"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to GroupBrowserFilterData - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (GroupBrowserFilterData.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in GroupBrowserFilterData is not found in the empty JSON string", GroupBrowserFilterData.openapiRequiredFields.toString())); - } - } - // ensure the json data is an array - if ((jsonObj.get("namespaces") != null && !jsonObj.get("namespaces").isJsonNull()) && !jsonObj.get("namespaces").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `namespaces` to be an array in the JSON string but got `%s`", jsonObj.get("namespaces").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("group_types") != null && !jsonObj.get("group_types").isJsonNull()) && !jsonObj.get("group_types").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `group_types` to be an array in the JSON string but got `%s`", jsonObj.get("group_types").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!GroupBrowserFilterData.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'GroupBrowserFilterData' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(GroupBrowserFilterData.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, GroupBrowserFilterData value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public GroupBrowserFilterData read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - GroupBrowserFilterData instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of GroupBrowserFilterData given an JSON string - * - * @param jsonString JSON string - * @return An instance of GroupBrowserFilterData - * @throws IOException if the JSON string is invalid with respect to GroupBrowserFilterData - */ - public static GroupBrowserFilterData fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, GroupBrowserFilterData.class); - } - - /** - * Convert an instance of GroupBrowserFilterData to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupChanges.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupChanges.java deleted file mode 100644 index add86fa..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupChanges.java +++ /dev/null @@ -1,335 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * A request to change the members of a group. Contains assets to add or remove. - */ -@ApiModel(description = "A request to change the members of a group. Contains assets to add or remove.") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class GroupChanges { - public static final String SERIALIZED_NAME_ADD = "add"; - @SerializedName(SERIALIZED_NAME_ADD) - private List add = null; - - public static final String SERIALIZED_NAME_REMOVE = "remove"; - @SerializedName(SERIALIZED_NAME_REMOVE) - private List remove = null; - - public GroupChanges() { - } - - public GroupChanges add(List add) { - - this.add = add; - return this; - } - - public GroupChanges addAddItem(GroupMember addItem) { - if (this.add == null) { - this.add = new ArrayList<>(); - } - this.add.add(addItem); - return this; - } - - /** - * the assets, arrays or groups, to add to the group. - * @return add - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "the assets, arrays or groups, to add to the group.") - - public List getAdd() { - return add; - } - - - public void setAdd(List add) { - this.add = add; - } - - - public GroupChanges remove(List remove) { - - this.remove = remove; - return this; - } - - public GroupChanges addRemoveItem(GroupMember removeItem) { - if (this.remove == null) { - this.remove = new ArrayList<>(); - } - this.remove.add(removeItem); - return this; - } - - /** - * the assets, arrays or groups, to remove from the group. - * @return remove - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "the assets, arrays or groups, to remove from the group.") - - public List getRemove() { - return remove; - } - - - public void setRemove(List remove) { - this.remove = remove; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public GroupChanges putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - GroupChanges groupChanges = (GroupChanges) o; - return Objects.equals(this.add, groupChanges.add) && - Objects.equals(this.remove, groupChanges.remove)&& - Objects.equals(this.additionalProperties, groupChanges.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(add, remove, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class GroupChanges {\n"); - sb.append(" add: ").append(toIndentedString(add)).append("\n"); - sb.append(" remove: ").append(toIndentedString(remove)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("add"); - openapiFields.add("remove"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to GroupChanges - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (GroupChanges.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in GroupChanges is not found in the empty JSON string", GroupChanges.openapiRequiredFields.toString())); - } - } - JsonArray jsonArrayadd = jsonObj.getAsJsonArray("add"); - if (jsonArrayadd != null) { - // ensure the json data is an array - if (!jsonObj.get("add").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `add` to be an array in the JSON string but got `%s`", jsonObj.get("add").toString())); - } - - // validate the optional field `add` (array) - for (int i = 0; i < jsonArrayadd.size(); i++) { - GroupMember.validateJsonObject(jsonArrayadd.get(i).getAsJsonObject()); - }; - } - JsonArray jsonArrayremove = jsonObj.getAsJsonArray("remove"); - if (jsonArrayremove != null) { - // ensure the json data is an array - if (!jsonObj.get("remove").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `remove` to be an array in the JSON string but got `%s`", jsonObj.get("remove").toString())); - } - - // validate the optional field `remove` (array) - for (int i = 0; i < jsonArrayremove.size(); i++) { - GroupMember.validateJsonObject(jsonArrayremove.get(i).getAsJsonObject()); - }; - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!GroupChanges.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'GroupChanges' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(GroupChanges.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, GroupChanges value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public GroupChanges read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - GroupChanges instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of GroupChanges given an JSON string - * - * @param jsonString JSON string - * @return An instance of GroupChanges - * @throws IOException if the JSON string is invalid with respect to GroupChanges - */ - public static GroupChanges fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, GroupChanges.class); - } - - /** - * Convert an instance of GroupChanges to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupContents.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupContents.java deleted file mode 100644 index 160d347..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupContents.java +++ /dev/null @@ -1,319 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Object including a page of members of a group and pagination metadata - */ -@ApiModel(description = "Object including a page of members of a group and pagination metadata") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class GroupContents { - public static final String SERIALIZED_NAME_ENTRIES = "entries"; - @SerializedName(SERIALIZED_NAME_ENTRIES) - private List entries = null; - - public static final String SERIALIZED_NAME_PAGINATION_METADATA = "pagination_metadata"; - @SerializedName(SERIALIZED_NAME_PAGINATION_METADATA) - private PaginationMetadata paginationMetadata; - - public GroupContents() { - } - - public GroupContents entries(List entries) { - - this.entries = entries; - return this; - } - - public GroupContents addEntriesItem(GroupEntry entriesItem) { - if (this.entries == null) { - this.entries = new ArrayList<>(); - } - this.entries.add(entriesItem); - return this; - } - - /** - * Groups members - * @return entries - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Groups members") - - public List getEntries() { - return entries; - } - - - public void setEntries(List entries) { - this.entries = entries; - } - - - public GroupContents paginationMetadata(PaginationMetadata paginationMetadata) { - - this.paginationMetadata = paginationMetadata; - return this; - } - - /** - * Get paginationMetadata - * @return paginationMetadata - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public PaginationMetadata getPaginationMetadata() { - return paginationMetadata; - } - - - public void setPaginationMetadata(PaginationMetadata paginationMetadata) { - this.paginationMetadata = paginationMetadata; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public GroupContents putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - GroupContents groupContents = (GroupContents) o; - return Objects.equals(this.entries, groupContents.entries) && - Objects.equals(this.paginationMetadata, groupContents.paginationMetadata)&& - Objects.equals(this.additionalProperties, groupContents.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(entries, paginationMetadata, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class GroupContents {\n"); - sb.append(" entries: ").append(toIndentedString(entries)).append("\n"); - sb.append(" paginationMetadata: ").append(toIndentedString(paginationMetadata)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("entries"); - openapiFields.add("pagination_metadata"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to GroupContents - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (GroupContents.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in GroupContents is not found in the empty JSON string", GroupContents.openapiRequiredFields.toString())); - } - } - JsonArray jsonArrayentries = jsonObj.getAsJsonArray("entries"); - if (jsonArrayentries != null) { - // ensure the json data is an array - if (!jsonObj.get("entries").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `entries` to be an array in the JSON string but got `%s`", jsonObj.get("entries").toString())); - } - - // validate the optional field `entries` (array) - for (int i = 0; i < jsonArrayentries.size(); i++) { - GroupEntry.validateJsonObject(jsonArrayentries.get(i).getAsJsonObject()); - }; - } - // validate the optional field `pagination_metadata` - if (jsonObj.get("pagination_metadata") != null && !jsonObj.get("pagination_metadata").isJsonNull()) { - PaginationMetadata.validateJsonObject(jsonObj.getAsJsonObject("pagination_metadata")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!GroupContents.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'GroupContents' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(GroupContents.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, GroupContents value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public GroupContents read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - GroupContents instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of GroupContents given an JSON string - * - * @param jsonString JSON string - * @return An instance of GroupContents - * @throws IOException if the JSON string is invalid with respect to GroupContents - */ - public static GroupContents fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, GroupContents.class); - } - - /** - * Convert an instance of GroupContents to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupContentsFilterData.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupContentsFilterData.java deleted file mode 100644 index a94a6d3..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupContentsFilterData.java +++ /dev/null @@ -1,276 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Object with data to fill contents filter - */ -@ApiModel(description = "Object with data to fill contents filter") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class GroupContentsFilterData { - public static final String SERIALIZED_NAME_NAMESPACES = "namespaces"; - @SerializedName(SERIALIZED_NAME_NAMESPACES) - private List namespaces = null; - - public GroupContentsFilterData() { - } - - public GroupContentsFilterData namespaces(List namespaces) { - - this.namespaces = namespaces; - return this; - } - - public GroupContentsFilterData addNamespacesItem(String namespacesItem) { - if (this.namespaces == null) { - this.namespaces = new ArrayList<>(); - } - this.namespaces.add(namespacesItem); - return this; - } - - /** - * list of all unique namespaces to display - * @return namespaces - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "list of all unique namespaces to display") - - public List getNamespaces() { - return namespaces; - } - - - public void setNamespaces(List namespaces) { - this.namespaces = namespaces; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public GroupContentsFilterData putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - GroupContentsFilterData groupContentsFilterData = (GroupContentsFilterData) o; - return Objects.equals(this.namespaces, groupContentsFilterData.namespaces)&& - Objects.equals(this.additionalProperties, groupContentsFilterData.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(namespaces, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class GroupContentsFilterData {\n"); - sb.append(" namespaces: ").append(toIndentedString(namespaces)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("namespaces"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to GroupContentsFilterData - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (GroupContentsFilterData.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in GroupContentsFilterData is not found in the empty JSON string", GroupContentsFilterData.openapiRequiredFields.toString())); - } - } - // ensure the json data is an array - if ((jsonObj.get("namespaces") != null && !jsonObj.get("namespaces").isJsonNull()) && !jsonObj.get("namespaces").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `namespaces` to be an array in the JSON string but got `%s`", jsonObj.get("namespaces").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!GroupContentsFilterData.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'GroupContentsFilterData' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(GroupContentsFilterData.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, GroupContentsFilterData value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public GroupContentsFilterData read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - GroupContentsFilterData instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of GroupContentsFilterData given an JSON string - * - * @param jsonString JSON string - * @return An instance of GroupContentsFilterData - * @throws IOException if the JSON string is invalid with respect to GroupContentsFilterData - */ - public static GroupContentsFilterData fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, GroupContentsFilterData.class); - } - - /** - * Convert an instance of GroupContentsFilterData to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupCreate.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupCreate.java deleted file mode 100644 index ed1ddc4..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupCreate.java +++ /dev/null @@ -1,540 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Initial attributes for the creation of a group. - */ -@ApiModel(description = "Initial attributes for the creation of a group.") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class GroupCreate { - public static final String SERIALIZED_NAME_DESCRIPTION = "description"; - @SerializedName(SERIALIZED_NAME_DESCRIPTION) - private String description; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_PARENT = "parent"; - @SerializedName(SERIALIZED_NAME_PARENT) - private String parent; - - public static final String SERIALIZED_NAME_URI = "uri"; - @SerializedName(SERIALIZED_NAME_URI) - private String uri; - - public static final String SERIALIZED_NAME_LOGO = "logo"; - @SerializedName(SERIALIZED_NAME_LOGO) - private String logo; - - public static final String SERIALIZED_NAME_ACCESS_CREDENTIALS_NAME = "access_credentials_name"; - @SerializedName(SERIALIZED_NAME_ACCESS_CREDENTIALS_NAME) - private String accessCredentialsName; - - public static final String SERIALIZED_NAME_TAGS = "tags"; - @SerializedName(SERIALIZED_NAME_TAGS) - private List tags = null; - - public static final String SERIALIZED_NAME_LICENSE_ID = "license_id"; - @SerializedName(SERIALIZED_NAME_LICENSE_ID) - private String licenseId; - - public static final String SERIALIZED_NAME_LICENSE_TEXT = "license_text"; - @SerializedName(SERIALIZED_NAME_LICENSE_TEXT) - private String licenseText; - - public GroupCreate() { - } - - public GroupCreate description(String description) { - - this.description = description; - return this; - } - - /** - * A human readable description of the contents of the group. - * @return description - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "A human readable description of the contents of the group.") - - public String getDescription() { - return description; - } - - - public void setDescription(String description) { - this.description = description; - } - - - public GroupCreate name(String name) { - - this.name = name; - return this; - } - - /** - * The name of the group. If must be unique within the group. - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The name of the group. If must be unique within the group.") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public GroupCreate parent(String parent) { - - this.parent = parent; - return this; - } - - /** - * The unique name or id of the parent of the group. If empty, then the new group will be a top level group. - * @return parent - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The unique name or id of the parent of the group. If empty, then the new group will be a top level group.") - - public String getParent() { - return parent; - } - - - public void setParent(String parent) { - this.parent = parent; - } - - - public GroupCreate uri(String uri) { - - this.uri = uri; - return this; - } - - /** - * uri of group. - * @return uri - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "uri of group.") - - public String getUri() { - return uri; - } - - - public void setUri(String uri) { - this.uri = uri; - } - - - public GroupCreate logo(String logo) { - - this.logo = logo; - return this; - } - - /** - * logo (base64 encoded) for the group. Optional - * @return logo - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "logo (base64 encoded) for the group. Optional") - - public String getLogo() { - return logo; - } - - - public void setLogo(String logo) { - this.logo = logo; - } - - - public GroupCreate accessCredentialsName(String accessCredentialsName) { - - this.accessCredentialsName = accessCredentialsName; - return this; - } - - /** - * the name of the access credentials to use. if unset, the default credentials will be used. - * @return accessCredentialsName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "the name of the access credentials to use. if unset, the default credentials will be used.") - - public String getAccessCredentialsName() { - return accessCredentialsName; - } - - - public void setAccessCredentialsName(String accessCredentialsName) { - this.accessCredentialsName = accessCredentialsName; - } - - - public GroupCreate tags(List tags) { - - this.tags = tags; - return this; - } - - public GroupCreate addTagsItem(String tagsItem) { - if (this.tags == null) { - this.tags = new ArrayList<>(); - } - this.tags.add(tagsItem); - return this; - } - - /** - * optional tags for groups. - * @return tags - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "optional tags for groups.") - - public List getTags() { - return tags; - } - - - public void setTags(List tags) { - this.tags = tags; - } - - - public GroupCreate licenseId(String licenseId) { - - this.licenseId = licenseId; - return this; - } - - /** - * License identifier from SPDX License List or Custom. - * @return licenseId - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "License identifier from SPDX License List or Custom.") - - public String getLicenseId() { - return licenseId; - } - - - public void setLicenseId(String licenseId) { - this.licenseId = licenseId; - } - - - public GroupCreate licenseText(String licenseText) { - - this.licenseText = licenseText; - return this; - } - - /** - * License text - * @return licenseText - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "License text") - - public String getLicenseText() { - return licenseText; - } - - - public void setLicenseText(String licenseText) { - this.licenseText = licenseText; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public GroupCreate putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - GroupCreate groupCreate = (GroupCreate) o; - return Objects.equals(this.description, groupCreate.description) && - Objects.equals(this.name, groupCreate.name) && - Objects.equals(this.parent, groupCreate.parent) && - Objects.equals(this.uri, groupCreate.uri) && - Objects.equals(this.logo, groupCreate.logo) && - Objects.equals(this.accessCredentialsName, groupCreate.accessCredentialsName) && - Objects.equals(this.tags, groupCreate.tags) && - Objects.equals(this.licenseId, groupCreate.licenseId) && - Objects.equals(this.licenseText, groupCreate.licenseText)&& - Objects.equals(this.additionalProperties, groupCreate.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(description, name, parent, uri, logo, accessCredentialsName, tags, licenseId, licenseText, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class GroupCreate {\n"); - sb.append(" description: ").append(toIndentedString(description)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" parent: ").append(toIndentedString(parent)).append("\n"); - sb.append(" uri: ").append(toIndentedString(uri)).append("\n"); - sb.append(" logo: ").append(toIndentedString(logo)).append("\n"); - sb.append(" accessCredentialsName: ").append(toIndentedString(accessCredentialsName)).append("\n"); - sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); - sb.append(" licenseId: ").append(toIndentedString(licenseId)).append("\n"); - sb.append(" licenseText: ").append(toIndentedString(licenseText)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("description"); - openapiFields.add("name"); - openapiFields.add("parent"); - openapiFields.add("uri"); - openapiFields.add("logo"); - openapiFields.add("access_credentials_name"); - openapiFields.add("tags"); - openapiFields.add("license_id"); - openapiFields.add("license_text"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to GroupCreate - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (GroupCreate.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in GroupCreate is not found in the empty JSON string", GroupCreate.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("description") != null && !jsonObj.get("description").isJsonNull()) && !jsonObj.get("description").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `description` to be a primitive type in the JSON string but got `%s`", jsonObj.get("description").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - if ((jsonObj.get("parent") != null && !jsonObj.get("parent").isJsonNull()) && !jsonObj.get("parent").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `parent` to be a primitive type in the JSON string but got `%s`", jsonObj.get("parent").toString())); - } - if ((jsonObj.get("uri") != null && !jsonObj.get("uri").isJsonNull()) && !jsonObj.get("uri").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `uri` to be a primitive type in the JSON string but got `%s`", jsonObj.get("uri").toString())); - } - if ((jsonObj.get("logo") != null && !jsonObj.get("logo").isJsonNull()) && !jsonObj.get("logo").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `logo` to be a primitive type in the JSON string but got `%s`", jsonObj.get("logo").toString())); - } - if ((jsonObj.get("access_credentials_name") != null && !jsonObj.get("access_credentials_name").isJsonNull()) && !jsonObj.get("access_credentials_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `access_credentials_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("access_credentials_name").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("tags") != null && !jsonObj.get("tags").isJsonNull()) && !jsonObj.get("tags").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `tags` to be an array in the JSON string but got `%s`", jsonObj.get("tags").toString())); - } - if ((jsonObj.get("license_id") != null && !jsonObj.get("license_id").isJsonNull()) && !jsonObj.get("license_id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `license_id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("license_id").toString())); - } - if ((jsonObj.get("license_text") != null && !jsonObj.get("license_text").isJsonNull()) && !jsonObj.get("license_text").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `license_text` to be a primitive type in the JSON string but got `%s`", jsonObj.get("license_text").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!GroupCreate.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'GroupCreate' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(GroupCreate.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, GroupCreate value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public GroupCreate read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - GroupCreate instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of GroupCreate given an JSON string - * - * @param jsonString JSON string - * @return An instance of GroupCreate - * @throws IOException if the JSON string is invalid with respect to GroupCreate - */ - public static GroupCreate fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, GroupCreate.class); - } - - /** - * Convert an instance of GroupCreate to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupEntry.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupEntry.java deleted file mode 100644 index ffbe4b2..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupEntry.java +++ /dev/null @@ -1,332 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Object describing a single member of a group, which can be an array or a group - */ -@ApiModel(description = "Object describing a single member of a group, which can be an array or a group") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class GroupEntry { - public static final String SERIALIZED_NAME_MEMBER_ID = "member_id"; - @SerializedName(SERIALIZED_NAME_MEMBER_ID) - private String memberId; - - public static final String SERIALIZED_NAME_GROUP = "group"; - @SerializedName(SERIALIZED_NAME_GROUP) - private GroupInfo group; - - public static final String SERIALIZED_NAME_ARRAY = "array"; - @SerializedName(SERIALIZED_NAME_ARRAY) - private ArrayInfo array; - - public GroupEntry() { - } - - - public GroupEntry( - String memberId - ) { - this(); - this.memberId = memberId; - } - - /** - * The unique member id for the entry - * @return memberId - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The unique member id for the entry") - - public String getMemberId() { - return memberId; - } - - - - - public GroupEntry group(GroupInfo group) { - - this.group = group; - return this; - } - - /** - * Get group - * @return group - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public GroupInfo getGroup() { - return group; - } - - - public void setGroup(GroupInfo group) { - this.group = group; - } - - - public GroupEntry array(ArrayInfo array) { - - this.array = array; - return this; - } - - /** - * Get array - * @return array - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public ArrayInfo getArray() { - return array; - } - - - public void setArray(ArrayInfo array) { - this.array = array; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public GroupEntry putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - GroupEntry groupEntry = (GroupEntry) o; - return Objects.equals(this.memberId, groupEntry.memberId) && - Objects.equals(this.group, groupEntry.group) && - Objects.equals(this.array, groupEntry.array)&& - Objects.equals(this.additionalProperties, groupEntry.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(memberId, group, array, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class GroupEntry {\n"); - sb.append(" memberId: ").append(toIndentedString(memberId)).append("\n"); - sb.append(" group: ").append(toIndentedString(group)).append("\n"); - sb.append(" array: ").append(toIndentedString(array)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("member_id"); - openapiFields.add("group"); - openapiFields.add("array"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to GroupEntry - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (GroupEntry.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in GroupEntry is not found in the empty JSON string", GroupEntry.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("member_id") != null && !jsonObj.get("member_id").isJsonNull()) && !jsonObj.get("member_id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `member_id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("member_id").toString())); - } - // validate the optional field `group` - if (jsonObj.get("group") != null && !jsonObj.get("group").isJsonNull()) { - GroupInfo.validateJsonObject(jsonObj.getAsJsonObject("group")); - } - // validate the optional field `array` - if (jsonObj.get("array") != null && !jsonObj.get("array").isJsonNull()) { - ArrayInfo.validateJsonObject(jsonObj.getAsJsonObject("array")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!GroupEntry.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'GroupEntry' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(GroupEntry.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, GroupEntry value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public GroupEntry read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - GroupEntry instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of GroupEntry given an JSON string - * - * @param jsonString JSON string - * @return An instance of GroupEntry - * @throws IOException if the JSON string is invalid with respect to GroupEntry - */ - public static GroupEntry fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, GroupEntry.class); - } - - /** - * Convert an instance of GroupEntry to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupInfo.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupInfo.java deleted file mode 100644 index 08044e9..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupInfo.java +++ /dev/null @@ -1,873 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.math.BigDecimal; -import java.time.OffsetDateTime; -import java.util.ArrayList; -import java.util.List; - -import org.openapitools.jackson.nullable.JsonNullable; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * metadata of a group - */ -@ApiModel(description = "metadata of a group") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class GroupInfo { - public static final String SERIALIZED_NAME_ID = "id"; - @SerializedName(SERIALIZED_NAME_ID) - private String id; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_DESCRIPTION = "description"; - @SerializedName(SERIALIZED_NAME_DESCRIPTION) - private String description; - - public static final String SERIALIZED_NAME_URI = "uri"; - @SerializedName(SERIALIZED_NAME_URI) - private String uri; - - public static final String SERIALIZED_NAME_TILEDB_URI = "tiledb_uri"; - @SerializedName(SERIALIZED_NAME_TILEDB_URI) - private String tiledbUri; - - public static final String SERIALIZED_NAME_ASSET_COUNT = "asset_count"; - @SerializedName(SERIALIZED_NAME_ASSET_COUNT) - private BigDecimal assetCount; - - public static final String SERIALIZED_NAME_GROUP_COUNT = "group_count"; - @SerializedName(SERIALIZED_NAME_GROUP_COUNT) - private BigDecimal groupCount; - - public static final String SERIALIZED_NAME_SIZE = "size"; - @SerializedName(SERIALIZED_NAME_SIZE) - private BigDecimal size; - - public static final String SERIALIZED_NAME_LAST_ACCESSED = "last_accessed"; - @SerializedName(SERIALIZED_NAME_LAST_ACCESSED) - private OffsetDateTime lastAccessed; - - public static final String SERIALIZED_NAME_ALLOWED_ACTIONS = "allowed_actions"; - @SerializedName(SERIALIZED_NAME_ALLOWED_ACTIONS) - private List allowedActions = null; - - public static final String SERIALIZED_NAME_GROUP_TYPE = "group_type"; - @SerializedName(SERIALIZED_NAME_GROUP_TYPE) - private GroupType groupType; - - public static final String SERIALIZED_NAME_LOGO = "logo"; - @SerializedName(SERIALIZED_NAME_LOGO) - private String logo; - - public static final String SERIALIZED_NAME_ACCESS_CREDENTIALS_NAME = "access_credentials_name"; - @SerializedName(SERIALIZED_NAME_ACCESS_CREDENTIALS_NAME) - private String accessCredentialsName; - - public static final String SERIALIZED_NAME_SHARE_COUNT = "share_count"; - @SerializedName(SERIALIZED_NAME_SHARE_COUNT) - private BigDecimal shareCount; - - public static final String SERIALIZED_NAME_PUBLIC_SHARE = "public_share"; - @SerializedName(SERIALIZED_NAME_PUBLIC_SHARE) - private Boolean publicShare; - - public static final String SERIALIZED_NAME_TAGS = "tags"; - @SerializedName(SERIALIZED_NAME_TAGS) - private List tags = null; - - public static final String SERIALIZED_NAME_LICENSE_ID = "license_id"; - @SerializedName(SERIALIZED_NAME_LICENSE_ID) - private String licenseId; - - public static final String SERIALIZED_NAME_LICENSE_TEXT = "license_text"; - @SerializedName(SERIALIZED_NAME_LICENSE_TEXT) - private String licenseText; - - public GroupInfo() { - } - - public GroupInfo id(String id) { - - this.id = id; - return this; - } - - /** - * unique ID of registered group - * @return id - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "unique ID of registered group") - - public String getId() { - return id; - } - - - public void setId(String id) { - this.id = id; - } - - - public GroupInfo namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * namespace group is in - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "user1", value = "namespace group is in") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - - public GroupInfo name(String name) { - - this.name = name; - return this; - } - - /** - * name of group - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "myarray1", value = "name of group") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public GroupInfo description(String description) { - - this.description = description; - return this; - } - - /** - * description of group - * @return description - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "description of group") - - public String getDescription() { - return description; - } - - - public void setDescription(String description) { - this.description = description; - } - - - public GroupInfo uri(String uri) { - - this.uri = uri; - return this; - } - - /** - * uri of group - * @return uri - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "s3://bucket/asset", value = "uri of group") - - public String getUri() { - return uri; - } - - - public void setUri(String uri) { - this.uri = uri; - } - - - public GroupInfo tiledbUri(String tiledbUri) { - - this.tiledbUri = tiledbUri; - return this; - } - - /** - * uri for access through TileDB cloud - * @return tiledbUri - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "uri for access through TileDB cloud") - - public String getTiledbUri() { - return tiledbUri; - } - - - public void setTiledbUri(String tiledbUri) { - this.tiledbUri = tiledbUri; - } - - - public GroupInfo assetCount(BigDecimal assetCount) { - - this.assetCount = assetCount; - return this; - } - - /** - * A count of direct array members - * @return assetCount - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "12.0", value = "A count of direct array members") - - public BigDecimal getAssetCount() { - return assetCount; - } - - - public void setAssetCount(BigDecimal assetCount) { - this.assetCount = assetCount; - } - - - public GroupInfo groupCount(BigDecimal groupCount) { - - this.groupCount = groupCount; - return this; - } - - /** - * A count of direct group members - * @return groupCount - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "4.0", value = "A count of direct group members") - - public BigDecimal getGroupCount() { - return groupCount; - } - - - public void setGroupCount(BigDecimal groupCount) { - this.groupCount = groupCount; - } - - - public GroupInfo size(BigDecimal size) { - - this.size = size; - return this; - } - - /** - * A count of direct members. This is the sum of asset_count and group_count - * @return size - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "16.0", value = "A count of direct members. This is the sum of asset_count and group_count") - - public BigDecimal getSize() { - return size; - } - - - public void setSize(BigDecimal size) { - this.size = size; - } - - - public GroupInfo lastAccessed(OffsetDateTime lastAccessed) { - - this.lastAccessed = lastAccessed; - return this; - } - - /** - * Datetime groups was last accessed in UTC - * @return lastAccessed - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Datetime groups was last accessed in UTC") - - public OffsetDateTime getLastAccessed() { - return lastAccessed; - } - - - public void setLastAccessed(OffsetDateTime lastAccessed) { - this.lastAccessed = lastAccessed; - } - - - public GroupInfo allowedActions(List allowedActions) { - - this.allowedActions = allowedActions; - return this; - } - - public GroupInfo addAllowedActionsItem(GroupActions allowedActionsItem) { - if (this.allowedActions == null) { - this.allowedActions = new ArrayList<>(); - } - this.allowedActions.add(allowedActionsItem); - return this; - } - - /** - * list of actions user is allowed to do on this group - * @return allowedActions - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "list of actions user is allowed to do on this group") - - public List getAllowedActions() { - return allowedActions; - } - - - public void setAllowedActions(List allowedActions) { - this.allowedActions = allowedActions; - } - - - public GroupInfo groupType(GroupType groupType) { - - this.groupType = groupType; - return this; - } - - /** - * Get groupType - * @return groupType - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public GroupType getGroupType() { - return groupType; - } - - - public void setGroupType(GroupType groupType) { - this.groupType = groupType; - } - - - public GroupInfo logo(String logo) { - - this.logo = logo; - return this; - } - - /** - * logo (base64 encoded) for the gruop. Optional - * @return logo - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "logo (base64 encoded) for the gruop. Optional") - - public String getLogo() { - return logo; - } - - - public void setLogo(String logo) { - this.logo = logo; - } - - - public GroupInfo accessCredentialsName(String accessCredentialsName) { - - this.accessCredentialsName = accessCredentialsName; - return this; - } - - /** - * the name of the access credentials to use. if unset, the default credentials will be used - * @return accessCredentialsName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "the name of the access credentials to use. if unset, the default credentials will be used") - - public String getAccessCredentialsName() { - return accessCredentialsName; - } - - - public void setAccessCredentialsName(String accessCredentialsName) { - this.accessCredentialsName = accessCredentialsName; - } - - - public GroupInfo shareCount(BigDecimal shareCount) { - - this.shareCount = shareCount; - return this; - } - - /** - * number of unique namespaces this group is shared with - * @return shareCount - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "number of unique namespaces this group is shared with") - - public BigDecimal getShareCount() { - return shareCount; - } - - - public void setShareCount(BigDecimal shareCount) { - this.shareCount = shareCount; - } - - - public GroupInfo publicShare(Boolean publicShare) { - - this.publicShare = publicShare; - return this; - } - - /** - * Suggests if the group was shared to public by owner - * @return publicShare - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "true", value = "Suggests if the group was shared to public by owner") - - public Boolean getPublicShare() { - return publicShare; - } - - - public void setPublicShare(Boolean publicShare) { - this.publicShare = publicShare; - } - - - public GroupInfo tags(List tags) { - - this.tags = tags; - return this; - } - - public GroupInfo addTagsItem(String tagsItem) { - if (this.tags == null) { - this.tags = new ArrayList<>(); - } - this.tags.add(tagsItem); - return this; - } - - /** - * optional tags for group - * @return tags - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "optional tags for group") - - public List getTags() { - return tags; - } - - - public void setTags(List tags) { - this.tags = tags; - } - - - public GroupInfo licenseId(String licenseId) { - - this.licenseId = licenseId; - return this; - } - - /** - * License identifier from SPDX License List or Custom - * @return licenseId - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "License identifier from SPDX License List or Custom") - - public String getLicenseId() { - return licenseId; - } - - - public void setLicenseId(String licenseId) { - this.licenseId = licenseId; - } - - - public GroupInfo licenseText(String licenseText) { - - this.licenseText = licenseText; - return this; - } - - /** - * License text - * @return licenseText - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "License text") - - public String getLicenseText() { - return licenseText; - } - - - public void setLicenseText(String licenseText) { - this.licenseText = licenseText; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public GroupInfo putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - GroupInfo groupInfo = (GroupInfo) o; - return Objects.equals(this.id, groupInfo.id) && - Objects.equals(this.namespace, groupInfo.namespace) && - Objects.equals(this.name, groupInfo.name) && - Objects.equals(this.description, groupInfo.description) && - Objects.equals(this.uri, groupInfo.uri) && - Objects.equals(this.tiledbUri, groupInfo.tiledbUri) && - Objects.equals(this.assetCount, groupInfo.assetCount) && - Objects.equals(this.groupCount, groupInfo.groupCount) && - Objects.equals(this.size, groupInfo.size) && - Objects.equals(this.lastAccessed, groupInfo.lastAccessed) && - Objects.equals(this.allowedActions, groupInfo.allowedActions) && - Objects.equals(this.groupType, groupInfo.groupType) && - Objects.equals(this.logo, groupInfo.logo) && - Objects.equals(this.accessCredentialsName, groupInfo.accessCredentialsName) && - Objects.equals(this.shareCount, groupInfo.shareCount) && - Objects.equals(this.publicShare, groupInfo.publicShare) && - Objects.equals(this.tags, groupInfo.tags) && - Objects.equals(this.licenseId, groupInfo.licenseId) && - Objects.equals(this.licenseText, groupInfo.licenseText)&& - Objects.equals(this.additionalProperties, groupInfo.additionalProperties); - } - - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); - } - - @Override - public int hashCode() { - return Objects.hash(id, namespace, name, description, uri, tiledbUri, assetCount, groupCount, size, lastAccessed, allowedActions, groupType, logo, accessCredentialsName, shareCount, publicShare, tags, licenseId, licenseText, additionalProperties); - } - - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class GroupInfo {\n"); - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" description: ").append(toIndentedString(description)).append("\n"); - sb.append(" uri: ").append(toIndentedString(uri)).append("\n"); - sb.append(" tiledbUri: ").append(toIndentedString(tiledbUri)).append("\n"); - sb.append(" assetCount: ").append(toIndentedString(assetCount)).append("\n"); - sb.append(" groupCount: ").append(toIndentedString(groupCount)).append("\n"); - sb.append(" size: ").append(toIndentedString(size)).append("\n"); - sb.append(" lastAccessed: ").append(toIndentedString(lastAccessed)).append("\n"); - sb.append(" allowedActions: ").append(toIndentedString(allowedActions)).append("\n"); - sb.append(" groupType: ").append(toIndentedString(groupType)).append("\n"); - sb.append(" logo: ").append(toIndentedString(logo)).append("\n"); - sb.append(" accessCredentialsName: ").append(toIndentedString(accessCredentialsName)).append("\n"); - sb.append(" shareCount: ").append(toIndentedString(shareCount)).append("\n"); - sb.append(" publicShare: ").append(toIndentedString(publicShare)).append("\n"); - sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); - sb.append(" licenseId: ").append(toIndentedString(licenseId)).append("\n"); - sb.append(" licenseText: ").append(toIndentedString(licenseText)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("id"); - openapiFields.add("namespace"); - openapiFields.add("name"); - openapiFields.add("description"); - openapiFields.add("uri"); - openapiFields.add("tiledb_uri"); - openapiFields.add("asset_count"); - openapiFields.add("group_count"); - openapiFields.add("size"); - openapiFields.add("last_accessed"); - openapiFields.add("allowed_actions"); - openapiFields.add("group_type"); - openapiFields.add("logo"); - openapiFields.add("access_credentials_name"); - openapiFields.add("share_count"); - openapiFields.add("public_share"); - openapiFields.add("tags"); - openapiFields.add("license_id"); - openapiFields.add("license_text"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to GroupInfo - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (GroupInfo.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in GroupInfo is not found in the empty JSON string", GroupInfo.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) && !jsonObj.get("id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("id").toString())); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - if ((jsonObj.get("description") != null && !jsonObj.get("description").isJsonNull()) && !jsonObj.get("description").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `description` to be a primitive type in the JSON string but got `%s`", jsonObj.get("description").toString())); - } - if ((jsonObj.get("uri") != null && !jsonObj.get("uri").isJsonNull()) && !jsonObj.get("uri").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `uri` to be a primitive type in the JSON string but got `%s`", jsonObj.get("uri").toString())); - } - if ((jsonObj.get("tiledb_uri") != null && !jsonObj.get("tiledb_uri").isJsonNull()) && !jsonObj.get("tiledb_uri").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `tiledb_uri` to be a primitive type in the JSON string but got `%s`", jsonObj.get("tiledb_uri").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("allowed_actions") != null && !jsonObj.get("allowed_actions").isJsonNull()) && !jsonObj.get("allowed_actions").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `allowed_actions` to be an array in the JSON string but got `%s`", jsonObj.get("allowed_actions").toString())); - } - if ((jsonObj.get("logo") != null && !jsonObj.get("logo").isJsonNull()) && !jsonObj.get("logo").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `logo` to be a primitive type in the JSON string but got `%s`", jsonObj.get("logo").toString())); - } - if ((jsonObj.get("access_credentials_name") != null && !jsonObj.get("access_credentials_name").isJsonNull()) && !jsonObj.get("access_credentials_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `access_credentials_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("access_credentials_name").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("tags") != null && !jsonObj.get("tags").isJsonNull()) && !jsonObj.get("tags").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `tags` to be an array in the JSON string but got `%s`", jsonObj.get("tags").toString())); - } - if ((jsonObj.get("license_id") != null && !jsonObj.get("license_id").isJsonNull()) && !jsonObj.get("license_id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `license_id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("license_id").toString())); - } - if ((jsonObj.get("license_text") != null && !jsonObj.get("license_text").isJsonNull()) && !jsonObj.get("license_text").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `license_text` to be a primitive type in the JSON string but got `%s`", jsonObj.get("license_text").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!GroupInfo.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'GroupInfo' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(GroupInfo.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, GroupInfo value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public GroupInfo read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - GroupInfo instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of GroupInfo given an JSON string - * - * @param jsonString JSON string - * @return An instance of GroupInfo - * @throws IOException if the JSON string is invalid with respect to GroupInfo - */ - public static GroupInfo fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, GroupInfo.class); - } - - /** - * Convert an instance of GroupInfo to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupMember.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupMember.java deleted file mode 100644 index b50a376..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupMember.java +++ /dev/null @@ -1,328 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * A groups member, array or another groups, to add or remove from an existing group. - */ -@ApiModel(description = "A groups member, array or another groups, to add or remove from an existing group.") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class GroupMember { - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_MEMBER_TYPE = "member_type"; - @SerializedName(SERIALIZED_NAME_MEMBER_TYPE) - private GroupMemberType memberType; - - public GroupMember() { - } - - public GroupMember namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * The namespace of the asset. - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The namespace of the asset.") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - - public GroupMember name(String name) { - - this.name = name; - return this; - } - - /** - * The name or id of the asset. - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The name or id of the asset.") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public GroupMember memberType(GroupMemberType memberType) { - - this.memberType = memberType; - return this; - } - - /** - * Get memberType - * @return memberType - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public GroupMemberType getMemberType() { - return memberType; - } - - - public void setMemberType(GroupMemberType memberType) { - this.memberType = memberType; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public GroupMember putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - GroupMember groupMember = (GroupMember) o; - return Objects.equals(this.namespace, groupMember.namespace) && - Objects.equals(this.name, groupMember.name) && - Objects.equals(this.memberType, groupMember.memberType)&& - Objects.equals(this.additionalProperties, groupMember.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(namespace, name, memberType, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class GroupMember {\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" memberType: ").append(toIndentedString(memberType)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("namespace"); - openapiFields.add("name"); - openapiFields.add("member_type"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to GroupMember - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (GroupMember.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in GroupMember is not found in the empty JSON string", GroupMember.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!GroupMember.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'GroupMember' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(GroupMember.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, GroupMember value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public GroupMember read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - GroupMember instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of GroupMember given an JSON string - * - * @param jsonString JSON string - * @return An instance of GroupMember - * @throws IOException if the JSON string is invalid with respect to GroupMember - */ - public static GroupMember fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, GroupMember.class); - } - - /** - * Convert an instance of GroupMember to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupMemberAssetType.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupMemberAssetType.java deleted file mode 100644 index 8243b5a..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupMemberAssetType.java +++ /dev/null @@ -1,93 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * Specific file types of group members - */ -@JsonAdapter(GroupMemberAssetType.Adapter.class) -public enum GroupMemberAssetType { - - GROUP("group"), - - ARRAY("array"), - - NOTEBOOK("notebook"), - - DASHBOARD("dashboard"), - - USER_DEFINED_FUNCTION("user_defined_function"), - - ML_MODEL("ml_model"), - - FILE("file"), - - BIOIMG("bioimg"), - - SOMA("soma"), - - VCF("vcf"), - - POINTCLOUD("pointcloud"), - - RASTER("raster"), - - GEOMETRY("geometry"), - - VECTOR_SEARCH("vector_search"); - - private String value; - - GroupMemberAssetType(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static GroupMemberAssetType fromValue(String value) { - for (GroupMemberAssetType b : GroupMemberAssetType.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final GroupMemberAssetType enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public GroupMemberAssetType read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return GroupMemberAssetType.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupMemberType.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupMemberType.java deleted file mode 100644 index de1b67b..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupMemberType.java +++ /dev/null @@ -1,69 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * File types that can be included in groups - */ -@JsonAdapter(GroupMemberType.Adapter.class) -public enum GroupMemberType { - - GROUP("group"), - - ARRAY("array"); - - private String value; - - GroupMemberType(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static GroupMemberType fromValue(String value) { - for (GroupMemberType b : GroupMemberType.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final GroupMemberType enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public GroupMemberType read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return GroupMemberType.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupRegister.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupRegister.java deleted file mode 100644 index 5f845eb..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupRegister.java +++ /dev/null @@ -1,540 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Initial attributes for the registration of a an existing group. - */ -@ApiModel(description = "Initial attributes for the registration of a an existing group.") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class GroupRegister { - public static final String SERIALIZED_NAME_DESCRIPTION = "description"; - @SerializedName(SERIALIZED_NAME_DESCRIPTION) - private String description; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_PARENT = "parent"; - @SerializedName(SERIALIZED_NAME_PARENT) - private String parent; - - public static final String SERIALIZED_NAME_URI = "uri"; - @SerializedName(SERIALIZED_NAME_URI) - private String uri; - - public static final String SERIALIZED_NAME_LOGO = "logo"; - @SerializedName(SERIALIZED_NAME_LOGO) - private String logo; - - public static final String SERIALIZED_NAME_ACCESS_CREDENTIALS_NAME = "access_credentials_name"; - @SerializedName(SERIALIZED_NAME_ACCESS_CREDENTIALS_NAME) - private String accessCredentialsName; - - public static final String SERIALIZED_NAME_TAGS = "tags"; - @SerializedName(SERIALIZED_NAME_TAGS) - private List tags = null; - - public static final String SERIALIZED_NAME_LICENSE_ID = "license_id"; - @SerializedName(SERIALIZED_NAME_LICENSE_ID) - private String licenseId; - - public static final String SERIALIZED_NAME_LICENSE_TEXT = "license_text"; - @SerializedName(SERIALIZED_NAME_LICENSE_TEXT) - private String licenseText; - - public GroupRegister() { - } - - public GroupRegister description(String description) { - - this.description = description; - return this; - } - - /** - * A human readable description of the contents of the group. - * @return description - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "A human readable description of the contents of the group.") - - public String getDescription() { - return description; - } - - - public void setDescription(String description) { - this.description = description; - } - - - public GroupRegister name(String name) { - - this.name = name; - return this; - } - - /** - * The name of the group. If must be unique within the group. - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The name of the group. If must be unique within the group.") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public GroupRegister parent(String parent) { - - this.parent = parent; - return this; - } - - /** - * The unique name or id of the parent of the group. If empty, then the new group will be a top level group. - * @return parent - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The unique name or id of the parent of the group. If empty, then the new group will be a top level group.") - - public String getParent() { - return parent; - } - - - public void setParent(String parent) { - this.parent = parent; - } - - - public GroupRegister uri(String uri) { - - this.uri = uri; - return this; - } - - /** - * uri of group. - * @return uri - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "uri of group.") - - public String getUri() { - return uri; - } - - - public void setUri(String uri) { - this.uri = uri; - } - - - public GroupRegister logo(String logo) { - - this.logo = logo; - return this; - } - - /** - * logo (base64 encoded) for the group. Optional - * @return logo - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "logo (base64 encoded) for the group. Optional") - - public String getLogo() { - return logo; - } - - - public void setLogo(String logo) { - this.logo = logo; - } - - - public GroupRegister accessCredentialsName(String accessCredentialsName) { - - this.accessCredentialsName = accessCredentialsName; - return this; - } - - /** - * the name of the access credentials to use. if unset, the default credentials will be used. - * @return accessCredentialsName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "the name of the access credentials to use. if unset, the default credentials will be used.") - - public String getAccessCredentialsName() { - return accessCredentialsName; - } - - - public void setAccessCredentialsName(String accessCredentialsName) { - this.accessCredentialsName = accessCredentialsName; - } - - - public GroupRegister tags(List tags) { - - this.tags = tags; - return this; - } - - public GroupRegister addTagsItem(String tagsItem) { - if (this.tags == null) { - this.tags = new ArrayList<>(); - } - this.tags.add(tagsItem); - return this; - } - - /** - * optional tags for groups. - * @return tags - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "optional tags for groups.") - - public List getTags() { - return tags; - } - - - public void setTags(List tags) { - this.tags = tags; - } - - - public GroupRegister licenseId(String licenseId) { - - this.licenseId = licenseId; - return this; - } - - /** - * License identifier from SPDX License List or Custom. - * @return licenseId - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "License identifier from SPDX License List or Custom.") - - public String getLicenseId() { - return licenseId; - } - - - public void setLicenseId(String licenseId) { - this.licenseId = licenseId; - } - - - public GroupRegister licenseText(String licenseText) { - - this.licenseText = licenseText; - return this; - } - - /** - * License text - * @return licenseText - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "License text") - - public String getLicenseText() { - return licenseText; - } - - - public void setLicenseText(String licenseText) { - this.licenseText = licenseText; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public GroupRegister putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - GroupRegister groupRegister = (GroupRegister) o; - return Objects.equals(this.description, groupRegister.description) && - Objects.equals(this.name, groupRegister.name) && - Objects.equals(this.parent, groupRegister.parent) && - Objects.equals(this.uri, groupRegister.uri) && - Objects.equals(this.logo, groupRegister.logo) && - Objects.equals(this.accessCredentialsName, groupRegister.accessCredentialsName) && - Objects.equals(this.tags, groupRegister.tags) && - Objects.equals(this.licenseId, groupRegister.licenseId) && - Objects.equals(this.licenseText, groupRegister.licenseText)&& - Objects.equals(this.additionalProperties, groupRegister.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(description, name, parent, uri, logo, accessCredentialsName, tags, licenseId, licenseText, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class GroupRegister {\n"); - sb.append(" description: ").append(toIndentedString(description)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" parent: ").append(toIndentedString(parent)).append("\n"); - sb.append(" uri: ").append(toIndentedString(uri)).append("\n"); - sb.append(" logo: ").append(toIndentedString(logo)).append("\n"); - sb.append(" accessCredentialsName: ").append(toIndentedString(accessCredentialsName)).append("\n"); - sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); - sb.append(" licenseId: ").append(toIndentedString(licenseId)).append("\n"); - sb.append(" licenseText: ").append(toIndentedString(licenseText)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("description"); - openapiFields.add("name"); - openapiFields.add("parent"); - openapiFields.add("uri"); - openapiFields.add("logo"); - openapiFields.add("access_credentials_name"); - openapiFields.add("tags"); - openapiFields.add("license_id"); - openapiFields.add("license_text"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to GroupRegister - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (GroupRegister.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in GroupRegister is not found in the empty JSON string", GroupRegister.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("description") != null && !jsonObj.get("description").isJsonNull()) && !jsonObj.get("description").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `description` to be a primitive type in the JSON string but got `%s`", jsonObj.get("description").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - if ((jsonObj.get("parent") != null && !jsonObj.get("parent").isJsonNull()) && !jsonObj.get("parent").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `parent` to be a primitive type in the JSON string but got `%s`", jsonObj.get("parent").toString())); - } - if ((jsonObj.get("uri") != null && !jsonObj.get("uri").isJsonNull()) && !jsonObj.get("uri").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `uri` to be a primitive type in the JSON string but got `%s`", jsonObj.get("uri").toString())); - } - if ((jsonObj.get("logo") != null && !jsonObj.get("logo").isJsonNull()) && !jsonObj.get("logo").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `logo` to be a primitive type in the JSON string but got `%s`", jsonObj.get("logo").toString())); - } - if ((jsonObj.get("access_credentials_name") != null && !jsonObj.get("access_credentials_name").isJsonNull()) && !jsonObj.get("access_credentials_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `access_credentials_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("access_credentials_name").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("tags") != null && !jsonObj.get("tags").isJsonNull()) && !jsonObj.get("tags").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `tags` to be an array in the JSON string but got `%s`", jsonObj.get("tags").toString())); - } - if ((jsonObj.get("license_id") != null && !jsonObj.get("license_id").isJsonNull()) && !jsonObj.get("license_id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `license_id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("license_id").toString())); - } - if ((jsonObj.get("license_text") != null && !jsonObj.get("license_text").isJsonNull()) && !jsonObj.get("license_text").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `license_text` to be a primitive type in the JSON string but got `%s`", jsonObj.get("license_text").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!GroupRegister.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'GroupRegister' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(GroupRegister.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, GroupRegister value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public GroupRegister read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - GroupRegister instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of GroupRegister given an JSON string - * - * @param jsonString JSON string - * @return An instance of GroupRegister - * @throws IOException if the JSON string is invalid with respect to GroupRegister - */ - public static GroupRegister fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, GroupRegister.class); - } - - /** - * Convert an instance of GroupRegister to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupSharing.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupSharing.java deleted file mode 100644 index 206da1d..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupSharing.java +++ /dev/null @@ -1,384 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * sharing state of a group with a namespace - */ -@ApiModel(description = "sharing state of a group with a namespace") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class GroupSharing { - public static final String SERIALIZED_NAME_GROUP_ACTIONS = "group_actions"; - @SerializedName(SERIALIZED_NAME_GROUP_ACTIONS) - private List groupActions = null; - - public static final String SERIALIZED_NAME_ARRAY_ACTIONS = "array_actions"; - @SerializedName(SERIALIZED_NAME_ARRAY_ACTIONS) - private List arrayActions = null; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public static final String SERIALIZED_NAME_NAMESPACE_TYPE = "namespace_type"; - @SerializedName(SERIALIZED_NAME_NAMESPACE_TYPE) - private String namespaceType; - - public GroupSharing() { - } - - public GroupSharing groupActions(List groupActions) { - - this.groupActions = groupActions; - return this; - } - - public GroupSharing addGroupActionsItem(GroupActions groupActionsItem) { - if (this.groupActions == null) { - this.groupActions = new ArrayList<>(); - } - this.groupActions.add(groupActionsItem); - return this; - } - - /** - * List of permitted actions for the group and all subgroups - * @return groupActions - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "[read, write]", value = "List of permitted actions for the group and all subgroups") - - public List getGroupActions() { - return groupActions; - } - - - public void setGroupActions(List groupActions) { - this.groupActions = groupActions; - } - - - public GroupSharing arrayActions(List arrayActions) { - - this.arrayActions = arrayActions; - return this; - } - - public GroupSharing addArrayActionsItem(ArrayActions arrayActionsItem) { - if (this.arrayActions == null) { - this.arrayActions = new ArrayList<>(); - } - this.arrayActions.add(arrayActionsItem); - return this; - } - - /** - * List of permitted actions for all the subarrays of the group - * @return arrayActions - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "[read, write]", value = "List of permitted actions for all the subarrays of the group") - - public List getArrayActions() { - return arrayActions; - } - - - public void setArrayActions(List arrayActions) { - this.arrayActions = arrayActions; - } - - - public GroupSharing namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * namespace being granted group access can be a user or organization - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "MyOrganization", value = "namespace being granted group access can be a user or organization") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - - public GroupSharing namespaceType(String namespaceType) { - - this.namespaceType = namespaceType; - return this; - } - - /** - * details on if the namespace is a organization or user - * @return namespaceType - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "organization", value = "details on if the namespace is a organization or user") - - public String getNamespaceType() { - return namespaceType; - } - - - public void setNamespaceType(String namespaceType) { - this.namespaceType = namespaceType; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public GroupSharing putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - GroupSharing groupSharing = (GroupSharing) o; - return Objects.equals(this.groupActions, groupSharing.groupActions) && - Objects.equals(this.arrayActions, groupSharing.arrayActions) && - Objects.equals(this.namespace, groupSharing.namespace) && - Objects.equals(this.namespaceType, groupSharing.namespaceType)&& - Objects.equals(this.additionalProperties, groupSharing.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(groupActions, arrayActions, namespace, namespaceType, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class GroupSharing {\n"); - sb.append(" groupActions: ").append(toIndentedString(groupActions)).append("\n"); - sb.append(" arrayActions: ").append(toIndentedString(arrayActions)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" namespaceType: ").append(toIndentedString(namespaceType)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("group_actions"); - openapiFields.add("array_actions"); - openapiFields.add("namespace"); - openapiFields.add("namespace_type"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to GroupSharing - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (GroupSharing.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in GroupSharing is not found in the empty JSON string", GroupSharing.openapiRequiredFields.toString())); - } - } - // ensure the json data is an array - if ((jsonObj.get("group_actions") != null && !jsonObj.get("group_actions").isJsonNull()) && !jsonObj.get("group_actions").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `group_actions` to be an array in the JSON string but got `%s`", jsonObj.get("group_actions").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("array_actions") != null && !jsonObj.get("array_actions").isJsonNull()) && !jsonObj.get("array_actions").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `array_actions` to be an array in the JSON string but got `%s`", jsonObj.get("array_actions").toString())); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - if ((jsonObj.get("namespace_type") != null && !jsonObj.get("namespace_type").isJsonNull()) && !jsonObj.get("namespace_type").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace_type` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace_type").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!GroupSharing.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'GroupSharing' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(GroupSharing.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, GroupSharing value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public GroupSharing read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - GroupSharing instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of GroupSharing given an JSON string - * - * @param jsonString JSON string - * @return An instance of GroupSharing - * @throws IOException if the JSON string is invalid with respect to GroupSharing - */ - public static GroupSharing fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, GroupSharing.class); - } - - /** - * Convert an instance of GroupSharing to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupSharingRequest.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupSharingRequest.java deleted file mode 100644 index 07194a3..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupSharingRequest.java +++ /dev/null @@ -1,351 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * a request to share a group and all the contents with a namespace - */ -@ApiModel(description = "a request to share a group and all the contents with a namespace") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class GroupSharingRequest { - public static final String SERIALIZED_NAME_GROUP_ACTIONS = "group_actions"; - @SerializedName(SERIALIZED_NAME_GROUP_ACTIONS) - private List groupActions = null; - - public static final String SERIALIZED_NAME_ARRAY_ACTIONS = "array_actions"; - @SerializedName(SERIALIZED_NAME_ARRAY_ACTIONS) - private List arrayActions = null; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public GroupSharingRequest() { - } - - public GroupSharingRequest groupActions(List groupActions) { - - this.groupActions = groupActions; - return this; - } - - public GroupSharingRequest addGroupActionsItem(GroupActions groupActionsItem) { - if (this.groupActions == null) { - this.groupActions = new ArrayList<>(); - } - this.groupActions.add(groupActionsItem); - return this; - } - - /** - * List of permitted actions for the group and all subgroups - * @return groupActions - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "[read, write]", value = "List of permitted actions for the group and all subgroups") - - public List getGroupActions() { - return groupActions; - } - - - public void setGroupActions(List groupActions) { - this.groupActions = groupActions; - } - - - public GroupSharingRequest arrayActions(List arrayActions) { - - this.arrayActions = arrayActions; - return this; - } - - public GroupSharingRequest addArrayActionsItem(ArrayActions arrayActionsItem) { - if (this.arrayActions == null) { - this.arrayActions = new ArrayList<>(); - } - this.arrayActions.add(arrayActionsItem); - return this; - } - - /** - * List of permitted actions for all the subarrays of the group - * @return arrayActions - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "[read, write]", value = "List of permitted actions for all the subarrays of the group") - - public List getArrayActions() { - return arrayActions; - } - - - public void setArrayActions(List arrayActions) { - this.arrayActions = arrayActions; - } - - - public GroupSharingRequest namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * namespace being granted group access can be a user or organization - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "MyOrganization", value = "namespace being granted group access can be a user or organization") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public GroupSharingRequest putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - GroupSharingRequest groupSharingRequest = (GroupSharingRequest) o; - return Objects.equals(this.groupActions, groupSharingRequest.groupActions) && - Objects.equals(this.arrayActions, groupSharingRequest.arrayActions) && - Objects.equals(this.namespace, groupSharingRequest.namespace)&& - Objects.equals(this.additionalProperties, groupSharingRequest.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(groupActions, arrayActions, namespace, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class GroupSharingRequest {\n"); - sb.append(" groupActions: ").append(toIndentedString(groupActions)).append("\n"); - sb.append(" arrayActions: ").append(toIndentedString(arrayActions)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("group_actions"); - openapiFields.add("array_actions"); - openapiFields.add("namespace"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to GroupSharingRequest - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (GroupSharingRequest.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in GroupSharingRequest is not found in the empty JSON string", GroupSharingRequest.openapiRequiredFields.toString())); - } - } - // ensure the json data is an array - if ((jsonObj.get("group_actions") != null && !jsonObj.get("group_actions").isJsonNull()) && !jsonObj.get("group_actions").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `group_actions` to be an array in the JSON string but got `%s`", jsonObj.get("group_actions").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("array_actions") != null && !jsonObj.get("array_actions").isJsonNull()) && !jsonObj.get("array_actions").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `array_actions` to be an array in the JSON string but got `%s`", jsonObj.get("array_actions").toString())); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!GroupSharingRequest.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'GroupSharingRequest' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(GroupSharingRequest.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, GroupSharingRequest value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public GroupSharingRequest read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - GroupSharingRequest instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of GroupSharingRequest given an JSON string - * - * @param jsonString JSON string - * @return An instance of GroupSharingRequest - * @throws IOException if the JSON string is invalid with respect to GroupSharingRequest - */ - public static GroupSharingRequest fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, GroupSharingRequest.class); - } - - /** - * Convert an instance of GroupSharingRequest to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupType.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupType.java deleted file mode 100644 index 7232039..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupType.java +++ /dev/null @@ -1,81 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * Group type is a hint for the groups contents and TileDB Cloud may use a specialized viewer for each type - */ -@JsonAdapter(GroupType.Adapter.class) -public enum GroupType { - - GENERIC("generic"), - - VCF("vcf"), - - SOMA("soma"), - - BIOIMG("bioimg"), - - POINTCLOUD("pointcloud"), - - RASTER("raster"), - - GEOMETRY("geometry"), - - VECTOR_SEARCH("vector_search"); - - private String value; - - GroupType(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static GroupType fromValue(String value) { - for (GroupType b : GroupType.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final GroupType enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public GroupType read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return GroupType.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupTypeMetadataKey.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupTypeMetadataKey.java deleted file mode 100644 index 3bb4025..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupTypeMetadataKey.java +++ /dev/null @@ -1,67 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * A group type is stored in the group metadata using this key - */ -@JsonAdapter(GroupTypeMetadataKey.Adapter.class) -public enum GroupTypeMetadataKey { - - DATASET_TYPE("dataset_type"); - - private String value; - - GroupTypeMetadataKey(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static GroupTypeMetadataKey fromValue(String value) { - for (GroupTypeMetadataKey b : GroupTypeMetadataKey.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final GroupTypeMetadataKey enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public GroupTypeMetadataKey read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return GroupTypeMetadataKey.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupUpdate.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupUpdate.java deleted file mode 100644 index 889cf92..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/GroupUpdate.java +++ /dev/null @@ -1,486 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; -import org.openapitools.jackson.nullable.JsonNullable; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Updates for a group. New values for the attributes. - */ -@ApiModel(description = "Updates for a group. New values for the attributes.") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class GroupUpdate { - public static final String SERIALIZED_NAME_DESCRIPTION = "description"; - @SerializedName(SERIALIZED_NAME_DESCRIPTION) - private String description; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_LOGO = "logo"; - @SerializedName(SERIALIZED_NAME_LOGO) - private String logo; - - public static final String SERIALIZED_NAME_ACCESS_CREDENTIALS_NAME = "access_credentials_name"; - @SerializedName(SERIALIZED_NAME_ACCESS_CREDENTIALS_NAME) - private String accessCredentialsName; - - public static final String SERIALIZED_NAME_TAGS = "tags"; - @SerializedName(SERIALIZED_NAME_TAGS) - private List tags = null; - - public static final String SERIALIZED_NAME_LICENSE_ID = "license_id"; - @SerializedName(SERIALIZED_NAME_LICENSE_ID) - private String licenseId; - - public static final String SERIALIZED_NAME_LICENSE_TEXT = "license_text"; - @SerializedName(SERIALIZED_NAME_LICENSE_TEXT) - private String licenseText; - - public GroupUpdate() { - } - - public GroupUpdate description(String description) { - - this.description = description; - return this; - } - - /** - * A human readable description of the content of the group - * @return description - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "A human readable description of the content of the group") - - public String getDescription() { - return description; - } - - - public void setDescription(String description) { - this.description = description; - } - - - public GroupUpdate name(String name) { - - this.name = name; - return this; - } - - /** - * The name of the group. If must be unique within the group. - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The name of the group. If must be unique within the group.") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public GroupUpdate logo(String logo) { - - this.logo = logo; - return this; - } - - /** - * logo (base64 encoded) for the group. Optional - * @return logo - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "logo (base64 encoded) for the group. Optional") - - public String getLogo() { - return logo; - } - - - public void setLogo(String logo) { - this.logo = logo; - } - - - public GroupUpdate accessCredentialsName(String accessCredentialsName) { - - this.accessCredentialsName = accessCredentialsName; - return this; - } - - /** - * the name of the access credentials to use. if unset, the default credentials will be used - * @return accessCredentialsName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "the name of the access credentials to use. if unset, the default credentials will be used") - - public String getAccessCredentialsName() { - return accessCredentialsName; - } - - - public void setAccessCredentialsName(String accessCredentialsName) { - this.accessCredentialsName = accessCredentialsName; - } - - - public GroupUpdate tags(List tags) { - - this.tags = tags; - return this; - } - - public GroupUpdate addTagsItem(String tagsItem) { - if (this.tags == null) { - this.tags = new ArrayList<>(); - } - this.tags.add(tagsItem); - return this; - } - - /** - * optional tags for groups - * @return tags - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "optional tags for groups") - - public List getTags() { - return tags; - } - - - public void setTags(List tags) { - this.tags = tags; - } - - - public GroupUpdate licenseId(String licenseId) { - - this.licenseId = licenseId; - return this; - } - - /** - * License identifier from SPDX License List or Custom - * @return licenseId - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "License identifier from SPDX License List or Custom") - - public String getLicenseId() { - return licenseId; - } - - - public void setLicenseId(String licenseId) { - this.licenseId = licenseId; - } - - - public GroupUpdate licenseText(String licenseText) { - - this.licenseText = licenseText; - return this; - } - - /** - * License text - * @return licenseText - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "License text") - - public String getLicenseText() { - return licenseText; - } - - - public void setLicenseText(String licenseText) { - this.licenseText = licenseText; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public GroupUpdate putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - GroupUpdate groupUpdate = (GroupUpdate) o; - return Objects.equals(this.description, groupUpdate.description) && - Objects.equals(this.name, groupUpdate.name) && - Objects.equals(this.logo, groupUpdate.logo) && - Objects.equals(this.accessCredentialsName, groupUpdate.accessCredentialsName) && - Objects.equals(this.tags, groupUpdate.tags) && - Objects.equals(this.licenseId, groupUpdate.licenseId) && - Objects.equals(this.licenseText, groupUpdate.licenseText)&& - Objects.equals(this.additionalProperties, groupUpdate.additionalProperties); - } - - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); - } - - @Override - public int hashCode() { - return Objects.hash(description, name, logo, accessCredentialsName, tags, licenseId, licenseText, additionalProperties); - } - - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class GroupUpdate {\n"); - sb.append(" description: ").append(toIndentedString(description)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" logo: ").append(toIndentedString(logo)).append("\n"); - sb.append(" accessCredentialsName: ").append(toIndentedString(accessCredentialsName)).append("\n"); - sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); - sb.append(" licenseId: ").append(toIndentedString(licenseId)).append("\n"); - sb.append(" licenseText: ").append(toIndentedString(licenseText)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("description"); - openapiFields.add("name"); - openapiFields.add("logo"); - openapiFields.add("access_credentials_name"); - openapiFields.add("tags"); - openapiFields.add("license_id"); - openapiFields.add("license_text"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to GroupUpdate - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (GroupUpdate.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in GroupUpdate is not found in the empty JSON string", GroupUpdate.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("description") != null && !jsonObj.get("description").isJsonNull()) && !jsonObj.get("description").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `description` to be a primitive type in the JSON string but got `%s`", jsonObj.get("description").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - if ((jsonObj.get("logo") != null && !jsonObj.get("logo").isJsonNull()) && !jsonObj.get("logo").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `logo` to be a primitive type in the JSON string but got `%s`", jsonObj.get("logo").toString())); - } - if ((jsonObj.get("access_credentials_name") != null && !jsonObj.get("access_credentials_name").isJsonNull()) && !jsonObj.get("access_credentials_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `access_credentials_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("access_credentials_name").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("tags") != null && !jsonObj.get("tags").isJsonNull()) && !jsonObj.get("tags").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `tags` to be an array in the JSON string but got `%s`", jsonObj.get("tags").toString())); - } - if ((jsonObj.get("license_id") != null && !jsonObj.get("license_id").isJsonNull()) && !jsonObj.get("license_id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `license_id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("license_id").toString())); - } - if ((jsonObj.get("license_text") != null && !jsonObj.get("license_text").isJsonNull()) && !jsonObj.get("license_text").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `license_text` to be a primitive type in the JSON string but got `%s`", jsonObj.get("license_text").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!GroupUpdate.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'GroupUpdate' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(GroupUpdate.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, GroupUpdate value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public GroupUpdate read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - GroupUpdate instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of GroupUpdate given an JSON string - * - * @param jsonString JSON string - * @return An instance of GroupUpdate - * @throws IOException if the JSON string is invalid with respect to GroupUpdate - */ - public static GroupUpdate fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, GroupUpdate.class); - } - - /** - * Convert an instance of GroupUpdate to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Invitation.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/Invitation.java deleted file mode 100644 index bdf43c6..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Invitation.java +++ /dev/null @@ -1,875 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.time.OffsetDateTime; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Invitations to share or collaborate - */ -@ApiModel(description = "Invitations to share or collaborate") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class Invitation { - public static final String SERIALIZED_NAME_ID = "id"; - @SerializedName(SERIALIZED_NAME_ID) - private String id; - - public static final String SERIALIZED_NAME_INVITATION_TYPE = "invitation_type"; - @SerializedName(SERIALIZED_NAME_INVITATION_TYPE) - private InvitationType invitationType; - - public static final String SERIALIZED_NAME_OWNER_NAMESPACE_UUID = "owner_namespace_uuid"; - @SerializedName(SERIALIZED_NAME_OWNER_NAMESPACE_UUID) - private String ownerNamespaceUuid; - - public static final String SERIALIZED_NAME_INVITER_UUID = "inviter_uuid"; - @SerializedName(SERIALIZED_NAME_INVITER_UUID) - private String inviterUuid; - - public static final String SERIALIZED_NAME_USER_NAMESPACE_UUID = "user_namespace_uuid"; - @SerializedName(SERIALIZED_NAME_USER_NAMESPACE_UUID) - private String userNamespaceUuid; - - public static final String SERIALIZED_NAME_ORGANIZATION_USER_UUID = "organization_user_uuid"; - @SerializedName(SERIALIZED_NAME_ORGANIZATION_USER_UUID) - private String organizationUserUuid; - - public static final String SERIALIZED_NAME_ORGANIZATION_NAME = "organization_name"; - @SerializedName(SERIALIZED_NAME_ORGANIZATION_NAME) - private String organizationName; - - public static final String SERIALIZED_NAME_ORGANIZATION_ROLE = "organization_role"; - @SerializedName(SERIALIZED_NAME_ORGANIZATION_ROLE) - private OrganizationRoles organizationRole; - - public static final String SERIALIZED_NAME_ORGANIZATION_UUID = "organization_uuid"; - @SerializedName(SERIALIZED_NAME_ORGANIZATION_UUID) - private String organizationUuid; - - public static final String SERIALIZED_NAME_ARRAY_UUID = "array_uuid"; - @SerializedName(SERIALIZED_NAME_ARRAY_UUID) - private String arrayUuid; - - public static final String SERIALIZED_NAME_GROUP_UUID = "group_uuid"; - @SerializedName(SERIALIZED_NAME_GROUP_UUID) - private String groupUuid; - - public static final String SERIALIZED_NAME_ARRAY_NAME = "array_name"; - @SerializedName(SERIALIZED_NAME_ARRAY_NAME) - private String arrayName; - - public static final String SERIALIZED_NAME_EMAIL = "email"; - @SerializedName(SERIALIZED_NAME_EMAIL) - private String email; - - public static final String SERIALIZED_NAME_ACTIONS = "actions"; - @SerializedName(SERIALIZED_NAME_ACTIONS) - private String actions; - - public static final String SERIALIZED_NAME_GROUP_ACTIONS = "group_actions"; - @SerializedName(SERIALIZED_NAME_GROUP_ACTIONS) - private String groupActions; - - public static final String SERIALIZED_NAME_STATUS = "status"; - @SerializedName(SERIALIZED_NAME_STATUS) - private InvitationStatus status; - - public static final String SERIALIZED_NAME_CREATED_AT = "created_at"; - @SerializedName(SERIALIZED_NAME_CREATED_AT) - private OffsetDateTime createdAt; - - public static final String SERIALIZED_NAME_EXPIRES_AT = "expires_at"; - @SerializedName(SERIALIZED_NAME_EXPIRES_AT) - private OffsetDateTime expiresAt; - - public static final String SERIALIZED_NAME_ACCEPTED_AT = "accepted_at"; - @SerializedName(SERIALIZED_NAME_ACCEPTED_AT) - private OffsetDateTime acceptedAt; - - public static final String SERIALIZED_NAME_NAMESPACE_INVITED = "namespace_invited"; - @SerializedName(SERIALIZED_NAME_NAMESPACE_INVITED) - private String namespaceInvited; - - public Invitation() { - } - - public Invitation id(String id) { - - this.id = id; - return this; - } - - /** - * Unique ID of invitation added to magic link - * @return id - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "Unique ID of invitation added to magic link") - - public String getId() { - return id; - } - - - public void setId(String id) { - this.id = id; - } - - - public Invitation invitationType(InvitationType invitationType) { - - this.invitationType = invitationType; - return this; - } - - /** - * Get invitationType - * @return invitationType - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public InvitationType getInvitationType() { - return invitationType; - } - - - public void setInvitationType(InvitationType invitationType) { - this.invitationType = invitationType; - } - - - public Invitation ownerNamespaceUuid(String ownerNamespaceUuid) { - - this.ownerNamespaceUuid = ownerNamespaceUuid; - return this; - } - - /** - * Namespace of the owner of the invitation (user or organization) - * @return ownerNamespaceUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "Namespace of the owner of the invitation (user or organization)") - - public String getOwnerNamespaceUuid() { - return ownerNamespaceUuid; - } - - - public void setOwnerNamespaceUuid(String ownerNamespaceUuid) { - this.ownerNamespaceUuid = ownerNamespaceUuid; - } - - - public Invitation inviterUuid(String inviterUuid) { - - this.inviterUuid = inviterUuid; - return this; - } - - /** - * Unique ID of the user that sent the invitation - * @return inviterUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "Unique ID of the user that sent the invitation") - - public String getInviterUuid() { - return inviterUuid; - } - - - public void setInviterUuid(String inviterUuid) { - this.inviterUuid = inviterUuid; - } - - - public Invitation userNamespaceUuid(String userNamespaceUuid) { - - this.userNamespaceUuid = userNamespaceUuid; - return this; - } - - /** - * Unique ID of the user accepted the invitation - * @return userNamespaceUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "Unique ID of the user accepted the invitation") - - public String getUserNamespaceUuid() { - return userNamespaceUuid; - } - - - public void setUserNamespaceUuid(String userNamespaceUuid) { - this.userNamespaceUuid = userNamespaceUuid; - } - - - public Invitation organizationUserUuid(String organizationUserUuid) { - - this.organizationUserUuid = organizationUserUuid; - return this; - } - - /** - * Unique ID of the organization user accepted the invitation - * @return organizationUserUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "Unique ID of the organization user accepted the invitation") - - public String getOrganizationUserUuid() { - return organizationUserUuid; - } - - - public void setOrganizationUserUuid(String organizationUserUuid) { - this.organizationUserUuid = organizationUserUuid; - } - - - public Invitation organizationName(String organizationName) { - - this.organizationName = organizationName; - return this; - } - - /** - * Name of the organization, does not persist in database - * @return organizationName - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "organization_name", value = "Name of the organization, does not persist in database") - - public String getOrganizationName() { - return organizationName; - } - - - public void setOrganizationName(String organizationName) { - this.organizationName = organizationName; - } - - - public Invitation organizationRole(OrganizationRoles organizationRole) { - - this.organizationRole = organizationRole; - return this; - } - - /** - * Get organizationRole - * @return organizationRole - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public OrganizationRoles getOrganizationRole() { - return organizationRole; - } - - - public void setOrganizationRole(OrganizationRoles organizationRole) { - this.organizationRole = organizationRole; - } - - - public Invitation organizationUuid(String organizationUuid) { - - this.organizationUuid = organizationUuid; - return this; - } - - /** - * Unique ID of the organization whose user(s) accepted the invitation - * @return organizationUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "Unique ID of the organization whose user(s) accepted the invitation") - - public String getOrganizationUuid() { - return organizationUuid; - } - - - public void setOrganizationUuid(String organizationUuid) { - this.organizationUuid = organizationUuid; - } - - - public Invitation arrayUuid(String arrayUuid) { - - this.arrayUuid = arrayUuid; - return this; - } - - /** - * Unique ID of the array - * @return arrayUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "Unique ID of the array") - - public String getArrayUuid() { - return arrayUuid; - } - - - public void setArrayUuid(String arrayUuid) { - this.arrayUuid = arrayUuid; - } - - - public Invitation groupUuid(String groupUuid) { - - this.groupUuid = groupUuid; - return this; - } - - /** - * Unique ID of the group - * @return groupUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "Unique ID of the group") - - public String getGroupUuid() { - return groupUuid; - } - - - public void setGroupUuid(String groupUuid) { - this.groupUuid = groupUuid; - } - - - public Invitation arrayName(String arrayName) { - - this.arrayName = arrayName; - return this; - } - - /** - * Name of the array, does not persist in database - * @return arrayName - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "array_name", value = "Name of the array, does not persist in database") - - public String getArrayName() { - return arrayName; - } - - - public void setArrayName(String arrayName) { - this.arrayName = arrayName; - } - - - public Invitation email(String email) { - - this.email = email; - return this; - } - - /** - * Email of the individual we send the invitation to - * @return email - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "jane@doe.com", value = "Email of the individual we send the invitation to") - - public String getEmail() { - return email; - } - - - public void setEmail(String email) { - this.email = email; - } - - - public Invitation actions(String actions) { - - this.actions = actions; - return this; - } - - /** - * A comma separated list of ArrayActions or NamespaceActions - * @return actions - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "read,write", value = "A comma separated list of ArrayActions or NamespaceActions") - - public String getActions() { - return actions; - } - - - public void setActions(String actions) { - this.actions = actions; - } - - - public Invitation groupActions(String groupActions) { - - this.groupActions = groupActions; - return this; - } - - /** - * A comma separated list of GroupActions - * @return groupActions - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "read,write", value = "A comma separated list of GroupActions") - - public String getGroupActions() { - return groupActions; - } - - - public void setGroupActions(String groupActions) { - this.groupActions = groupActions; - } - - - public Invitation status(InvitationStatus status) { - - this.status = status; - return this; - } - - /** - * Get status - * @return status - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public InvitationStatus getStatus() { - return status; - } - - - public void setStatus(InvitationStatus status) { - this.status = status; - } - - - public Invitation createdAt(OffsetDateTime createdAt) { - - this.createdAt = createdAt; - return this; - } - - /** - * Datetime the invitation was created in UTC - * @return createdAt - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Datetime the invitation was created in UTC") - - public OffsetDateTime getCreatedAt() { - return createdAt; - } - - - public void setCreatedAt(OffsetDateTime createdAt) { - this.createdAt = createdAt; - } - - - public Invitation expiresAt(OffsetDateTime expiresAt) { - - this.expiresAt = expiresAt; - return this; - } - - /** - * Datetime the invitation is expected to expire in UTC - * @return expiresAt - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Datetime the invitation is expected to expire in UTC") - - public OffsetDateTime getExpiresAt() { - return expiresAt; - } - - - public void setExpiresAt(OffsetDateTime expiresAt) { - this.expiresAt = expiresAt; - } - - - public Invitation acceptedAt(OffsetDateTime acceptedAt) { - - this.acceptedAt = acceptedAt; - return this; - } - - /** - * Datetime the invitation was accepted in UTC - * @return acceptedAt - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Datetime the invitation was accepted in UTC") - - public OffsetDateTime getAcceptedAt() { - return acceptedAt; - } - - - public void setAcceptedAt(OffsetDateTime acceptedAt) { - this.acceptedAt = acceptedAt; - } - - - public Invitation namespaceInvited(String namespaceInvited) { - - this.namespaceInvited = namespaceInvited; - return this; - } - - /** - * The namespace invited (user or organization, if it exists in the DB) - * @return namespaceInvited - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The namespace invited (user or organization, if it exists in the DB)") - - public String getNamespaceInvited() { - return namespaceInvited; - } - - - public void setNamespaceInvited(String namespaceInvited) { - this.namespaceInvited = namespaceInvited; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public Invitation putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Invitation invitation = (Invitation) o; - return Objects.equals(this.id, invitation.id) && - Objects.equals(this.invitationType, invitation.invitationType) && - Objects.equals(this.ownerNamespaceUuid, invitation.ownerNamespaceUuid) && - Objects.equals(this.inviterUuid, invitation.inviterUuid) && - Objects.equals(this.userNamespaceUuid, invitation.userNamespaceUuid) && - Objects.equals(this.organizationUserUuid, invitation.organizationUserUuid) && - Objects.equals(this.organizationName, invitation.organizationName) && - Objects.equals(this.organizationRole, invitation.organizationRole) && - Objects.equals(this.organizationUuid, invitation.organizationUuid) && - Objects.equals(this.arrayUuid, invitation.arrayUuid) && - Objects.equals(this.groupUuid, invitation.groupUuid) && - Objects.equals(this.arrayName, invitation.arrayName) && - Objects.equals(this.email, invitation.email) && - Objects.equals(this.actions, invitation.actions) && - Objects.equals(this.groupActions, invitation.groupActions) && - Objects.equals(this.status, invitation.status) && - Objects.equals(this.createdAt, invitation.createdAt) && - Objects.equals(this.expiresAt, invitation.expiresAt) && - Objects.equals(this.acceptedAt, invitation.acceptedAt) && - Objects.equals(this.namespaceInvited, invitation.namespaceInvited)&& - Objects.equals(this.additionalProperties, invitation.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(id, invitationType, ownerNamespaceUuid, inviterUuid, userNamespaceUuid, organizationUserUuid, organizationName, organizationRole, organizationUuid, arrayUuid, groupUuid, arrayName, email, actions, groupActions, status, createdAt, expiresAt, acceptedAt, namespaceInvited, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Invitation {\n"); - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" invitationType: ").append(toIndentedString(invitationType)).append("\n"); - sb.append(" ownerNamespaceUuid: ").append(toIndentedString(ownerNamespaceUuid)).append("\n"); - sb.append(" inviterUuid: ").append(toIndentedString(inviterUuid)).append("\n"); - sb.append(" userNamespaceUuid: ").append(toIndentedString(userNamespaceUuid)).append("\n"); - sb.append(" organizationUserUuid: ").append(toIndentedString(organizationUserUuid)).append("\n"); - sb.append(" organizationName: ").append(toIndentedString(organizationName)).append("\n"); - sb.append(" organizationRole: ").append(toIndentedString(organizationRole)).append("\n"); - sb.append(" organizationUuid: ").append(toIndentedString(organizationUuid)).append("\n"); - sb.append(" arrayUuid: ").append(toIndentedString(arrayUuid)).append("\n"); - sb.append(" groupUuid: ").append(toIndentedString(groupUuid)).append("\n"); - sb.append(" arrayName: ").append(toIndentedString(arrayName)).append("\n"); - sb.append(" email: ").append(toIndentedString(email)).append("\n"); - sb.append(" actions: ").append(toIndentedString(actions)).append("\n"); - sb.append(" groupActions: ").append(toIndentedString(groupActions)).append("\n"); - sb.append(" status: ").append(toIndentedString(status)).append("\n"); - sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); - sb.append(" expiresAt: ").append(toIndentedString(expiresAt)).append("\n"); - sb.append(" acceptedAt: ").append(toIndentedString(acceptedAt)).append("\n"); - sb.append(" namespaceInvited: ").append(toIndentedString(namespaceInvited)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("id"); - openapiFields.add("invitation_type"); - openapiFields.add("owner_namespace_uuid"); - openapiFields.add("inviter_uuid"); - openapiFields.add("user_namespace_uuid"); - openapiFields.add("organization_user_uuid"); - openapiFields.add("organization_name"); - openapiFields.add("organization_role"); - openapiFields.add("organization_uuid"); - openapiFields.add("array_uuid"); - openapiFields.add("group_uuid"); - openapiFields.add("array_name"); - openapiFields.add("email"); - openapiFields.add("actions"); - openapiFields.add("group_actions"); - openapiFields.add("status"); - openapiFields.add("created_at"); - openapiFields.add("expires_at"); - openapiFields.add("accepted_at"); - openapiFields.add("namespace_invited"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to Invitation - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (Invitation.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in Invitation is not found in the empty JSON string", Invitation.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) && !jsonObj.get("id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("id").toString())); - } - if ((jsonObj.get("owner_namespace_uuid") != null && !jsonObj.get("owner_namespace_uuid").isJsonNull()) && !jsonObj.get("owner_namespace_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `owner_namespace_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("owner_namespace_uuid").toString())); - } - if ((jsonObj.get("inviter_uuid") != null && !jsonObj.get("inviter_uuid").isJsonNull()) && !jsonObj.get("inviter_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `inviter_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("inviter_uuid").toString())); - } - if ((jsonObj.get("user_namespace_uuid") != null && !jsonObj.get("user_namespace_uuid").isJsonNull()) && !jsonObj.get("user_namespace_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `user_namespace_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("user_namespace_uuid").toString())); - } - if ((jsonObj.get("organization_user_uuid") != null && !jsonObj.get("organization_user_uuid").isJsonNull()) && !jsonObj.get("organization_user_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `organization_user_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("organization_user_uuid").toString())); - } - if ((jsonObj.get("organization_name") != null && !jsonObj.get("organization_name").isJsonNull()) && !jsonObj.get("organization_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `organization_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("organization_name").toString())); - } - if ((jsonObj.get("organization_uuid") != null && !jsonObj.get("organization_uuid").isJsonNull()) && !jsonObj.get("organization_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `organization_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("organization_uuid").toString())); - } - if ((jsonObj.get("array_uuid") != null && !jsonObj.get("array_uuid").isJsonNull()) && !jsonObj.get("array_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `array_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("array_uuid").toString())); - } - if ((jsonObj.get("group_uuid") != null && !jsonObj.get("group_uuid").isJsonNull()) && !jsonObj.get("group_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `group_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("group_uuid").toString())); - } - if ((jsonObj.get("array_name") != null && !jsonObj.get("array_name").isJsonNull()) && !jsonObj.get("array_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `array_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("array_name").toString())); - } - if ((jsonObj.get("email") != null && !jsonObj.get("email").isJsonNull()) && !jsonObj.get("email").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `email` to be a primitive type in the JSON string but got `%s`", jsonObj.get("email").toString())); - } - if ((jsonObj.get("actions") != null && !jsonObj.get("actions").isJsonNull()) && !jsonObj.get("actions").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `actions` to be a primitive type in the JSON string but got `%s`", jsonObj.get("actions").toString())); - } - if ((jsonObj.get("group_actions") != null && !jsonObj.get("group_actions").isJsonNull()) && !jsonObj.get("group_actions").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `group_actions` to be a primitive type in the JSON string but got `%s`", jsonObj.get("group_actions").toString())); - } - if ((jsonObj.get("namespace_invited") != null && !jsonObj.get("namespace_invited").isJsonNull()) && !jsonObj.get("namespace_invited").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace_invited` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace_invited").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!Invitation.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'Invitation' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(Invitation.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, Invitation value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public Invitation read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - Invitation instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of Invitation given an JSON string - * - * @param jsonString JSON string - * @return An instance of Invitation - * @throws IOException if the JSON string is invalid with respect to Invitation - */ - public static Invitation fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, Invitation.class); - } - - /** - * Convert an instance of Invitation to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/InvitationArrayShareEmail.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/InvitationArrayShareEmail.java deleted file mode 100644 index 75dcb5c..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/InvitationArrayShareEmail.java +++ /dev/null @@ -1,321 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Encapsulates information regarding inviting people using email to share array, same permissions for all invitees - */ -@ApiModel(description = "Encapsulates information regarding inviting people using email to share array, same permissions for all invitees") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class InvitationArrayShareEmail { - public static final String SERIALIZED_NAME_ACTIONS = "actions"; - @SerializedName(SERIALIZED_NAME_ACTIONS) - private List actions = new ArrayList<>(); - - public static final String SERIALIZED_NAME_INVITEE_EMAIL = "invitee_email"; - @SerializedName(SERIALIZED_NAME_INVITEE_EMAIL) - private List inviteeEmail = new ArrayList<>(); - - public InvitationArrayShareEmail() { - } - - public InvitationArrayShareEmail actions(List actions) { - - this.actions = actions; - return this; - } - - public InvitationArrayShareEmail addActionsItem(ArrayActions actionsItem) { - this.actions.add(actionsItem); - return this; - } - - /** - * List of permitted actions - * @return actions - **/ - @javax.annotation.Nonnull - @ApiModelProperty(example = "[read, write]", required = true, value = "List of permitted actions") - - public List getActions() { - return actions; - } - - - public void setActions(List actions) { - this.actions = actions; - } - - - public InvitationArrayShareEmail inviteeEmail(List inviteeEmail) { - - this.inviteeEmail = inviteeEmail; - return this; - } - - public InvitationArrayShareEmail addInviteeEmailItem(String inviteeEmailItem) { - this.inviteeEmail.add(inviteeEmailItem); - return this; - } - - /** - * Get inviteeEmail - * @return inviteeEmail - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public List getInviteeEmail() { - return inviteeEmail; - } - - - public void setInviteeEmail(List inviteeEmail) { - this.inviteeEmail = inviteeEmail; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public InvitationArrayShareEmail putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - InvitationArrayShareEmail invitationArrayShareEmail = (InvitationArrayShareEmail) o; - return Objects.equals(this.actions, invitationArrayShareEmail.actions) && - Objects.equals(this.inviteeEmail, invitationArrayShareEmail.inviteeEmail)&& - Objects.equals(this.additionalProperties, invitationArrayShareEmail.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(actions, inviteeEmail, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class InvitationArrayShareEmail {\n"); - sb.append(" actions: ").append(toIndentedString(actions)).append("\n"); - sb.append(" inviteeEmail: ").append(toIndentedString(inviteeEmail)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("actions"); - openapiFields.add("invitee_email"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - openapiRequiredFields.add("actions"); - openapiRequiredFields.add("invitee_email"); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to InvitationArrayShareEmail - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (InvitationArrayShareEmail.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in InvitationArrayShareEmail is not found in the empty JSON string", InvitationArrayShareEmail.openapiRequiredFields.toString())); - } - } - - // check to make sure all required properties/fields are present in the JSON string - for (String requiredField : InvitationArrayShareEmail.openapiRequiredFields) { - if (jsonObj.get(requiredField) == null) { - throw new IllegalArgumentException(String.format("The required field `%s` is not found in the JSON string: %s", requiredField, jsonObj.toString())); - } - } - // ensure the json data is an array - if ((jsonObj.get("actions") != null && !jsonObj.get("actions").isJsonNull()) && !jsonObj.get("actions").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `actions` to be an array in the JSON string but got `%s`", jsonObj.get("actions").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("invitee_email") != null && !jsonObj.get("invitee_email").isJsonNull()) && !jsonObj.get("invitee_email").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `invitee_email` to be an array in the JSON string but got `%s`", jsonObj.get("invitee_email").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!InvitationArrayShareEmail.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'InvitationArrayShareEmail' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(InvitationArrayShareEmail.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, InvitationArrayShareEmail value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public InvitationArrayShareEmail read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - InvitationArrayShareEmail instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of InvitationArrayShareEmail given an JSON string - * - * @param jsonString JSON string - * @return An instance of InvitationArrayShareEmail - * @throws IOException if the JSON string is invalid with respect to InvitationArrayShareEmail - */ - public static InvitationArrayShareEmail fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, InvitationArrayShareEmail.class); - } - - /** - * Convert an instance of InvitationArrayShareEmail to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/InvitationData.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/InvitationData.java deleted file mode 100644 index cbe3b98..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/InvitationData.java +++ /dev/null @@ -1,319 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Object including invitations and metadata - */ -@ApiModel(description = "Object including invitations and metadata") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class InvitationData { - public static final String SERIALIZED_NAME_INVITATIONS = "invitations"; - @SerializedName(SERIALIZED_NAME_INVITATIONS) - private List invitations = null; - - public static final String SERIALIZED_NAME_PAGINATION_METADATA = "pagination_metadata"; - @SerializedName(SERIALIZED_NAME_PAGINATION_METADATA) - private PaginationMetadata paginationMetadata; - - public InvitationData() { - } - - public InvitationData invitations(List invitations) { - - this.invitations = invitations; - return this; - } - - public InvitationData addInvitationsItem(Invitation invitationsItem) { - if (this.invitations == null) { - this.invitations = new ArrayList<>(); - } - this.invitations.add(invitationsItem); - return this; - } - - /** - * List of invitations - * @return invitations - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "List of invitations") - - public List getInvitations() { - return invitations; - } - - - public void setInvitations(List invitations) { - this.invitations = invitations; - } - - - public InvitationData paginationMetadata(PaginationMetadata paginationMetadata) { - - this.paginationMetadata = paginationMetadata; - return this; - } - - /** - * Get paginationMetadata - * @return paginationMetadata - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public PaginationMetadata getPaginationMetadata() { - return paginationMetadata; - } - - - public void setPaginationMetadata(PaginationMetadata paginationMetadata) { - this.paginationMetadata = paginationMetadata; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public InvitationData putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - InvitationData invitationData = (InvitationData) o; - return Objects.equals(this.invitations, invitationData.invitations) && - Objects.equals(this.paginationMetadata, invitationData.paginationMetadata)&& - Objects.equals(this.additionalProperties, invitationData.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(invitations, paginationMetadata, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class InvitationData {\n"); - sb.append(" invitations: ").append(toIndentedString(invitations)).append("\n"); - sb.append(" paginationMetadata: ").append(toIndentedString(paginationMetadata)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("invitations"); - openapiFields.add("pagination_metadata"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to InvitationData - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (InvitationData.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in InvitationData is not found in the empty JSON string", InvitationData.openapiRequiredFields.toString())); - } - } - JsonArray jsonArrayinvitations = jsonObj.getAsJsonArray("invitations"); - if (jsonArrayinvitations != null) { - // ensure the json data is an array - if (!jsonObj.get("invitations").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `invitations` to be an array in the JSON string but got `%s`", jsonObj.get("invitations").toString())); - } - - // validate the optional field `invitations` (array) - for (int i = 0; i < jsonArrayinvitations.size(); i++) { - Invitation.validateJsonObject(jsonArrayinvitations.get(i).getAsJsonObject()); - }; - } - // validate the optional field `pagination_metadata` - if (jsonObj.get("pagination_metadata") != null && !jsonObj.get("pagination_metadata").isJsonNull()) { - PaginationMetadata.validateJsonObject(jsonObj.getAsJsonObject("pagination_metadata")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!InvitationData.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'InvitationData' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(InvitationData.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, InvitationData value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public InvitationData read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - InvitationData instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of InvitationData given an JSON string - * - * @param jsonString JSON string - * @return An instance of InvitationData - * @throws IOException if the JSON string is invalid with respect to InvitationData - */ - public static InvitationData fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, InvitationData.class); - } - - /** - * Convert an instance of InvitationData to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/InvitationFailedRecipients.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/InvitationFailedRecipients.java deleted file mode 100644 index acdd16e..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/InvitationFailedRecipients.java +++ /dev/null @@ -1,281 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Encapsulates information regarding the failed invitation recipients - */ -@ApiModel(description = "Encapsulates information regarding the failed invitation recipients") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class InvitationFailedRecipients { - public static final String SERIALIZED_NAME_FAILED_RECIPIENTS = "failed_recipients"; - @SerializedName(SERIALIZED_NAME_FAILED_RECIPIENTS) - private List failedRecipients = new ArrayList<>(); - - public InvitationFailedRecipients() { - } - - public InvitationFailedRecipients failedRecipients(List failedRecipients) { - - this.failedRecipients = failedRecipients; - return this; - } - - public InvitationFailedRecipients addFailedRecipientsItem(String failedRecipientsItem) { - this.failedRecipients.add(failedRecipientsItem); - return this; - } - - /** - * Get failedRecipients - * @return failedRecipients - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public List getFailedRecipients() { - return failedRecipients; - } - - - public void setFailedRecipients(List failedRecipients) { - this.failedRecipients = failedRecipients; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public InvitationFailedRecipients putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - InvitationFailedRecipients invitationFailedRecipients = (InvitationFailedRecipients) o; - return Objects.equals(this.failedRecipients, invitationFailedRecipients.failedRecipients)&& - Objects.equals(this.additionalProperties, invitationFailedRecipients.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(failedRecipients, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class InvitationFailedRecipients {\n"); - sb.append(" failedRecipients: ").append(toIndentedString(failedRecipients)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("failed_recipients"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - openapiRequiredFields.add("failed_recipients"); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to InvitationFailedRecipients - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (InvitationFailedRecipients.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in InvitationFailedRecipients is not found in the empty JSON string", InvitationFailedRecipients.openapiRequiredFields.toString())); - } - } - - // check to make sure all required properties/fields are present in the JSON string - for (String requiredField : InvitationFailedRecipients.openapiRequiredFields) { - if (jsonObj.get(requiredField) == null) { - throw new IllegalArgumentException(String.format("The required field `%s` is not found in the JSON string: %s", requiredField, jsonObj.toString())); - } - } - // ensure the json data is an array - if ((jsonObj.get("failed_recipients") != null && !jsonObj.get("failed_recipients").isJsonNull()) && !jsonObj.get("failed_recipients").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `failed_recipients` to be an array in the JSON string but got `%s`", jsonObj.get("failed_recipients").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!InvitationFailedRecipients.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'InvitationFailedRecipients' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(InvitationFailedRecipients.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, InvitationFailedRecipients value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public InvitationFailedRecipients read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - InvitationFailedRecipients instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of InvitationFailedRecipients given an JSON string - * - * @param jsonString JSON string - * @return An instance of InvitationFailedRecipients - * @throws IOException if the JSON string is invalid with respect to InvitationFailedRecipients - */ - public static InvitationFailedRecipients fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, InvitationFailedRecipients.class); - } - - /** - * Convert an instance of InvitationFailedRecipients to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/InvitationGroupShareEmail.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/InvitationGroupShareEmail.java deleted file mode 100644 index 03dff70..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/InvitationGroupShareEmail.java +++ /dev/null @@ -1,361 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Encapsulates information regarding inviting people using email to share group, same permissions for all invitees - */ -@ApiModel(description = "Encapsulates information regarding inviting people using email to share group, same permissions for all invitees") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class InvitationGroupShareEmail { - public static final String SERIALIZED_NAME_ARRAY_ACTIONS = "array_actions"; - @SerializedName(SERIALIZED_NAME_ARRAY_ACTIONS) - private List arrayActions = new ArrayList<>(); - - public static final String SERIALIZED_NAME_GROUP_ACTIONS = "group_actions"; - @SerializedName(SERIALIZED_NAME_GROUP_ACTIONS) - private List groupActions = new ArrayList<>(); - - public static final String SERIALIZED_NAME_INVITEE_EMAIL_OR_NAME = "invitee_email_or_name"; - @SerializedName(SERIALIZED_NAME_INVITEE_EMAIL_OR_NAME) - private List inviteeEmailOrName = new ArrayList<>(); - - public InvitationGroupShareEmail() { - } - - public InvitationGroupShareEmail arrayActions(List arrayActions) { - - this.arrayActions = arrayActions; - return this; - } - - public InvitationGroupShareEmail addArrayActionsItem(ArrayActions arrayActionsItem) { - this.arrayActions.add(arrayActionsItem); - return this; - } - - /** - * List of permitted array actions - * @return arrayActions - **/ - @javax.annotation.Nonnull - @ApiModelProperty(example = "[read, write]", required = true, value = "List of permitted array actions") - - public List getArrayActions() { - return arrayActions; - } - - - public void setArrayActions(List arrayActions) { - this.arrayActions = arrayActions; - } - - - public InvitationGroupShareEmail groupActions(List groupActions) { - - this.groupActions = groupActions; - return this; - } - - public InvitationGroupShareEmail addGroupActionsItem(GroupActions groupActionsItem) { - this.groupActions.add(groupActionsItem); - return this; - } - - /** - * List of permitted group actions - * @return groupActions - **/ - @javax.annotation.Nonnull - @ApiModelProperty(example = "[read, write]", required = true, value = "List of permitted group actions") - - public List getGroupActions() { - return groupActions; - } - - - public void setGroupActions(List groupActions) { - this.groupActions = groupActions; - } - - - public InvitationGroupShareEmail inviteeEmailOrName(List inviteeEmailOrName) { - - this.inviteeEmailOrName = inviteeEmailOrName; - return this; - } - - public InvitationGroupShareEmail addInviteeEmailOrNameItem(String inviteeEmailOrNameItem) { - this.inviteeEmailOrName.add(inviteeEmailOrNameItem); - return this; - } - - /** - * Get inviteeEmailOrName - * @return inviteeEmailOrName - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public List getInviteeEmailOrName() { - return inviteeEmailOrName; - } - - - public void setInviteeEmailOrName(List inviteeEmailOrName) { - this.inviteeEmailOrName = inviteeEmailOrName; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public InvitationGroupShareEmail putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - InvitationGroupShareEmail invitationGroupShareEmail = (InvitationGroupShareEmail) o; - return Objects.equals(this.arrayActions, invitationGroupShareEmail.arrayActions) && - Objects.equals(this.groupActions, invitationGroupShareEmail.groupActions) && - Objects.equals(this.inviteeEmailOrName, invitationGroupShareEmail.inviteeEmailOrName)&& - Objects.equals(this.additionalProperties, invitationGroupShareEmail.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(arrayActions, groupActions, inviteeEmailOrName, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class InvitationGroupShareEmail {\n"); - sb.append(" arrayActions: ").append(toIndentedString(arrayActions)).append("\n"); - sb.append(" groupActions: ").append(toIndentedString(groupActions)).append("\n"); - sb.append(" inviteeEmailOrName: ").append(toIndentedString(inviteeEmailOrName)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("array_actions"); - openapiFields.add("group_actions"); - openapiFields.add("invitee_email_or_name"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - openapiRequiredFields.add("array_actions"); - openapiRequiredFields.add("group_actions"); - openapiRequiredFields.add("invitee_email_or_name"); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to InvitationGroupShareEmail - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (InvitationGroupShareEmail.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in InvitationGroupShareEmail is not found in the empty JSON string", InvitationGroupShareEmail.openapiRequiredFields.toString())); - } - } - - // check to make sure all required properties/fields are present in the JSON string - for (String requiredField : InvitationGroupShareEmail.openapiRequiredFields) { - if (jsonObj.get(requiredField) == null) { - throw new IllegalArgumentException(String.format("The required field `%s` is not found in the JSON string: %s", requiredField, jsonObj.toString())); - } - } - // ensure the json data is an array - if ((jsonObj.get("array_actions") != null && !jsonObj.get("array_actions").isJsonNull()) && !jsonObj.get("array_actions").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `array_actions` to be an array in the JSON string but got `%s`", jsonObj.get("array_actions").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("group_actions") != null && !jsonObj.get("group_actions").isJsonNull()) && !jsonObj.get("group_actions").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `group_actions` to be an array in the JSON string but got `%s`", jsonObj.get("group_actions").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("invitee_email_or_name") != null && !jsonObj.get("invitee_email_or_name").isJsonNull()) && !jsonObj.get("invitee_email_or_name").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `invitee_email_or_name` to be an array in the JSON string but got `%s`", jsonObj.get("invitee_email_or_name").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!InvitationGroupShareEmail.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'InvitationGroupShareEmail' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(InvitationGroupShareEmail.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, InvitationGroupShareEmail value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public InvitationGroupShareEmail read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - InvitationGroupShareEmail instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of InvitationGroupShareEmail given an JSON string - * - * @param jsonString JSON string - * @return An instance of InvitationGroupShareEmail - * @throws IOException if the JSON string is invalid with respect to InvitationGroupShareEmail - */ - public static InvitationGroupShareEmail fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, InvitationGroupShareEmail.class); - } - - /** - * Convert an instance of InvitationGroupShareEmail to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/InvitationOrganizationJoinEmail.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/InvitationOrganizationJoinEmail.java deleted file mode 100644 index f0df730..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/InvitationOrganizationJoinEmail.java +++ /dev/null @@ -1,354 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Encapsulates information regarding inviting people using email to join organization, same permissions for all invitees - */ -@ApiModel(description = "Encapsulates information regarding inviting people using email to join organization, same permissions for all invitees") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class InvitationOrganizationJoinEmail { - public static final String SERIALIZED_NAME_ACTIONS = "actions"; - @SerializedName(SERIALIZED_NAME_ACTIONS) - private List actions = null; - - public static final String SERIALIZED_NAME_ORGANIZATION_ROLE = "organization_role"; - @SerializedName(SERIALIZED_NAME_ORGANIZATION_ROLE) - private OrganizationRoles organizationRole; - - public static final String SERIALIZED_NAME_INVITEE_EMAIL = "invitee_email"; - @SerializedName(SERIALIZED_NAME_INVITEE_EMAIL) - private List inviteeEmail = new ArrayList<>(); - - public InvitationOrganizationJoinEmail() { - } - - public InvitationOrganizationJoinEmail actions(List actions) { - - this.actions = actions; - return this; - } - - public InvitationOrganizationJoinEmail addActionsItem(NamespaceActions actionsItem) { - if (this.actions == null) { - this.actions = new ArrayList<>(); - } - this.actions.add(actionsItem); - return this; - } - - /** - * List of permitted actions - * @return actions - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "[read, write]", value = "List of permitted actions") - - public List getActions() { - return actions; - } - - - public void setActions(List actions) { - this.actions = actions; - } - - - public InvitationOrganizationJoinEmail organizationRole(OrganizationRoles organizationRole) { - - this.organizationRole = organizationRole; - return this; - } - - /** - * Get organizationRole - * @return organizationRole - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public OrganizationRoles getOrganizationRole() { - return organizationRole; - } - - - public void setOrganizationRole(OrganizationRoles organizationRole) { - this.organizationRole = organizationRole; - } - - - public InvitationOrganizationJoinEmail inviteeEmail(List inviteeEmail) { - - this.inviteeEmail = inviteeEmail; - return this; - } - - public InvitationOrganizationJoinEmail addInviteeEmailItem(String inviteeEmailItem) { - this.inviteeEmail.add(inviteeEmailItem); - return this; - } - - /** - * Get inviteeEmail - * @return inviteeEmail - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public List getInviteeEmail() { - return inviteeEmail; - } - - - public void setInviteeEmail(List inviteeEmail) { - this.inviteeEmail = inviteeEmail; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public InvitationOrganizationJoinEmail putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - InvitationOrganizationJoinEmail invitationOrganizationJoinEmail = (InvitationOrganizationJoinEmail) o; - return Objects.equals(this.actions, invitationOrganizationJoinEmail.actions) && - Objects.equals(this.organizationRole, invitationOrganizationJoinEmail.organizationRole) && - Objects.equals(this.inviteeEmail, invitationOrganizationJoinEmail.inviteeEmail)&& - Objects.equals(this.additionalProperties, invitationOrganizationJoinEmail.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(actions, organizationRole, inviteeEmail, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class InvitationOrganizationJoinEmail {\n"); - sb.append(" actions: ").append(toIndentedString(actions)).append("\n"); - sb.append(" organizationRole: ").append(toIndentedString(organizationRole)).append("\n"); - sb.append(" inviteeEmail: ").append(toIndentedString(inviteeEmail)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("actions"); - openapiFields.add("organization_role"); - openapiFields.add("invitee_email"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - openapiRequiredFields.add("organization_role"); - openapiRequiredFields.add("invitee_email"); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to InvitationOrganizationJoinEmail - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (InvitationOrganizationJoinEmail.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in InvitationOrganizationJoinEmail is not found in the empty JSON string", InvitationOrganizationJoinEmail.openapiRequiredFields.toString())); - } - } - - // check to make sure all required properties/fields are present in the JSON string - for (String requiredField : InvitationOrganizationJoinEmail.openapiRequiredFields) { - if (jsonObj.get(requiredField) == null) { - throw new IllegalArgumentException(String.format("The required field `%s` is not found in the JSON string: %s", requiredField, jsonObj.toString())); - } - } - // ensure the json data is an array - if ((jsonObj.get("actions") != null && !jsonObj.get("actions").isJsonNull()) && !jsonObj.get("actions").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `actions` to be an array in the JSON string but got `%s`", jsonObj.get("actions").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("invitee_email") != null && !jsonObj.get("invitee_email").isJsonNull()) && !jsonObj.get("invitee_email").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `invitee_email` to be an array in the JSON string but got `%s`", jsonObj.get("invitee_email").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!InvitationOrganizationJoinEmail.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'InvitationOrganizationJoinEmail' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(InvitationOrganizationJoinEmail.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, InvitationOrganizationJoinEmail value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public InvitationOrganizationJoinEmail read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - InvitationOrganizationJoinEmail instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of InvitationOrganizationJoinEmail given an JSON string - * - * @param jsonString JSON string - * @return An instance of InvitationOrganizationJoinEmail - * @throws IOException if the JSON string is invalid with respect to InvitationOrganizationJoinEmail - */ - public static InvitationOrganizationJoinEmail fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, InvitationOrganizationJoinEmail.class); - } - - /** - * Convert an instance of InvitationOrganizationJoinEmail to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/InvitationStatus.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/InvitationStatus.java deleted file mode 100644 index bbd92ed..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/InvitationStatus.java +++ /dev/null @@ -1,69 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * List of values that InvitationStatus can take - */ -@JsonAdapter(InvitationStatus.Adapter.class) -public enum InvitationStatus { - - PENDING("PENDING"), - - ACCEPTED("ACCEPTED"); - - private String value; - - InvitationStatus(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static InvitationStatus fromValue(String value) { - for (InvitationStatus b : InvitationStatus.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final InvitationStatus enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public InvitationStatus read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return InvitationStatus.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/InvitationType.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/InvitationType.java deleted file mode 100644 index 36f5453..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/InvitationType.java +++ /dev/null @@ -1,71 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * List of values that InvitationType can take - */ -@JsonAdapter(InvitationType.Adapter.class) -public enum InvitationType { - - ARRAY_SHARE("ARRAY_SHARE"), - - GROUP_SHARE("GROUP_SHARE"), - - JOIN_ORGANIZATION("JOIN_ORGANIZATION"); - - private String value; - - InvitationType(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static InvitationType fromValue(String value) { - for (InvitationType b : InvitationType.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final InvitationType enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public InvitationType read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return InvitationType.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/LastAccessedArray.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/LastAccessedArray.java deleted file mode 100644 index a085a79..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/LastAccessedArray.java +++ /dev/null @@ -1,392 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.math.BigDecimal; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Information related to last access of an array - */ -@ApiModel(description = "Information related to last access of an array") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class LastAccessedArray { - public static final String SERIALIZED_NAME_ARRAY_ID = "array_id"; - @SerializedName(SERIALIZED_NAME_ARRAY_ID) - private String arrayId; - - public static final String SERIALIZED_NAME_ARRAY_NAME = "array_name"; - @SerializedName(SERIALIZED_NAME_ARRAY_NAME) - private String arrayName; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public static final String SERIALIZED_NAME_ACCESSED_TIME = "accessed_time"; - @SerializedName(SERIALIZED_NAME_ACCESSED_TIME) - private BigDecimal accessedTime; - - public static final String SERIALIZED_NAME_ACCESS_TYPE = "access_type"; - @SerializedName(SERIALIZED_NAME_ACCESS_TYPE) - private ActivityEventType accessType; - - public LastAccessedArray() { - } - - public LastAccessedArray arrayId(String arrayId) { - - this.arrayId = arrayId; - return this; - } - - /** - * unique ID of array - * @return arrayId - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "unique ID of array") - - public String getArrayId() { - return arrayId; - } - - - public void setArrayId(String arrayId) { - this.arrayId = arrayId; - } - - - public LastAccessedArray arrayName(String arrayName) { - - this.arrayName = arrayName; - return this; - } - - /** - * name of the array - * @return arrayName - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "array1", value = "name of the array") - - public String getArrayName() { - return arrayName; - } - - - public void setArrayName(String arrayName) { - this.arrayName = arrayName; - } - - - public LastAccessedArray namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * namespace of a user or organization - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "mockuser", value = "namespace of a user or organization") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - - public LastAccessedArray accessedTime(BigDecimal accessedTime) { - - this.accessedTime = accessedTime; - return this; - } - - /** - * timestamp (epoch milliseconds) array is last accessed - * @return accessedTime - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "1540471791873", value = "timestamp (epoch milliseconds) array is last accessed") - - public BigDecimal getAccessedTime() { - return accessedTime; - } - - - public void setAccessedTime(BigDecimal accessedTime) { - this.accessedTime = accessedTime; - } - - - public LastAccessedArray accessType(ActivityEventType accessType) { - - this.accessType = accessType; - return this; - } - - /** - * Get accessType - * @return accessType - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public ActivityEventType getAccessType() { - return accessType; - } - - - public void setAccessType(ActivityEventType accessType) { - this.accessType = accessType; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public LastAccessedArray putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - LastAccessedArray lastAccessedArray = (LastAccessedArray) o; - return Objects.equals(this.arrayId, lastAccessedArray.arrayId) && - Objects.equals(this.arrayName, lastAccessedArray.arrayName) && - Objects.equals(this.namespace, lastAccessedArray.namespace) && - Objects.equals(this.accessedTime, lastAccessedArray.accessedTime) && - Objects.equals(this.accessType, lastAccessedArray.accessType)&& - Objects.equals(this.additionalProperties, lastAccessedArray.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(arrayId, arrayName, namespace, accessedTime, accessType, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class LastAccessedArray {\n"); - sb.append(" arrayId: ").append(toIndentedString(arrayId)).append("\n"); - sb.append(" arrayName: ").append(toIndentedString(arrayName)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" accessedTime: ").append(toIndentedString(accessedTime)).append("\n"); - sb.append(" accessType: ").append(toIndentedString(accessType)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("array_id"); - openapiFields.add("array_name"); - openapiFields.add("namespace"); - openapiFields.add("accessed_time"); - openapiFields.add("access_type"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to LastAccessedArray - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (LastAccessedArray.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in LastAccessedArray is not found in the empty JSON string", LastAccessedArray.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("array_id") != null && !jsonObj.get("array_id").isJsonNull()) && !jsonObj.get("array_id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `array_id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("array_id").toString())); - } - if ((jsonObj.get("array_name") != null && !jsonObj.get("array_name").isJsonNull()) && !jsonObj.get("array_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `array_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("array_name").toString())); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!LastAccessedArray.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'LastAccessedArray' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(LastAccessedArray.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, LastAccessedArray value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public LastAccessedArray read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - LastAccessedArray instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of LastAccessedArray given an JSON string - * - * @param jsonString JSON string - * @return An instance of LastAccessedArray - * @throws IOException if the JSON string is invalid with respect to LastAccessedArray - */ - public static LastAccessedArray fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, LastAccessedArray.class); - } - - /** - * Convert an instance of LastAccessedArray to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Layout.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/Layout.java deleted file mode 100644 index 859dcd4..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Layout.java +++ /dev/null @@ -1,73 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * Layout of array - */ -@JsonAdapter(Layout.Adapter.class) -public enum Layout { - - ROW_MAJOR("row-major"), - - COL_MAJOR("col-major"), - - GLOBAL_ORDER("global-order"), - - UNORDERED("unordered"); - - private String value; - - Layout(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static Layout fromValue(String value) { - for (Layout b : Layout.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final Layout enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public Layout read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return Layout.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/MLModelFavorite.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/MLModelFavorite.java deleted file mode 100644 index 47cb55b..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/MLModelFavorite.java +++ /dev/null @@ -1,331 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * A user-favorite MLModel item - */ -@ApiModel(description = "A user-favorite MLModel item") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class MLModelFavorite { - public static final String SERIALIZED_NAME_MLMODEL_UUID = "mlmodel_uuid"; - @SerializedName(SERIALIZED_NAME_MLMODEL_UUID) - private String mlmodelUuid; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public MLModelFavorite() { - } - - public MLModelFavorite mlmodelUuid(String mlmodelUuid) { - - this.mlmodelUuid = mlmodelUuid; - return this; - } - - /** - * unique UUID of the MLModel - * @return mlmodelUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "unique UUID of the MLModel") - - public String getMlmodelUuid() { - return mlmodelUuid; - } - - - public void setMlmodelUuid(String mlmodelUuid) { - this.mlmodelUuid = mlmodelUuid; - } - - - public MLModelFavorite namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * the namespace of the MLModel - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "the namespace of the MLModel") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - - public MLModelFavorite name(String name) { - - this.name = name; - return this; - } - - /** - * the name of the MLModel - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "the name of the MLModel") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public MLModelFavorite putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - MLModelFavorite mlModelFavorite = (MLModelFavorite) o; - return Objects.equals(this.mlmodelUuid, mlModelFavorite.mlmodelUuid) && - Objects.equals(this.namespace, mlModelFavorite.namespace) && - Objects.equals(this.name, mlModelFavorite.name)&& - Objects.equals(this.additionalProperties, mlModelFavorite.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(mlmodelUuid, namespace, name, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class MLModelFavorite {\n"); - sb.append(" mlmodelUuid: ").append(toIndentedString(mlmodelUuid)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("mlmodel_uuid"); - openapiFields.add("namespace"); - openapiFields.add("name"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to MLModelFavorite - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (MLModelFavorite.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in MLModelFavorite is not found in the empty JSON string", MLModelFavorite.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("mlmodel_uuid") != null && !jsonObj.get("mlmodel_uuid").isJsonNull()) && !jsonObj.get("mlmodel_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `mlmodel_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("mlmodel_uuid").toString())); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!MLModelFavorite.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'MLModelFavorite' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(MLModelFavorite.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, MLModelFavorite value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public MLModelFavorite read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - MLModelFavorite instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of MLModelFavorite given an JSON string - * - * @param jsonString JSON string - * @return An instance of MLModelFavorite - * @throws IOException if the JSON string is invalid with respect to MLModelFavorite - */ - public static MLModelFavorite fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, MLModelFavorite.class); - } - - /** - * Convert an instance of MLModelFavorite to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/MLModelFavoritesData.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/MLModelFavoritesData.java deleted file mode 100644 index 4154102..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/MLModelFavoritesData.java +++ /dev/null @@ -1,319 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Object including MLModel favorites and pagination metadata - */ -@ApiModel(description = "Object including MLModel favorites and pagination metadata") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class MLModelFavoritesData { - public static final String SERIALIZED_NAME_MLMODELS = "mlmodels"; - @SerializedName(SERIALIZED_NAME_MLMODELS) - private List mlmodels = null; - - public static final String SERIALIZED_NAME_PAGINATION_METADATA = "pagination_metadata"; - @SerializedName(SERIALIZED_NAME_PAGINATION_METADATA) - private PaginationMetadata paginationMetadata; - - public MLModelFavoritesData() { - } - - public MLModelFavoritesData mlmodels(List mlmodels) { - - this.mlmodels = mlmodels; - return this; - } - - public MLModelFavoritesData addMlmodelsItem(ArrayInfo mlmodelsItem) { - if (this.mlmodels == null) { - this.mlmodels = new ArrayList<>(); - } - this.mlmodels.add(mlmodelsItem); - return this; - } - - /** - * List of MLModel infos - * @return mlmodels - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "List of MLModel infos") - - public List getMlmodels() { - return mlmodels; - } - - - public void setMlmodels(List mlmodels) { - this.mlmodels = mlmodels; - } - - - public MLModelFavoritesData paginationMetadata(PaginationMetadata paginationMetadata) { - - this.paginationMetadata = paginationMetadata; - return this; - } - - /** - * Get paginationMetadata - * @return paginationMetadata - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public PaginationMetadata getPaginationMetadata() { - return paginationMetadata; - } - - - public void setPaginationMetadata(PaginationMetadata paginationMetadata) { - this.paginationMetadata = paginationMetadata; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public MLModelFavoritesData putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - MLModelFavoritesData mlModelFavoritesData = (MLModelFavoritesData) o; - return Objects.equals(this.mlmodels, mlModelFavoritesData.mlmodels) && - Objects.equals(this.paginationMetadata, mlModelFavoritesData.paginationMetadata)&& - Objects.equals(this.additionalProperties, mlModelFavoritesData.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(mlmodels, paginationMetadata, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class MLModelFavoritesData {\n"); - sb.append(" mlmodels: ").append(toIndentedString(mlmodels)).append("\n"); - sb.append(" paginationMetadata: ").append(toIndentedString(paginationMetadata)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("mlmodels"); - openapiFields.add("pagination_metadata"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to MLModelFavoritesData - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (MLModelFavoritesData.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in MLModelFavoritesData is not found in the empty JSON string", MLModelFavoritesData.openapiRequiredFields.toString())); - } - } - JsonArray jsonArraymlmodels = jsonObj.getAsJsonArray("mlmodels"); - if (jsonArraymlmodels != null) { - // ensure the json data is an array - if (!jsonObj.get("mlmodels").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `mlmodels` to be an array in the JSON string but got `%s`", jsonObj.get("mlmodels").toString())); - } - - // validate the optional field `mlmodels` (array) - for (int i = 0; i < jsonArraymlmodels.size(); i++) { - ArrayInfo.validateJsonObject(jsonArraymlmodels.get(i).getAsJsonObject()); - }; - } - // validate the optional field `pagination_metadata` - if (jsonObj.get("pagination_metadata") != null && !jsonObj.get("pagination_metadata").isJsonNull()) { - PaginationMetadata.validateJsonObject(jsonObj.getAsJsonObject("pagination_metadata")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!MLModelFavoritesData.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'MLModelFavoritesData' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(MLModelFavoritesData.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, MLModelFavoritesData value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public MLModelFavoritesData read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - MLModelFavoritesData instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of MLModelFavoritesData given an JSON string - * - * @param jsonString JSON string - * @return An instance of MLModelFavoritesData - * @throws IOException if the JSON string is invalid with respect to MLModelFavoritesData - */ - public static MLModelFavoritesData fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, MLModelFavoritesData.class); - } - - /** - * Convert an instance of MLModelFavoritesData to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/MaxBufferSizes.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/MaxBufferSizes.java deleted file mode 100644 index abd2c7d..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/MaxBufferSizes.java +++ /dev/null @@ -1,285 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * a list of max buffer sizes, one per attribute - */ -@ApiModel(description = "a list of max buffer sizes, one per attribute") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class MaxBufferSizes { - public static final String SERIALIZED_NAME_MAX_BUFFER_SIZES = "maxBufferSizes"; - @SerializedName(SERIALIZED_NAME_MAX_BUFFER_SIZES) - private List maxBufferSizes = null; - - public MaxBufferSizes() { - } - - public MaxBufferSizes maxBufferSizes(List maxBufferSizes) { - - this.maxBufferSizes = maxBufferSizes; - return this; - } - - public MaxBufferSizes addMaxBufferSizesItem(AttributeBufferSize maxBufferSizesItem) { - if (this.maxBufferSizes == null) { - this.maxBufferSizes = new ArrayList<>(); - } - this.maxBufferSizes.add(maxBufferSizesItem); - return this; - } - - /** - * Get maxBufferSizes - * @return maxBufferSizes - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List getMaxBufferSizes() { - return maxBufferSizes; - } - - - public void setMaxBufferSizes(List maxBufferSizes) { - this.maxBufferSizes = maxBufferSizes; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public MaxBufferSizes putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - MaxBufferSizes maxBufferSizes = (MaxBufferSizes) o; - return Objects.equals(this.maxBufferSizes, maxBufferSizes.maxBufferSizes)&& - Objects.equals(this.additionalProperties, maxBufferSizes.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(maxBufferSizes, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class MaxBufferSizes {\n"); - sb.append(" maxBufferSizes: ").append(toIndentedString(maxBufferSizes)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("maxBufferSizes"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to MaxBufferSizes - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (MaxBufferSizes.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in MaxBufferSizes is not found in the empty JSON string", MaxBufferSizes.openapiRequiredFields.toString())); - } - } - JsonArray jsonArraymaxBufferSizes = jsonObj.getAsJsonArray("maxBufferSizes"); - if (jsonArraymaxBufferSizes != null) { - // ensure the json data is an array - if (!jsonObj.get("maxBufferSizes").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `maxBufferSizes` to be an array in the JSON string but got `%s`", jsonObj.get("maxBufferSizes").toString())); - } - - // validate the optional field `maxBufferSizes` (array) - for (int i = 0; i < jsonArraymaxBufferSizes.size(); i++) { - AttributeBufferSize.validateJsonObject(jsonArraymaxBufferSizes.get(i).getAsJsonObject()); - }; - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!MaxBufferSizes.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'MaxBufferSizes' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(MaxBufferSizes.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, MaxBufferSizes value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public MaxBufferSizes read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - MaxBufferSizes instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of MaxBufferSizes given an JSON string - * - * @param jsonString JSON string - * @return An instance of MaxBufferSizes - * @throws IOException if the JSON string is invalid with respect to MaxBufferSizes - */ - public static MaxBufferSizes fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, MaxBufferSizes.class); - } - - /** - * Convert an instance of MaxBufferSizes to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/MultiArrayUDF.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/MultiArrayUDF.java deleted file mode 100644 index eafdf47..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/MultiArrayUDF.java +++ /dev/null @@ -1,1013 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import org.openapitools.jackson.nullable.JsonNullable; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * User-defined function - */ -@ApiModel(description = "User-defined function") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class MultiArrayUDF { - public static final String SERIALIZED_NAME_UDF_INFO_NAME = "udf_info_name"; - @SerializedName(SERIALIZED_NAME_UDF_INFO_NAME) - private String udfInfoName; - - public static final String SERIALIZED_NAME_LANGUAGE = "language"; - @SerializedName(SERIALIZED_NAME_LANGUAGE) - private UDFLanguage language; - - public static final String SERIALIZED_NAME_VERSION = "version"; - @SerializedName(SERIALIZED_NAME_VERSION) - private String version; - - public static final String SERIALIZED_NAME_IMAGE_NAME = "image_name"; - @SerializedName(SERIALIZED_NAME_IMAGE_NAME) - private String imageName; - - public static final String SERIALIZED_NAME_ACCESS_CREDENTIALS_NAME = "access_credentials_name"; - @SerializedName(SERIALIZED_NAME_ACCESS_CREDENTIALS_NAME) - private String accessCredentialsName; - - public static final String SERIALIZED_NAME_RESOURCE_CLASS = "resource_class"; - @SerializedName(SERIALIZED_NAME_RESOURCE_CLASS) - private String resourceClass; - - public static final String SERIALIZED_NAME_EXEC = "exec"; - @SerializedName(SERIALIZED_NAME_EXEC) - private String exec; - - public static final String SERIALIZED_NAME_EXEC_RAW = "exec_raw"; - @SerializedName(SERIALIZED_NAME_EXEC_RAW) - private String execRaw; - - public static final String SERIALIZED_NAME_RESULT_FORMAT = "result_format"; - @SerializedName(SERIALIZED_NAME_RESULT_FORMAT) - private ResultFormat resultFormat; - - public static final String SERIALIZED_NAME_TASK_NAME = "task_name"; - @SerializedName(SERIALIZED_NAME_TASK_NAME) - private String taskName; - - public static final String SERIALIZED_NAME_ARGUMENT = "argument"; - @SerializedName(SERIALIZED_NAME_ARGUMENT) - private String argument; - - public static final String SERIALIZED_NAME_ARGUMENTS_JSON = "arguments_json"; - @SerializedName(SERIALIZED_NAME_ARGUMENTS_JSON) - private List argumentsJson = null; - - public static final String SERIALIZED_NAME_STORED_PARAM_UUIDS = "stored_param_uuids"; - @SerializedName(SERIALIZED_NAME_STORED_PARAM_UUIDS) - private List storedParamUuids = null; - - public static final String SERIALIZED_NAME_STORE_RESULTS = "store_results"; - @SerializedName(SERIALIZED_NAME_STORE_RESULTS) - private Boolean storeResults; - - public static final String SERIALIZED_NAME_DONT_DOWNLOAD_RESULTS = "dont_download_results"; - @SerializedName(SERIALIZED_NAME_DONT_DOWNLOAD_RESULTS) - private Boolean dontDownloadResults; - - public static final String SERIALIZED_NAME_RANGES = "ranges"; - @SerializedName(SERIALIZED_NAME_RANGES) - private QueryRanges ranges; - - public static final String SERIALIZED_NAME_SUBARRAY = "subarray"; - @SerializedName(SERIALIZED_NAME_SUBARRAY) - private UDFSubarray subarray; - - public static final String SERIALIZED_NAME_BUFFERS = "buffers"; - @SerializedName(SERIALIZED_NAME_BUFFERS) - private List buffers = null; - - public static final String SERIALIZED_NAME_ARRAYS = "arrays"; - @SerializedName(SERIALIZED_NAME_ARRAYS) - private List arrays = null; - - public static final String SERIALIZED_NAME_TIMEOUT = "timeout"; - @SerializedName(SERIALIZED_NAME_TIMEOUT) - private Integer timeout; - - public static final String SERIALIZED_NAME_TASK_GRAPH_UUID = "task_graph_uuid"; - @SerializedName(SERIALIZED_NAME_TASK_GRAPH_UUID) - private String taskGraphUuid; - - public static final String SERIALIZED_NAME_CLIENT_NODE_UUID = "client_node_uuid"; - @SerializedName(SERIALIZED_NAME_CLIENT_NODE_UUID) - private String clientNodeUuid; - - public MultiArrayUDF() { - } - - public MultiArrayUDF udfInfoName(String udfInfoName) { - - this.udfInfoName = udfInfoName; - return this; - } - - /** - * name of UDFInfo to run, format is {namespace}/{udf_name}. Can not be used with exec - * @return udfInfoName - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "TileDB-Inc/quickstart_median", value = "name of UDFInfo to run, format is {namespace}/{udf_name}. Can not be used with exec") - - public String getUdfInfoName() { - return udfInfoName; - } - - - public void setUdfInfoName(String udfInfoName) { - this.udfInfoName = udfInfoName; - } - - - public MultiArrayUDF language(UDFLanguage language) { - - this.language = language; - return this; - } - - /** - * Get language - * @return language - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public UDFLanguage getLanguage() { - return language; - } - - - public void setLanguage(UDFLanguage language) { - this.language = language; - } - - - public MultiArrayUDF version(String version) { - - this.version = version; - return this; - } - - /** - * Type-specific version - * @return version - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Type-specific version") - - public String getVersion() { - return version; - } - - - public void setVersion(String version) { - this.version = version; - } - - - public MultiArrayUDF imageName(String imageName) { - - this.imageName = imageName; - return this; - } - - /** - * Docker image name to use for UDF - * @return imageName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Docker image name to use for UDF") - - public String getImageName() { - return imageName; - } - - - public void setImageName(String imageName) { - this.imageName = imageName; - } - - - public MultiArrayUDF accessCredentialsName(String accessCredentialsName) { - - this.accessCredentialsName = accessCredentialsName; - return this; - } - - /** - * The name of the access credentials to use. if unset, no credentials will be configured in the environment. - * @return accessCredentialsName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The name of the access credentials to use. if unset, no credentials will be configured in the environment.") - - public String getAccessCredentialsName() { - return accessCredentialsName; - } - - - public void setAccessCredentialsName(String accessCredentialsName) { - this.accessCredentialsName = accessCredentialsName; - } - - - public MultiArrayUDF resourceClass(String resourceClass) { - - this.resourceClass = resourceClass; - return this; - } - - /** - * The resource class to use for the UDF execution. Resource classes define resource limits for memory and CPUs. If this is empty, then the UDF will execute in the standard resource class of the TileDB Cloud provider. - * @return resourceClass - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "standard", value = "The resource class to use for the UDF execution. Resource classes define resource limits for memory and CPUs. If this is empty, then the UDF will execute in the standard resource class of the TileDB Cloud provider. ") - - public String getResourceClass() { - return resourceClass; - } - - - public void setResourceClass(String resourceClass) { - this.resourceClass = resourceClass; - } - - - public MultiArrayUDF exec(String exec) { - - this.exec = exec; - return this; - } - - /** - * Type-specific executable text - * @return exec - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Type-specific executable text") - - public String getExec() { - return exec; - } - - - public void setExec(String exec) { - this.exec = exec; - } - - - public MultiArrayUDF execRaw(String execRaw) { - - this.execRaw = execRaw; - return this; - } - - /** - * optional raw text to store of serialized function, used for showing in UI - * @return execRaw - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "optional raw text to store of serialized function, used for showing in UI") - - public String getExecRaw() { - return execRaw; - } - - - public void setExecRaw(String execRaw) { - this.execRaw = execRaw; - } - - - public MultiArrayUDF resultFormat(ResultFormat resultFormat) { - - this.resultFormat = resultFormat; - return this; - } - - /** - * Get resultFormat - * @return resultFormat - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public ResultFormat getResultFormat() { - return resultFormat; - } - - - public void setResultFormat(ResultFormat resultFormat) { - this.resultFormat = resultFormat; - } - - - public MultiArrayUDF taskName(String taskName) { - - this.taskName = taskName; - return this; - } - - /** - * name of task, optional - * @return taskName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "name of task, optional") - - public String getTaskName() { - return taskName; - } - - - public void setTaskName(String taskName) { - this.taskName = taskName; - } - - - public MultiArrayUDF argument(String argument) { - - this.argument = argument; - return this; - } - - /** - * Deprecated: Prefer to use `argument_json` instead. Argument(s) to pass to UDF function, tuple or list of args/kwargs which can be in native or JSON format - * @return argument - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Deprecated: Prefer to use `argument_json` instead. Argument(s) to pass to UDF function, tuple or list of args/kwargs which can be in native or JSON format ") - - public String getArgument() { - return argument; - } - - - public void setArgument(String argument) { - this.argument = argument; - } - - - public MultiArrayUDF argumentsJson(List argumentsJson) { - - this.argumentsJson = argumentsJson; - return this; - } - - public MultiArrayUDF addArgumentsJsonItem(TGUDFArgument argumentsJsonItem) { - if (this.argumentsJson == null) { - this.argumentsJson = new ArrayList<>(); - } - this.argumentsJson.add(argumentsJsonItem); - return this; - } - - /** - * A series of key-value pairs to be passed as arguments into the UDF. See `TGUDFNodeData.arguments` for more information. If this format is used to pass arguments, arrays will be passed into the UDF as specified by the Node placeholders passed in here, rather than the classic method of putting all array arguments in the first parameter. Either this or `argument` should be set. - * @return argumentsJson - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "A series of key-value pairs to be passed as arguments into the UDF. See `TGUDFNodeData.arguments` for more information. If this format is used to pass arguments, arrays will be passed into the UDF as specified by the Node placeholders passed in here, rather than the classic method of putting all array arguments in the first parameter. Either this or `argument` should be set. ") - - public List getArgumentsJson() { - return argumentsJson; - } - - - public void setArgumentsJson(List argumentsJson) { - this.argumentsJson = argumentsJson; - } - - - public MultiArrayUDF storedParamUuids(List storedParamUuids) { - - this.storedParamUuids = storedParamUuids; - return this; - } - - public MultiArrayUDF addStoredParamUuidsItem(String storedParamUuidsItem) { - if (this.storedParamUuids == null) { - this.storedParamUuids = new ArrayList<>(); - } - this.storedParamUuids.add(storedParamUuidsItem); - return this; - } - - /** - * The UUIDs of stored input parameters (passed in a language-specific format within \"argument\") to be retrieved from the server-side cache. Serialized in standard hex format with no {}. - * @return storedParamUuids - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The UUIDs of stored input parameters (passed in a language-specific format within \"argument\") to be retrieved from the server-side cache. Serialized in standard hex format with no {}.") - - public List getStoredParamUuids() { - return storedParamUuids; - } - - - public void setStoredParamUuids(List storedParamUuids) { - this.storedParamUuids = storedParamUuids; - } - - - public MultiArrayUDF storeResults(Boolean storeResults) { - - this.storeResults = storeResults; - return this; - } - - /** - * store results for later retrieval - * @return storeResults - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "store results for later retrieval") - - public Boolean getStoreResults() { - return storeResults; - } - - - public void setStoreResults(Boolean storeResults) { - this.storeResults = storeResults; - } - - - public MultiArrayUDF dontDownloadResults(Boolean dontDownloadResults) { - - this.dontDownloadResults = dontDownloadResults; - return this; - } - - /** - * Set to true to avoid downloading the results of this UDF. Useful for intermediate nodes in a task graph where you will not be using the results of your function. Defaults to false (\"yes download results\"). - * @return dontDownloadResults - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Set to true to avoid downloading the results of this UDF. Useful for intermediate nodes in a task graph where you will not be using the results of your function. Defaults to false (\"yes download results\").") - - public Boolean getDontDownloadResults() { - return dontDownloadResults; - } - - - public void setDontDownloadResults(Boolean dontDownloadResults) { - this.dontDownloadResults = dontDownloadResults; - } - - - public MultiArrayUDF ranges(QueryRanges ranges) { - - this.ranges = ranges; - return this; - } - - /** - * Get ranges - * @return ranges - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public QueryRanges getRanges() { - return ranges; - } - - - public void setRanges(QueryRanges ranges) { - this.ranges = ranges; - } - - - public MultiArrayUDF subarray(UDFSubarray subarray) { - - this.subarray = subarray; - return this; - } - - /** - * Get subarray - * @return subarray - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public UDFSubarray getSubarray() { - return subarray; - } - - - public void setSubarray(UDFSubarray subarray) { - this.subarray = subarray; - } - - - public MultiArrayUDF buffers(List buffers) { - - this.buffers = buffers; - return this; - } - - public MultiArrayUDF addBuffersItem(String buffersItem) { - if (this.buffers == null) { - this.buffers = new ArrayList<>(); - } - this.buffers.add(buffersItem); - return this; - } - - /** - * List of buffers to fetch (attributes + dimensions). Deprecated; please set arrays with `UDFArrayDetails`. - * @return buffers - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "List of buffers to fetch (attributes + dimensions). Deprecated; please set arrays with `UDFArrayDetails`.") - - public List getBuffers() { - return buffers; - } - - - public void setBuffers(List buffers) { - this.buffers = buffers; - } - - - public MultiArrayUDF arrays(List arrays) { - - this.arrays = arrays; - return this; - } - - public MultiArrayUDF addArraysItem(UDFArrayDetails arraysItem) { - if (this.arrays == null) { - this.arrays = new ArrayList<>(); - } - this.arrays.add(arraysItem); - return this; - } - - /** - * Array ranges/buffer into to run UDF on - * @return arrays - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Array ranges/buffer into to run UDF on") - - public List getArrays() { - return arrays; - } - - - public void setArrays(List arrays) { - this.arrays = arrays; - } - - - public MultiArrayUDF timeout(Integer timeout) { - - this.timeout = timeout; - return this; - } - - /** - * UDF-type timeout in seconds (default: 900) - * @return timeout - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "UDF-type timeout in seconds (default: 900)") - - public Integer getTimeout() { - return timeout; - } - - - public void setTimeout(Integer timeout) { - this.timeout = timeout; - } - - - public MultiArrayUDF taskGraphUuid(String taskGraphUuid) { - - this.taskGraphUuid = taskGraphUuid; - return this; - } - - /** - * If set, the ID of the log for the task graph that this was part of. - * @return taskGraphUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "If set, the ID of the log for the task graph that this was part of. ") - - public String getTaskGraphUuid() { - return taskGraphUuid; - } - - - public void setTaskGraphUuid(String taskGraphUuid) { - this.taskGraphUuid = taskGraphUuid; - } - - - public MultiArrayUDF clientNodeUuid(String clientNodeUuid) { - - this.clientNodeUuid = clientNodeUuid; - return this; - } - - /** - * If set, the client-defined ID of the node within this task's graph. - * @return clientNodeUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "If set, the client-defined ID of the node within this task's graph. ") - - public String getClientNodeUuid() { - return clientNodeUuid; - } - - - public void setClientNodeUuid(String clientNodeUuid) { - this.clientNodeUuid = clientNodeUuid; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public MultiArrayUDF putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - MultiArrayUDF multiArrayUDF = (MultiArrayUDF) o; - return Objects.equals(this.udfInfoName, multiArrayUDF.udfInfoName) && - Objects.equals(this.language, multiArrayUDF.language) && - Objects.equals(this.version, multiArrayUDF.version) && - Objects.equals(this.imageName, multiArrayUDF.imageName) && - Objects.equals(this.accessCredentialsName, multiArrayUDF.accessCredentialsName) && - Objects.equals(this.resourceClass, multiArrayUDF.resourceClass) && - Objects.equals(this.exec, multiArrayUDF.exec) && - Objects.equals(this.execRaw, multiArrayUDF.execRaw) && - Objects.equals(this.resultFormat, multiArrayUDF.resultFormat) && - Objects.equals(this.taskName, multiArrayUDF.taskName) && - Objects.equals(this.argument, multiArrayUDF.argument) && - Objects.equals(this.argumentsJson, multiArrayUDF.argumentsJson) && - Objects.equals(this.storedParamUuids, multiArrayUDF.storedParamUuids) && - Objects.equals(this.storeResults, multiArrayUDF.storeResults) && - Objects.equals(this.dontDownloadResults, multiArrayUDF.dontDownloadResults) && - Objects.equals(this.ranges, multiArrayUDF.ranges) && - Objects.equals(this.subarray, multiArrayUDF.subarray) && - Objects.equals(this.buffers, multiArrayUDF.buffers) && - Objects.equals(this.arrays, multiArrayUDF.arrays) && - Objects.equals(this.timeout, multiArrayUDF.timeout) && - Objects.equals(this.taskGraphUuid, multiArrayUDF.taskGraphUuid) && - Objects.equals(this.clientNodeUuid, multiArrayUDF.clientNodeUuid)&& - Objects.equals(this.additionalProperties, multiArrayUDF.additionalProperties); - } - - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); - } - - @Override - public int hashCode() { - return Objects.hash(udfInfoName, language, version, imageName, accessCredentialsName, resourceClass, exec, execRaw, resultFormat, taskName, argument, argumentsJson, storedParamUuids, storeResults, dontDownloadResults, ranges, subarray, buffers, arrays, timeout, taskGraphUuid, clientNodeUuid, additionalProperties); - } - - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class MultiArrayUDF {\n"); - sb.append(" udfInfoName: ").append(toIndentedString(udfInfoName)).append("\n"); - sb.append(" language: ").append(toIndentedString(language)).append("\n"); - sb.append(" version: ").append(toIndentedString(version)).append("\n"); - sb.append(" imageName: ").append(toIndentedString(imageName)).append("\n"); - sb.append(" accessCredentialsName: ").append(toIndentedString(accessCredentialsName)).append("\n"); - sb.append(" resourceClass: ").append(toIndentedString(resourceClass)).append("\n"); - sb.append(" exec: ").append(toIndentedString(exec)).append("\n"); - sb.append(" execRaw: ").append(toIndentedString(execRaw)).append("\n"); - sb.append(" resultFormat: ").append(toIndentedString(resultFormat)).append("\n"); - sb.append(" taskName: ").append(toIndentedString(taskName)).append("\n"); - sb.append(" argument: ").append(toIndentedString(argument)).append("\n"); - sb.append(" argumentsJson: ").append(toIndentedString(argumentsJson)).append("\n"); - sb.append(" storedParamUuids: ").append(toIndentedString(storedParamUuids)).append("\n"); - sb.append(" storeResults: ").append(toIndentedString(storeResults)).append("\n"); - sb.append(" dontDownloadResults: ").append(toIndentedString(dontDownloadResults)).append("\n"); - sb.append(" ranges: ").append(toIndentedString(ranges)).append("\n"); - sb.append(" subarray: ").append(toIndentedString(subarray)).append("\n"); - sb.append(" buffers: ").append(toIndentedString(buffers)).append("\n"); - sb.append(" arrays: ").append(toIndentedString(arrays)).append("\n"); - sb.append(" timeout: ").append(toIndentedString(timeout)).append("\n"); - sb.append(" taskGraphUuid: ").append(toIndentedString(taskGraphUuid)).append("\n"); - sb.append(" clientNodeUuid: ").append(toIndentedString(clientNodeUuid)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("udf_info_name"); - openapiFields.add("language"); - openapiFields.add("version"); - openapiFields.add("image_name"); - openapiFields.add("access_credentials_name"); - openapiFields.add("resource_class"); - openapiFields.add("exec"); - openapiFields.add("exec_raw"); - openapiFields.add("result_format"); - openapiFields.add("task_name"); - openapiFields.add("argument"); - openapiFields.add("arguments_json"); - openapiFields.add("stored_param_uuids"); - openapiFields.add("store_results"); - openapiFields.add("dont_download_results"); - openapiFields.add("ranges"); - openapiFields.add("subarray"); - openapiFields.add("buffers"); - openapiFields.add("arrays"); - openapiFields.add("timeout"); - openapiFields.add("task_graph_uuid"); - openapiFields.add("client_node_uuid"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to MultiArrayUDF - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (MultiArrayUDF.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in MultiArrayUDF is not found in the empty JSON string", MultiArrayUDF.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("udf_info_name") != null && !jsonObj.get("udf_info_name").isJsonNull()) && !jsonObj.get("udf_info_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `udf_info_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("udf_info_name").toString())); - } - if ((jsonObj.get("version") != null && !jsonObj.get("version").isJsonNull()) && !jsonObj.get("version").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `version` to be a primitive type in the JSON string but got `%s`", jsonObj.get("version").toString())); - } - if ((jsonObj.get("image_name") != null && !jsonObj.get("image_name").isJsonNull()) && !jsonObj.get("image_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `image_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("image_name").toString())); - } - if ((jsonObj.get("access_credentials_name") != null && !jsonObj.get("access_credentials_name").isJsonNull()) && !jsonObj.get("access_credentials_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `access_credentials_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("access_credentials_name").toString())); - } - if ((jsonObj.get("resource_class") != null && !jsonObj.get("resource_class").isJsonNull()) && !jsonObj.get("resource_class").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `resource_class` to be a primitive type in the JSON string but got `%s`", jsonObj.get("resource_class").toString())); - } - if ((jsonObj.get("exec") != null && !jsonObj.get("exec").isJsonNull()) && !jsonObj.get("exec").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `exec` to be a primitive type in the JSON string but got `%s`", jsonObj.get("exec").toString())); - } - if ((jsonObj.get("exec_raw") != null && !jsonObj.get("exec_raw").isJsonNull()) && !jsonObj.get("exec_raw").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `exec_raw` to be a primitive type in the JSON string but got `%s`", jsonObj.get("exec_raw").toString())); - } - if ((jsonObj.get("task_name") != null && !jsonObj.get("task_name").isJsonNull()) && !jsonObj.get("task_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `task_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("task_name").toString())); - } - if ((jsonObj.get("argument") != null && !jsonObj.get("argument").isJsonNull()) && !jsonObj.get("argument").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `argument` to be a primitive type in the JSON string but got `%s`", jsonObj.get("argument").toString())); - } - JsonArray jsonArrayargumentsJson = jsonObj.getAsJsonArray("arguments_json"); - if (jsonArrayargumentsJson != null) { - // ensure the json data is an array - if (!jsonObj.get("arguments_json").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `arguments_json` to be an array in the JSON string but got `%s`", jsonObj.get("arguments_json").toString())); - } - - // validate the optional field `arguments_json` (array) - for (int i = 0; i < jsonArrayargumentsJson.size(); i++) { - TGUDFArgument.validateJsonObject(jsonArrayargumentsJson.get(i).getAsJsonObject()); - }; - } - // ensure the json data is an array - if ((jsonObj.get("stored_param_uuids") != null && !jsonObj.get("stored_param_uuids").isJsonNull()) && !jsonObj.get("stored_param_uuids").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `stored_param_uuids` to be an array in the JSON string but got `%s`", jsonObj.get("stored_param_uuids").toString())); - } - // validate the optional field `ranges` - if (jsonObj.get("ranges") != null && !jsonObj.get("ranges").isJsonNull()) { - QueryRanges.validateJsonObject(jsonObj.getAsJsonObject("ranges")); - } - // validate the optional field `subarray` - if (jsonObj.get("subarray") != null && !jsonObj.get("subarray").isJsonNull()) { - UDFSubarray.validateJsonObject(jsonObj.getAsJsonObject("subarray")); - } - // ensure the json data is an array - if ((jsonObj.get("buffers") != null && !jsonObj.get("buffers").isJsonNull()) && !jsonObj.get("buffers").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `buffers` to be an array in the JSON string but got `%s`", jsonObj.get("buffers").toString())); - } - JsonArray jsonArrayarrays = jsonObj.getAsJsonArray("arrays"); - if (jsonArrayarrays != null) { - // ensure the json data is an array - if (!jsonObj.get("arrays").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `arrays` to be an array in the JSON string but got `%s`", jsonObj.get("arrays").toString())); - } - - // validate the optional field `arrays` (array) - for (int i = 0; i < jsonArrayarrays.size(); i++) { - UDFArrayDetails.validateJsonObject(jsonArrayarrays.get(i).getAsJsonObject()); - }; - } - if ((jsonObj.get("task_graph_uuid") != null && !jsonObj.get("task_graph_uuid").isJsonNull()) && !jsonObj.get("task_graph_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `task_graph_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("task_graph_uuid").toString())); - } - if ((jsonObj.get("client_node_uuid") != null && !jsonObj.get("client_node_uuid").isJsonNull()) && !jsonObj.get("client_node_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `client_node_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("client_node_uuid").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!MultiArrayUDF.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'MultiArrayUDF' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(MultiArrayUDF.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, MultiArrayUDF value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public MultiArrayUDF read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - MultiArrayUDF instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of MultiArrayUDF given an JSON string - * - * @param jsonString JSON string - * @return An instance of MultiArrayUDF - * @throws IOException if the JSON string is invalid with respect to MultiArrayUDF - */ - public static MultiArrayUDF fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, MultiArrayUDF.class); - } - - /** - * Convert an instance of MultiArrayUDF to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/NamespaceActions.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/NamespaceActions.java deleted file mode 100644 index 6887713..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/NamespaceActions.java +++ /dev/null @@ -1,89 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * actions a user can take on an organization - */ -@JsonAdapter(NamespaceActions.Adapter.class) -public enum NamespaceActions { - - READ("read"), - - WRITE("write"), - - CREATE("create"), - - DELETE("delete"), - - EDIT("edit"), - - READ_ARRAY_LOGS("read_array_logs"), - - READ_JOB_LOGS("read_job_logs"), - - READ_OBJECT_LOGS("read_object_logs"), - - RUN_JOB("run_job"), - - DELETE_ORGANIZATION("delete_organization"), - - EDIT_ORGANIZATION("edit_organization"), - - EDIT_BILLING("edit_billing"); - - private String value; - - NamespaceActions(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static NamespaceActions fromValue(String value) { - for (NamespaceActions b : NamespaceActions.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final NamespaceActions enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public NamespaceActions read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return NamespaceActions.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/NonEmptyDomain.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/NonEmptyDomain.java deleted file mode 100644 index 302853a..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/NonEmptyDomain.java +++ /dev/null @@ -1,305 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * object representing a non-empty domain - */ -@ApiModel(description = "object representing a non-empty domain") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class NonEmptyDomain { - public static final String SERIALIZED_NAME_NON_EMPTY_DOMAIN = "nonEmptyDomain"; - @SerializedName(SERIALIZED_NAME_NON_EMPTY_DOMAIN) - private DomainArray nonEmptyDomain; - - public static final String SERIALIZED_NAME_IS_EMPTY = "isEmpty"; - @SerializedName(SERIALIZED_NAME_IS_EMPTY) - private Boolean isEmpty; - - public NonEmptyDomain() { - } - - public NonEmptyDomain nonEmptyDomain(DomainArray nonEmptyDomain) { - - this.nonEmptyDomain = nonEmptyDomain; - return this; - } - - /** - * Get nonEmptyDomain - * @return nonEmptyDomain - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public DomainArray getNonEmptyDomain() { - return nonEmptyDomain; - } - - - public void setNonEmptyDomain(DomainArray nonEmptyDomain) { - this.nonEmptyDomain = nonEmptyDomain; - } - - - public NonEmptyDomain isEmpty(Boolean isEmpty) { - - this.isEmpty = isEmpty; - return this; - } - - /** - * Is non-empty domain really empty? - * @return isEmpty - **/ - @javax.annotation.Nonnull - @ApiModelProperty(example = "false", required = true, value = "Is non-empty domain really empty?") - - public Boolean getIsEmpty() { - return isEmpty; - } - - - public void setIsEmpty(Boolean isEmpty) { - this.isEmpty = isEmpty; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public NonEmptyDomain putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - NonEmptyDomain nonEmptyDomain = (NonEmptyDomain) o; - return Objects.equals(this.nonEmptyDomain, nonEmptyDomain.nonEmptyDomain) && - Objects.equals(this.isEmpty, nonEmptyDomain.isEmpty)&& - Objects.equals(this.additionalProperties, nonEmptyDomain.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(nonEmptyDomain, isEmpty, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class NonEmptyDomain {\n"); - sb.append(" nonEmptyDomain: ").append(toIndentedString(nonEmptyDomain)).append("\n"); - sb.append(" isEmpty: ").append(toIndentedString(isEmpty)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("nonEmptyDomain"); - openapiFields.add("isEmpty"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - openapiRequiredFields.add("nonEmptyDomain"); - openapiRequiredFields.add("isEmpty"); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to NonEmptyDomain - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (NonEmptyDomain.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in NonEmptyDomain is not found in the empty JSON string", NonEmptyDomain.openapiRequiredFields.toString())); - } - } - - // check to make sure all required properties/fields are present in the JSON string - for (String requiredField : NonEmptyDomain.openapiRequiredFields) { - if (jsonObj.get(requiredField) == null) { - throw new IllegalArgumentException(String.format("The required field `%s` is not found in the JSON string: %s", requiredField, jsonObj.toString())); - } - } - // validate the optional field `nonEmptyDomain` - if (jsonObj.get("nonEmptyDomain") != null && !jsonObj.get("nonEmptyDomain").isJsonNull()) { - DomainArray.validateJsonObject(jsonObj.getAsJsonObject("nonEmptyDomain")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!NonEmptyDomain.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'NonEmptyDomain' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(NonEmptyDomain.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, NonEmptyDomain value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public NonEmptyDomain read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - NonEmptyDomain instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of NonEmptyDomain given an JSON string - * - * @param jsonString JSON string - * @return An instance of NonEmptyDomain - * @throws IOException if the JSON string is invalid with respect to NonEmptyDomain - */ - public static NonEmptyDomain fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, NonEmptyDomain.class); - } - - /** - * Convert an instance of NonEmptyDomain to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/NotebookCopied.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/NotebookCopied.java deleted file mode 100644 index 42029da..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/NotebookCopied.java +++ /dev/null @@ -1,372 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Copied notebook uri and information - */ -@ApiModel(description = "Copied notebook uri and information") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class NotebookCopied { - public static final String SERIALIZED_NAME_OUTPUT_URI = "output_uri"; - @SerializedName(SERIALIZED_NAME_OUTPUT_URI) - private String outputUri; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public static final String SERIALIZED_NAME_ID = "id"; - @SerializedName(SERIALIZED_NAME_ID) - private String id; - - public NotebookCopied() { - } - - public NotebookCopied outputUri(String outputUri) { - - this.outputUri = outputUri; - return this; - } - - /** - * output location of the TileDB Notebook - * @return outputUri - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "output location of the TileDB Notebook") - - public String getOutputUri() { - return outputUri; - } - - - public void setOutputUri(String outputUri) { - this.outputUri = outputUri; - } - - - public NotebookCopied name(String name) { - - this.name = name; - return this; - } - - /** - * name of the notebook created - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "name of the notebook created") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public NotebookCopied namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * namespace copied to - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "namespace copied to") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - - public NotebookCopied id(String id) { - - this.id = id; - return this; - } - - /** - * unique ID of the copied notebook - * @return id - **/ - @javax.annotation.Nonnull - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", required = true, value = "unique ID of the copied notebook") - - public String getId() { - return id; - } - - - public void setId(String id) { - this.id = id; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public NotebookCopied putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - NotebookCopied notebookCopied = (NotebookCopied) o; - return Objects.equals(this.outputUri, notebookCopied.outputUri) && - Objects.equals(this.name, notebookCopied.name) && - Objects.equals(this.namespace, notebookCopied.namespace) && - Objects.equals(this.id, notebookCopied.id)&& - Objects.equals(this.additionalProperties, notebookCopied.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(outputUri, name, namespace, id, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class NotebookCopied {\n"); - sb.append(" outputUri: ").append(toIndentedString(outputUri)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("output_uri"); - openapiFields.add("name"); - openapiFields.add("namespace"); - openapiFields.add("id"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - openapiRequiredFields.add("id"); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to NotebookCopied - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (NotebookCopied.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in NotebookCopied is not found in the empty JSON string", NotebookCopied.openapiRequiredFields.toString())); - } - } - - // check to make sure all required properties/fields are present in the JSON string - for (String requiredField : NotebookCopied.openapiRequiredFields) { - if (jsonObj.get(requiredField) == null) { - throw new IllegalArgumentException(String.format("The required field `%s` is not found in the JSON string: %s", requiredField, jsonObj.toString())); - } - } - if ((jsonObj.get("output_uri") != null && !jsonObj.get("output_uri").isJsonNull()) && !jsonObj.get("output_uri").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `output_uri` to be a primitive type in the JSON string but got `%s`", jsonObj.get("output_uri").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) && !jsonObj.get("id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("id").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!NotebookCopied.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'NotebookCopied' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(NotebookCopied.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, NotebookCopied value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public NotebookCopied read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - NotebookCopied instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of NotebookCopied given an JSON string - * - * @param jsonString JSON string - * @return An instance of NotebookCopied - * @throws IOException if the JSON string is invalid with respect to NotebookCopied - */ - public static NotebookCopied fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, NotebookCopied.class); - } - - /** - * Convert an instance of NotebookCopied to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/NotebookCopy.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/NotebookCopy.java deleted file mode 100644 index 1ae511a..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/NotebookCopy.java +++ /dev/null @@ -1,331 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Output information required to copy a notebook - */ -@ApiModel(description = "Output information required to copy a notebook") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class NotebookCopy { - public static final String SERIALIZED_NAME_OUTPUT_URI = "output_uri"; - @SerializedName(SERIALIZED_NAME_OUTPUT_URI) - private String outputUri; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public NotebookCopy() { - } - - public NotebookCopy outputUri(String outputUri) { - - this.outputUri = outputUri; - return this; - } - - /** - * output location of the TileDB File - * @return outputUri - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "output location of the TileDB File") - - public String getOutputUri() { - return outputUri; - } - - - public void setOutputUri(String outputUri) { - this.outputUri = outputUri; - } - - - public NotebookCopy name(String name) { - - this.name = name; - return this; - } - - /** - * name to set for registered notebook - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "name to set for registered notebook") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public NotebookCopy namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * namespace to copy to - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "namespace to copy to") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public NotebookCopy putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - NotebookCopy notebookCopy = (NotebookCopy) o; - return Objects.equals(this.outputUri, notebookCopy.outputUri) && - Objects.equals(this.name, notebookCopy.name) && - Objects.equals(this.namespace, notebookCopy.namespace)&& - Objects.equals(this.additionalProperties, notebookCopy.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(outputUri, name, namespace, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class NotebookCopy {\n"); - sb.append(" outputUri: ").append(toIndentedString(outputUri)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("output_uri"); - openapiFields.add("name"); - openapiFields.add("namespace"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to NotebookCopy - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (NotebookCopy.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in NotebookCopy is not found in the empty JSON string", NotebookCopy.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("output_uri") != null && !jsonObj.get("output_uri").isJsonNull()) && !jsonObj.get("output_uri").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `output_uri` to be a primitive type in the JSON string but got `%s`", jsonObj.get("output_uri").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!NotebookCopy.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'NotebookCopy' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(NotebookCopy.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, NotebookCopy value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public NotebookCopy read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - NotebookCopy instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of NotebookCopy given an JSON string - * - * @param jsonString JSON string - * @return An instance of NotebookCopy - * @throws IOException if the JSON string is invalid with respect to NotebookCopy - */ - public static NotebookCopy fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, NotebookCopy.class); - } - - /** - * Convert an instance of NotebookCopy to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/NotebookFavorite.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/NotebookFavorite.java deleted file mode 100644 index 63d8936..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/NotebookFavorite.java +++ /dev/null @@ -1,331 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * A user-favorite notebook item - */ -@ApiModel(description = "A user-favorite notebook item") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class NotebookFavorite { - public static final String SERIALIZED_NAME_NOTEBOOK_UUID = "notebook_uuid"; - @SerializedName(SERIALIZED_NAME_NOTEBOOK_UUID) - private String notebookUuid; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public NotebookFavorite() { - } - - public NotebookFavorite notebookUuid(String notebookUuid) { - - this.notebookUuid = notebookUuid; - return this; - } - - /** - * unique UUID of the notebook - * @return notebookUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "unique UUID of the notebook") - - public String getNotebookUuid() { - return notebookUuid; - } - - - public void setNotebookUuid(String notebookUuid) { - this.notebookUuid = notebookUuid; - } - - - public NotebookFavorite namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * the namespace of the notebook - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "the namespace of the notebook") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - - public NotebookFavorite name(String name) { - - this.name = name; - return this; - } - - /** - * the name of the notebook - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "the name of the notebook") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public NotebookFavorite putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - NotebookFavorite notebookFavorite = (NotebookFavorite) o; - return Objects.equals(this.notebookUuid, notebookFavorite.notebookUuid) && - Objects.equals(this.namespace, notebookFavorite.namespace) && - Objects.equals(this.name, notebookFavorite.name)&& - Objects.equals(this.additionalProperties, notebookFavorite.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(notebookUuid, namespace, name, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class NotebookFavorite {\n"); - sb.append(" notebookUuid: ").append(toIndentedString(notebookUuid)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("notebook_uuid"); - openapiFields.add("namespace"); - openapiFields.add("name"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to NotebookFavorite - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (NotebookFavorite.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in NotebookFavorite is not found in the empty JSON string", NotebookFavorite.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("notebook_uuid") != null && !jsonObj.get("notebook_uuid").isJsonNull()) && !jsonObj.get("notebook_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `notebook_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("notebook_uuid").toString())); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!NotebookFavorite.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'NotebookFavorite' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(NotebookFavorite.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, NotebookFavorite value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public NotebookFavorite read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - NotebookFavorite instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of NotebookFavorite given an JSON string - * - * @param jsonString JSON string - * @return An instance of NotebookFavorite - * @throws IOException if the JSON string is invalid with respect to NotebookFavorite - */ - public static NotebookFavorite fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, NotebookFavorite.class); - } - - /** - * Convert an instance of NotebookFavorite to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/NotebookFavoritesData.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/NotebookFavoritesData.java deleted file mode 100644 index c9fece4..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/NotebookFavoritesData.java +++ /dev/null @@ -1,319 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Object including notebook favorites and pagination metadata - */ -@ApiModel(description = "Object including notebook favorites and pagination metadata") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class NotebookFavoritesData { - public static final String SERIALIZED_NAME_NOTEBOOKS = "notebooks"; - @SerializedName(SERIALIZED_NAME_NOTEBOOKS) - private List notebooks = null; - - public static final String SERIALIZED_NAME_PAGINATION_METADATA = "pagination_metadata"; - @SerializedName(SERIALIZED_NAME_PAGINATION_METADATA) - private PaginationMetadata paginationMetadata; - - public NotebookFavoritesData() { - } - - public NotebookFavoritesData notebooks(List notebooks) { - - this.notebooks = notebooks; - return this; - } - - public NotebookFavoritesData addNotebooksItem(ArrayInfo notebooksItem) { - if (this.notebooks == null) { - this.notebooks = new ArrayList<>(); - } - this.notebooks.add(notebooksItem); - return this; - } - - /** - * List of notebook infos - * @return notebooks - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "List of notebook infos") - - public List getNotebooks() { - return notebooks; - } - - - public void setNotebooks(List notebooks) { - this.notebooks = notebooks; - } - - - public NotebookFavoritesData paginationMetadata(PaginationMetadata paginationMetadata) { - - this.paginationMetadata = paginationMetadata; - return this; - } - - /** - * Get paginationMetadata - * @return paginationMetadata - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public PaginationMetadata getPaginationMetadata() { - return paginationMetadata; - } - - - public void setPaginationMetadata(PaginationMetadata paginationMetadata) { - this.paginationMetadata = paginationMetadata; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public NotebookFavoritesData putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - NotebookFavoritesData notebookFavoritesData = (NotebookFavoritesData) o; - return Objects.equals(this.notebooks, notebookFavoritesData.notebooks) && - Objects.equals(this.paginationMetadata, notebookFavoritesData.paginationMetadata)&& - Objects.equals(this.additionalProperties, notebookFavoritesData.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(notebooks, paginationMetadata, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class NotebookFavoritesData {\n"); - sb.append(" notebooks: ").append(toIndentedString(notebooks)).append("\n"); - sb.append(" paginationMetadata: ").append(toIndentedString(paginationMetadata)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("notebooks"); - openapiFields.add("pagination_metadata"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to NotebookFavoritesData - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (NotebookFavoritesData.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in NotebookFavoritesData is not found in the empty JSON string", NotebookFavoritesData.openapiRequiredFields.toString())); - } - } - JsonArray jsonArraynotebooks = jsonObj.getAsJsonArray("notebooks"); - if (jsonArraynotebooks != null) { - // ensure the json data is an array - if (!jsonObj.get("notebooks").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `notebooks` to be an array in the JSON string but got `%s`", jsonObj.get("notebooks").toString())); - } - - // validate the optional field `notebooks` (array) - for (int i = 0; i < jsonArraynotebooks.size(); i++) { - ArrayInfo.validateJsonObject(jsonArraynotebooks.get(i).getAsJsonObject()); - }; - } - // validate the optional field `pagination_metadata` - if (jsonObj.get("pagination_metadata") != null && !jsonObj.get("pagination_metadata").isJsonNull()) { - PaginationMetadata.validateJsonObject(jsonObj.getAsJsonObject("pagination_metadata")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!NotebookFavoritesData.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'NotebookFavoritesData' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(NotebookFavoritesData.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, NotebookFavoritesData value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public NotebookFavoritesData read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - NotebookFavoritesData instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of NotebookFavoritesData given an JSON string - * - * @param jsonString JSON string - * @return An instance of NotebookFavoritesData - * @throws IOException if the JSON string is invalid with respect to NotebookFavoritesData - */ - public static NotebookFavoritesData fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, NotebookFavoritesData.class); - } - - /** - * Convert an instance of NotebookFavoritesData to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/NotebookStatus.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/NotebookStatus.java deleted file mode 100644 index c317d70..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/NotebookStatus.java +++ /dev/null @@ -1,577 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import org.openapitools.jackson.nullable.JsonNullable; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Status details of a notebook server - */ -@ApiModel(description = "Status details of a notebook server") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class NotebookStatus { - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public static final String SERIALIZED_NAME_UPTIME = "uptime"; - @SerializedName(SERIALIZED_NAME_UPTIME) - private Integer uptime; - - public static final String SERIALIZED_NAME_CPU_USAGE = "cpu_usage"; - @SerializedName(SERIALIZED_NAME_CPU_USAGE) - private Integer cpuUsage; - - public static final String SERIALIZED_NAME_GPU_USAGE = "gpu_usage"; - @SerializedName(SERIALIZED_NAME_GPU_USAGE) - private Integer gpuUsage; - - public static final String SERIALIZED_NAME_MEMORY_USAGE = "memory_usage"; - @SerializedName(SERIALIZED_NAME_MEMORY_USAGE) - private Integer memoryUsage; - - public static final String SERIALIZED_NAME_GPU_LIMIT = "gpu_limit"; - @SerializedName(SERIALIZED_NAME_GPU_LIMIT) - private Integer gpuLimit; - - public static final String SERIALIZED_NAME_MEMORY_LIMIT = "memory_limit"; - @SerializedName(SERIALIZED_NAME_MEMORY_LIMIT) - private Integer memoryLimit; - - public static final String SERIALIZED_NAME_STORAGE_USAGE = "storage_usage"; - @SerializedName(SERIALIZED_NAME_STORAGE_USAGE) - private Integer storageUsage; - - public static final String SERIALIZED_NAME_STORAGE_LIMIT = "storage_limit"; - @SerializedName(SERIALIZED_NAME_STORAGE_LIMIT) - private Integer storageLimit; - - public static final String SERIALIZED_NAME_CPU_COUNT = "cpu_count"; - @SerializedName(SERIALIZED_NAME_CPU_COUNT) - private Integer cpuCount; - - public static final String SERIALIZED_NAME_COST = "cost"; - @SerializedName(SERIALIZED_NAME_COST) - private Double cost; - - public NotebookStatus() { - } - - public NotebookStatus namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * namespace of notebook - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "namespace of notebook") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - - public NotebookStatus uptime(Integer uptime) { - - this.uptime = uptime; - return this; - } - - /** - * duration notebook has been running in seconds - * @return uptime - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "120", value = "duration notebook has been running in seconds") - - public Integer getUptime() { - return uptime; - } - - - public void setUptime(Integer uptime) { - this.uptime = uptime; - } - - - public NotebookStatus cpuUsage(Integer cpuUsage) { - - this.cpuUsage = cpuUsage; - return this; - } - - /** - * current cpu usage in millicpu - * @return cpuUsage - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "4000", value = "current cpu usage in millicpu") - - public Integer getCpuUsage() { - return cpuUsage; - } - - - public void setCpuUsage(Integer cpuUsage) { - this.cpuUsage = cpuUsage; - } - - - public NotebookStatus gpuUsage(Integer gpuUsage) { - - this.gpuUsage = gpuUsage; - return this; - } - - /** - * gpu usage in milligpu - * @return gpuUsage - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "4000", value = "gpu usage in milligpu") - - public Integer getGpuUsage() { - return gpuUsage; - } - - - public void setGpuUsage(Integer gpuUsage) { - this.gpuUsage = gpuUsage; - } - - - public NotebookStatus memoryUsage(Integer memoryUsage) { - - this.memoryUsage = memoryUsage; - return this; - } - - /** - * memory usage in bytes - * @return memoryUsage - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "1073741824", value = "memory usage in bytes") - - public Integer getMemoryUsage() { - return memoryUsage; - } - - - public void setMemoryUsage(Integer memoryUsage) { - this.memoryUsage = memoryUsage; - } - - - public NotebookStatus gpuLimit(Integer gpuLimit) { - - this.gpuLimit = gpuLimit; - return this; - } - - /** - * gpu limit in milligpu - * @return gpuLimit - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "1073741824", value = "gpu limit in milligpu") - - public Integer getGpuLimit() { - return gpuLimit; - } - - - public void setGpuLimit(Integer gpuLimit) { - this.gpuLimit = gpuLimit; - } - - - public NotebookStatus memoryLimit(Integer memoryLimit) { - - this.memoryLimit = memoryLimit; - return this; - } - - /** - * memory allocated to notebook server in bytes - * @return memoryLimit - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "1073741824", value = "memory allocated to notebook server in bytes") - - public Integer getMemoryLimit() { - return memoryLimit; - } - - - public void setMemoryLimit(Integer memoryLimit) { - this.memoryLimit = memoryLimit; - } - - - public NotebookStatus storageUsage(Integer storageUsage) { - - this.storageUsage = storageUsage; - return this; - } - - /** - * storage usage in bytes - * @return storageUsage - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "1073741824", value = "storage usage in bytes") - - public Integer getStorageUsage() { - return storageUsage; - } - - - public void setStorageUsage(Integer storageUsage) { - this.storageUsage = storageUsage; - } - - - public NotebookStatus storageLimit(Integer storageLimit) { - - this.storageLimit = storageLimit; - return this; - } - - /** - * storage allocated to notebook server in bytes - * @return storageLimit - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "1073741824", value = "storage allocated to notebook server in bytes") - - public Integer getStorageLimit() { - return storageLimit; - } - - - public void setStorageLimit(Integer storageLimit) { - this.storageLimit = storageLimit; - } - - - public NotebookStatus cpuCount(Integer cpuCount) { - - this.cpuCount = cpuCount; - return this; - } - - /** - * millicpu allocated to notebook server - * @return cpuCount - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "4000", value = "millicpu allocated to notebook server") - - public Integer getCpuCount() { - return cpuCount; - } - - - public void setCpuCount(Integer cpuCount) { - this.cpuCount = cpuCount; - } - - - public NotebookStatus cost(Double cost) { - - this.cost = cost; - return this; - } - - /** - * cost in USD for the current notebook session - * @return cost - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "0.27", value = "cost in USD for the current notebook session") - - public Double getCost() { - return cost; - } - - - public void setCost(Double cost) { - this.cost = cost; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public NotebookStatus putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - NotebookStatus notebookStatus = (NotebookStatus) o; - return Objects.equals(this.namespace, notebookStatus.namespace) && - Objects.equals(this.uptime, notebookStatus.uptime) && - Objects.equals(this.cpuUsage, notebookStatus.cpuUsage) && - Objects.equals(this.gpuUsage, notebookStatus.gpuUsage) && - Objects.equals(this.memoryUsage, notebookStatus.memoryUsage) && - Objects.equals(this.gpuLimit, notebookStatus.gpuLimit) && - Objects.equals(this.memoryLimit, notebookStatus.memoryLimit) && - Objects.equals(this.storageUsage, notebookStatus.storageUsage) && - Objects.equals(this.storageLimit, notebookStatus.storageLimit) && - Objects.equals(this.cpuCount, notebookStatus.cpuCount) && - Objects.equals(this.cost, notebookStatus.cost)&& - Objects.equals(this.additionalProperties, notebookStatus.additionalProperties); - } - - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); - } - - @Override - public int hashCode() { - return Objects.hash(namespace, uptime, cpuUsage, gpuUsage, memoryUsage, gpuLimit, memoryLimit, storageUsage, storageLimit, cpuCount, cost, additionalProperties); - } - - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class NotebookStatus {\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" uptime: ").append(toIndentedString(uptime)).append("\n"); - sb.append(" cpuUsage: ").append(toIndentedString(cpuUsage)).append("\n"); - sb.append(" gpuUsage: ").append(toIndentedString(gpuUsage)).append("\n"); - sb.append(" memoryUsage: ").append(toIndentedString(memoryUsage)).append("\n"); - sb.append(" gpuLimit: ").append(toIndentedString(gpuLimit)).append("\n"); - sb.append(" memoryLimit: ").append(toIndentedString(memoryLimit)).append("\n"); - sb.append(" storageUsage: ").append(toIndentedString(storageUsage)).append("\n"); - sb.append(" storageLimit: ").append(toIndentedString(storageLimit)).append("\n"); - sb.append(" cpuCount: ").append(toIndentedString(cpuCount)).append("\n"); - sb.append(" cost: ").append(toIndentedString(cost)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("namespace"); - openapiFields.add("uptime"); - openapiFields.add("cpu_usage"); - openapiFields.add("gpu_usage"); - openapiFields.add("memory_usage"); - openapiFields.add("gpu_limit"); - openapiFields.add("memory_limit"); - openapiFields.add("storage_usage"); - openapiFields.add("storage_limit"); - openapiFields.add("cpu_count"); - openapiFields.add("cost"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to NotebookStatus - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (NotebookStatus.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in NotebookStatus is not found in the empty JSON string", NotebookStatus.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!NotebookStatus.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'NotebookStatus' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(NotebookStatus.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, NotebookStatus value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public NotebookStatus read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - NotebookStatus instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of NotebookStatus given an JSON string - * - * @param jsonString JSON string - * @return An instance of NotebookStatus - * @throws IOException if the JSON string is invalid with respect to NotebookStatus - */ - public static NotebookStatus fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, NotebookStatus.class); - } - - /** - * Convert an instance of NotebookStatus to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Organization.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/Organization.java deleted file mode 100644 index a058cbb..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Organization.java +++ /dev/null @@ -1,781 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.math.BigDecimal; -import java.time.OffsetDateTime; -import java.util.ArrayList; -import java.util.List; - -import org.openapitools.jackson.nullable.JsonNullable; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Organization - */ -@ApiModel(description = "Organization") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class Organization { - public static final String SERIALIZED_NAME_ID = "id"; - @SerializedName(SERIALIZED_NAME_ID) - private String id; - - public static final String SERIALIZED_NAME_ROLE = "role"; - @SerializedName(SERIALIZED_NAME_ROLE) - private OrganizationRoles role; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_CREATED_AT = "created_at"; - @SerializedName(SERIALIZED_NAME_CREATED_AT) - private OffsetDateTime createdAt; - - public static final String SERIALIZED_NAME_UPDATED_AT = "updated_at"; - @SerializedName(SERIALIZED_NAME_UPDATED_AT) - private OffsetDateTime updatedAt; - - public static final String SERIALIZED_NAME_LOGO = "logo"; - @SerializedName(SERIALIZED_NAME_LOGO) - private String logo; - - public static final String SERIALIZED_NAME_DESCRIPTION = "description"; - @SerializedName(SERIALIZED_NAME_DESCRIPTION) - private String description; - - public static final String SERIALIZED_NAME_USERS = "users"; - @SerializedName(SERIALIZED_NAME_USERS) - private List users = null; - - public static final String SERIALIZED_NAME_ALLOWED_ACTIONS = "allowed_actions"; - @SerializedName(SERIALIZED_NAME_ALLOWED_ACTIONS) - private List allowedActions = null; - - public static final String SERIALIZED_NAME_NUM_OF_ARRAYS = "num_of_arrays"; - @SerializedName(SERIALIZED_NAME_NUM_OF_ARRAYS) - private BigDecimal numOfArrays; - - public static final String SERIALIZED_NAME_ENABLED_FEATURES = "enabled_features"; - @SerializedName(SERIALIZED_NAME_ENABLED_FEATURES) - private List enabledFeatures = null; - - public static final String SERIALIZED_NAME_UNPAID_SUBSCRIPTION = "unpaid_subscription"; - @SerializedName(SERIALIZED_NAME_UNPAID_SUBSCRIPTION) - private Boolean unpaidSubscription; - - public static final String SERIALIZED_NAME_DEFAULT_S3_PATH = "default_s3_path"; - @SerializedName(SERIALIZED_NAME_DEFAULT_S3_PATH) - private String defaultS3Path; - - public static final String SERIALIZED_NAME_DEFAULT_S3_PATH_CREDENTIALS_NAME = "default_s3_path_credentials_name"; - @SerializedName(SERIALIZED_NAME_DEFAULT_S3_PATH_CREDENTIALS_NAME) - private String defaultS3PathCredentialsName; - - public static final String SERIALIZED_NAME_ASSET_LOCATIONS = "asset_locations"; - @SerializedName(SERIALIZED_NAME_ASSET_LOCATIONS) - private AssetLocations assetLocations; - - public static final String SERIALIZED_NAME_STRIPE_CONNECT = "stripe_connect"; - @SerializedName(SERIALIZED_NAME_STRIPE_CONNECT) - private Boolean stripeConnect; - - public Organization() { - } - - - public Organization( - List enabledFeatures, - Boolean unpaidSubscription, - Boolean stripeConnect - ) { - this(); - this.enabledFeatures = enabledFeatures; - this.unpaidSubscription = unpaidSubscription; - this.stripeConnect = stripeConnect; - } - - public Organization id(String id) { - - this.id = id; - return this; - } - - /** - * unique ID of organization - * @return id - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "unique ID of organization") - - public String getId() { - return id; - } - - - public void setId(String id) { - this.id = id; - } - - - public Organization role(OrganizationRoles role) { - - this.role = role; - return this; - } - - /** - * Get role - * @return role - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public OrganizationRoles getRole() { - return role; - } - - - public void setRole(OrganizationRoles role) { - this.role = role; - } - - - public Organization name(String name) { - - this.name = name; - return this; - } - - /** - * organization name must be unique - * @return name - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "organization name must be unique") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public Organization createdAt(OffsetDateTime createdAt) { - - this.createdAt = createdAt; - return this; - } - - /** - * Datetime organization was created in UTC - * @return createdAt - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Datetime organization was created in UTC") - - public OffsetDateTime getCreatedAt() { - return createdAt; - } - - - public void setCreatedAt(OffsetDateTime createdAt) { - this.createdAt = createdAt; - } - - - public Organization updatedAt(OffsetDateTime updatedAt) { - - this.updatedAt = updatedAt; - return this; - } - - /** - * Datetime organization was updated in UTC - * @return updatedAt - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Datetime organization was updated in UTC") - - public OffsetDateTime getUpdatedAt() { - return updatedAt; - } - - - public void setUpdatedAt(OffsetDateTime updatedAt) { - this.updatedAt = updatedAt; - } - - - public Organization logo(String logo) { - - this.logo = logo; - return this; - } - - /** - * Organization logo - * @return logo - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Organization logo") - - public String getLogo() { - return logo; - } - - - public void setLogo(String logo) { - this.logo = logo; - } - - - public Organization description(String description) { - - this.description = description; - return this; - } - - /** - * Organization description - * @return description - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Organization description") - - public String getDescription() { - return description; - } - - - public void setDescription(String description) { - this.description = description; - } - - - public Organization users(List users) { - - this.users = users; - return this; - } - - public Organization addUsersItem(OrganizationUser usersItem) { - if (this.users == null) { - this.users = new ArrayList<>(); - } - this.users.add(usersItem); - return this; - } - - /** - * Get users - * @return users - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List getUsers() { - return users; - } - - - public void setUsers(List users) { - this.users = users; - } - - - public Organization allowedActions(List allowedActions) { - - this.allowedActions = allowedActions; - return this; - } - - public Organization addAllowedActionsItem(NamespaceActions allowedActionsItem) { - if (this.allowedActions == null) { - this.allowedActions = new ArrayList<>(); - } - this.allowedActions.add(allowedActionsItem); - return this; - } - - /** - * list of actions user is allowed to do on this organization - * @return allowedActions - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "list of actions user is allowed to do on this organization") - - public List getAllowedActions() { - return allowedActions; - } - - - public void setAllowedActions(List allowedActions) { - this.allowedActions = allowedActions; - } - - - public Organization numOfArrays(BigDecimal numOfArrays) { - - this.numOfArrays = numOfArrays; - return this; - } - - /** - * number of registered arrays for this organization - * @return numOfArrays - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "number of registered arrays for this organization") - - public BigDecimal getNumOfArrays() { - return numOfArrays; - } - - - public void setNumOfArrays(BigDecimal numOfArrays) { - this.numOfArrays = numOfArrays; - } - - - /** - * List of extra/optional/beta features to enable for namespace - * @return enabledFeatures - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "List of extra/optional/beta features to enable for namespace") - - public List getEnabledFeatures() { - return enabledFeatures; - } - - - - - /** - * A notice that the user has an unpaid subscription - * @return unpaidSubscription - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "A notice that the user has an unpaid subscription") - - public Boolean getUnpaidSubscription() { - return unpaidSubscription; - } - - - - - public Organization defaultS3Path(String defaultS3Path) { - - this.defaultS3Path = defaultS3Path; - return this; - } - - /** - * The default location to store newly-created notebooks and other assets like UDFs. The name `default_s3_path` is a legacy holdover; it may refer to any supported storage location. - * @return defaultS3Path - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The default location to store newly-created notebooks and other assets like UDFs. The name `default_s3_path` is a legacy holdover; it may refer to any supported storage location. ") - - public String getDefaultS3Path() { - return defaultS3Path; - } - - - public void setDefaultS3Path(String defaultS3Path) { - this.defaultS3Path = defaultS3Path; - } - - - public Organization defaultS3PathCredentialsName(String defaultS3PathCredentialsName) { - - this.defaultS3PathCredentialsName = defaultS3PathCredentialsName; - return this; - } - - /** - * The name of the credentials used to create and access files in the `default_s3_path`, if needed. - * @return defaultS3PathCredentialsName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The name of the credentials used to create and access files in the `default_s3_path`, if needed. ") - - public String getDefaultS3PathCredentialsName() { - return defaultS3PathCredentialsName; - } - - - public void setDefaultS3PathCredentialsName(String defaultS3PathCredentialsName) { - this.defaultS3PathCredentialsName = defaultS3PathCredentialsName; - } - - - public Organization assetLocations(AssetLocations assetLocations) { - - this.assetLocations = assetLocations; - return this; - } - - /** - * Get assetLocations - * @return assetLocations - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public AssetLocations getAssetLocations() { - return assetLocations; - } - - - public void setAssetLocations(AssetLocations assetLocations) { - this.assetLocations = assetLocations; - } - - - /** - * Denotes that the organization is able to apply pricing to arrays by means of Stripe Connect - * @return stripeConnect - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "false", value = "Denotes that the organization is able to apply pricing to arrays by means of Stripe Connect") - - public Boolean getStripeConnect() { - return stripeConnect; - } - - - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public Organization putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Organization organization = (Organization) o; - return Objects.equals(this.id, organization.id) && - Objects.equals(this.role, organization.role) && - Objects.equals(this.name, organization.name) && - Objects.equals(this.createdAt, organization.createdAt) && - Objects.equals(this.updatedAt, organization.updatedAt) && - Objects.equals(this.logo, organization.logo) && - Objects.equals(this.description, organization.description) && - Objects.equals(this.users, organization.users) && - Objects.equals(this.allowedActions, organization.allowedActions) && - Objects.equals(this.numOfArrays, organization.numOfArrays) && - Objects.equals(this.enabledFeatures, organization.enabledFeatures) && - Objects.equals(this.unpaidSubscription, organization.unpaidSubscription) && - Objects.equals(this.defaultS3Path, organization.defaultS3Path) && - Objects.equals(this.defaultS3PathCredentialsName, organization.defaultS3PathCredentialsName) && - Objects.equals(this.assetLocations, organization.assetLocations) && - Objects.equals(this.stripeConnect, organization.stripeConnect)&& - Objects.equals(this.additionalProperties, organization.additionalProperties); - } - - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); - } - - @Override - public int hashCode() { - return Objects.hash(id, role, name, createdAt, updatedAt, logo, description, users, allowedActions, numOfArrays, enabledFeatures, unpaidSubscription, defaultS3Path, defaultS3PathCredentialsName, assetLocations, stripeConnect, additionalProperties); - } - - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Organization {\n"); - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" role: ").append(toIndentedString(role)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); - sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n"); - sb.append(" logo: ").append(toIndentedString(logo)).append("\n"); - sb.append(" description: ").append(toIndentedString(description)).append("\n"); - sb.append(" users: ").append(toIndentedString(users)).append("\n"); - sb.append(" allowedActions: ").append(toIndentedString(allowedActions)).append("\n"); - sb.append(" numOfArrays: ").append(toIndentedString(numOfArrays)).append("\n"); - sb.append(" enabledFeatures: ").append(toIndentedString(enabledFeatures)).append("\n"); - sb.append(" unpaidSubscription: ").append(toIndentedString(unpaidSubscription)).append("\n"); - sb.append(" defaultS3Path: ").append(toIndentedString(defaultS3Path)).append("\n"); - sb.append(" defaultS3PathCredentialsName: ").append(toIndentedString(defaultS3PathCredentialsName)).append("\n"); - sb.append(" assetLocations: ").append(toIndentedString(assetLocations)).append("\n"); - sb.append(" stripeConnect: ").append(toIndentedString(stripeConnect)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("id"); - openapiFields.add("role"); - openapiFields.add("name"); - openapiFields.add("created_at"); - openapiFields.add("updated_at"); - openapiFields.add("logo"); - openapiFields.add("description"); - openapiFields.add("users"); - openapiFields.add("allowed_actions"); - openapiFields.add("num_of_arrays"); - openapiFields.add("enabled_features"); - openapiFields.add("unpaid_subscription"); - openapiFields.add("default_s3_path"); - openapiFields.add("default_s3_path_credentials_name"); - openapiFields.add("asset_locations"); - openapiFields.add("stripe_connect"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - openapiRequiredFields.add("name"); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to Organization - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (Organization.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in Organization is not found in the empty JSON string", Organization.openapiRequiredFields.toString())); - } - } - - // check to make sure all required properties/fields are present in the JSON string - for (String requiredField : Organization.openapiRequiredFields) { - if (jsonObj.get(requiredField) == null) { - throw new IllegalArgumentException(String.format("The required field `%s` is not found in the JSON string: %s", requiredField, jsonObj.toString())); - } - } - if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) && !jsonObj.get("id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("id").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - if ((jsonObj.get("logo") != null && !jsonObj.get("logo").isJsonNull()) && !jsonObj.get("logo").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `logo` to be a primitive type in the JSON string but got `%s`", jsonObj.get("logo").toString())); - } - if ((jsonObj.get("description") != null && !jsonObj.get("description").isJsonNull()) && !jsonObj.get("description").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `description` to be a primitive type in the JSON string but got `%s`", jsonObj.get("description").toString())); - } - JsonArray jsonArrayusers = jsonObj.getAsJsonArray("users"); - if (jsonArrayusers != null) { - // ensure the json data is an array - if (!jsonObj.get("users").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `users` to be an array in the JSON string but got `%s`", jsonObj.get("users").toString())); - } - - // validate the optional field `users` (array) - for (int i = 0; i < jsonArrayusers.size(); i++) { - OrganizationUser.validateJsonObject(jsonArrayusers.get(i).getAsJsonObject()); - }; - } - // ensure the json data is an array - if ((jsonObj.get("allowed_actions") != null && !jsonObj.get("allowed_actions").isJsonNull()) && !jsonObj.get("allowed_actions").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `allowed_actions` to be an array in the JSON string but got `%s`", jsonObj.get("allowed_actions").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("enabled_features") != null && !jsonObj.get("enabled_features").isJsonNull()) && !jsonObj.get("enabled_features").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `enabled_features` to be an array in the JSON string but got `%s`", jsonObj.get("enabled_features").toString())); - } - if ((jsonObj.get("default_s3_path") != null && !jsonObj.get("default_s3_path").isJsonNull()) && !jsonObj.get("default_s3_path").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `default_s3_path` to be a primitive type in the JSON string but got `%s`", jsonObj.get("default_s3_path").toString())); - } - if ((jsonObj.get("default_s3_path_credentials_name") != null && !jsonObj.get("default_s3_path_credentials_name").isJsonNull()) && !jsonObj.get("default_s3_path_credentials_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `default_s3_path_credentials_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("default_s3_path_credentials_name").toString())); - } - // validate the optional field `asset_locations` - if (jsonObj.get("asset_locations") != null && !jsonObj.get("asset_locations").isJsonNull()) { - AssetLocations.validateJsonObject(jsonObj.getAsJsonObject("asset_locations")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!Organization.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'Organization' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(Organization.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, Organization value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public Organization read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - Organization instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of Organization given an JSON string - * - * @param jsonString JSON string - * @return An instance of Organization - * @throws IOException if the JSON string is invalid with respect to Organization - */ - public static Organization fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, Organization.class); - } - - /** - * Convert an instance of Organization to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/OrganizationRoles.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/OrganizationRoles.java deleted file mode 100644 index 17e3f92..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/OrganizationRoles.java +++ /dev/null @@ -1,73 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * role user has in organization - */ -@JsonAdapter(OrganizationRoles.Adapter.class) -public enum OrganizationRoles { - - OWNER("owner"), - - ADMIN("admin"), - - READ_WRITE("read_write"), - - READ_ONLY("read_only"); - - private String value; - - OrganizationRoles(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static OrganizationRoles fromValue(String value) { - for (OrganizationRoles b : OrganizationRoles.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final OrganizationRoles enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public OrganizationRoles read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return OrganizationRoles.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/OrganizationUser.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/OrganizationUser.java deleted file mode 100644 index f284ce1..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/OrganizationUser.java +++ /dev/null @@ -1,438 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * user in an organization - */ -@ApiModel(description = "user in an organization") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class OrganizationUser { - public static final String SERIALIZED_NAME_USER_ID = "user_id"; - @SerializedName(SERIALIZED_NAME_USER_ID) - private String userId; - - public static final String SERIALIZED_NAME_ORGANIZATION_ID = "organization_id"; - @SerializedName(SERIALIZED_NAME_ORGANIZATION_ID) - private String organizationId; - - public static final String SERIALIZED_NAME_USERNAME = "username"; - @SerializedName(SERIALIZED_NAME_USERNAME) - private String username; - - public static final String SERIALIZED_NAME_ORGANIZATION_NAME = "organization_name"; - @SerializedName(SERIALIZED_NAME_ORGANIZATION_NAME) - private String organizationName; - - public static final String SERIALIZED_NAME_ROLE = "role"; - @SerializedName(SERIALIZED_NAME_ROLE) - private OrganizationRoles role; - - public static final String SERIALIZED_NAME_ALLOWED_ACTIONS = "allowed_actions"; - @SerializedName(SERIALIZED_NAME_ALLOWED_ACTIONS) - private List allowedActions = null; - - public OrganizationUser() { - } - - public OrganizationUser userId(String userId) { - - this.userId = userId; - return this; - } - - /** - * unique ID of user - * @return userId - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "unique ID of user") - - public String getUserId() { - return userId; - } - - - public void setUserId(String userId) { - this.userId = userId; - } - - - public OrganizationUser organizationId(String organizationId) { - - this.organizationId = organizationId; - return this; - } - - /** - * unique ID of organization - * @return organizationId - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "unique ID of organization") - - public String getOrganizationId() { - return organizationId; - } - - - public void setOrganizationId(String organizationId) { - this.organizationId = organizationId; - } - - - public OrganizationUser username(String username) { - - this.username = username; - return this; - } - - /** - * username for user - * @return username - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "username", value = "username for user") - - public String getUsername() { - return username; - } - - - public void setUsername(String username) { - this.username = username; - } - - - public OrganizationUser organizationName(String organizationName) { - - this.organizationName = organizationName; - return this; - } - - /** - * name of organization - * @return organizationName - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "MyOrganization", value = "name of organization") - - public String getOrganizationName() { - return organizationName; - } - - - public void setOrganizationName(String organizationName) { - this.organizationName = organizationName; - } - - - public OrganizationUser role(OrganizationRoles role) { - - this.role = role; - return this; - } - - /** - * Get role - * @return role - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public OrganizationRoles getRole() { - return role; - } - - - public void setRole(OrganizationRoles role) { - this.role = role; - } - - - public OrganizationUser allowedActions(List allowedActions) { - - this.allowedActions = allowedActions; - return this; - } - - public OrganizationUser addAllowedActionsItem(NamespaceActions allowedActionsItem) { - if (this.allowedActions == null) { - this.allowedActions = new ArrayList<>(); - } - this.allowedActions.add(allowedActionsItem); - return this; - } - - /** - * list of actions user is allowed to do on this organization - * @return allowedActions - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "list of actions user is allowed to do on this organization") - - public List getAllowedActions() { - return allowedActions; - } - - - public void setAllowedActions(List allowedActions) { - this.allowedActions = allowedActions; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public OrganizationUser putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - OrganizationUser organizationUser = (OrganizationUser) o; - return Objects.equals(this.userId, organizationUser.userId) && - Objects.equals(this.organizationId, organizationUser.organizationId) && - Objects.equals(this.username, organizationUser.username) && - Objects.equals(this.organizationName, organizationUser.organizationName) && - Objects.equals(this.role, organizationUser.role) && - Objects.equals(this.allowedActions, organizationUser.allowedActions)&& - Objects.equals(this.additionalProperties, organizationUser.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(userId, organizationId, username, organizationName, role, allowedActions, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class OrganizationUser {\n"); - sb.append(" userId: ").append(toIndentedString(userId)).append("\n"); - sb.append(" organizationId: ").append(toIndentedString(organizationId)).append("\n"); - sb.append(" username: ").append(toIndentedString(username)).append("\n"); - sb.append(" organizationName: ").append(toIndentedString(organizationName)).append("\n"); - sb.append(" role: ").append(toIndentedString(role)).append("\n"); - sb.append(" allowedActions: ").append(toIndentedString(allowedActions)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("user_id"); - openapiFields.add("organization_id"); - openapiFields.add("username"); - openapiFields.add("organization_name"); - openapiFields.add("role"); - openapiFields.add("allowed_actions"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to OrganizationUser - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (OrganizationUser.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in OrganizationUser is not found in the empty JSON string", OrganizationUser.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("user_id") != null && !jsonObj.get("user_id").isJsonNull()) && !jsonObj.get("user_id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `user_id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("user_id").toString())); - } - if ((jsonObj.get("organization_id") != null && !jsonObj.get("organization_id").isJsonNull()) && !jsonObj.get("organization_id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `organization_id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("organization_id").toString())); - } - if ((jsonObj.get("username") != null && !jsonObj.get("username").isJsonNull()) && !jsonObj.get("username").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `username` to be a primitive type in the JSON string but got `%s`", jsonObj.get("username").toString())); - } - if ((jsonObj.get("organization_name") != null && !jsonObj.get("organization_name").isJsonNull()) && !jsonObj.get("organization_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `organization_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("organization_name").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("allowed_actions") != null && !jsonObj.get("allowed_actions").isJsonNull()) && !jsonObj.get("allowed_actions").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `allowed_actions` to be an array in the JSON string but got `%s`", jsonObj.get("allowed_actions").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!OrganizationUser.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'OrganizationUser' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(OrganizationUser.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, OrganizationUser value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public OrganizationUser read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - OrganizationUser instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of OrganizationUser given an JSON string - * - * @param jsonString JSON string - * @return An instance of OrganizationUser - * @throws IOException if the JSON string is invalid with respect to OrganizationUser - */ - public static OrganizationUser fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, OrganizationUser.class); - } - - /** - * Convert an instance of OrganizationUser to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/PaginationMetadata.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/PaginationMetadata.java deleted file mode 100644 index a846f78..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/PaginationMetadata.java +++ /dev/null @@ -1,351 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.math.BigDecimal; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * PaginationMetadata - */ -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class PaginationMetadata { - public static final String SERIALIZED_NAME_PAGE = "page"; - @SerializedName(SERIALIZED_NAME_PAGE) - private BigDecimal page; - - public static final String SERIALIZED_NAME_PER_PAGE = "per_page"; - @SerializedName(SERIALIZED_NAME_PER_PAGE) - private BigDecimal perPage; - - public static final String SERIALIZED_NAME_TOTAL_PAGES = "total_pages"; - @SerializedName(SERIALIZED_NAME_TOTAL_PAGES) - private BigDecimal totalPages; - - public static final String SERIALIZED_NAME_TOTAL_ITEMS = "total_items"; - @SerializedName(SERIALIZED_NAME_TOTAL_ITEMS) - private BigDecimal totalItems; - - public PaginationMetadata() { - } - - public PaginationMetadata page(BigDecimal page) { - - this.page = page; - return this; - } - - /** - * pagination offset. Use it to skip the first ((page - 1) * per_page) items - * @return page - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "1.0", value = "pagination offset. Use it to skip the first ((page - 1) * per_page) items") - - public BigDecimal getPage() { - return page; - } - - - public void setPage(BigDecimal page) { - this.page = page; - } - - - public PaginationMetadata perPage(BigDecimal perPage) { - - this.perPage = perPage; - return this; - } - - /** - * pagination limit (page size) - * @return perPage - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "10.0", value = "pagination limit (page size)") - - public BigDecimal getPerPage() { - return perPage; - } - - - public void setPerPage(BigDecimal perPage) { - this.perPage = perPage; - } - - - public PaginationMetadata totalPages(BigDecimal totalPages) { - - this.totalPages = totalPages; - return this; - } - - /** - * number of total pages with current limit - * @return totalPages - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "14.0", value = "number of total pages with current limit") - - public BigDecimal getTotalPages() { - return totalPages; - } - - - public void setTotalPages(BigDecimal totalPages) { - this.totalPages = totalPages; - } - - - public PaginationMetadata totalItems(BigDecimal totalItems) { - - this.totalItems = totalItems; - return this; - } - - /** - * number of total available items - * @return totalItems - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "138.0", value = "number of total available items") - - public BigDecimal getTotalItems() { - return totalItems; - } - - - public void setTotalItems(BigDecimal totalItems) { - this.totalItems = totalItems; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public PaginationMetadata putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - PaginationMetadata paginationMetadata = (PaginationMetadata) o; - return Objects.equals(this.page, paginationMetadata.page) && - Objects.equals(this.perPage, paginationMetadata.perPage) && - Objects.equals(this.totalPages, paginationMetadata.totalPages) && - Objects.equals(this.totalItems, paginationMetadata.totalItems)&& - Objects.equals(this.additionalProperties, paginationMetadata.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(page, perPage, totalPages, totalItems, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class PaginationMetadata {\n"); - sb.append(" page: ").append(toIndentedString(page)).append("\n"); - sb.append(" perPage: ").append(toIndentedString(perPage)).append("\n"); - sb.append(" totalPages: ").append(toIndentedString(totalPages)).append("\n"); - sb.append(" totalItems: ").append(toIndentedString(totalItems)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("page"); - openapiFields.add("per_page"); - openapiFields.add("total_pages"); - openapiFields.add("total_items"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to PaginationMetadata - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (PaginationMetadata.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in PaginationMetadata is not found in the empty JSON string", PaginationMetadata.openapiRequiredFields.toString())); - } - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!PaginationMetadata.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'PaginationMetadata' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(PaginationMetadata.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, PaginationMetadata value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public PaginationMetadata read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - PaginationMetadata instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of PaginationMetadata given an JSON string - * - * @param jsonString JSON string - * @return An instance of PaginationMetadata - * @throws IOException if the JSON string is invalid with respect to PaginationMetadata - */ - public static PaginationMetadata fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, PaginationMetadata.class); - } - - /** - * Convert an instance of PaginationMetadata to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Pricing.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/Pricing.java deleted file mode 100644 index dae7d7c..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Pricing.java +++ /dev/null @@ -1,637 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Pricing created by converting an array to product - */ -@ApiModel(description = "Pricing created by converting an array to product") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class Pricing { - public static final String SERIALIZED_NAME_ID = "id"; - @SerializedName(SERIALIZED_NAME_ID) - private String id; - - public static final String SERIALIZED_NAME_ARRAY_UUID = "array_uuid"; - @SerializedName(SERIALIZED_NAME_ARRAY_UUID) - private String arrayUuid; - - public static final String SERIALIZED_NAME_PRICING_NAME = "pricing_name"; - @SerializedName(SERIALIZED_NAME_PRICING_NAME) - private String pricingName; - - public static final String SERIALIZED_NAME_PRICING_TYPE = "pricing_type"; - @SerializedName(SERIALIZED_NAME_PRICING_TYPE) - private PricingType pricingType; - - public static final String SERIALIZED_NAME_PRODUCT_NAME = "product_name"; - @SerializedName(SERIALIZED_NAME_PRODUCT_NAME) - private String productName; - - public static final String SERIALIZED_NAME_PRODUCT_STATEMENT_DESCRIPTOR = "product_statement_descriptor"; - @SerializedName(SERIALIZED_NAME_PRODUCT_STATEMENT_DESCRIPTOR) - private String productStatementDescriptor; - - public static final String SERIALIZED_NAME_PRODUCT_UNIT_LABEL = "product_unit_label"; - @SerializedName(SERIALIZED_NAME_PRODUCT_UNIT_LABEL) - private PricingUnitLabel productUnitLabel; - - public static final String SERIALIZED_NAME_CURRENCY = "currency"; - @SerializedName(SERIALIZED_NAME_CURRENCY) - private PricingCurrency currency; - - public static final String SERIALIZED_NAME_AGGREGATE_USAGE = "aggregate_usage"; - @SerializedName(SERIALIZED_NAME_AGGREGATE_USAGE) - private PricingAggregateUsage aggregateUsage; - - public static final String SERIALIZED_NAME_INTERVAL = "interval"; - @SerializedName(SERIALIZED_NAME_INTERVAL) - private PricingInterval interval; - - public static final String SERIALIZED_NAME_DIVIDED_BY = "divided_by"; - @SerializedName(SERIALIZED_NAME_DIVIDED_BY) - private Long dividedBy; - - public static final String SERIALIZED_NAME_CHARGE = "charge"; - @SerializedName(SERIALIZED_NAME_CHARGE) - private Double charge; - - public static final String SERIALIZED_NAME_ACTIVATED = "activated"; - @SerializedName(SERIALIZED_NAME_ACTIVATED) - private Boolean activated; - - public Pricing() { - } - - public Pricing id(String id) { - - this.id = id; - return this; - } - - /** - * Unique ID of plan as defined by Stripe - * @return id - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "planID", value = "Unique ID of plan as defined by Stripe") - - public String getId() { - return id; - } - - - public void setId(String id) { - this.id = id; - } - - - public Pricing arrayUuid(String arrayUuid) { - - this.arrayUuid = arrayUuid; - return this; - } - - /** - * Unique ID of registered array - * @return arrayUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "Unique ID of registered array") - - public String getArrayUuid() { - return arrayUuid; - } - - - public void setArrayUuid(String arrayUuid) { - this.arrayUuid = arrayUuid; - } - - - public Pricing pricingName(String pricingName) { - - this.pricingName = pricingName; - return this; - } - - /** - * Name of pricing - * @return pricingName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Name of pricing") - - public String getPricingName() { - return pricingName; - } - - - public void setPricingName(String pricingName) { - this.pricingName = pricingName; - } - - - public Pricing pricingType(PricingType pricingType) { - - this.pricingType = pricingType; - return this; - } - - /** - * Get pricingType - * @return pricingType - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public PricingType getPricingType() { - return pricingType; - } - - - public void setPricingType(PricingType pricingType) { - this.pricingType = pricingType; - } - - - public Pricing productName(String productName) { - - this.productName = productName; - return this; - } - - /** - * Name of product - * @return productName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Name of product") - - public String getProductName() { - return productName; - } - - - public void setProductName(String productName) { - this.productName = productName; - } - - - public Pricing productStatementDescriptor(String productStatementDescriptor) { - - this.productStatementDescriptor = productStatementDescriptor; - return this; - } - - /** - * Extra information about a product which will appear on the credit card statement of the customer - * @return productStatementDescriptor - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Extra information about a product which will appear on the credit card statement of the customer") - - public String getProductStatementDescriptor() { - return productStatementDescriptor; - } - - - public void setProductStatementDescriptor(String productStatementDescriptor) { - this.productStatementDescriptor = productStatementDescriptor; - } - - - public Pricing productUnitLabel(PricingUnitLabel productUnitLabel) { - - this.productUnitLabel = productUnitLabel; - return this; - } - - /** - * Get productUnitLabel - * @return productUnitLabel - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public PricingUnitLabel getProductUnitLabel() { - return productUnitLabel; - } - - - public void setProductUnitLabel(PricingUnitLabel productUnitLabel) { - this.productUnitLabel = productUnitLabel; - } - - - public Pricing currency(PricingCurrency currency) { - - this.currency = currency; - return this; - } - - /** - * Get currency - * @return currency - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public PricingCurrency getCurrency() { - return currency; - } - - - public void setCurrency(PricingCurrency currency) { - this.currency = currency; - } - - - public Pricing aggregateUsage(PricingAggregateUsage aggregateUsage) { - - this.aggregateUsage = aggregateUsage; - return this; - } - - /** - * Get aggregateUsage - * @return aggregateUsage - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public PricingAggregateUsage getAggregateUsage() { - return aggregateUsage; - } - - - public void setAggregateUsage(PricingAggregateUsage aggregateUsage) { - this.aggregateUsage = aggregateUsage; - } - - - public Pricing interval(PricingInterval interval) { - - this.interval = interval; - return this; - } - - /** - * Get interval - * @return interval - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public PricingInterval getInterval() { - return interval; - } - - - public void setInterval(PricingInterval interval) { - this.interval = interval; - } - - - public Pricing dividedBy(Long dividedBy) { - - this.dividedBy = dividedBy; - return this; - } - - /** - * Group of n product unit labels - * @return dividedBy - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "1048576", value = "Group of n product unit labels") - - public Long getDividedBy() { - return dividedBy; - } - - - public void setDividedBy(Long dividedBy) { - this.dividedBy = dividedBy; - } - - - public Pricing charge(Double charge) { - - this.charge = charge; - return this; - } - - /** - * Price in cents (decimal) per unitlabel - * @return charge - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Price in cents (decimal) per unitlabel") - - public Double getCharge() { - return charge; - } - - - public void setCharge(Double charge) { - this.charge = charge; - } - - - public Pricing activated(Boolean activated) { - - this.activated = activated; - return this; - } - - /** - * If pricing is activated - * @return activated - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "false", value = "If pricing is activated") - - public Boolean getActivated() { - return activated; - } - - - public void setActivated(Boolean activated) { - this.activated = activated; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public Pricing putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Pricing pricing = (Pricing) o; - return Objects.equals(this.id, pricing.id) && - Objects.equals(this.arrayUuid, pricing.arrayUuid) && - Objects.equals(this.pricingName, pricing.pricingName) && - Objects.equals(this.pricingType, pricing.pricingType) && - Objects.equals(this.productName, pricing.productName) && - Objects.equals(this.productStatementDescriptor, pricing.productStatementDescriptor) && - Objects.equals(this.productUnitLabel, pricing.productUnitLabel) && - Objects.equals(this.currency, pricing.currency) && - Objects.equals(this.aggregateUsage, pricing.aggregateUsage) && - Objects.equals(this.interval, pricing.interval) && - Objects.equals(this.dividedBy, pricing.dividedBy) && - Objects.equals(this.charge, pricing.charge) && - Objects.equals(this.activated, pricing.activated)&& - Objects.equals(this.additionalProperties, pricing.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(id, arrayUuid, pricingName, pricingType, productName, productStatementDescriptor, productUnitLabel, currency, aggregateUsage, interval, dividedBy, charge, activated, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Pricing {\n"); - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" arrayUuid: ").append(toIndentedString(arrayUuid)).append("\n"); - sb.append(" pricingName: ").append(toIndentedString(pricingName)).append("\n"); - sb.append(" pricingType: ").append(toIndentedString(pricingType)).append("\n"); - sb.append(" productName: ").append(toIndentedString(productName)).append("\n"); - sb.append(" productStatementDescriptor: ").append(toIndentedString(productStatementDescriptor)).append("\n"); - sb.append(" productUnitLabel: ").append(toIndentedString(productUnitLabel)).append("\n"); - sb.append(" currency: ").append(toIndentedString(currency)).append("\n"); - sb.append(" aggregateUsage: ").append(toIndentedString(aggregateUsage)).append("\n"); - sb.append(" interval: ").append(toIndentedString(interval)).append("\n"); - sb.append(" dividedBy: ").append(toIndentedString(dividedBy)).append("\n"); - sb.append(" charge: ").append(toIndentedString(charge)).append("\n"); - sb.append(" activated: ").append(toIndentedString(activated)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("id"); - openapiFields.add("array_uuid"); - openapiFields.add("pricing_name"); - openapiFields.add("pricing_type"); - openapiFields.add("product_name"); - openapiFields.add("product_statement_descriptor"); - openapiFields.add("product_unit_label"); - openapiFields.add("currency"); - openapiFields.add("aggregate_usage"); - openapiFields.add("interval"); - openapiFields.add("divided_by"); - openapiFields.add("charge"); - openapiFields.add("activated"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to Pricing - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (Pricing.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in Pricing is not found in the empty JSON string", Pricing.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) && !jsonObj.get("id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("id").toString())); - } - if ((jsonObj.get("array_uuid") != null && !jsonObj.get("array_uuid").isJsonNull()) && !jsonObj.get("array_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `array_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("array_uuid").toString())); - } - if ((jsonObj.get("pricing_name") != null && !jsonObj.get("pricing_name").isJsonNull()) && !jsonObj.get("pricing_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `pricing_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("pricing_name").toString())); - } - if ((jsonObj.get("product_name") != null && !jsonObj.get("product_name").isJsonNull()) && !jsonObj.get("product_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `product_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("product_name").toString())); - } - if ((jsonObj.get("product_statement_descriptor") != null && !jsonObj.get("product_statement_descriptor").isJsonNull()) && !jsonObj.get("product_statement_descriptor").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `product_statement_descriptor` to be a primitive type in the JSON string but got `%s`", jsonObj.get("product_statement_descriptor").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!Pricing.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'Pricing' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(Pricing.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, Pricing value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public Pricing read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - Pricing instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of Pricing given an JSON string - * - * @param jsonString JSON string - * @return An instance of Pricing - * @throws IOException if the JSON string is invalid with respect to Pricing - */ - public static Pricing fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, Pricing.class); - } - - /** - * Convert an instance of Pricing to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/PricingAggregateUsage.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/PricingAggregateUsage.java deleted file mode 100644 index 5505bf0..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/PricingAggregateUsage.java +++ /dev/null @@ -1,67 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * Specifies a usage aggregation strategy for pricings of usage_type=metered - */ -@JsonAdapter(PricingAggregateUsage.Adapter.class) -public enum PricingAggregateUsage { - - SUM("sum"); - - private String value; - - PricingAggregateUsage(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static PricingAggregateUsage fromValue(String value) { - for (PricingAggregateUsage b : PricingAggregateUsage.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final PricingAggregateUsage enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public PricingAggregateUsage read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return PricingAggregateUsage.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/PricingCurrency.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/PricingCurrency.java deleted file mode 100644 index 90b84c2..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/PricingCurrency.java +++ /dev/null @@ -1,67 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * Currency of pricing - */ -@JsonAdapter(PricingCurrency.Adapter.class) -public enum PricingCurrency { - - USD("USD"); - - private String value; - - PricingCurrency(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static PricingCurrency fromValue(String value) { - for (PricingCurrency b : PricingCurrency.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final PricingCurrency enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public PricingCurrency read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return PricingCurrency.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/PricingInterval.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/PricingInterval.java deleted file mode 100644 index 688fcce..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/PricingInterval.java +++ /dev/null @@ -1,67 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * Interval for pricing - */ -@JsonAdapter(PricingInterval.Adapter.class) -public enum PricingInterval { - - MONTH("month"); - - private String value; - - PricingInterval(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static PricingInterval fromValue(String value) { - for (PricingInterval b : PricingInterval.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final PricingInterval enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public PricingInterval read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return PricingInterval.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/PricingType.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/PricingType.java deleted file mode 100644 index 122011d..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/PricingType.java +++ /dev/null @@ -1,69 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * Pricing types - */ -@JsonAdapter(PricingType.Adapter.class) -public enum PricingType { - - EGRESS("egress"), - - ACCESS("access"); - - private String value; - - PricingType(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static PricingType fromValue(String value) { - for (PricingType b : PricingType.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final PricingType enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public PricingType read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return PricingType.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/PricingUnitLabel.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/PricingUnitLabel.java deleted file mode 100644 index 2e564d6..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/PricingUnitLabel.java +++ /dev/null @@ -1,69 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * Unit label - */ -@JsonAdapter(PricingUnitLabel.Adapter.class) -public enum PricingUnitLabel { - - BYTE("byte"), - - SECOND("second"); - - private String value; - - PricingUnitLabel(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static PricingUnitLabel fromValue(String value) { - for (PricingUnitLabel b : PricingUnitLabel.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final PricingUnitLabel enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public PricingUnitLabel read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return PricingUnitLabel.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/PublicShareFilter.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/PublicShareFilter.java deleted file mode 100644 index 23abbfe..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/PublicShareFilter.java +++ /dev/null @@ -1,69 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * Query parameter to get array metadatas - */ -@JsonAdapter(PublicShareFilter.Adapter.class) -public enum PublicShareFilter { - - EXCLUDE("exclude"), - - ONLY("only"); - - private String value; - - PublicShareFilter(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static PublicShareFilter fromValue(String value) { - for (PublicShareFilter b : PublicShareFilter.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final PublicShareFilter enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public PublicShareFilter read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return PublicShareFilter.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Query.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/Query.java deleted file mode 100644 index 28951eb..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Query.java +++ /dev/null @@ -1,546 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Query - */ -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class Query { - public static final String SERIALIZED_NAME_TYPE = "type"; - @SerializedName(SERIALIZED_NAME_TYPE) - private Querytype type; - - public static final String SERIALIZED_NAME_LAYOUT = "layout"; - @SerializedName(SERIALIZED_NAME_LAYOUT) - private Layout layout; - - public static final String SERIALIZED_NAME_STATUS = "status"; - @SerializedName(SERIALIZED_NAME_STATUS) - private Querystatus status; - - public static final String SERIALIZED_NAME_ATTRIBUTE_BUFFER_HEADERS = "attributeBufferHeaders"; - @SerializedName(SERIALIZED_NAME_ATTRIBUTE_BUFFER_HEADERS) - private List attributeBufferHeaders = new ArrayList<>(); - - public static final String SERIALIZED_NAME_WRITER = "writer"; - @SerializedName(SERIALIZED_NAME_WRITER) - private Writer writer; - - public static final String SERIALIZED_NAME_READER = "reader"; - @SerializedName(SERIALIZED_NAME_READER) - private QueryReader reader; - - public static final String SERIALIZED_NAME_ARRAY = "array"; - @SerializedName(SERIALIZED_NAME_ARRAY) - private Array array; - - public static final String SERIALIZED_NAME_TOTAL_FIXED_LENGTH_BUFFER_BYTES = "totalFixedLengthBufferBytes"; - @SerializedName(SERIALIZED_NAME_TOTAL_FIXED_LENGTH_BUFFER_BYTES) - private Integer totalFixedLengthBufferBytes; - - public static final String SERIALIZED_NAME_TOTAL_VAR_LEN_BUFFER_BYTES = "totalVarLenBufferBytes"; - @SerializedName(SERIALIZED_NAME_TOTAL_VAR_LEN_BUFFER_BYTES) - private Integer totalVarLenBufferBytes; - - public Query() { - } - - public Query type(Querytype type) { - - this.type = type; - return this; - } - - /** - * Get type - * @return type - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public Querytype getType() { - return type; - } - - - public void setType(Querytype type) { - this.type = type; - } - - - public Query layout(Layout layout) { - - this.layout = layout; - return this; - } - - /** - * Get layout - * @return layout - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public Layout getLayout() { - return layout; - } - - - public void setLayout(Layout layout) { - this.layout = layout; - } - - - public Query status(Querystatus status) { - - this.status = status; - return this; - } - - /** - * Get status - * @return status - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public Querystatus getStatus() { - return status; - } - - - public void setStatus(Querystatus status) { - this.status = status; - } - - - public Query attributeBufferHeaders(List attributeBufferHeaders) { - - this.attributeBufferHeaders = attributeBufferHeaders; - return this; - } - - public Query addAttributeBufferHeadersItem(AttributeBufferHeader attributeBufferHeadersItem) { - this.attributeBufferHeaders.add(attributeBufferHeadersItem); - return this; - } - - /** - * List of attribute buffer headers - * @return attributeBufferHeaders - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "List of attribute buffer headers") - - public List getAttributeBufferHeaders() { - return attributeBufferHeaders; - } - - - public void setAttributeBufferHeaders(List attributeBufferHeaders) { - this.attributeBufferHeaders = attributeBufferHeaders; - } - - - public Query writer(Writer writer) { - - this.writer = writer; - return this; - } - - /** - * Get writer - * @return writer - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Writer getWriter() { - return writer; - } - - - public void setWriter(Writer writer) { - this.writer = writer; - } - - - public Query reader(QueryReader reader) { - - this.reader = reader; - return this; - } - - /** - * Get reader - * @return reader - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public QueryReader getReader() { - return reader; - } - - - public void setReader(QueryReader reader) { - this.reader = reader; - } - - - public Query array(Array array) { - - this.array = array; - return this; - } - - /** - * Get array - * @return array - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") - - public Array getArray() { - return array; - } - - - public void setArray(Array array) { - this.array = array; - } - - - public Query totalFixedLengthBufferBytes(Integer totalFixedLengthBufferBytes) { - - this.totalFixedLengthBufferBytes = totalFixedLengthBufferBytes; - return this; - } - - /** - * Total number of bytes in fixed size attribute buffers. - * @return totalFixedLengthBufferBytes - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "Total number of bytes in fixed size attribute buffers.") - - public Integer getTotalFixedLengthBufferBytes() { - return totalFixedLengthBufferBytes; - } - - - public void setTotalFixedLengthBufferBytes(Integer totalFixedLengthBufferBytes) { - this.totalFixedLengthBufferBytes = totalFixedLengthBufferBytes; - } - - - public Query totalVarLenBufferBytes(Integer totalVarLenBufferBytes) { - - this.totalVarLenBufferBytes = totalVarLenBufferBytes; - return this; - } - - /** - * Total number of bytes in variable size attribute buffers. - * @return totalVarLenBufferBytes - **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "Total number of bytes in variable size attribute buffers.") - - public Integer getTotalVarLenBufferBytes() { - return totalVarLenBufferBytes; - } - - - public void setTotalVarLenBufferBytes(Integer totalVarLenBufferBytes) { - this.totalVarLenBufferBytes = totalVarLenBufferBytes; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public Query putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Query query = (Query) o; - return Objects.equals(this.type, query.type) && - Objects.equals(this.layout, query.layout) && - Objects.equals(this.status, query.status) && - Objects.equals(this.attributeBufferHeaders, query.attributeBufferHeaders) && - Objects.equals(this.writer, query.writer) && - Objects.equals(this.reader, query.reader) && - Objects.equals(this.array, query.array) && - Objects.equals(this.totalFixedLengthBufferBytes, query.totalFixedLengthBufferBytes) && - Objects.equals(this.totalVarLenBufferBytes, query.totalVarLenBufferBytes)&& - Objects.equals(this.additionalProperties, query.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(type, layout, status, attributeBufferHeaders, writer, reader, array, totalFixedLengthBufferBytes, totalVarLenBufferBytes, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Query {\n"); - sb.append(" type: ").append(toIndentedString(type)).append("\n"); - sb.append(" layout: ").append(toIndentedString(layout)).append("\n"); - sb.append(" status: ").append(toIndentedString(status)).append("\n"); - sb.append(" attributeBufferHeaders: ").append(toIndentedString(attributeBufferHeaders)).append("\n"); - sb.append(" writer: ").append(toIndentedString(writer)).append("\n"); - sb.append(" reader: ").append(toIndentedString(reader)).append("\n"); - sb.append(" array: ").append(toIndentedString(array)).append("\n"); - sb.append(" totalFixedLengthBufferBytes: ").append(toIndentedString(totalFixedLengthBufferBytes)).append("\n"); - sb.append(" totalVarLenBufferBytes: ").append(toIndentedString(totalVarLenBufferBytes)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("type"); - openapiFields.add("layout"); - openapiFields.add("status"); - openapiFields.add("attributeBufferHeaders"); - openapiFields.add("writer"); - openapiFields.add("reader"); - openapiFields.add("array"); - openapiFields.add("totalFixedLengthBufferBytes"); - openapiFields.add("totalVarLenBufferBytes"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - openapiRequiredFields.add("type"); - openapiRequiredFields.add("layout"); - openapiRequiredFields.add("status"); - openapiRequiredFields.add("attributeBufferHeaders"); - openapiRequiredFields.add("array"); - openapiRequiredFields.add("totalFixedLengthBufferBytes"); - openapiRequiredFields.add("totalVarLenBufferBytes"); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to Query - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (Query.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in Query is not found in the empty JSON string", Query.openapiRequiredFields.toString())); - } - } - - // check to make sure all required properties/fields are present in the JSON string - for (String requiredField : Query.openapiRequiredFields) { - if (jsonObj.get(requiredField) == null) { - throw new IllegalArgumentException(String.format("The required field `%s` is not found in the JSON string: %s", requiredField, jsonObj.toString())); - } - } - JsonArray jsonArrayattributeBufferHeaders = jsonObj.getAsJsonArray("attributeBufferHeaders"); - if (jsonArrayattributeBufferHeaders != null) { - // ensure the json data is an array - if (!jsonObj.get("attributeBufferHeaders").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `attributeBufferHeaders` to be an array in the JSON string but got `%s`", jsonObj.get("attributeBufferHeaders").toString())); - } - - // validate the optional field `attributeBufferHeaders` (array) - for (int i = 0; i < jsonArrayattributeBufferHeaders.size(); i++) { - AttributeBufferHeader.validateJsonObject(jsonArrayattributeBufferHeaders.get(i).getAsJsonObject()); - }; - } - // validate the optional field `writer` - if (jsonObj.get("writer") != null && !jsonObj.get("writer").isJsonNull()) { - Writer.validateJsonObject(jsonObj.getAsJsonObject("writer")); - } - // validate the optional field `reader` - if (jsonObj.get("reader") != null && !jsonObj.get("reader").isJsonNull()) { - QueryReader.validateJsonObject(jsonObj.getAsJsonObject("reader")); - } - // validate the optional field `array` - if (jsonObj.get("array") != null && !jsonObj.get("array").isJsonNull()) { - Array.validateJsonObject(jsonObj.getAsJsonObject("array")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!Query.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'Query' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(Query.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, Query value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public Query read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - Query instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of Query given an JSON string - * - * @param jsonString JSON string - * @return An instance of Query - * @throws IOException if the JSON string is invalid with respect to Query - */ - public static Query fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, Query.class); - } - - /** - * Convert an instance of Query to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/QueryJson.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/QueryJson.java deleted file mode 100644 index 1abae88..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/QueryJson.java +++ /dev/null @@ -1,310 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Query returning results as JSON - */ -@ApiModel(description = "Query returning results as JSON") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class QueryJson { - public static final String SERIALIZED_NAME_QUERY_RANGES = "query_ranges"; - @SerializedName(SERIALIZED_NAME_QUERY_RANGES) - private QueryRanges queryRanges; - - public static final String SERIALIZED_NAME_FIELDS = "fields"; - @SerializedName(SERIALIZED_NAME_FIELDS) - private List fields = null; - - public QueryJson() { - } - - public QueryJson queryRanges(QueryRanges queryRanges) { - - this.queryRanges = queryRanges; - return this; - } - - /** - * Get queryRanges - * @return queryRanges - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public QueryRanges getQueryRanges() { - return queryRanges; - } - - - public void setQueryRanges(QueryRanges queryRanges) { - this.queryRanges = queryRanges; - } - - - public QueryJson fields(List fields) { - - this.fields = fields; - return this; - } - - public QueryJson addFieldsItem(String fieldsItem) { - if (this.fields == null) { - this.fields = new ArrayList<>(); - } - this.fields.add(fieldsItem); - return this; - } - - /** - * List of fields to return data from, empty means return data for all fields - * @return fields - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "List of fields to return data from, empty means return data for all fields") - - public List getFields() { - return fields; - } - - - public void setFields(List fields) { - this.fields = fields; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public QueryJson putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - QueryJson queryJson = (QueryJson) o; - return Objects.equals(this.queryRanges, queryJson.queryRanges) && - Objects.equals(this.fields, queryJson.fields)&& - Objects.equals(this.additionalProperties, queryJson.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(queryRanges, fields, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class QueryJson {\n"); - sb.append(" queryRanges: ").append(toIndentedString(queryRanges)).append("\n"); - sb.append(" fields: ").append(toIndentedString(fields)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("query_ranges"); - openapiFields.add("fields"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to QueryJson - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (QueryJson.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in QueryJson is not found in the empty JSON string", QueryJson.openapiRequiredFields.toString())); - } - } - // validate the optional field `query_ranges` - if (jsonObj.get("query_ranges") != null && !jsonObj.get("query_ranges").isJsonNull()) { - QueryRanges.validateJsonObject(jsonObj.getAsJsonObject("query_ranges")); - } - // ensure the json data is an array - if ((jsonObj.get("fields") != null && !jsonObj.get("fields").isJsonNull()) && !jsonObj.get("fields").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `fields` to be an array in the JSON string but got `%s`", jsonObj.get("fields").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!QueryJson.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'QueryJson' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(QueryJson.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, QueryJson value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public QueryJson read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - QueryJson instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of QueryJson given an JSON string - * - * @param jsonString JSON string - * @return An instance of QueryJson - * @throws IOException if the JSON string is invalid with respect to QueryJson - */ - public static QueryJson fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, QueryJson.class); - } - - /** - * Convert an instance of QueryJson to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/QueryRanges.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/QueryRanges.java deleted file mode 100644 index 818f20f..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/QueryRanges.java +++ /dev/null @@ -1,307 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.math.BigDecimal; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Subarray bounds to query - */ -@ApiModel(description = "Subarray bounds to query") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class QueryRanges { - public static final String SERIALIZED_NAME_LAYOUT = "layout"; - @SerializedName(SERIALIZED_NAME_LAYOUT) - private Layout layout; - - public static final String SERIALIZED_NAME_RANGES = "ranges"; - @SerializedName(SERIALIZED_NAME_RANGES) - private List> ranges = null; - - public QueryRanges() { - } - - public QueryRanges layout(Layout layout) { - - this.layout = layout; - return this; - } - - /** - * Get layout - * @return layout - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Layout getLayout() { - return layout; - } - - - public void setLayout(Layout layout) { - this.layout = layout; - } - - - public QueryRanges ranges(List> ranges) { - - this.ranges = ranges; - return this; - } - - public QueryRanges addRangesItem(List rangesItem) { - if (this.ranges == null) { - this.ranges = new ArrayList<>(); - } - this.ranges.add(rangesItem); - return this; - } - - /** - * List of ranges, - * @return ranges - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "List of ranges,") - - public List> getRanges() { - return ranges; - } - - - public void setRanges(List> ranges) { - this.ranges = ranges; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public QueryRanges putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - QueryRanges queryRanges = (QueryRanges) o; - return Objects.equals(this.layout, queryRanges.layout) && - Objects.equals(this.ranges, queryRanges.ranges)&& - Objects.equals(this.additionalProperties, queryRanges.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(layout, ranges, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class QueryRanges {\n"); - sb.append(" layout: ").append(toIndentedString(layout)).append("\n"); - sb.append(" ranges: ").append(toIndentedString(ranges)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("layout"); - openapiFields.add("ranges"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to QueryRanges - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (QueryRanges.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in QueryRanges is not found in the empty JSON string", QueryRanges.openapiRequiredFields.toString())); - } - } - // ensure the json data is an array - if ((jsonObj.get("ranges") != null && !jsonObj.get("ranges").isJsonNull()) && !jsonObj.get("ranges").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `ranges` to be an array in the JSON string but got `%s`", jsonObj.get("ranges").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!QueryRanges.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'QueryRanges' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(QueryRanges.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, QueryRanges value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public QueryRanges read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - QueryRanges instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of QueryRanges given an JSON string - * - * @param jsonString JSON string - * @return An instance of QueryRanges - * @throws IOException if the JSON string is invalid with respect to QueryRanges - */ - public static QueryRanges fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, QueryRanges.class); - } - - /** - * Convert an instance of QueryRanges to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/QueryReader.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/QueryReader.java deleted file mode 100644 index 45f2155..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/QueryReader.java +++ /dev/null @@ -1,423 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Read struct (can't be called reader due to class name conflict) - */ -@ApiModel(description = "Read struct (can't be called reader due to class name conflict)") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class QueryReader { - public static final String SERIALIZED_NAME_LAYOUT = "layout"; - @SerializedName(SERIALIZED_NAME_LAYOUT) - private Layout layout; - - public static final String SERIALIZED_NAME_SUBARRAY = "subarray"; - @SerializedName(SERIALIZED_NAME_SUBARRAY) - private Subarray subarray; - - public static final String SERIALIZED_NAME_READ_STATE = "readState"; - @SerializedName(SERIALIZED_NAME_READ_STATE) - private ReadState readState; - - public static final String SERIALIZED_NAME_VAR_OFFSETS_MODE = "varOffsetsMode"; - @SerializedName(SERIALIZED_NAME_VAR_OFFSETS_MODE) - private String varOffsetsMode; - - public static final String SERIALIZED_NAME_VAR_OFFSETS_ADD_EXTRA_ELEMENT = "varOffsetsAddExtraElement"; - @SerializedName(SERIALIZED_NAME_VAR_OFFSETS_ADD_EXTRA_ELEMENT) - private Boolean varOffsetsAddExtraElement; - - public static final String SERIALIZED_NAME_VAR_OFFSETS_BITSIZE = "varOffsetsBitsize"; - @SerializedName(SERIALIZED_NAME_VAR_OFFSETS_BITSIZE) - private Integer varOffsetsBitsize; - - public QueryReader() { - } - - public QueryReader layout(Layout layout) { - - this.layout = layout; - return this; - } - - /** - * Get layout - * @return layout - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Layout getLayout() { - return layout; - } - - - public void setLayout(Layout layout) { - this.layout = layout; - } - - - public QueryReader subarray(Subarray subarray) { - - this.subarray = subarray; - return this; - } - - /** - * Get subarray - * @return subarray - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Subarray getSubarray() { - return subarray; - } - - - public void setSubarray(Subarray subarray) { - this.subarray = subarray; - } - - - public QueryReader readState(ReadState readState) { - - this.readState = readState; - return this; - } - - /** - * Get readState - * @return readState - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public ReadState getReadState() { - return readState; - } - - - public void setReadState(ReadState readState) { - this.readState = readState; - } - - - public QueryReader varOffsetsMode(String varOffsetsMode) { - - this.varOffsetsMode = varOffsetsMode; - return this; - } - - /** - * The offsets format (bytes or elements) to be used. - * @return varOffsetsMode - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The offsets format (bytes or elements) to be used.") - - public String getVarOffsetsMode() { - return varOffsetsMode; - } - - - public void setVarOffsetsMode(String varOffsetsMode) { - this.varOffsetsMode = varOffsetsMode; - } - - - public QueryReader varOffsetsAddExtraElement(Boolean varOffsetsAddExtraElement) { - - this.varOffsetsAddExtraElement = varOffsetsAddExtraElement; - return this; - } - - /** - * True if an extra element will be added to the end of the offsets buffer. - * @return varOffsetsAddExtraElement - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "True if an extra element will be added to the end of the offsets buffer.") - - public Boolean getVarOffsetsAddExtraElement() { - return varOffsetsAddExtraElement; - } - - - public void setVarOffsetsAddExtraElement(Boolean varOffsetsAddExtraElement) { - this.varOffsetsAddExtraElement = varOffsetsAddExtraElement; - } - - - public QueryReader varOffsetsBitsize(Integer varOffsetsBitsize) { - - this.varOffsetsBitsize = varOffsetsBitsize; - return this; - } - - /** - * The offsets bitsize (32 or 64) to be used. - * @return varOffsetsBitsize - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The offsets bitsize (32 or 64) to be used.") - - public Integer getVarOffsetsBitsize() { - return varOffsetsBitsize; - } - - - public void setVarOffsetsBitsize(Integer varOffsetsBitsize) { - this.varOffsetsBitsize = varOffsetsBitsize; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public QueryReader putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - QueryReader queryReader = (QueryReader) o; - return Objects.equals(this.layout, queryReader.layout) && - Objects.equals(this.subarray, queryReader.subarray) && - Objects.equals(this.readState, queryReader.readState) && - Objects.equals(this.varOffsetsMode, queryReader.varOffsetsMode) && - Objects.equals(this.varOffsetsAddExtraElement, queryReader.varOffsetsAddExtraElement) && - Objects.equals(this.varOffsetsBitsize, queryReader.varOffsetsBitsize)&& - Objects.equals(this.additionalProperties, queryReader.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(layout, subarray, readState, varOffsetsMode, varOffsetsAddExtraElement, varOffsetsBitsize, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class QueryReader {\n"); - sb.append(" layout: ").append(toIndentedString(layout)).append("\n"); - sb.append(" subarray: ").append(toIndentedString(subarray)).append("\n"); - sb.append(" readState: ").append(toIndentedString(readState)).append("\n"); - sb.append(" varOffsetsMode: ").append(toIndentedString(varOffsetsMode)).append("\n"); - sb.append(" varOffsetsAddExtraElement: ").append(toIndentedString(varOffsetsAddExtraElement)).append("\n"); - sb.append(" varOffsetsBitsize: ").append(toIndentedString(varOffsetsBitsize)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("layout"); - openapiFields.add("subarray"); - openapiFields.add("readState"); - openapiFields.add("varOffsetsMode"); - openapiFields.add("varOffsetsAddExtraElement"); - openapiFields.add("varOffsetsBitsize"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to QueryReader - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (QueryReader.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in QueryReader is not found in the empty JSON string", QueryReader.openapiRequiredFields.toString())); - } - } - // validate the optional field `subarray` - if (jsonObj.get("subarray") != null && !jsonObj.get("subarray").isJsonNull()) { - Subarray.validateJsonObject(jsonObj.getAsJsonObject("subarray")); - } - // validate the optional field `readState` - if (jsonObj.get("readState") != null && !jsonObj.get("readState").isJsonNull()) { - ReadState.validateJsonObject(jsonObj.getAsJsonObject("readState")); - } - if ((jsonObj.get("varOffsetsMode") != null && !jsonObj.get("varOffsetsMode").isJsonNull()) && !jsonObj.get("varOffsetsMode").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `varOffsetsMode` to be a primitive type in the JSON string but got `%s`", jsonObj.get("varOffsetsMode").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!QueryReader.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'QueryReader' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(QueryReader.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, QueryReader value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public QueryReader read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - QueryReader instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of QueryReader given an JSON string - * - * @param jsonString JSON string - * @return An instance of QueryReader - * @throws IOException if the JSON string is invalid with respect to QueryReader - */ - public static QueryReader fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, QueryReader.class); - } - - /** - * Convert an instance of QueryReader to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Querystatus.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/Querystatus.java deleted file mode 100644 index cdf9008..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Querystatus.java +++ /dev/null @@ -1,75 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * Status of query - */ -@JsonAdapter(Querystatus.Adapter.class) -public enum Querystatus { - - FAILED("FAILED"), - - COMPLETED("COMPLETED"), - - INPROGRESS("INPROGRESS"), - - INCOMPLETE("INCOMPLETE"), - - UNINITIALIZED("UNINITIALIZED"); - - private String value; - - Querystatus(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static Querystatus fromValue(String value) { - for (Querystatus b : Querystatus.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final Querystatus enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public Querystatus read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return Querystatus.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Querytype.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/Querytype.java deleted file mode 100644 index 5254982..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Querytype.java +++ /dev/null @@ -1,71 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * Type of query - */ -@JsonAdapter(Querytype.Adapter.class) -public enum Querytype { - - READ("READ"), - - WRITE("WRITE"), - - DELETE("DELETE"); - - private String value; - - Querytype(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static Querytype fromValue(String value) { - for (Querytype b : Querytype.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final Querytype enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public Querytype read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return Querytype.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ReadState.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ReadState.java deleted file mode 100644 index 7af3904..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ReadState.java +++ /dev/null @@ -1,356 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * state for reads - */ -@ApiModel(description = "state for reads") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ReadState { - public static final String SERIALIZED_NAME_INITIALIZED = "initialized"; - @SerializedName(SERIALIZED_NAME_INITIALIZED) - private Boolean initialized; - - public static final String SERIALIZED_NAME_OVERFLOWED = "overflowed"; - @SerializedName(SERIALIZED_NAME_OVERFLOWED) - private Boolean overflowed; - - public static final String SERIALIZED_NAME_UNSPLITTABLE = "unsplittable"; - @SerializedName(SERIALIZED_NAME_UNSPLITTABLE) - private Boolean unsplittable; - - public static final String SERIALIZED_NAME_SUBARRAY_PARTITIONER = "subarrayPartitioner"; - @SerializedName(SERIALIZED_NAME_SUBARRAY_PARTITIONER) - private SubarrayPartitioner subarrayPartitioner; - - public ReadState() { - } - - public ReadState initialized(Boolean initialized) { - - this.initialized = initialized; - return this; - } - - /** - * True if the reader has been initialized. - * @return initialized - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "True if the reader has been initialized.") - - public Boolean getInitialized() { - return initialized; - } - - - public void setInitialized(Boolean initialized) { - this.initialized = initialized; - } - - - public ReadState overflowed(Boolean overflowed) { - - this.overflowed = overflowed; - return this; - } - - /** - * True if the query produced results that could not fit in some buffer. - * @return overflowed - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "True if the query produced results that could not fit in some buffer.") - - public Boolean getOverflowed() { - return overflowed; - } - - - public void setOverflowed(Boolean overflowed) { - this.overflowed = overflowed; - } - - - public ReadState unsplittable(Boolean unsplittable) { - - this.unsplittable = unsplittable; - return this; - } - - /** - * True if the current subarray partition is unsplittable. - * @return unsplittable - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "True if the current subarray partition is unsplittable.") - - public Boolean getUnsplittable() { - return unsplittable; - } - - - public void setUnsplittable(Boolean unsplittable) { - this.unsplittable = unsplittable; - } - - - public ReadState subarrayPartitioner(SubarrayPartitioner subarrayPartitioner) { - - this.subarrayPartitioner = subarrayPartitioner; - return this; - } - - /** - * Get subarrayPartitioner - * @return subarrayPartitioner - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public SubarrayPartitioner getSubarrayPartitioner() { - return subarrayPartitioner; - } - - - public void setSubarrayPartitioner(SubarrayPartitioner subarrayPartitioner) { - this.subarrayPartitioner = subarrayPartitioner; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public ReadState putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ReadState readState = (ReadState) o; - return Objects.equals(this.initialized, readState.initialized) && - Objects.equals(this.overflowed, readState.overflowed) && - Objects.equals(this.unsplittable, readState.unsplittable) && - Objects.equals(this.subarrayPartitioner, readState.subarrayPartitioner)&& - Objects.equals(this.additionalProperties, readState.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(initialized, overflowed, unsplittable, subarrayPartitioner, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ReadState {\n"); - sb.append(" initialized: ").append(toIndentedString(initialized)).append("\n"); - sb.append(" overflowed: ").append(toIndentedString(overflowed)).append("\n"); - sb.append(" unsplittable: ").append(toIndentedString(unsplittable)).append("\n"); - sb.append(" subarrayPartitioner: ").append(toIndentedString(subarrayPartitioner)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("initialized"); - openapiFields.add("overflowed"); - openapiFields.add("unsplittable"); - openapiFields.add("subarrayPartitioner"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to ReadState - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (ReadState.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in ReadState is not found in the empty JSON string", ReadState.openapiRequiredFields.toString())); - } - } - // validate the optional field `subarrayPartitioner` - if (jsonObj.get("subarrayPartitioner") != null && !jsonObj.get("subarrayPartitioner").isJsonNull()) { - SubarrayPartitioner.validateJsonObject(jsonObj.getAsJsonObject("subarrayPartitioner")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!ReadState.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'ReadState' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(ReadState.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, ReadState value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public ReadState read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - ReadState instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of ReadState given an JSON string - * - * @param jsonString JSON string - * @return An instance of ReadState - * @throws IOException if the JSON string is invalid with respect to ReadState - */ - public static ReadState fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, ReadState.class); - } - - /** - * Convert an instance of ReadState to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/RegisteredTaskGraph.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/RegisteredTaskGraph.java deleted file mode 100644 index 87af929..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/RegisteredTaskGraph.java +++ /dev/null @@ -1,538 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import org.openapitools.jackson.nullable.JsonNullable; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * The structure and metadata of a task graph that can be stored on TileDB Cloud and executed by users who have access to it. - */ -@ApiModel(description = "The structure and metadata of a task graph that can be stored on TileDB Cloud and executed by users who have access to it. ") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class RegisteredTaskGraph { - public static final String SERIALIZED_NAME_UUID = "uuid"; - @SerializedName(SERIALIZED_NAME_UUID) - private String uuid; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_README = "readme"; - @SerializedName(SERIALIZED_NAME_README) - private String readme; - - public static final String SERIALIZED_NAME_LICENSE_ID = "license_id"; - @SerializedName(SERIALIZED_NAME_LICENSE_ID) - private String licenseId; - - public static final String SERIALIZED_NAME_LICENSE_TEXT = "license_text"; - @SerializedName(SERIALIZED_NAME_LICENSE_TEXT) - private String licenseText; - - public static final String SERIALIZED_NAME_TAGS = "tags"; - @SerializedName(SERIALIZED_NAME_TAGS) - private List tags = null; - - public static final String SERIALIZED_NAME_NODES = "nodes"; - @SerializedName(SERIALIZED_NAME_NODES) - private List nodes = null; - - public RegisteredTaskGraph() { - } - - public RegisteredTaskGraph uuid(String uuid) { - - this.uuid = uuid; - return this; - } - - /** - * A server-assigned unique ID for the UDF, in UUID format. - * @return uuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "A server-assigned unique ID for the UDF, in UUID format.") - - public String getUuid() { - return uuid; - } - - - public void setUuid(String uuid) { - this.uuid = uuid; - } - - - public RegisteredTaskGraph namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * The namespace that owns this task graph log. - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The namespace that owns this task graph log.") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - - public RegisteredTaskGraph name(String name) { - - this.name = name; - return this; - } - - /** - * The name of this graph, to appear in URLs. Must be unique per-namespace. - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The name of this graph, to appear in URLs. Must be unique per-namespace. ") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public RegisteredTaskGraph readme(String readme) { - - this.readme = readme; - return this; - } - - /** - * Documentation for the task graph, in Markdown format. - * @return readme - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Documentation for the task graph, in Markdown format.") - - public String getReadme() { - return readme; - } - - - public void setReadme(String readme) { - this.readme = readme; - } - - - public RegisteredTaskGraph licenseId(String licenseId) { - - this.licenseId = licenseId; - return this; - } - - /** - * SPDX license identifier. - * @return licenseId - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "SPDX license identifier.") - - public String getLicenseId() { - return licenseId; - } - - - public void setLicenseId(String licenseId) { - this.licenseId = licenseId; - } - - - public RegisteredTaskGraph licenseText(String licenseText) { - - this.licenseText = licenseText; - return this; - } - - /** - * Full text of the license. - * @return licenseText - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Full text of the license.") - - public String getLicenseText() { - return licenseText; - } - - - public void setLicenseText(String licenseText) { - this.licenseText = licenseText; - } - - - public RegisteredTaskGraph tags(List tags) { - - this.tags = tags; - return this; - } - - public RegisteredTaskGraph addTagsItem(String tagsItem) { - if (this.tags == null) { - this.tags = new ArrayList<>(); - } - this.tags.add(tagsItem); - return this; - } - - /** - * Optional tags to classify the graph. - * @return tags - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Optional tags to classify the graph.") - - public List getTags() { - return tags; - } - - - public void setTags(List tags) { - this.tags = tags; - } - - - public RegisteredTaskGraph nodes(List nodes) { - - this.nodes = nodes; - return this; - } - - public RegisteredTaskGraph addNodesItem(TaskGraphNode nodesItem) { - if (this.nodes == null) { - this.nodes = new ArrayList<>(); - } - this.nodes.add(nodesItem); - return this; - } - - /** - * The structure of the graph, in the form of the nodes that make it up. As with `TaskGraphLog`, nodes must topologically sorted, so that any node appears after all the nodes it depends on. - * @return nodes - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The structure of the graph, in the form of the nodes that make it up. As with `TaskGraphLog`, nodes must topologically sorted, so that any node appears after all the nodes it depends on. ") - - public List getNodes() { - return nodes; - } - - - public void setNodes(List nodes) { - this.nodes = nodes; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public RegisteredTaskGraph putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - RegisteredTaskGraph registeredTaskGraph = (RegisteredTaskGraph) o; - return Objects.equals(this.uuid, registeredTaskGraph.uuid) && - Objects.equals(this.namespace, registeredTaskGraph.namespace) && - Objects.equals(this.name, registeredTaskGraph.name) && - Objects.equals(this.readme, registeredTaskGraph.readme) && - Objects.equals(this.licenseId, registeredTaskGraph.licenseId) && - Objects.equals(this.licenseText, registeredTaskGraph.licenseText) && - Objects.equals(this.tags, registeredTaskGraph.tags) && - Objects.equals(this.nodes, registeredTaskGraph.nodes)&& - Objects.equals(this.additionalProperties, registeredTaskGraph.additionalProperties); - } - - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); - } - - @Override - public int hashCode() { - return Objects.hash(uuid, namespace, name, readme, licenseId, licenseText, tags, nodes, additionalProperties); - } - - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class RegisteredTaskGraph {\n"); - sb.append(" uuid: ").append(toIndentedString(uuid)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" readme: ").append(toIndentedString(readme)).append("\n"); - sb.append(" licenseId: ").append(toIndentedString(licenseId)).append("\n"); - sb.append(" licenseText: ").append(toIndentedString(licenseText)).append("\n"); - sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); - sb.append(" nodes: ").append(toIndentedString(nodes)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("uuid"); - openapiFields.add("namespace"); - openapiFields.add("name"); - openapiFields.add("readme"); - openapiFields.add("license_id"); - openapiFields.add("license_text"); - openapiFields.add("tags"); - openapiFields.add("nodes"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to RegisteredTaskGraph - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (RegisteredTaskGraph.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in RegisteredTaskGraph is not found in the empty JSON string", RegisteredTaskGraph.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("uuid") != null && !jsonObj.get("uuid").isJsonNull()) && !jsonObj.get("uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("uuid").toString())); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - if ((jsonObj.get("readme") != null && !jsonObj.get("readme").isJsonNull()) && !jsonObj.get("readme").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `readme` to be a primitive type in the JSON string but got `%s`", jsonObj.get("readme").toString())); - } - if ((jsonObj.get("license_id") != null && !jsonObj.get("license_id").isJsonNull()) && !jsonObj.get("license_id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `license_id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("license_id").toString())); - } - if ((jsonObj.get("license_text") != null && !jsonObj.get("license_text").isJsonNull()) && !jsonObj.get("license_text").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `license_text` to be a primitive type in the JSON string but got `%s`", jsonObj.get("license_text").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("tags") != null && !jsonObj.get("tags").isJsonNull()) && !jsonObj.get("tags").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `tags` to be an array in the JSON string but got `%s`", jsonObj.get("tags").toString())); - } - JsonArray jsonArraynodes = jsonObj.getAsJsonArray("nodes"); - if (jsonArraynodes != null) { - // ensure the json data is an array - if (!jsonObj.get("nodes").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `nodes` to be an array in the JSON string but got `%s`", jsonObj.get("nodes").toString())); - } - - // validate the optional field `nodes` (array) - for (int i = 0; i < jsonArraynodes.size(); i++) { - TaskGraphNode.validateJsonObject(jsonArraynodes.get(i).getAsJsonObject()); - }; - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!RegisteredTaskGraph.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'RegisteredTaskGraph' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(RegisteredTaskGraph.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, RegisteredTaskGraph value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public RegisteredTaskGraph read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - RegisteredTaskGraph instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of RegisteredTaskGraph given an JSON string - * - * @param jsonString JSON string - * @return An instance of RegisteredTaskGraph - * @throws IOException if the JSON string is invalid with respect to RegisteredTaskGraph - */ - public static RegisteredTaskGraph fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, RegisteredTaskGraph.class); - } - - /** - * Convert an instance of RegisteredTaskGraph to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ResetUserPasswordRequest.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ResetUserPasswordRequest.java deleted file mode 100644 index 07048f7..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ResetUserPasswordRequest.java +++ /dev/null @@ -1,265 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Password to update - */ -@ApiModel(description = "Password to update") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class ResetUserPasswordRequest { - public static final String SERIALIZED_NAME_PASSWORD = "password"; - @SerializedName(SERIALIZED_NAME_PASSWORD) - private String password; - - public ResetUserPasswordRequest() { - } - - public ResetUserPasswordRequest password(String password) { - - this.password = password; - return this; - } - - /** - * password - * @return password - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "password", value = "password") - - public String getPassword() { - return password; - } - - - public void setPassword(String password) { - this.password = password; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public ResetUserPasswordRequest putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ResetUserPasswordRequest resetUserPasswordRequest = (ResetUserPasswordRequest) o; - return Objects.equals(this.password, resetUserPasswordRequest.password)&& - Objects.equals(this.additionalProperties, resetUserPasswordRequest.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(password, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ResetUserPasswordRequest {\n"); - sb.append(" password: ").append(toIndentedString(password)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("password"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to ResetUserPasswordRequest - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (ResetUserPasswordRequest.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in ResetUserPasswordRequest is not found in the empty JSON string", ResetUserPasswordRequest.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("password") != null && !jsonObj.get("password").isJsonNull()) && !jsonObj.get("password").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `password` to be a primitive type in the JSON string but got `%s`", jsonObj.get("password").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!ResetUserPasswordRequest.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'ResetUserPasswordRequest' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(ResetUserPasswordRequest.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, ResetUserPasswordRequest value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public ResetUserPasswordRequest read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - ResetUserPasswordRequest instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of ResetUserPasswordRequest given an JSON string - * - * @param jsonString JSON string - * @return An instance of ResetUserPasswordRequest - * @throws IOException if the JSON string is invalid with respect to ResetUserPasswordRequest - */ - public static ResetUserPasswordRequest fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, ResetUserPasswordRequest.class); - } - - /** - * Convert an instance of ResetUserPasswordRequest to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ResultFormat.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/ResultFormat.java deleted file mode 100644 index 97d863a..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/ResultFormat.java +++ /dev/null @@ -1,79 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * Data format of a result - */ -@JsonAdapter(ResultFormat.Adapter.class) -public enum ResultFormat { - - PYTHON_PICKLE("python_pickle"), - - R_SERIALIZATION("r_serialization"), - - JSON("json"), - - ARROW("arrow"), - - BYTES("bytes"), - - TILEDB_JSON("tiledb_json"), - - NATIVE("native"); - - private String value; - - ResultFormat(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static ResultFormat fromValue(String value) { - for (ResultFormat b : ResultFormat.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final ResultFormat enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public ResultFormat read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return ResultFormat.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/RetryPolicy.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/RetryPolicy.java deleted file mode 100644 index 81894e3..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/RetryPolicy.java +++ /dev/null @@ -1,73 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * RetryPolicy is a policy of node statuses that will be retried - */ -@JsonAdapter(RetryPolicy.Adapter.class) -public enum RetryPolicy { - - ALWAYS("Always"), - - ONFAILURE("OnFailure"), - - ONERROR("OnError"), - - ONTRANSIENTERROR("OnTransientError"); - - private String value; - - RetryPolicy(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static RetryPolicy fromValue(String value) { - for (RetryPolicy b : RetryPolicy.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final RetryPolicy enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public RetryPolicy read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return RetryPolicy.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/RetryStrategy.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/RetryStrategy.java deleted file mode 100644 index 55ad48d..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/RetryStrategy.java +++ /dev/null @@ -1,359 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * RetryStrategy provides controls on how to retry a taskgraph node - */ -@ApiModel(description = "RetryStrategy provides controls on how to retry a taskgraph node") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class RetryStrategy { - public static final String SERIALIZED_NAME_BACKOFF = "backoff"; - @SerializedName(SERIALIZED_NAME_BACKOFF) - private Backoff backoff; - - public static final String SERIALIZED_NAME_EXPRESSION = "expression"; - @SerializedName(SERIALIZED_NAME_EXPRESSION) - private String expression; - - public static final String SERIALIZED_NAME_LIMIT = "limit"; - @SerializedName(SERIALIZED_NAME_LIMIT) - private Integer limit; - - public static final String SERIALIZED_NAME_RETRY_POLICY = "retryPolicy"; - @SerializedName(SERIALIZED_NAME_RETRY_POLICY) - private RetryPolicy retryPolicy; - - public RetryStrategy() { - } - - public RetryStrategy backoff(Backoff backoff) { - - this.backoff = backoff; - return this; - } - - /** - * Get backoff - * @return backoff - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Backoff getBackoff() { - return backoff; - } - - - public void setBackoff(Backoff backoff) { - this.backoff = backoff; - } - - - public RetryStrategy expression(String expression) { - - this.expression = expression; - return this; - } - - /** - * Expression is a condition expression for when a node will be retried. If it evaluates to false, the node will not be retried and the retry strategy will be ignored - * @return expression - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Expression is a condition expression for when a node will be retried. If it evaluates to false, the node will not be retried and the retry strategy will be ignored") - - public String getExpression() { - return expression; - } - - - public void setExpression(String expression) { - this.expression = expression; - } - - - public RetryStrategy limit(Integer limit) { - - this.limit = limit; - return this; - } - - /** - * Limit is the maximum number of retry attempts when retrying a container. It does not include the original container; the maximum number of total attempts will be `limit + 1`. - * @return limit - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Limit is the maximum number of retry attempts when retrying a container. It does not include the original container; the maximum number of total attempts will be `limit + 1`.") - - public Integer getLimit() { - return limit; - } - - - public void setLimit(Integer limit) { - this.limit = limit; - } - - - public RetryStrategy retryPolicy(RetryPolicy retryPolicy) { - - this.retryPolicy = retryPolicy; - return this; - } - - /** - * Get retryPolicy - * @return retryPolicy - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public RetryPolicy getRetryPolicy() { - return retryPolicy; - } - - - public void setRetryPolicy(RetryPolicy retryPolicy) { - this.retryPolicy = retryPolicy; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public RetryStrategy putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - RetryStrategy retryStrategy = (RetryStrategy) o; - return Objects.equals(this.backoff, retryStrategy.backoff) && - Objects.equals(this.expression, retryStrategy.expression) && - Objects.equals(this.limit, retryStrategy.limit) && - Objects.equals(this.retryPolicy, retryStrategy.retryPolicy)&& - Objects.equals(this.additionalProperties, retryStrategy.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(backoff, expression, limit, retryPolicy, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class RetryStrategy {\n"); - sb.append(" backoff: ").append(toIndentedString(backoff)).append("\n"); - sb.append(" expression: ").append(toIndentedString(expression)).append("\n"); - sb.append(" limit: ").append(toIndentedString(limit)).append("\n"); - sb.append(" retryPolicy: ").append(toIndentedString(retryPolicy)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("backoff"); - openapiFields.add("expression"); - openapiFields.add("limit"); - openapiFields.add("retryPolicy"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to RetryStrategy - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (RetryStrategy.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in RetryStrategy is not found in the empty JSON string", RetryStrategy.openapiRequiredFields.toString())); - } - } - // validate the optional field `backoff` - if (jsonObj.get("backoff") != null && !jsonObj.get("backoff").isJsonNull()) { - Backoff.validateJsonObject(jsonObj.getAsJsonObject("backoff")); - } - if ((jsonObj.get("expression") != null && !jsonObj.get("expression").isJsonNull()) && !jsonObj.get("expression").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `expression` to be a primitive type in the JSON string but got `%s`", jsonObj.get("expression").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!RetryStrategy.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'RetryStrategy' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(RetryStrategy.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, RetryStrategy value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public RetryStrategy read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - RetryStrategy instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of RetryStrategy given an JSON string - * - * @param jsonString JSON string - * @return An instance of RetryStrategy - * @throws IOException if the JSON string is invalid with respect to RetryStrategy - */ - public static RetryStrategy fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, RetryStrategy.class); - } - - /** - * Convert an instance of RetryStrategy to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/SQLParameters.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/SQLParameters.java deleted file mode 100644 index 05f721c..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/SQLParameters.java +++ /dev/null @@ -1,606 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Parameters for running sql query - */ -@ApiModel(description = "Parameters for running sql query") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class SQLParameters { - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_QUERY = "query"; - @SerializedName(SERIALIZED_NAME_QUERY) - private String query; - - public static final String SERIALIZED_NAME_OUTPUT_URI = "output_uri"; - @SerializedName(SERIALIZED_NAME_OUTPUT_URI) - private String outputUri; - - public static final String SERIALIZED_NAME_STORE_RESULTS = "store_results"; - @SerializedName(SERIALIZED_NAME_STORE_RESULTS) - private Boolean storeResults; - - public static final String SERIALIZED_NAME_DONT_DOWNLOAD_RESULTS = "dont_download_results"; - @SerializedName(SERIALIZED_NAME_DONT_DOWNLOAD_RESULTS) - private Boolean dontDownloadResults; - - public static final String SERIALIZED_NAME_RESOURCE_CLASS = "resource_class"; - @SerializedName(SERIALIZED_NAME_RESOURCE_CLASS) - private String resourceClass; - - public static final String SERIALIZED_NAME_RESULT_FORMAT = "result_format"; - @SerializedName(SERIALIZED_NAME_RESULT_FORMAT) - private ResultFormat resultFormat; - - public static final String SERIALIZED_NAME_INIT_COMMANDS = "init_commands"; - @SerializedName(SERIALIZED_NAME_INIT_COMMANDS) - private List initCommands = null; - - public static final String SERIALIZED_NAME_PARAMETERS = "parameters"; - @SerializedName(SERIALIZED_NAME_PARAMETERS) - private List parameters = null; - - public static final String SERIALIZED_NAME_TASK_GRAPH_UUID = "task_graph_uuid"; - @SerializedName(SERIALIZED_NAME_TASK_GRAPH_UUID) - private String taskGraphUuid; - - public static final String SERIALIZED_NAME_CLIENT_NODE_UUID = "client_node_uuid"; - @SerializedName(SERIALIZED_NAME_CLIENT_NODE_UUID) - private String clientNodeUuid; - - public SQLParameters() { - } - - public SQLParameters name(String name) { - - this.name = name; - return this; - } - - /** - * name of task, optional - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "name of task, optional") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public SQLParameters query(String query) { - - this.query = query; - return this; - } - - /** - * query to run - * @return query - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "query to run") - - public String getQuery() { - return query; - } - - - public void setQuery(String query) { - this.query = query; - } - - - public SQLParameters outputUri(String outputUri) { - - this.outputUri = outputUri; - return this; - } - - /** - * Output array uri - * @return outputUri - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "s3://my_bucket/my_output_array", value = "Output array uri") - - public String getOutputUri() { - return outputUri; - } - - - public void setOutputUri(String outputUri) { - this.outputUri = outputUri; - } - - - public SQLParameters storeResults(Boolean storeResults) { - - this.storeResults = storeResults; - return this; - } - - /** - * store results for later retrieval - * @return storeResults - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "store results for later retrieval") - - public Boolean getStoreResults() { - return storeResults; - } - - - public void setStoreResults(Boolean storeResults) { - this.storeResults = storeResults; - } - - - public SQLParameters dontDownloadResults(Boolean dontDownloadResults) { - - this.dontDownloadResults = dontDownloadResults; - return this; - } - - /** - * Set to true to avoid downloading the results of this UDF. Useful for intermediate nodes in a task graph where you will not be using the results of your function. Defaults to false (\"yes download results\"). - * @return dontDownloadResults - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Set to true to avoid downloading the results of this UDF. Useful for intermediate nodes in a task graph where you will not be using the results of your function. Defaults to false (\"yes download results\").") - - public Boolean getDontDownloadResults() { - return dontDownloadResults; - } - - - public void setDontDownloadResults(Boolean dontDownloadResults) { - this.dontDownloadResults = dontDownloadResults; - } - - - public SQLParameters resourceClass(String resourceClass) { - - this.resourceClass = resourceClass; - return this; - } - - /** - * The resource class to use for the SQL execution. Resource classes define resource limits for memory and CPUs. If this is empty, then the SQL will execute in the standard resource class of the TileDB Cloud provider. - * @return resourceClass - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "standard", value = "The resource class to use for the SQL execution. Resource classes define resource limits for memory and CPUs. If this is empty, then the SQL will execute in the standard resource class of the TileDB Cloud provider. ") - - public String getResourceClass() { - return resourceClass; - } - - - public void setResourceClass(String resourceClass) { - this.resourceClass = resourceClass; - } - - - public SQLParameters resultFormat(ResultFormat resultFormat) { - - this.resultFormat = resultFormat; - return this; - } - - /** - * Get resultFormat - * @return resultFormat - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public ResultFormat getResultFormat() { - return resultFormat; - } - - - public void setResultFormat(ResultFormat resultFormat) { - this.resultFormat = resultFormat; - } - - - public SQLParameters initCommands(List initCommands) { - - this.initCommands = initCommands; - return this; - } - - public SQLParameters addInitCommandsItem(String initCommandsItem) { - if (this.initCommands == null) { - this.initCommands = new ArrayList<>(); - } - this.initCommands.add(initCommandsItem); - return this; - } - - /** - * Queries or commands to run before main query - * @return initCommands - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Queries or commands to run before main query") - - public List getInitCommands() { - return initCommands; - } - - - public void setInitCommands(List initCommands) { - this.initCommands = initCommands; - } - - - public SQLParameters parameters(List parameters) { - - this.parameters = parameters; - return this; - } - - public SQLParameters addParametersItem(Object parametersItem) { - if (this.parameters == null) { - this.parameters = new ArrayList<>(); - } - this.parameters.add(parametersItem); - return this; - } - - /** - * SQL query parameters - * @return parameters - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "SQL query parameters") - - public List getParameters() { - return parameters; - } - - - public void setParameters(List parameters) { - this.parameters = parameters; - } - - - public SQLParameters taskGraphUuid(String taskGraphUuid) { - - this.taskGraphUuid = taskGraphUuid; - return this; - } - - /** - * If set, the ID of the log for the task graph that this was part of. - * @return taskGraphUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "If set, the ID of the log for the task graph that this was part of. ") - - public String getTaskGraphUuid() { - return taskGraphUuid; - } - - - public void setTaskGraphUuid(String taskGraphUuid) { - this.taskGraphUuid = taskGraphUuid; - } - - - public SQLParameters clientNodeUuid(String clientNodeUuid) { - - this.clientNodeUuid = clientNodeUuid; - return this; - } - - /** - * If set, the client-defined ID of the node within this task's graph. - * @return clientNodeUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "If set, the client-defined ID of the node within this task's graph. ") - - public String getClientNodeUuid() { - return clientNodeUuid; - } - - - public void setClientNodeUuid(String clientNodeUuid) { - this.clientNodeUuid = clientNodeUuid; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public SQLParameters putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - SQLParameters sqLParameters = (SQLParameters) o; - return Objects.equals(this.name, sqLParameters.name) && - Objects.equals(this.query, sqLParameters.query) && - Objects.equals(this.outputUri, sqLParameters.outputUri) && - Objects.equals(this.storeResults, sqLParameters.storeResults) && - Objects.equals(this.dontDownloadResults, sqLParameters.dontDownloadResults) && - Objects.equals(this.resourceClass, sqLParameters.resourceClass) && - Objects.equals(this.resultFormat, sqLParameters.resultFormat) && - Objects.equals(this.initCommands, sqLParameters.initCommands) && - Objects.equals(this.parameters, sqLParameters.parameters) && - Objects.equals(this.taskGraphUuid, sqLParameters.taskGraphUuid) && - Objects.equals(this.clientNodeUuid, sqLParameters.clientNodeUuid)&& - Objects.equals(this.additionalProperties, sqLParameters.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(name, query, outputUri, storeResults, dontDownloadResults, resourceClass, resultFormat, initCommands, parameters, taskGraphUuid, clientNodeUuid, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class SQLParameters {\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" query: ").append(toIndentedString(query)).append("\n"); - sb.append(" outputUri: ").append(toIndentedString(outputUri)).append("\n"); - sb.append(" storeResults: ").append(toIndentedString(storeResults)).append("\n"); - sb.append(" dontDownloadResults: ").append(toIndentedString(dontDownloadResults)).append("\n"); - sb.append(" resourceClass: ").append(toIndentedString(resourceClass)).append("\n"); - sb.append(" resultFormat: ").append(toIndentedString(resultFormat)).append("\n"); - sb.append(" initCommands: ").append(toIndentedString(initCommands)).append("\n"); - sb.append(" parameters: ").append(toIndentedString(parameters)).append("\n"); - sb.append(" taskGraphUuid: ").append(toIndentedString(taskGraphUuid)).append("\n"); - sb.append(" clientNodeUuid: ").append(toIndentedString(clientNodeUuid)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("name"); - openapiFields.add("query"); - openapiFields.add("output_uri"); - openapiFields.add("store_results"); - openapiFields.add("dont_download_results"); - openapiFields.add("resource_class"); - openapiFields.add("result_format"); - openapiFields.add("init_commands"); - openapiFields.add("parameters"); - openapiFields.add("task_graph_uuid"); - openapiFields.add("client_node_uuid"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to SQLParameters - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (SQLParameters.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in SQLParameters is not found in the empty JSON string", SQLParameters.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - if ((jsonObj.get("query") != null && !jsonObj.get("query").isJsonNull()) && !jsonObj.get("query").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `query` to be a primitive type in the JSON string but got `%s`", jsonObj.get("query").toString())); - } - if ((jsonObj.get("output_uri") != null && !jsonObj.get("output_uri").isJsonNull()) && !jsonObj.get("output_uri").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `output_uri` to be a primitive type in the JSON string but got `%s`", jsonObj.get("output_uri").toString())); - } - if ((jsonObj.get("resource_class") != null && !jsonObj.get("resource_class").isJsonNull()) && !jsonObj.get("resource_class").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `resource_class` to be a primitive type in the JSON string but got `%s`", jsonObj.get("resource_class").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("init_commands") != null && !jsonObj.get("init_commands").isJsonNull()) && !jsonObj.get("init_commands").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `init_commands` to be an array in the JSON string but got `%s`", jsonObj.get("init_commands").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("parameters") != null && !jsonObj.get("parameters").isJsonNull()) && !jsonObj.get("parameters").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `parameters` to be an array in the JSON string but got `%s`", jsonObj.get("parameters").toString())); - } - if ((jsonObj.get("task_graph_uuid") != null && !jsonObj.get("task_graph_uuid").isJsonNull()) && !jsonObj.get("task_graph_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `task_graph_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("task_graph_uuid").toString())); - } - if ((jsonObj.get("client_node_uuid") != null && !jsonObj.get("client_node_uuid").isJsonNull()) && !jsonObj.get("client_node_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `client_node_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("client_node_uuid").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!SQLParameters.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'SQLParameters' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(SQLParameters.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, SQLParameters value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public SQLParameters read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - SQLParameters instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of SQLParameters given an JSON string - * - * @param jsonString JSON string - * @return An instance of SQLParameters - * @throws IOException if the JSON string is invalid with respect to SQLParameters - */ - public static SQLParameters fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, SQLParameters.class); - } - - /** - * Convert an instance of SQLParameters to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/SSODomainConfig.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/SSODomainConfig.java deleted file mode 100644 index 2aacdca..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/SSODomainConfig.java +++ /dev/null @@ -1,527 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import org.openapitools.jackson.nullable.JsonNullable; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * The information used to set up a single-sign on connection to a customer domain. - */ -@ApiModel(description = "The information used to set up a single-sign on connection to a customer domain. ") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class SSODomainConfig { - public static final String SERIALIZED_NAME_UUID = "uuid"; - @SerializedName(SERIALIZED_NAME_UUID) - private String uuid; - - public static final String SERIALIZED_NAME_DOMAIN = "domain"; - @SerializedName(SERIALIZED_NAME_DOMAIN) - private String domain; - - public static final String SERIALIZED_NAME_OIDC_ISSUER = "oidc_issuer"; - @SerializedName(SERIALIZED_NAME_OIDC_ISSUER) - private String oidcIssuer; - - public static final String SERIALIZED_NAME_OIDC_CLIENT_ID = "oidc_client_id"; - @SerializedName(SERIALIZED_NAME_OIDC_CLIENT_ID) - private String oidcClientId; - - public static final String SERIALIZED_NAME_OIDC_CLIENT_SECRET = "oidc_client_secret"; - @SerializedName(SERIALIZED_NAME_OIDC_CLIENT_SECRET) - private String oidcClientSecret; - - public static final String SERIALIZED_NAME_DOMAIN_SETUP = "domain_setup"; - @SerializedName(SERIALIZED_NAME_DOMAIN_SETUP) - private SSODomainSetup domainSetup; - - public static final String SERIALIZED_NAME_VERIFICATION_STATUS = "verification_status"; - @SerializedName(SERIALIZED_NAME_VERIFICATION_STATUS) - private DomainVerificationStatus verificationStatus; - - public static final String SERIALIZED_NAME_CHECK_RESULTS = "check_results"; - @SerializedName(SERIALIZED_NAME_CHECK_RESULTS) - private List checkResults = null; - - public SSODomainConfig() { - } - - public SSODomainConfig uuid(String uuid) { - - this.uuid = uuid; - return this; - } - - /** - * A server-generated ID for the configuration. - * @return uuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "A server-generated ID for the configuration.") - - public String getUuid() { - return uuid; - } - - - public void setUuid(String uuid) { - this.uuid = uuid; - } - - - public SSODomainConfig domain(String domain) { - - this.domain = domain; - return this; - } - - /** - * The fully-qualified domain (but with no trailing dot) to connect for single sign-on. This may not be changed after creation. - * @return domain - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The fully-qualified domain (but with no trailing dot) to connect for single sign-on. This may not be changed after creation. ") - - public String getDomain() { - return domain; - } - - - public void setDomain(String domain) { - this.domain = domain; - } - - - public SSODomainConfig oidcIssuer(String oidcIssuer) { - - this.oidcIssuer = oidcIssuer; - return this; - } - - /** - * The URL of the OpenID Connect issuer that can be used to authenticate this domain's users. The prefix where the `/.well-known/openid-configuration` file can be found; usually without a trailing slash. - * @return oidcIssuer - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The URL of the OpenID Connect issuer that can be used to authenticate this domain's users. The prefix where the `/.well-known/openid-configuration` file can be found; usually without a trailing slash. ") - - public String getOidcIssuer() { - return oidcIssuer; - } - - - public void setOidcIssuer(String oidcIssuer) { - this.oidcIssuer = oidcIssuer; - } - - - public SSODomainConfig oidcClientId(String oidcClientId) { - - this.oidcClientId = oidcClientId; - return this; - } - - /** - * The OpenID Connect client ID for this SSO instance. - * @return oidcClientId - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The OpenID Connect client ID for this SSO instance.") - - public String getOidcClientId() { - return oidcClientId; - } - - - public void setOidcClientId(String oidcClientId) { - this.oidcClientId = oidcClientId; - } - - - public SSODomainConfig oidcClientSecret(String oidcClientSecret) { - - this.oidcClientSecret = oidcClientSecret; - return this; - } - - /** - * The OpenID Connect client secret for this SSO instance. - * @return oidcClientSecret - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The OpenID Connect client secret for this SSO instance.") - - public String getOidcClientSecret() { - return oidcClientSecret; - } - - - public void setOidcClientSecret(String oidcClientSecret) { - this.oidcClientSecret = oidcClientSecret; - } - - - public SSODomainConfig domainSetup(SSODomainSetup domainSetup) { - - this.domainSetup = domainSetup; - return this; - } - - /** - * Get domainSetup - * @return domainSetup - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public SSODomainSetup getDomainSetup() { - return domainSetup; - } - - - public void setDomainSetup(SSODomainSetup domainSetup) { - this.domainSetup = domainSetup; - } - - - public SSODomainConfig verificationStatus(DomainVerificationStatus verificationStatus) { - - this.verificationStatus = verificationStatus; - return this; - } - - /** - * Get verificationStatus - * @return verificationStatus - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public DomainVerificationStatus getVerificationStatus() { - return verificationStatus; - } - - - public void setVerificationStatus(DomainVerificationStatus verificationStatus) { - this.verificationStatus = verificationStatus; - } - - - public SSODomainConfig checkResults(List checkResults) { - - this.checkResults = checkResults; - return this; - } - - public SSODomainConfig addCheckResultsItem(DomainCheckResult checkResultsItem) { - if (this.checkResults == null) { - this.checkResults = new ArrayList<>(); - } - this.checkResults.add(checkResultsItem); - return this; - } - - /** - * A list of the results of recent attempts to verify this domain. - * @return checkResults - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "A list of the results of recent attempts to verify this domain. ") - - public List getCheckResults() { - return checkResults; - } - - - public void setCheckResults(List checkResults) { - this.checkResults = checkResults; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public SSODomainConfig putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - SSODomainConfig ssODomainConfig = (SSODomainConfig) o; - return Objects.equals(this.uuid, ssODomainConfig.uuid) && - Objects.equals(this.domain, ssODomainConfig.domain) && - Objects.equals(this.oidcIssuer, ssODomainConfig.oidcIssuer) && - Objects.equals(this.oidcClientId, ssODomainConfig.oidcClientId) && - Objects.equals(this.oidcClientSecret, ssODomainConfig.oidcClientSecret) && - Objects.equals(this.domainSetup, ssODomainConfig.domainSetup) && - Objects.equals(this.verificationStatus, ssODomainConfig.verificationStatus) && - Objects.equals(this.checkResults, ssODomainConfig.checkResults)&& - Objects.equals(this.additionalProperties, ssODomainConfig.additionalProperties); - } - - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); - } - - @Override - public int hashCode() { - return Objects.hash(uuid, domain, oidcIssuer, oidcClientId, oidcClientSecret, domainSetup, verificationStatus, checkResults, additionalProperties); - } - - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class SSODomainConfig {\n"); - sb.append(" uuid: ").append(toIndentedString(uuid)).append("\n"); - sb.append(" domain: ").append(toIndentedString(domain)).append("\n"); - sb.append(" oidcIssuer: ").append(toIndentedString(oidcIssuer)).append("\n"); - sb.append(" oidcClientId: ").append(toIndentedString(oidcClientId)).append("\n"); - sb.append(" oidcClientSecret: ").append(toIndentedString(oidcClientSecret)).append("\n"); - sb.append(" domainSetup: ").append(toIndentedString(domainSetup)).append("\n"); - sb.append(" verificationStatus: ").append(toIndentedString(verificationStatus)).append("\n"); - sb.append(" checkResults: ").append(toIndentedString(checkResults)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("uuid"); - openapiFields.add("domain"); - openapiFields.add("oidc_issuer"); - openapiFields.add("oidc_client_id"); - openapiFields.add("oidc_client_secret"); - openapiFields.add("domain_setup"); - openapiFields.add("verification_status"); - openapiFields.add("check_results"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to SSODomainConfig - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (SSODomainConfig.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in SSODomainConfig is not found in the empty JSON string", SSODomainConfig.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("uuid") != null && !jsonObj.get("uuid").isJsonNull()) && !jsonObj.get("uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("uuid").toString())); - } - if ((jsonObj.get("domain") != null && !jsonObj.get("domain").isJsonNull()) && !jsonObj.get("domain").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `domain` to be a primitive type in the JSON string but got `%s`", jsonObj.get("domain").toString())); - } - if ((jsonObj.get("oidc_issuer") != null && !jsonObj.get("oidc_issuer").isJsonNull()) && !jsonObj.get("oidc_issuer").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `oidc_issuer` to be a primitive type in the JSON string but got `%s`", jsonObj.get("oidc_issuer").toString())); - } - if ((jsonObj.get("oidc_client_id") != null && !jsonObj.get("oidc_client_id").isJsonNull()) && !jsonObj.get("oidc_client_id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `oidc_client_id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("oidc_client_id").toString())); - } - if ((jsonObj.get("oidc_client_secret") != null && !jsonObj.get("oidc_client_secret").isJsonNull()) && !jsonObj.get("oidc_client_secret").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `oidc_client_secret` to be a primitive type in the JSON string but got `%s`", jsonObj.get("oidc_client_secret").toString())); - } - // validate the optional field `domain_setup` - if (jsonObj.get("domain_setup") != null && !jsonObj.get("domain_setup").isJsonNull()) { - SSODomainSetup.validateJsonObject(jsonObj.getAsJsonObject("domain_setup")); - } - JsonArray jsonArraycheckResults = jsonObj.getAsJsonArray("check_results"); - if (jsonArraycheckResults != null) { - // ensure the json data is an array - if (!jsonObj.get("check_results").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `check_results` to be an array in the JSON string but got `%s`", jsonObj.get("check_results").toString())); - } - - // validate the optional field `check_results` (array) - for (int i = 0; i < jsonArraycheckResults.size(); i++) { - DomainCheckResult.validateJsonObject(jsonArraycheckResults.get(i).getAsJsonObject()); - }; - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!SSODomainConfig.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'SSODomainConfig' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(SSODomainConfig.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, SSODomainConfig value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public SSODomainConfig read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - SSODomainConfig instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of SSODomainConfig given an JSON string - * - * @param jsonString JSON string - * @return An instance of SSODomainConfig - * @throws IOException if the JSON string is invalid with respect to SSODomainConfig - */ - public static SSODomainConfig fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, SSODomainConfig.class); - } - - /** - * Convert an instance of SSODomainConfig to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/SSODomainConfigResponse.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/SSODomainConfigResponse.java deleted file mode 100644 index 0f141de..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/SSODomainConfigResponse.java +++ /dev/null @@ -1,285 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * The response to a request for the list of domain claims associated with a particular organization. - */ -@ApiModel(description = "The response to a request for the list of domain claims associated with a particular organization. ") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class SSODomainConfigResponse { - public static final String SERIALIZED_NAME_DOMAIN_CONFIGS = "domain_configs"; - @SerializedName(SERIALIZED_NAME_DOMAIN_CONFIGS) - private List domainConfigs = null; - - public SSODomainConfigResponse() { - } - - public SSODomainConfigResponse domainConfigs(List domainConfigs) { - - this.domainConfigs = domainConfigs; - return this; - } - - public SSODomainConfigResponse addDomainConfigsItem(SSODomainConfig domainConfigsItem) { - if (this.domainConfigs == null) { - this.domainConfigs = new ArrayList<>(); - } - this.domainConfigs.add(domainConfigsItem); - return this; - } - - /** - * Get domainConfigs - * @return domainConfigs - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List getDomainConfigs() { - return domainConfigs; - } - - - public void setDomainConfigs(List domainConfigs) { - this.domainConfigs = domainConfigs; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public SSODomainConfigResponse putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - SSODomainConfigResponse ssODomainConfigResponse = (SSODomainConfigResponse) o; - return Objects.equals(this.domainConfigs, ssODomainConfigResponse.domainConfigs)&& - Objects.equals(this.additionalProperties, ssODomainConfigResponse.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(domainConfigs, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class SSODomainConfigResponse {\n"); - sb.append(" domainConfigs: ").append(toIndentedString(domainConfigs)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("domain_configs"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to SSODomainConfigResponse - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (SSODomainConfigResponse.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in SSODomainConfigResponse is not found in the empty JSON string", SSODomainConfigResponse.openapiRequiredFields.toString())); - } - } - JsonArray jsonArraydomainConfigs = jsonObj.getAsJsonArray("domain_configs"); - if (jsonArraydomainConfigs != null) { - // ensure the json data is an array - if (!jsonObj.get("domain_configs").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `domain_configs` to be an array in the JSON string but got `%s`", jsonObj.get("domain_configs").toString())); - } - - // validate the optional field `domain_configs` (array) - for (int i = 0; i < jsonArraydomainConfigs.size(); i++) { - SSODomainConfig.validateJsonObject(jsonArraydomainConfigs.get(i).getAsJsonObject()); - }; - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!SSODomainConfigResponse.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'SSODomainConfigResponse' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(SSODomainConfigResponse.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, SSODomainConfigResponse value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public SSODomainConfigResponse read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - SSODomainConfigResponse instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of SSODomainConfigResponse given an JSON string - * - * @param jsonString JSON string - * @return An instance of SSODomainConfigResponse - * @throws IOException if the JSON string is invalid with respect to SSODomainConfigResponse - */ - public static SSODomainConfigResponse fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, SSODomainConfigResponse.class); - } - - /** - * Convert an instance of SSODomainConfigResponse to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/SSODomainSetup.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/SSODomainSetup.java deleted file mode 100644 index 7ffb238..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/SSODomainSetup.java +++ /dev/null @@ -1,331 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Configuration settings to verify ownership of a given domain. At least one of these must be completed enable user login from the domain. - */ -@ApiModel(description = "Configuration settings to verify ownership of a given domain. At least one of these must be completed enable user login from the domain. ") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class SSODomainSetup { - public static final String SERIALIZED_NAME_TXT = "txt"; - @SerializedName(SERIALIZED_NAME_TXT) - private String txt; - - public static final String SERIALIZED_NAME_CNAME_SRC = "cname_src"; - @SerializedName(SERIALIZED_NAME_CNAME_SRC) - private String cnameSrc; - - public static final String SERIALIZED_NAME_CNAME_DST = "cname_dst"; - @SerializedName(SERIALIZED_NAME_CNAME_DST) - private String cnameDst; - - public SSODomainSetup() { - } - - public SSODomainSetup txt(String txt) { - - this.txt = txt; - return this; - } - - /** - * a DNS TXT record to set on the domain to claim. - * @return txt - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "a DNS TXT record to set on the domain to claim.") - - public String getTxt() { - return txt; - } - - - public void setTxt(String txt) { - this.txt = txt; - } - - - public SSODomainSetup cnameSrc(String cnameSrc) { - - this.cnameSrc = cnameSrc; - return this; - } - - /** - * a DNS name to set a CNAME record on - * @return cnameSrc - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "a DNS name to set a CNAME record on") - - public String getCnameSrc() { - return cnameSrc; - } - - - public void setCnameSrc(String cnameSrc) { - this.cnameSrc = cnameSrc; - } - - - public SSODomainSetup cnameDst(String cnameDst) { - - this.cnameDst = cnameDst; - return this; - } - - /** - * the CNAME target of `cname_src`. - * @return cnameDst - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "the CNAME target of `cname_src`.") - - public String getCnameDst() { - return cnameDst; - } - - - public void setCnameDst(String cnameDst) { - this.cnameDst = cnameDst; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public SSODomainSetup putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - SSODomainSetup ssODomainSetup = (SSODomainSetup) o; - return Objects.equals(this.txt, ssODomainSetup.txt) && - Objects.equals(this.cnameSrc, ssODomainSetup.cnameSrc) && - Objects.equals(this.cnameDst, ssODomainSetup.cnameDst)&& - Objects.equals(this.additionalProperties, ssODomainSetup.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(txt, cnameSrc, cnameDst, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class SSODomainSetup {\n"); - sb.append(" txt: ").append(toIndentedString(txt)).append("\n"); - sb.append(" cnameSrc: ").append(toIndentedString(cnameSrc)).append("\n"); - sb.append(" cnameDst: ").append(toIndentedString(cnameDst)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("txt"); - openapiFields.add("cname_src"); - openapiFields.add("cname_dst"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to SSODomainSetup - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (SSODomainSetup.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in SSODomainSetup is not found in the empty JSON string", SSODomainSetup.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("txt") != null && !jsonObj.get("txt").isJsonNull()) && !jsonObj.get("txt").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `txt` to be a primitive type in the JSON string but got `%s`", jsonObj.get("txt").toString())); - } - if ((jsonObj.get("cname_src") != null && !jsonObj.get("cname_src").isJsonNull()) && !jsonObj.get("cname_src").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `cname_src` to be a primitive type in the JSON string but got `%s`", jsonObj.get("cname_src").toString())); - } - if ((jsonObj.get("cname_dst") != null && !jsonObj.get("cname_dst").isJsonNull()) && !jsonObj.get("cname_dst").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `cname_dst` to be a primitive type in the JSON string but got `%s`", jsonObj.get("cname_dst").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!SSODomainSetup.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'SSODomainSetup' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(SSODomainSetup.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, SSODomainSetup value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public SSODomainSetup read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - SSODomainSetup instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of SSODomainSetup given an JSON string - * - * @param jsonString JSON string - * @return An instance of SSODomainSetup - * @throws IOException if the JSON string is invalid with respect to SSODomainSetup - */ - public static SSODomainSetup fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, SSODomainSetup.class); - } - - /** - * Convert an instance of SSODomainSetup to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/SSOProvider.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/SSOProvider.java deleted file mode 100644 index aced3a4..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/SSOProvider.java +++ /dev/null @@ -1,73 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * Single sign on provider - */ -@JsonAdapter(SSOProvider.Adapter.class) -public enum SSOProvider { - - GITHUB("github"), - - GOOGLE("google"), - - STRIPE("stripe"), - - OKTA("okta"); - - private String value; - - SSOProvider(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static SSOProvider fromValue(String value) { - for (SSOProvider b : SSOProvider.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final SSOProvider enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public SSOProvider read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return SSOProvider.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/SingleFragmentInfo.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/SingleFragmentInfo.java deleted file mode 100644 index c0a9365..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/SingleFragmentInfo.java +++ /dev/null @@ -1,299 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Single Fragment info of an array - */ -@ApiModel(description = "Single Fragment info of an array") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class SingleFragmentInfo { - public static final String SERIALIZED_NAME_ARRAY_SCHEMA_NAME = "ArraySchemaName"; - @SerializedName(SERIALIZED_NAME_ARRAY_SCHEMA_NAME) - private String arraySchemaName; - - public static final String SERIALIZED_NAME_META = "meta"; - @SerializedName(SERIALIZED_NAME_META) - private FragmentMetadata meta; - - public SingleFragmentInfo() { - } - - public SingleFragmentInfo arraySchemaName(String arraySchemaName) { - - this.arraySchemaName = arraySchemaName; - return this; - } - - /** - * array schema name - * @return arraySchemaName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "array schema name") - - public String getArraySchemaName() { - return arraySchemaName; - } - - - public void setArraySchemaName(String arraySchemaName) { - this.arraySchemaName = arraySchemaName; - } - - - public SingleFragmentInfo meta(FragmentMetadata meta) { - - this.meta = meta; - return this; - } - - /** - * Get meta - * @return meta - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public FragmentMetadata getMeta() { - return meta; - } - - - public void setMeta(FragmentMetadata meta) { - this.meta = meta; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public SingleFragmentInfo putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - SingleFragmentInfo singleFragmentInfo = (SingleFragmentInfo) o; - return Objects.equals(this.arraySchemaName, singleFragmentInfo.arraySchemaName) && - Objects.equals(this.meta, singleFragmentInfo.meta)&& - Objects.equals(this.additionalProperties, singleFragmentInfo.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(arraySchemaName, meta, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class SingleFragmentInfo {\n"); - sb.append(" arraySchemaName: ").append(toIndentedString(arraySchemaName)).append("\n"); - sb.append(" meta: ").append(toIndentedString(meta)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("ArraySchemaName"); - openapiFields.add("meta"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to SingleFragmentInfo - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (SingleFragmentInfo.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in SingleFragmentInfo is not found in the empty JSON string", SingleFragmentInfo.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("ArraySchemaName") != null && !jsonObj.get("ArraySchemaName").isJsonNull()) && !jsonObj.get("ArraySchemaName").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `ArraySchemaName` to be a primitive type in the JSON string but got `%s`", jsonObj.get("ArraySchemaName").toString())); - } - // validate the optional field `meta` - if (jsonObj.get("meta") != null && !jsonObj.get("meta").isJsonNull()) { - FragmentMetadata.validateJsonObject(jsonObj.getAsJsonObject("meta")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!SingleFragmentInfo.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'SingleFragmentInfo' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(SingleFragmentInfo.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, SingleFragmentInfo value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public SingleFragmentInfo read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - SingleFragmentInfo instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of SingleFragmentInfo given an JSON string - * - * @param jsonString JSON string - * @return An instance of SingleFragmentInfo - * @throws IOException if the JSON string is invalid with respect to SingleFragmentInfo - */ - public static SingleFragmentInfo fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, SingleFragmentInfo.class); - } - - /** - * Convert an instance of SingleFragmentInfo to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/StorageLocation.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/StorageLocation.java deleted file mode 100644 index bedb40f..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/StorageLocation.java +++ /dev/null @@ -1,310 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import org.openapitools.jackson.nullable.JsonNullable; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * The path at which a given asset will be stored, and the credentials used to access that asset. - */ -@ApiModel(description = "The path at which a given asset will be stored, and the credentials used to access that asset. ") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class StorageLocation { - public static final String SERIALIZED_NAME_PATH = "path"; - @SerializedName(SERIALIZED_NAME_PATH) - private String path; - - public static final String SERIALIZED_NAME_CREDENTIALS_NAME = "credentials_name"; - @SerializedName(SERIALIZED_NAME_CREDENTIALS_NAME) - private String credentialsName; - - public StorageLocation() { - } - - public StorageLocation path(String path) { - - this.path = path; - return this; - } - - /** - * The path to store this asset type. If unset, a suffix of the user's `default_s3_path` is used. When updating, explicitly set to `\"\"`, the empty string, to clear this path; leaving it `null` (or absent) will leave the path unchanged. - * @return path - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The path to store this asset type. If unset, a suffix of the user's `default_s3_path` is used. When updating, explicitly set to `\"\"`, the empty string, to clear this path; leaving it `null` (or absent) will leave the path unchanged. ") - - public String getPath() { - return path; - } - - - public void setPath(String path) { - this.path = path; - } - - - public StorageLocation credentialsName(String credentialsName) { - - this.credentialsName = credentialsName; - return this; - } - - /** - * The name of the credentials used to acess this storage path. If unset, the `default_s3_path_credentials_name` is used. When updating, explicitly set to `\"\"`, the empty string, to clear this name; leaving it `null` (or absent) will leave the name unchanged. - * @return credentialsName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The name of the credentials used to acess this storage path. If unset, the `default_s3_path_credentials_name` is used. When updating, explicitly set to `\"\"`, the empty string, to clear this name; leaving it `null` (or absent) will leave the name unchanged. ") - - public String getCredentialsName() { - return credentialsName; - } - - - public void setCredentialsName(String credentialsName) { - this.credentialsName = credentialsName; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public StorageLocation putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - StorageLocation storageLocation = (StorageLocation) o; - return Objects.equals(this.path, storageLocation.path) && - Objects.equals(this.credentialsName, storageLocation.credentialsName)&& - Objects.equals(this.additionalProperties, storageLocation.additionalProperties); - } - - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); - } - - @Override - public int hashCode() { - return Objects.hash(path, credentialsName, additionalProperties); - } - - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class StorageLocation {\n"); - sb.append(" path: ").append(toIndentedString(path)).append("\n"); - sb.append(" credentialsName: ").append(toIndentedString(credentialsName)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("path"); - openapiFields.add("credentials_name"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to StorageLocation - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (StorageLocation.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in StorageLocation is not found in the empty JSON string", StorageLocation.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("path") != null && !jsonObj.get("path").isJsonNull()) && !jsonObj.get("path").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `path` to be a primitive type in the JSON string but got `%s`", jsonObj.get("path").toString())); - } - if ((jsonObj.get("credentials_name") != null && !jsonObj.get("credentials_name").isJsonNull()) && !jsonObj.get("credentials_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `credentials_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("credentials_name").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!StorageLocation.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'StorageLocation' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(StorageLocation.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, StorageLocation value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public StorageLocation read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - StorageLocation instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of StorageLocation given an JSON string - * - * @param jsonString JSON string - * @return An instance of StorageLocation - * @throws IOException if the JSON string is invalid with respect to StorageLocation - */ - public static StorageLocation fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, StorageLocation.class); - } - - /** - * Convert an instance of StorageLocation to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Subarray.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/Subarray.java deleted file mode 100644 index 8da28c1..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Subarray.java +++ /dev/null @@ -1,315 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * A Subarray - */ -@ApiModel(description = "A Subarray") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class Subarray { - public static final String SERIALIZED_NAME_LAYOUT = "layout"; - @SerializedName(SERIALIZED_NAME_LAYOUT) - private Layout layout; - - public static final String SERIALIZED_NAME_RANGES = "ranges"; - @SerializedName(SERIALIZED_NAME_RANGES) - private List ranges = null; - - public Subarray() { - } - - public Subarray layout(Layout layout) { - - this.layout = layout; - return this; - } - - /** - * Get layout - * @return layout - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Layout getLayout() { - return layout; - } - - - public void setLayout(Layout layout) { - this.layout = layout; - } - - - public Subarray ranges(List ranges) { - - this.ranges = ranges; - return this; - } - - public Subarray addRangesItem(SubarrayRanges rangesItem) { - if (this.ranges == null) { - this.ranges = new ArrayList<>(); - } - this.ranges.add(rangesItem); - return this; - } - - /** - * List of 1D ranges, one per dimension - * @return ranges - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "List of 1D ranges, one per dimension") - - public List getRanges() { - return ranges; - } - - - public void setRanges(List ranges) { - this.ranges = ranges; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public Subarray putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Subarray subarray = (Subarray) o; - return Objects.equals(this.layout, subarray.layout) && - Objects.equals(this.ranges, subarray.ranges)&& - Objects.equals(this.additionalProperties, subarray.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(layout, ranges, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Subarray {\n"); - sb.append(" layout: ").append(toIndentedString(layout)).append("\n"); - sb.append(" ranges: ").append(toIndentedString(ranges)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("layout"); - openapiFields.add("ranges"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to Subarray - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (Subarray.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in Subarray is not found in the empty JSON string", Subarray.openapiRequiredFields.toString())); - } - } - JsonArray jsonArrayranges = jsonObj.getAsJsonArray("ranges"); - if (jsonArrayranges != null) { - // ensure the json data is an array - if (!jsonObj.get("ranges").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `ranges` to be an array in the JSON string but got `%s`", jsonObj.get("ranges").toString())); - } - - // validate the optional field `ranges` (array) - for (int i = 0; i < jsonArrayranges.size(); i++) { - SubarrayRanges.validateJsonObject(jsonArrayranges.get(i).getAsJsonObject()); - }; - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!Subarray.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'Subarray' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(Subarray.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, Subarray value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public Subarray read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - Subarray instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of Subarray given an JSON string - * - * @param jsonString JSON string - * @return An instance of Subarray - * @throws IOException if the JSON string is invalid with respect to Subarray - */ - public static Subarray fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, Subarray.class); - } - - /** - * Convert an instance of Subarray to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/SubarrayPartitioner.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/SubarrayPartitioner.java deleted file mode 100644 index 5fee8a4..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/SubarrayPartitioner.java +++ /dev/null @@ -1,447 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * The subarray partitioner - */ -@ApiModel(description = "The subarray partitioner") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class SubarrayPartitioner { - public static final String SERIALIZED_NAME_SUBARRAY = "subarray"; - @SerializedName(SERIALIZED_NAME_SUBARRAY) - private Subarray subarray; - - public static final String SERIALIZED_NAME_BUDGET = "budget"; - @SerializedName(SERIALIZED_NAME_BUDGET) - private List budget = null; - - public static final String SERIALIZED_NAME_CURRENT = "current"; - @SerializedName(SERIALIZED_NAME_CURRENT) - private SubarrayPartitionerCurrent current; - - public static final String SERIALIZED_NAME_STATE = "state"; - @SerializedName(SERIALIZED_NAME_STATE) - private SubarrayPartitionerState state; - - public static final String SERIALIZED_NAME_MEMORY_BUDGET = "memoryBudget"; - @SerializedName(SERIALIZED_NAME_MEMORY_BUDGET) - private Integer memoryBudget; - - public static final String SERIALIZED_NAME_MEMORY_BUDGET_VAR = "memoryBudgetVar"; - @SerializedName(SERIALIZED_NAME_MEMORY_BUDGET_VAR) - private Integer memoryBudgetVar; - - public SubarrayPartitioner() { - } - - public SubarrayPartitioner subarray(Subarray subarray) { - - this.subarray = subarray; - return this; - } - - /** - * Get subarray - * @return subarray - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Subarray getSubarray() { - return subarray; - } - - - public void setSubarray(Subarray subarray) { - this.subarray = subarray; - } - - - public SubarrayPartitioner budget(List budget) { - - this.budget = budget; - return this; - } - - public SubarrayPartitioner addBudgetItem(AttributeBufferSize budgetItem) { - if (this.budget == null) { - this.budget = new ArrayList<>(); - } - this.budget.add(budgetItem); - return this; - } - - /** - * Result size budget (in bytes) for all attributes. - * @return budget - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Result size budget (in bytes) for all attributes.") - - public List getBudget() { - return budget; - } - - - public void setBudget(List budget) { - this.budget = budget; - } - - - public SubarrayPartitioner current(SubarrayPartitionerCurrent current) { - - this.current = current; - return this; - } - - /** - * Get current - * @return current - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public SubarrayPartitionerCurrent getCurrent() { - return current; - } - - - public void setCurrent(SubarrayPartitionerCurrent current) { - this.current = current; - } - - - public SubarrayPartitioner state(SubarrayPartitionerState state) { - - this.state = state; - return this; - } - - /** - * Get state - * @return state - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public SubarrayPartitionerState getState() { - return state; - } - - - public void setState(SubarrayPartitionerState state) { - this.state = state; - } - - - public SubarrayPartitioner memoryBudget(Integer memoryBudget) { - - this.memoryBudget = memoryBudget; - return this; - } - - /** - * The memory budget for the fixed-sized attributes and the offsets of the var-sized attributes - * @return memoryBudget - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The memory budget for the fixed-sized attributes and the offsets of the var-sized attributes") - - public Integer getMemoryBudget() { - return memoryBudget; - } - - - public void setMemoryBudget(Integer memoryBudget) { - this.memoryBudget = memoryBudget; - } - - - public SubarrayPartitioner memoryBudgetVar(Integer memoryBudgetVar) { - - this.memoryBudgetVar = memoryBudgetVar; - return this; - } - - /** - * The memory budget for the var-sized attributes - * @return memoryBudgetVar - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The memory budget for the var-sized attributes") - - public Integer getMemoryBudgetVar() { - return memoryBudgetVar; - } - - - public void setMemoryBudgetVar(Integer memoryBudgetVar) { - this.memoryBudgetVar = memoryBudgetVar; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public SubarrayPartitioner putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - SubarrayPartitioner subarrayPartitioner = (SubarrayPartitioner) o; - return Objects.equals(this.subarray, subarrayPartitioner.subarray) && - Objects.equals(this.budget, subarrayPartitioner.budget) && - Objects.equals(this.current, subarrayPartitioner.current) && - Objects.equals(this.state, subarrayPartitioner.state) && - Objects.equals(this.memoryBudget, subarrayPartitioner.memoryBudget) && - Objects.equals(this.memoryBudgetVar, subarrayPartitioner.memoryBudgetVar)&& - Objects.equals(this.additionalProperties, subarrayPartitioner.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(subarray, budget, current, state, memoryBudget, memoryBudgetVar, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class SubarrayPartitioner {\n"); - sb.append(" subarray: ").append(toIndentedString(subarray)).append("\n"); - sb.append(" budget: ").append(toIndentedString(budget)).append("\n"); - sb.append(" current: ").append(toIndentedString(current)).append("\n"); - sb.append(" state: ").append(toIndentedString(state)).append("\n"); - sb.append(" memoryBudget: ").append(toIndentedString(memoryBudget)).append("\n"); - sb.append(" memoryBudgetVar: ").append(toIndentedString(memoryBudgetVar)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("subarray"); - openapiFields.add("budget"); - openapiFields.add("current"); - openapiFields.add("state"); - openapiFields.add("memoryBudget"); - openapiFields.add("memoryBudgetVar"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to SubarrayPartitioner - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (SubarrayPartitioner.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in SubarrayPartitioner is not found in the empty JSON string", SubarrayPartitioner.openapiRequiredFields.toString())); - } - } - // validate the optional field `subarray` - if (jsonObj.get("subarray") != null && !jsonObj.get("subarray").isJsonNull()) { - Subarray.validateJsonObject(jsonObj.getAsJsonObject("subarray")); - } - JsonArray jsonArraybudget = jsonObj.getAsJsonArray("budget"); - if (jsonArraybudget != null) { - // ensure the json data is an array - if (!jsonObj.get("budget").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `budget` to be an array in the JSON string but got `%s`", jsonObj.get("budget").toString())); - } - - // validate the optional field `budget` (array) - for (int i = 0; i < jsonArraybudget.size(); i++) { - AttributeBufferSize.validateJsonObject(jsonArraybudget.get(i).getAsJsonObject()); - }; - } - // validate the optional field `current` - if (jsonObj.get("current") != null && !jsonObj.get("current").isJsonNull()) { - SubarrayPartitionerCurrent.validateJsonObject(jsonObj.getAsJsonObject("current")); - } - // validate the optional field `state` - if (jsonObj.get("state") != null && !jsonObj.get("state").isJsonNull()) { - SubarrayPartitionerState.validateJsonObject(jsonObj.getAsJsonObject("state")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!SubarrayPartitioner.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'SubarrayPartitioner' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(SubarrayPartitioner.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, SubarrayPartitioner value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public SubarrayPartitioner read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - SubarrayPartitioner instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of SubarrayPartitioner given an JSON string - * - * @param jsonString JSON string - * @return An instance of SubarrayPartitioner - * @throws IOException if the JSON string is invalid with respect to SubarrayPartitioner - */ - public static SubarrayPartitioner fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, SubarrayPartitioner.class); - } - - /** - * Convert an instance of SubarrayPartitioner to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/SubarrayPartitionerCurrent.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/SubarrayPartitionerCurrent.java deleted file mode 100644 index 89cd8f9..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/SubarrayPartitionerCurrent.java +++ /dev/null @@ -1,356 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * The current partition info - */ -@ApiModel(description = "The current partition info") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class SubarrayPartitionerCurrent { - public static final String SERIALIZED_NAME_SUBARRAY = "subarray"; - @SerializedName(SERIALIZED_NAME_SUBARRAY) - private Subarray subarray; - - public static final String SERIALIZED_NAME_START = "start"; - @SerializedName(SERIALIZED_NAME_START) - private Integer start; - - public static final String SERIALIZED_NAME_END = "end"; - @SerializedName(SERIALIZED_NAME_END) - private Integer end; - - public static final String SERIALIZED_NAME_SPLIT_MULTI_RANGE = "splitMultiRange"; - @SerializedName(SERIALIZED_NAME_SPLIT_MULTI_RANGE) - private Boolean splitMultiRange; - - public SubarrayPartitionerCurrent() { - } - - public SubarrayPartitionerCurrent subarray(Subarray subarray) { - - this.subarray = subarray; - return this; - } - - /** - * Get subarray - * @return subarray - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Subarray getSubarray() { - return subarray; - } - - - public void setSubarray(Subarray subarray) { - this.subarray = subarray; - } - - - public SubarrayPartitionerCurrent start(Integer start) { - - this.start = start; - return this; - } - - /** - * PartitionInfo start - * @return start - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "PartitionInfo start") - - public Integer getStart() { - return start; - } - - - public void setStart(Integer start) { - this.start = start; - } - - - public SubarrayPartitionerCurrent end(Integer end) { - - this.end = end; - return this; - } - - /** - * PartitionInfo end - * @return end - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "PartitionInfo end") - - public Integer getEnd() { - return end; - } - - - public void setEnd(Integer end) { - this.end = end; - } - - - public SubarrayPartitionerCurrent splitMultiRange(Boolean splitMultiRange) { - - this.splitMultiRange = splitMultiRange; - return this; - } - - /** - * PartitionInfo splitMultiRange - * @return splitMultiRange - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "PartitionInfo splitMultiRange") - - public Boolean getSplitMultiRange() { - return splitMultiRange; - } - - - public void setSplitMultiRange(Boolean splitMultiRange) { - this.splitMultiRange = splitMultiRange; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public SubarrayPartitionerCurrent putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - SubarrayPartitionerCurrent subarrayPartitionerCurrent = (SubarrayPartitionerCurrent) o; - return Objects.equals(this.subarray, subarrayPartitionerCurrent.subarray) && - Objects.equals(this.start, subarrayPartitionerCurrent.start) && - Objects.equals(this.end, subarrayPartitionerCurrent.end) && - Objects.equals(this.splitMultiRange, subarrayPartitionerCurrent.splitMultiRange)&& - Objects.equals(this.additionalProperties, subarrayPartitionerCurrent.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(subarray, start, end, splitMultiRange, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class SubarrayPartitionerCurrent {\n"); - sb.append(" subarray: ").append(toIndentedString(subarray)).append("\n"); - sb.append(" start: ").append(toIndentedString(start)).append("\n"); - sb.append(" end: ").append(toIndentedString(end)).append("\n"); - sb.append(" splitMultiRange: ").append(toIndentedString(splitMultiRange)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("subarray"); - openapiFields.add("start"); - openapiFields.add("end"); - openapiFields.add("splitMultiRange"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to SubarrayPartitionerCurrent - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (SubarrayPartitionerCurrent.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in SubarrayPartitionerCurrent is not found in the empty JSON string", SubarrayPartitionerCurrent.openapiRequiredFields.toString())); - } - } - // validate the optional field `subarray` - if (jsonObj.get("subarray") != null && !jsonObj.get("subarray").isJsonNull()) { - Subarray.validateJsonObject(jsonObj.getAsJsonObject("subarray")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!SubarrayPartitionerCurrent.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'SubarrayPartitionerCurrent' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(SubarrayPartitionerCurrent.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, SubarrayPartitionerCurrent value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public SubarrayPartitionerCurrent read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - SubarrayPartitionerCurrent instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of SubarrayPartitionerCurrent given an JSON string - * - * @param jsonString JSON string - * @return An instance of SubarrayPartitionerCurrent - * @throws IOException if the JSON string is invalid with respect to SubarrayPartitionerCurrent - */ - public static SubarrayPartitionerCurrent fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, SubarrayPartitionerCurrent.class); - } - - /** - * Convert an instance of SubarrayPartitionerCurrent to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/SubarrayPartitionerState.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/SubarrayPartitionerState.java deleted file mode 100644 index c6aab36..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/SubarrayPartitionerState.java +++ /dev/null @@ -1,395 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * The state information for the remaining partitions to be produced - */ -@ApiModel(description = "The state information for the remaining partitions to be produced") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class SubarrayPartitionerState { - public static final String SERIALIZED_NAME_START = "start"; - @SerializedName(SERIALIZED_NAME_START) - private Integer start; - - public static final String SERIALIZED_NAME_END = "end"; - @SerializedName(SERIALIZED_NAME_END) - private Integer end; - - public static final String SERIALIZED_NAME_SINGLE_RANGE = "singleRange"; - @SerializedName(SERIALIZED_NAME_SINGLE_RANGE) - private List singleRange = null; - - public static final String SERIALIZED_NAME_MULTI_RANGE = "multiRange"; - @SerializedName(SERIALIZED_NAME_MULTI_RANGE) - private List multiRange = null; - - public SubarrayPartitionerState() { - } - - public SubarrayPartitionerState start(Integer start) { - - this.start = start; - return this; - } - - /** - * State start - * @return start - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "State start") - - public Integer getStart() { - return start; - } - - - public void setStart(Integer start) { - this.start = start; - } - - - public SubarrayPartitionerState end(Integer end) { - - this.end = end; - return this; - } - - /** - * State end - * @return end - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "State end") - - public Integer getEnd() { - return end; - } - - - public void setEnd(Integer end) { - this.end = end; - } - - - public SubarrayPartitionerState singleRange(List singleRange) { - - this.singleRange = singleRange; - return this; - } - - public SubarrayPartitionerState addSingleRangeItem(Subarray singleRangeItem) { - if (this.singleRange == null) { - this.singleRange = new ArrayList<>(); - } - this.singleRange.add(singleRangeItem); - return this; - } - - /** - * State singleRange - * @return singleRange - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "State singleRange") - - public List getSingleRange() { - return singleRange; - } - - - public void setSingleRange(List singleRange) { - this.singleRange = singleRange; - } - - - public SubarrayPartitionerState multiRange(List multiRange) { - - this.multiRange = multiRange; - return this; - } - - public SubarrayPartitionerState addMultiRangeItem(Subarray multiRangeItem) { - if (this.multiRange == null) { - this.multiRange = new ArrayList<>(); - } - this.multiRange.add(multiRangeItem); - return this; - } - - /** - * State multiRange - * @return multiRange - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "State multiRange") - - public List getMultiRange() { - return multiRange; - } - - - public void setMultiRange(List multiRange) { - this.multiRange = multiRange; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public SubarrayPartitionerState putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - SubarrayPartitionerState subarrayPartitionerState = (SubarrayPartitionerState) o; - return Objects.equals(this.start, subarrayPartitionerState.start) && - Objects.equals(this.end, subarrayPartitionerState.end) && - Objects.equals(this.singleRange, subarrayPartitionerState.singleRange) && - Objects.equals(this.multiRange, subarrayPartitionerState.multiRange)&& - Objects.equals(this.additionalProperties, subarrayPartitionerState.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(start, end, singleRange, multiRange, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class SubarrayPartitionerState {\n"); - sb.append(" start: ").append(toIndentedString(start)).append("\n"); - sb.append(" end: ").append(toIndentedString(end)).append("\n"); - sb.append(" singleRange: ").append(toIndentedString(singleRange)).append("\n"); - sb.append(" multiRange: ").append(toIndentedString(multiRange)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("start"); - openapiFields.add("end"); - openapiFields.add("singleRange"); - openapiFields.add("multiRange"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to SubarrayPartitionerState - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (SubarrayPartitionerState.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in SubarrayPartitionerState is not found in the empty JSON string", SubarrayPartitionerState.openapiRequiredFields.toString())); - } - } - JsonArray jsonArraysingleRange = jsonObj.getAsJsonArray("singleRange"); - if (jsonArraysingleRange != null) { - // ensure the json data is an array - if (!jsonObj.get("singleRange").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `singleRange` to be an array in the JSON string but got `%s`", jsonObj.get("singleRange").toString())); - } - - // validate the optional field `singleRange` (array) - for (int i = 0; i < jsonArraysingleRange.size(); i++) { - Subarray.validateJsonObject(jsonArraysingleRange.get(i).getAsJsonObject()); - }; - } - JsonArray jsonArraymultiRange = jsonObj.getAsJsonArray("multiRange"); - if (jsonArraymultiRange != null) { - // ensure the json data is an array - if (!jsonObj.get("multiRange").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `multiRange` to be an array in the JSON string but got `%s`", jsonObj.get("multiRange").toString())); - } - - // validate the optional field `multiRange` (array) - for (int i = 0; i < jsonArraymultiRange.size(); i++) { - Subarray.validateJsonObject(jsonArraymultiRange.get(i).getAsJsonObject()); - }; - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!SubarrayPartitionerState.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'SubarrayPartitionerState' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(SubarrayPartitionerState.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, SubarrayPartitionerState value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public SubarrayPartitionerState read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - SubarrayPartitionerState instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of SubarrayPartitionerState given an JSON string - * - * @param jsonString JSON string - * @return An instance of SubarrayPartitionerState - * @throws IOException if the JSON string is invalid with respect to SubarrayPartitionerState - */ - public static SubarrayPartitionerState fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, SubarrayPartitionerState.class); - } - - /** - * Convert an instance of SubarrayPartitionerState to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/SubarrayRanges.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/SubarrayRanges.java deleted file mode 100644 index b635b3a..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/SubarrayRanges.java +++ /dev/null @@ -1,336 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * A set of 1D ranges for a subarray - */ -@ApiModel(description = "A set of 1D ranges for a subarray") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class SubarrayRanges { - public static final String SERIALIZED_NAME_TYPE = "type"; - @SerializedName(SERIALIZED_NAME_TYPE) - private Datatype type; - - public static final String SERIALIZED_NAME_HAS_DEFAULT_RANGE = "hasDefaultRange"; - @SerializedName(SERIALIZED_NAME_HAS_DEFAULT_RANGE) - private Boolean hasDefaultRange; - - public static final String SERIALIZED_NAME_BUFFER = "buffer"; - @SerializedName(SERIALIZED_NAME_BUFFER) - private List buffer = null; - - public SubarrayRanges() { - } - - public SubarrayRanges type(Datatype type) { - - this.type = type; - return this; - } - - /** - * Get type - * @return type - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Datatype getType() { - return type; - } - - - public void setType(Datatype type) { - this.type = type; - } - - - public SubarrayRanges hasDefaultRange(Boolean hasDefaultRange) { - - this.hasDefaultRange = hasDefaultRange; - return this; - } - - /** - * True if the range is the default range - * @return hasDefaultRange - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "True if the range is the default range") - - public Boolean getHasDefaultRange() { - return hasDefaultRange; - } - - - public void setHasDefaultRange(Boolean hasDefaultRange) { - this.hasDefaultRange = hasDefaultRange; - } - - - public SubarrayRanges buffer(List buffer) { - - this.buffer = buffer; - return this; - } - - public SubarrayRanges addBufferItem(Integer bufferItem) { - if (this.buffer == null) { - this.buffer = new ArrayList<>(); - } - this.buffer.add(bufferItem); - return this; - } - - /** - * The bytes of the ranges - * @return buffer - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The bytes of the ranges") - - public List getBuffer() { - return buffer; - } - - - public void setBuffer(List buffer) { - this.buffer = buffer; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public SubarrayRanges putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - SubarrayRanges subarrayRanges = (SubarrayRanges) o; - return Objects.equals(this.type, subarrayRanges.type) && - Objects.equals(this.hasDefaultRange, subarrayRanges.hasDefaultRange) && - Objects.equals(this.buffer, subarrayRanges.buffer)&& - Objects.equals(this.additionalProperties, subarrayRanges.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(type, hasDefaultRange, buffer, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class SubarrayRanges {\n"); - sb.append(" type: ").append(toIndentedString(type)).append("\n"); - sb.append(" hasDefaultRange: ").append(toIndentedString(hasDefaultRange)).append("\n"); - sb.append(" buffer: ").append(toIndentedString(buffer)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("type"); - openapiFields.add("hasDefaultRange"); - openapiFields.add("buffer"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to SubarrayRanges - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (SubarrayRanges.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in SubarrayRanges is not found in the empty JSON string", SubarrayRanges.openapiRequiredFields.toString())); - } - } - // ensure the json data is an array - if ((jsonObj.get("buffer") != null && !jsonObj.get("buffer").isJsonNull()) && !jsonObj.get("buffer").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `buffer` to be an array in the JSON string but got `%s`", jsonObj.get("buffer").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!SubarrayRanges.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'SubarrayRanges' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(SubarrayRanges.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, SubarrayRanges value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public SubarrayRanges read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - SubarrayRanges instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of SubarrayRanges given an JSON string - * - * @param jsonString JSON string - * @return An instance of SubarrayRanges - * @throws IOException if the JSON string is invalid with respect to SubarrayRanges - */ - public static SubarrayRanges fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, SubarrayRanges.class); - } - - /** - * Convert an instance of SubarrayRanges to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Subscription.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/Subscription.java deleted file mode 100644 index e9ffd3d..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Subscription.java +++ /dev/null @@ -1,384 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Subscription of a user (customer) to another user's arrays - */ -@ApiModel(description = "Subscription of a user (customer) to another user's arrays") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class Subscription { - public static final String SERIALIZED_NAME_ID = "id"; - @SerializedName(SERIALIZED_NAME_ID) - private String id; - - public static final String SERIALIZED_NAME_OWNER_NAMESPACE_UUID = "owner_namespace_uuid"; - @SerializedName(SERIALIZED_NAME_OWNER_NAMESPACE_UUID) - private String ownerNamespaceUuid; - - public static final String SERIALIZED_NAME_CUSTOMER_NAMESPACE_UUID = "customer_namespace_uuid"; - @SerializedName(SERIALIZED_NAME_CUSTOMER_NAMESPACE_UUID) - private String customerNamespaceUuid; - - public static final String SERIALIZED_NAME_PRICING = "pricing"; - @SerializedName(SERIALIZED_NAME_PRICING) - private List pricing = null; - - public Subscription() { - } - - public Subscription id(String id) { - - this.id = id; - return this; - } - - /** - * Unique ID of subscription as defined by Stripe - * @return id - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "subscriptionID", value = "Unique ID of subscription as defined by Stripe") - - public String getId() { - return id; - } - - - public void setId(String id) { - this.id = id; - } - - - public Subscription ownerNamespaceUuid(String ownerNamespaceUuid) { - - this.ownerNamespaceUuid = ownerNamespaceUuid; - return this; - } - - /** - * Unique ID of the array (product) owner - * @return ownerNamespaceUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "Unique ID of the array (product) owner") - - public String getOwnerNamespaceUuid() { - return ownerNamespaceUuid; - } - - - public void setOwnerNamespaceUuid(String ownerNamespaceUuid) { - this.ownerNamespaceUuid = ownerNamespaceUuid; - } - - - public Subscription customerNamespaceUuid(String customerNamespaceUuid) { - - this.customerNamespaceUuid = customerNamespaceUuid; - return this; - } - - /** - * Unique ID of the array (product) user (customer) - * @return customerNamespaceUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "Unique ID of the array (product) user (customer)") - - public String getCustomerNamespaceUuid() { - return customerNamespaceUuid; - } - - - public void setCustomerNamespaceUuid(String customerNamespaceUuid) { - this.customerNamespaceUuid = customerNamespaceUuid; - } - - - public Subscription pricing(List pricing) { - - this.pricing = pricing; - return this; - } - - public Subscription addPricingItem(Pricing pricingItem) { - if (this.pricing == null) { - this.pricing = new ArrayList<>(); - } - this.pricing.add(pricingItem); - return this; - } - - /** - * list of pricing used by this subscription - * @return pricing - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "list of pricing used by this subscription") - - public List getPricing() { - return pricing; - } - - - public void setPricing(List pricing) { - this.pricing = pricing; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public Subscription putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Subscription subscription = (Subscription) o; - return Objects.equals(this.id, subscription.id) && - Objects.equals(this.ownerNamespaceUuid, subscription.ownerNamespaceUuid) && - Objects.equals(this.customerNamespaceUuid, subscription.customerNamespaceUuid) && - Objects.equals(this.pricing, subscription.pricing)&& - Objects.equals(this.additionalProperties, subscription.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(id, ownerNamespaceUuid, customerNamespaceUuid, pricing, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Subscription {\n"); - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" ownerNamespaceUuid: ").append(toIndentedString(ownerNamespaceUuid)).append("\n"); - sb.append(" customerNamespaceUuid: ").append(toIndentedString(customerNamespaceUuid)).append("\n"); - sb.append(" pricing: ").append(toIndentedString(pricing)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("id"); - openapiFields.add("owner_namespace_uuid"); - openapiFields.add("customer_namespace_uuid"); - openapiFields.add("pricing"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to Subscription - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (Subscription.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in Subscription is not found in the empty JSON string", Subscription.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) && !jsonObj.get("id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("id").toString())); - } - if ((jsonObj.get("owner_namespace_uuid") != null && !jsonObj.get("owner_namespace_uuid").isJsonNull()) && !jsonObj.get("owner_namespace_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `owner_namespace_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("owner_namespace_uuid").toString())); - } - if ((jsonObj.get("customer_namespace_uuid") != null && !jsonObj.get("customer_namespace_uuid").isJsonNull()) && !jsonObj.get("customer_namespace_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `customer_namespace_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("customer_namespace_uuid").toString())); - } - JsonArray jsonArraypricing = jsonObj.getAsJsonArray("pricing"); - if (jsonArraypricing != null) { - // ensure the json data is an array - if (!jsonObj.get("pricing").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `pricing` to be an array in the JSON string but got `%s`", jsonObj.get("pricing").toString())); - } - - // validate the optional field `pricing` (array) - for (int i = 0; i < jsonArraypricing.size(); i++) { - Pricing.validateJsonObject(jsonArraypricing.get(i).getAsJsonObject()); - }; - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!Subscription.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'Subscription' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(Subscription.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, Subscription value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public Subscription read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - Subscription instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of Subscription given an JSON string - * - * @param jsonString JSON string - * @return An instance of Subscription - * @throws IOException if the JSON string is invalid with respect to Subscription - */ - public static Subscription fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, Subscription.class); - } - - /** - * Convert an instance of Subscription to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGArrayNodeData.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGArrayNodeData.java deleted file mode 100644 index ee953a0..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGArrayNodeData.java +++ /dev/null @@ -1,326 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * The details of an array that should be queried and provided as the input to a UDF Node. This is essentially a `UDFArrayDetails`, but you’re allowed to provide most of the values as Nodes if you want. - */ -@ApiModel(description = "The details of an array that should be queried and provided as the input to a UDF Node. This is essentially a `UDFArrayDetails`, but you’re allowed to provide most of the values as Nodes if you want. ") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class TGArrayNodeData { - public static final String SERIALIZED_NAME_URI = "uri"; - @SerializedName(SERIALIZED_NAME_URI) - private Object uri; - - public static final String SERIALIZED_NAME_RANGES = "ranges"; - @SerializedName(SERIALIZED_NAME_RANGES) - private TGQueryRanges ranges; - - public static final String SERIALIZED_NAME_BUFFERS = "buffers"; - @SerializedName(SERIALIZED_NAME_BUFFERS) - private Object buffers; - - public TGArrayNodeData() { - } - - public TGArrayNodeData uri(Object uri) { - - this.uri = uri; - return this; - } - - /** - * An argument provided to a node. This is one of a direct value (i.e., a raw JSON value) or a `TGSentinel`. For example this Python value: {\"a\": [1, \"pipe\", range(30), None], \"b\": b\"bytes\"} is encoded thusly (with included comments): { // A dictionary with string keys is JSON-encodable. \"a\": [ // As is a list. 1, \"pipe\", { // A `range` is replaced with its pickle. \"__tdbudf__\": \"immediate\", \"format\": \"python_pickle\", \"base64_data\": \"gASVIAAAAAAAAACMCGJ1aWx0aW5zlIwFcmFuZ2WUk5RLAEseSwGHlFKULg==\" }, null ], \"b\": { // Raw binary data is encoded into base64. \"__tdbudf__\": \"immediate\" \"format\": \"bytes\", \"base64_data\": \"Ynl0ZXM=\" } } - * @return uri - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "An argument provided to a node. This is one of a direct value (i.e., a raw JSON value) or a `TGSentinel`. For example this Python value: {\"a\": [1, \"pipe\", range(30), None], \"b\": b\"bytes\"} is encoded thusly (with included comments): { // A dictionary with string keys is JSON-encodable. \"a\": [ // As is a list. 1, \"pipe\", { // A `range` is replaced with its pickle. \"__tdbudf__\": \"immediate\", \"format\": \"python_pickle\", \"base64_data\": \"gASVIAAAAAAAAACMCGJ1aWx0aW5zlIwFcmFuZ2WUk5RLAEseSwGHlFKULg==\" }, null ], \"b\": { // Raw binary data is encoded into base64. \"__tdbudf__\": \"immediate\" \"format\": \"bytes\", \"base64_data\": \"Ynl0ZXM=\" } } ") - - public Object getUri() { - return uri; - } - - - public void setUri(Object uri) { - this.uri = uri; - } - - - public TGArrayNodeData ranges(TGQueryRanges ranges) { - - this.ranges = ranges; - return this; - } - - /** - * Get ranges - * @return ranges - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public TGQueryRanges getRanges() { - return ranges; - } - - - public void setRanges(TGQueryRanges ranges) { - this.ranges = ranges; - } - - - public TGArrayNodeData buffers(Object buffers) { - - this.buffers = buffers; - return this; - } - - /** - * An argument provided to a node. This is one of a direct value (i.e., a raw JSON value) or a `TGSentinel`. For example this Python value: {\"a\": [1, \"pipe\", range(30), None], \"b\": b\"bytes\"} is encoded thusly (with included comments): { // A dictionary with string keys is JSON-encodable. \"a\": [ // As is a list. 1, \"pipe\", { // A `range` is replaced with its pickle. \"__tdbudf__\": \"immediate\", \"format\": \"python_pickle\", \"base64_data\": \"gASVIAAAAAAAAACMCGJ1aWx0aW5zlIwFcmFuZ2WUk5RLAEseSwGHlFKULg==\" }, null ], \"b\": { // Raw binary data is encoded into base64. \"__tdbudf__\": \"immediate\" \"format\": \"bytes\", \"base64_data\": \"Ynl0ZXM=\" } } - * @return buffers - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "An argument provided to a node. This is one of a direct value (i.e., a raw JSON value) or a `TGSentinel`. For example this Python value: {\"a\": [1, \"pipe\", range(30), None], \"b\": b\"bytes\"} is encoded thusly (with included comments): { // A dictionary with string keys is JSON-encodable. \"a\": [ // As is a list. 1, \"pipe\", { // A `range` is replaced with its pickle. \"__tdbudf__\": \"immediate\", \"format\": \"python_pickle\", \"base64_data\": \"gASVIAAAAAAAAACMCGJ1aWx0aW5zlIwFcmFuZ2WUk5RLAEseSwGHlFKULg==\" }, null ], \"b\": { // Raw binary data is encoded into base64. \"__tdbudf__\": \"immediate\" \"format\": \"bytes\", \"base64_data\": \"Ynl0ZXM=\" } } ") - - public Object getBuffers() { - return buffers; - } - - - public void setBuffers(Object buffers) { - this.buffers = buffers; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public TGArrayNodeData putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - TGArrayNodeData tgArrayNodeData = (TGArrayNodeData) o; - return Objects.equals(this.uri, tgArrayNodeData.uri) && - Objects.equals(this.ranges, tgArrayNodeData.ranges) && - Objects.equals(this.buffers, tgArrayNodeData.buffers)&& - Objects.equals(this.additionalProperties, tgArrayNodeData.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(uri, ranges, buffers, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class TGArrayNodeData {\n"); - sb.append(" uri: ").append(toIndentedString(uri)).append("\n"); - sb.append(" ranges: ").append(toIndentedString(ranges)).append("\n"); - sb.append(" buffers: ").append(toIndentedString(buffers)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("uri"); - openapiFields.add("ranges"); - openapiFields.add("buffers"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to TGArrayNodeData - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (TGArrayNodeData.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in TGArrayNodeData is not found in the empty JSON string", TGArrayNodeData.openapiRequiredFields.toString())); - } - } - // validate the optional field `ranges` - if (jsonObj.get("ranges") != null && !jsonObj.get("ranges").isJsonNull()) { - TGQueryRanges.validateJsonObject(jsonObj.getAsJsonObject("ranges")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!TGArrayNodeData.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'TGArrayNodeData' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(TGArrayNodeData.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, TGArrayNodeData value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public TGArrayNodeData read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - TGArrayNodeData instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of TGArrayNodeData given an JSON string - * - * @param jsonString JSON string - * @return An instance of TGArrayNodeData - * @throws IOException if the JSON string is invalid with respect to TGArrayNodeData - */ - public static TGArrayNodeData fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, TGArrayNodeData.class); - } - - /** - * Convert an instance of TGArrayNodeData to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGInputNodeData.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGInputNodeData.java deleted file mode 100644 index 253f98d..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGInputNodeData.java +++ /dev/null @@ -1,307 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import org.openapitools.jackson.nullable.JsonNullable; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Specifies that a node is an “input value”, allowing for parameterized task graphs. An input node may not depend upon any other nodes. - */ -@ApiModel(description = "Specifies that a node is an “input value”, allowing for parameterized task graphs. An input node may not depend upon any other nodes. ") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class TGInputNodeData { - public static final String SERIALIZED_NAME_DEFAULT_VALUE = "default_value"; - @SerializedName(SERIALIZED_NAME_DEFAULT_VALUE) - private Object defaultValue; - - public static final String SERIALIZED_NAME_DATATYPE = "datatype"; - @SerializedName(SERIALIZED_NAME_DATATYPE) - private String datatype; - - public TGInputNodeData() { - } - - public TGInputNodeData defaultValue(Object defaultValue) { - - this.defaultValue = defaultValue; - return this; - } - - /** - * An argument provided to a node. This is one of a direct value (i.e., a raw JSON value) or a `TGSentinel`. For example this Python value: {\"a\": [1, \"pipe\", range(30), None], \"b\": b\"bytes\"} is encoded thusly (with included comments): { // A dictionary with string keys is JSON-encodable. \"a\": [ // As is a list. 1, \"pipe\", { // A `range` is replaced with its pickle. \"__tdbudf__\": \"immediate\", \"format\": \"python_pickle\", \"base64_data\": \"gASVIAAAAAAAAACMCGJ1aWx0aW5zlIwFcmFuZ2WUk5RLAEseSwGHlFKULg==\" }, null ], \"b\": { // Raw binary data is encoded into base64. \"__tdbudf__\": \"immediate\" \"format\": \"bytes\", \"base64_data\": \"Ynl0ZXM=\" } } - * @return defaultValue - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "An argument provided to a node. This is one of a direct value (i.e., a raw JSON value) or a `TGSentinel`. For example this Python value: {\"a\": [1, \"pipe\", range(30), None], \"b\": b\"bytes\"} is encoded thusly (with included comments): { // A dictionary with string keys is JSON-encodable. \"a\": [ // As is a list. 1, \"pipe\", { // A `range` is replaced with its pickle. \"__tdbudf__\": \"immediate\", \"format\": \"python_pickle\", \"base64_data\": \"gASVIAAAAAAAAACMCGJ1aWx0aW5zlIwFcmFuZ2WUk5RLAEseSwGHlFKULg==\" }, null ], \"b\": { // Raw binary data is encoded into base64. \"__tdbudf__\": \"immediate\" \"format\": \"bytes\", \"base64_data\": \"Ynl0ZXM=\" } } ") - - public Object getDefaultValue() { - return defaultValue; - } - - - public void setDefaultValue(Object defaultValue) { - this.defaultValue = defaultValue; - } - - - public TGInputNodeData datatype(String datatype) { - - this.datatype = datatype; - return this; - } - - /** - * An annotation of what datatype this node is supposed to be. Conventionally, this is a Python-format type annotation, but it’s purely for documentation purposes and not validated. - * @return datatype - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "An annotation of what datatype this node is supposed to be. Conventionally, this is a Python-format type annotation, but it’s purely for documentation purposes and not validated. ") - - public String getDatatype() { - return datatype; - } - - - public void setDatatype(String datatype) { - this.datatype = datatype; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public TGInputNodeData putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - TGInputNodeData tgInputNodeData = (TGInputNodeData) o; - return Objects.equals(this.defaultValue, tgInputNodeData.defaultValue) && - Objects.equals(this.datatype, tgInputNodeData.datatype)&& - Objects.equals(this.additionalProperties, tgInputNodeData.additionalProperties); - } - - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); - } - - @Override - public int hashCode() { - return Objects.hash(defaultValue, datatype, additionalProperties); - } - - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class TGInputNodeData {\n"); - sb.append(" defaultValue: ").append(toIndentedString(defaultValue)).append("\n"); - sb.append(" datatype: ").append(toIndentedString(datatype)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("default_value"); - openapiFields.add("datatype"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to TGInputNodeData - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (TGInputNodeData.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in TGInputNodeData is not found in the empty JSON string", TGInputNodeData.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("datatype") != null && !jsonObj.get("datatype").isJsonNull()) && !jsonObj.get("datatype").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `datatype` to be a primitive type in the JSON string but got `%s`", jsonObj.get("datatype").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!TGInputNodeData.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'TGInputNodeData' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(TGInputNodeData.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, TGInputNodeData value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public TGInputNodeData read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - TGInputNodeData instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of TGInputNodeData given an JSON string - * - * @param jsonString JSON string - * @return An instance of TGInputNodeData - * @throws IOException if the JSON string is invalid with respect to TGInputNodeData - */ - public static TGInputNodeData fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, TGInputNodeData.class); - } - - /** - * Convert an instance of TGInputNodeData to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGQueryRanges.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGQueryRanges.java deleted file mode 100644 index 008d80f..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGQueryRanges.java +++ /dev/null @@ -1,322 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Parameterizable version of `QueryRanges`. - */ -@ApiModel(description = "Parameterizable version of `QueryRanges`.") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class TGQueryRanges { - public static final String SERIALIZED_NAME_LAYOUT = "layout"; - @SerializedName(SERIALIZED_NAME_LAYOUT) - private Layout layout; - - public static final String SERIALIZED_NAME_FRIENDLY_RANGES = "friendly_ranges"; - @SerializedName(SERIALIZED_NAME_FRIENDLY_RANGES) - private Object friendlyRanges; - - public static final String SERIALIZED_NAME_RANGES = "ranges"; - @SerializedName(SERIALIZED_NAME_RANGES) - private Object ranges; - - public TGQueryRanges() { - } - - public TGQueryRanges layout(Layout layout) { - - this.layout = layout; - return this; - } - - /** - * Get layout - * @return layout - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Layout getLayout() { - return layout; - } - - - public void setLayout(Layout layout) { - this.layout = layout; - } - - - public TGQueryRanges friendlyRanges(Object friendlyRanges) { - - this.friendlyRanges = friendlyRanges; - return this; - } - - /** - * An argument provided to a node. This is one of a direct value (i.e., a raw JSON value) or a `TGSentinel`. For example this Python value: {\"a\": [1, \"pipe\", range(30), None], \"b\": b\"bytes\"} is encoded thusly (with included comments): { // A dictionary with string keys is JSON-encodable. \"a\": [ // As is a list. 1, \"pipe\", { // A `range` is replaced with its pickle. \"__tdbudf__\": \"immediate\", \"format\": \"python_pickle\", \"base64_data\": \"gASVIAAAAAAAAACMCGJ1aWx0aW5zlIwFcmFuZ2WUk5RLAEseSwGHlFKULg==\" }, null ], \"b\": { // Raw binary data is encoded into base64. \"__tdbudf__\": \"immediate\" \"format\": \"bytes\", \"base64_data\": \"Ynl0ZXM=\" } } - * @return friendlyRanges - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "An argument provided to a node. This is one of a direct value (i.e., a raw JSON value) or a `TGSentinel`. For example this Python value: {\"a\": [1, \"pipe\", range(30), None], \"b\": b\"bytes\"} is encoded thusly (with included comments): { // A dictionary with string keys is JSON-encodable. \"a\": [ // As is a list. 1, \"pipe\", { // A `range` is replaced with its pickle. \"__tdbudf__\": \"immediate\", \"format\": \"python_pickle\", \"base64_data\": \"gASVIAAAAAAAAACMCGJ1aWx0aW5zlIwFcmFuZ2WUk5RLAEseSwGHlFKULg==\" }, null ], \"b\": { // Raw binary data is encoded into base64. \"__tdbudf__\": \"immediate\" \"format\": \"bytes\", \"base64_data\": \"Ynl0ZXM=\" } } ") - - public Object getFriendlyRanges() { - return friendlyRanges; - } - - - public void setFriendlyRanges(Object friendlyRanges) { - this.friendlyRanges = friendlyRanges; - } - - - public TGQueryRanges ranges(Object ranges) { - - this.ranges = ranges; - return this; - } - - /** - * An argument provided to a node. This is one of a direct value (i.e., a raw JSON value) or a `TGSentinel`. For example this Python value: {\"a\": [1, \"pipe\", range(30), None], \"b\": b\"bytes\"} is encoded thusly (with included comments): { // A dictionary with string keys is JSON-encodable. \"a\": [ // As is a list. 1, \"pipe\", { // A `range` is replaced with its pickle. \"__tdbudf__\": \"immediate\", \"format\": \"python_pickle\", \"base64_data\": \"gASVIAAAAAAAAACMCGJ1aWx0aW5zlIwFcmFuZ2WUk5RLAEseSwGHlFKULg==\" }, null ], \"b\": { // Raw binary data is encoded into base64. \"__tdbudf__\": \"immediate\" \"format\": \"bytes\", \"base64_data\": \"Ynl0ZXM=\" } } - * @return ranges - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "An argument provided to a node. This is one of a direct value (i.e., a raw JSON value) or a `TGSentinel`. For example this Python value: {\"a\": [1, \"pipe\", range(30), None], \"b\": b\"bytes\"} is encoded thusly (with included comments): { // A dictionary with string keys is JSON-encodable. \"a\": [ // As is a list. 1, \"pipe\", { // A `range` is replaced with its pickle. \"__tdbudf__\": \"immediate\", \"format\": \"python_pickle\", \"base64_data\": \"gASVIAAAAAAAAACMCGJ1aWx0aW5zlIwFcmFuZ2WUk5RLAEseSwGHlFKULg==\" }, null ], \"b\": { // Raw binary data is encoded into base64. \"__tdbudf__\": \"immediate\" \"format\": \"bytes\", \"base64_data\": \"Ynl0ZXM=\" } } ") - - public Object getRanges() { - return ranges; - } - - - public void setRanges(Object ranges) { - this.ranges = ranges; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public TGQueryRanges putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - TGQueryRanges tgQueryRanges = (TGQueryRanges) o; - return Objects.equals(this.layout, tgQueryRanges.layout) && - Objects.equals(this.friendlyRanges, tgQueryRanges.friendlyRanges) && - Objects.equals(this.ranges, tgQueryRanges.ranges)&& - Objects.equals(this.additionalProperties, tgQueryRanges.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(layout, friendlyRanges, ranges, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class TGQueryRanges {\n"); - sb.append(" layout: ").append(toIndentedString(layout)).append("\n"); - sb.append(" friendlyRanges: ").append(toIndentedString(friendlyRanges)).append("\n"); - sb.append(" ranges: ").append(toIndentedString(ranges)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("layout"); - openapiFields.add("friendly_ranges"); - openapiFields.add("ranges"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to TGQueryRanges - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (TGQueryRanges.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in TGQueryRanges is not found in the empty JSON string", TGQueryRanges.openapiRequiredFields.toString())); - } - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!TGQueryRanges.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'TGQueryRanges' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(TGQueryRanges.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, TGQueryRanges value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public TGQueryRanges read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - TGQueryRanges instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of TGQueryRanges given an JSON string - * - * @param jsonString JSON string - * @return An instance of TGQueryRanges - * @throws IOException if the JSON string is invalid with respect to TGQueryRanges - */ - public static TGQueryRanges fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, TGQueryRanges.class); - } - - /** - * Convert an instance of TGQueryRanges to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGSQLNodeData.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGSQLNodeData.java deleted file mode 100644 index 6d2d3bd..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGSQLNodeData.java +++ /dev/null @@ -1,427 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import org.openapitools.jackson.nullable.JsonNullable; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * A node specifying an SQL query to execute in TileDB Cloud. - */ -@ApiModel(description = "A node specifying an SQL query to execute in TileDB Cloud. ") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class TGSQLNodeData { - public static final String SERIALIZED_NAME_INIT_COMMANDS = "init_commands"; - @SerializedName(SERIALIZED_NAME_INIT_COMMANDS) - private List initCommands = null; - - public static final String SERIALIZED_NAME_QUERY = "query"; - @SerializedName(SERIALIZED_NAME_QUERY) - private String query; - - public static final String SERIALIZED_NAME_PARAMETERS = "parameters"; - @SerializedName(SERIALIZED_NAME_PARAMETERS) - private List parameters = null; - - public static final String SERIALIZED_NAME_RESULT_FORMAT = "result_format"; - @SerializedName(SERIALIZED_NAME_RESULT_FORMAT) - private ResultFormat resultFormat; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public TGSQLNodeData() { - } - - public TGSQLNodeData initCommands(List initCommands) { - - this.initCommands = initCommands; - return this; - } - - public TGSQLNodeData addInitCommandsItem(String initCommandsItem) { - if (this.initCommands == null) { - this.initCommands = new ArrayList<>(); - } - this.initCommands.add(initCommandsItem); - return this; - } - - /** - * The commands to execute before running the query itself. - * @return initCommands - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The commands to execute before running the query itself.") - - public List getInitCommands() { - return initCommands; - } - - - public void setInitCommands(List initCommands) { - this.initCommands = initCommands; - } - - - public TGSQLNodeData query(String query) { - - this.query = query; - return this; - } - - /** - * The text of the SQL query to execute. Parameters are substituted in for `?`s, just as in a regular MariaDB query. - * @return query - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The text of the SQL query to execute. Parameters are substituted in for `?`s, just as in a regular MariaDB query. ") - - public String getQuery() { - return query; - } - - - public void setQuery(String query) { - this.query = query; - } - - - public TGSQLNodeData parameters(List parameters) { - - this.parameters = parameters; - return this; - } - - public TGSQLNodeData addParametersItem(Object parametersItem) { - if (this.parameters == null) { - this.parameters = new ArrayList<>(); - } - this.parameters.add(parametersItem); - return this; - } - - /** - * The parameters to substitute in for arguments in the `query`. Fixed-length. Arguments must be in JSON format. - * @return parameters - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The parameters to substitute in for arguments in the `query`. Fixed-length. Arguments must be in JSON format. ") - - public List getParameters() { - return parameters; - } - - - public void setParameters(List parameters) { - this.parameters = parameters; - } - - - public TGSQLNodeData resultFormat(ResultFormat resultFormat) { - - this.resultFormat = resultFormat; - return this; - } - - /** - * Get resultFormat - * @return resultFormat - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public ResultFormat getResultFormat() { - return resultFormat; - } - - - public void setResultFormat(ResultFormat resultFormat) { - this.resultFormat = resultFormat; - } - - - public TGSQLNodeData namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * If set, the non-default namespace to execute this SQL query under. - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "If set, the non-default namespace to execute this SQL query under. ") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public TGSQLNodeData putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - TGSQLNodeData tgSQLNodeData = (TGSQLNodeData) o; - return Objects.equals(this.initCommands, tgSQLNodeData.initCommands) && - Objects.equals(this.query, tgSQLNodeData.query) && - Objects.equals(this.parameters, tgSQLNodeData.parameters) && - Objects.equals(this.resultFormat, tgSQLNodeData.resultFormat) && - Objects.equals(this.namespace, tgSQLNodeData.namespace)&& - Objects.equals(this.additionalProperties, tgSQLNodeData.additionalProperties); - } - - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); - } - - @Override - public int hashCode() { - return Objects.hash(initCommands, query, parameters, resultFormat, namespace, additionalProperties); - } - - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class TGSQLNodeData {\n"); - sb.append(" initCommands: ").append(toIndentedString(initCommands)).append("\n"); - sb.append(" query: ").append(toIndentedString(query)).append("\n"); - sb.append(" parameters: ").append(toIndentedString(parameters)).append("\n"); - sb.append(" resultFormat: ").append(toIndentedString(resultFormat)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("init_commands"); - openapiFields.add("query"); - openapiFields.add("parameters"); - openapiFields.add("result_format"); - openapiFields.add("namespace"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to TGSQLNodeData - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (TGSQLNodeData.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in TGSQLNodeData is not found in the empty JSON string", TGSQLNodeData.openapiRequiredFields.toString())); - } - } - // ensure the json data is an array - if ((jsonObj.get("init_commands") != null && !jsonObj.get("init_commands").isJsonNull()) && !jsonObj.get("init_commands").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `init_commands` to be an array in the JSON string but got `%s`", jsonObj.get("init_commands").toString())); - } - if ((jsonObj.get("query") != null && !jsonObj.get("query").isJsonNull()) && !jsonObj.get("query").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `query` to be a primitive type in the JSON string but got `%s`", jsonObj.get("query").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("parameters") != null && !jsonObj.get("parameters").isJsonNull()) && !jsonObj.get("parameters").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `parameters` to be an array in the JSON string but got `%s`", jsonObj.get("parameters").toString())); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!TGSQLNodeData.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'TGSQLNodeData' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(TGSQLNodeData.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, TGSQLNodeData value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public TGSQLNodeData read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - TGSQLNodeData instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of TGSQLNodeData given an JSON string - * - * @param jsonString JSON string - * @return An instance of TGSQLNodeData - * @throws IOException if the JSON string is invalid with respect to TGSQLNodeData - */ - public static TGSQLNodeData fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, TGSQLNodeData.class); - } - - /** - * Convert an instance of TGSQLNodeData to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGUDFArgument.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGUDFArgument.java deleted file mode 100644 index f582cbf..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGUDFArgument.java +++ /dev/null @@ -1,307 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import org.openapitools.jackson.nullable.JsonNullable; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * A single argument to a UDF. This may represent a positional argument or a named argument, depending upon whether `name` is set. - */ -@ApiModel(description = "A single argument to a UDF. This may represent a positional argument or a named argument, depending upon whether `name` is set. ") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class TGUDFArgument { - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_VALUE = "value"; - @SerializedName(SERIALIZED_NAME_VALUE) - private Object value; - - public TGUDFArgument() { - } - - public TGUDFArgument name(String name) { - - this.name = name; - return this; - } - - /** - * The name of the argument, if present. - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The name of the argument, if present.") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public TGUDFArgument value(Object value) { - - this.value = value; - return this; - } - - /** - * An argument provided to a node. This is one of a direct value (i.e., a raw JSON value) or a `TGSentinel`. For example this Python value: {\"a\": [1, \"pipe\", range(30), None], \"b\": b\"bytes\"} is encoded thusly (with included comments): { // A dictionary with string keys is JSON-encodable. \"a\": [ // As is a list. 1, \"pipe\", { // A `range` is replaced with its pickle. \"__tdbudf__\": \"immediate\", \"format\": \"python_pickle\", \"base64_data\": \"gASVIAAAAAAAAACMCGJ1aWx0aW5zlIwFcmFuZ2WUk5RLAEseSwGHlFKULg==\" }, null ], \"b\": { // Raw binary data is encoded into base64. \"__tdbudf__\": \"immediate\" \"format\": \"bytes\", \"base64_data\": \"Ynl0ZXM=\" } } - * @return value - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "An argument provided to a node. This is one of a direct value (i.e., a raw JSON value) or a `TGSentinel`. For example this Python value: {\"a\": [1, \"pipe\", range(30), None], \"b\": b\"bytes\"} is encoded thusly (with included comments): { // A dictionary with string keys is JSON-encodable. \"a\": [ // As is a list. 1, \"pipe\", { // A `range` is replaced with its pickle. \"__tdbudf__\": \"immediate\", \"format\": \"python_pickle\", \"base64_data\": \"gASVIAAAAAAAAACMCGJ1aWx0aW5zlIwFcmFuZ2WUk5RLAEseSwGHlFKULg==\" }, null ], \"b\": { // Raw binary data is encoded into base64. \"__tdbudf__\": \"immediate\" \"format\": \"bytes\", \"base64_data\": \"Ynl0ZXM=\" } } ") - - public Object getValue() { - return value; - } - - - public void setValue(Object value) { - this.value = value; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public TGUDFArgument putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - TGUDFArgument tgUDFArgument = (TGUDFArgument) o; - return Objects.equals(this.name, tgUDFArgument.name) && - Objects.equals(this.value, tgUDFArgument.value)&& - Objects.equals(this.additionalProperties, tgUDFArgument.additionalProperties); - } - - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); - } - - @Override - public int hashCode() { - return Objects.hash(name, value, additionalProperties); - } - - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class TGUDFArgument {\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" value: ").append(toIndentedString(value)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("name"); - openapiFields.add("value"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to TGUDFArgument - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (TGUDFArgument.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in TGUDFArgument is not found in the empty JSON string", TGUDFArgument.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!TGUDFArgument.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'TGUDFArgument' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(TGUDFArgument.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, TGUDFArgument value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public TGUDFArgument read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - TGUDFArgument instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of TGUDFArgument given an JSON string - * - * @param jsonString JSON string - * @return An instance of TGUDFArgument - * @throws IOException if the JSON string is invalid with respect to TGUDFArgument - */ - public static TGUDFArgument fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, TGUDFArgument.class); - } - - /** - * Convert an instance of TGUDFArgument to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGUDFEnvironment.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGUDFEnvironment.java deleted file mode 100644 index 74fe8fb..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGUDFEnvironment.java +++ /dev/null @@ -1,535 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.math.BigDecimal; - -import org.openapitools.jackson.nullable.JsonNullable; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Metadata about the environment where we want to execute a UDF. - */ -@ApiModel(description = "Metadata about the environment where we want to execute a UDF.") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class TGUDFEnvironment { - public static final String SERIALIZED_NAME_LANGUAGE = "language"; - @SerializedName(SERIALIZED_NAME_LANGUAGE) - private UDFLanguage language; - - public static final String SERIALIZED_NAME_LANGUAGE_VERSION = "language_version"; - @SerializedName(SERIALIZED_NAME_LANGUAGE_VERSION) - private String languageVersion; - - public static final String SERIALIZED_NAME_IMAGE_NAME = "image_name"; - @SerializedName(SERIALIZED_NAME_IMAGE_NAME) - private String imageName; - - public static final String SERIALIZED_NAME_ACCESS_CREDENTIALS_NAME = "access_credentials_name"; - @SerializedName(SERIALIZED_NAME_ACCESS_CREDENTIALS_NAME) - private String accessCredentialsName; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public static final String SERIALIZED_NAME_RESOURCE_CLASS = "resource_class"; - @SerializedName(SERIALIZED_NAME_RESOURCE_CLASS) - private String resourceClass; - - public static final String SERIALIZED_NAME_RESOURCES = "resources"; - @SerializedName(SERIALIZED_NAME_RESOURCES) - private TGUDFEnvironmentResources resources; - - public static final String SERIALIZED_NAME_RUN_CLIENT_SIDE = "run_client_side"; - @SerializedName(SERIALIZED_NAME_RUN_CLIENT_SIDE) - private Boolean runClientSide; - - public static final String SERIALIZED_NAME_TIMEOUT = "timeout"; - @SerializedName(SERIALIZED_NAME_TIMEOUT) - private BigDecimal timeout; - - public TGUDFEnvironment() { - } - - public TGUDFEnvironment language(UDFLanguage language) { - - this.language = language; - return this; - } - - /** - * Get language - * @return language - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public UDFLanguage getLanguage() { - return language; - } - - - public void setLanguage(UDFLanguage language) { - this.language = language; - } - - - public TGUDFEnvironment languageVersion(String languageVersion) { - - this.languageVersion = languageVersion; - return this; - } - - /** - * The language version used to execute this UDF. Neither this nor `language` needs to be set for registered UDFs, since the language and version are stored server-side with the UDF itself. - * @return languageVersion - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The language version used to execute this UDF. Neither this nor `language` needs to be set for registered UDFs, since the language and version are stored server-side with the UDF itself. ") - - public String getLanguageVersion() { - return languageVersion; - } - - - public void setLanguageVersion(String languageVersion) { - this.languageVersion = languageVersion; - } - - - public TGUDFEnvironment imageName(String imageName) { - - this.imageName = imageName; - return this; - } - - /** - * The name of the image to use for the execution environment. - * @return imageName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The name of the image to use for the execution environment. ") - - public String getImageName() { - return imageName; - } - - - public void setImageName(String imageName) { - this.imageName = imageName; - } - - - public TGUDFEnvironment accessCredentialsName(String accessCredentialsName) { - - this.accessCredentialsName = accessCredentialsName; - return this; - } - - /** - * The name of the access credentials to use. if unset, no credentials will be configured in the environment. - * @return accessCredentialsName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The name of the access credentials to use. if unset, no credentials will be configured in the environment. ") - - public String getAccessCredentialsName() { - return accessCredentialsName; - } - - - public void setAccessCredentialsName(String accessCredentialsName) { - this.accessCredentialsName = accessCredentialsName; - } - - - public TGUDFEnvironment namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * If set, the non-default namespace to execute this UDF under (and to query any Array Nodes that are used as inputs to this UDF). - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "If set, the non-default namespace to execute this UDF under (and to query any Array Nodes that are used as inputs to this UDF). ") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - - public TGUDFEnvironment resourceClass(String resourceClass) { - - this.resourceClass = resourceClass; - return this; - } - - /** - * The resource class to use for the UDF execution. Resource classes define resource limits for memory and CPUs. If this is empty, then the UDF will execute in the standard resource class of the TileDB Cloud provider. - * @return resourceClass - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The resource class to use for the UDF execution. Resource classes define resource limits for memory and CPUs. If this is empty, then the UDF will execute in the standard resource class of the TileDB Cloud provider. ") - - public String getResourceClass() { - return resourceClass; - } - - - public void setResourceClass(String resourceClass) { - this.resourceClass = resourceClass; - } - - - public TGUDFEnvironment resources(TGUDFEnvironmentResources resources) { - - this.resources = resources; - return this; - } - - /** - * Get resources - * @return resources - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public TGUDFEnvironmentResources getResources() { - return resources; - } - - - public void setResources(TGUDFEnvironmentResources resources) { - this.resources = resources; - } - - - public TGUDFEnvironment runClientSide(Boolean runClientSide) { - - this.runClientSide = runClientSide; - return this; - } - - /** - * A hint that, if possible, this function should be executed on the client side rather than on the server. Registered UDFs and functions which take arrays as inputs can never be executed client-side. If the client’s environment is incompatible, or the client does not support client-side execution, the function will be executed on the server. - * @return runClientSide - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "A hint that, if possible, this function should be executed on the client side rather than on the server. Registered UDFs and functions which take arrays as inputs can never be executed client-side. If the client’s environment is incompatible, or the client does not support client-side execution, the function will be executed on the server. ") - - public Boolean getRunClientSide() { - return runClientSide; - } - - - public void setRunClientSide(Boolean runClientSide) { - this.runClientSide = runClientSide; - } - - - public TGUDFEnvironment timeout(BigDecimal timeout) { - - this.timeout = timeout; - return this; - } - - /** - * The maximum length of time this UDF is allowed to execute for before it is killed and fails. If not present (or zero), the function is allowed to run indefinitely (subject to the server’s global limits). - * @return timeout - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The maximum length of time this UDF is allowed to execute for before it is killed and fails. If not present (or zero), the function is allowed to run indefinitely (subject to the server’s global limits). ") - - public BigDecimal getTimeout() { - return timeout; - } - - - public void setTimeout(BigDecimal timeout) { - this.timeout = timeout; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public TGUDFEnvironment putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - TGUDFEnvironment tgUDFEnvironment = (TGUDFEnvironment) o; - return Objects.equals(this.language, tgUDFEnvironment.language) && - Objects.equals(this.languageVersion, tgUDFEnvironment.languageVersion) && - Objects.equals(this.imageName, tgUDFEnvironment.imageName) && - Objects.equals(this.accessCredentialsName, tgUDFEnvironment.accessCredentialsName) && - Objects.equals(this.namespace, tgUDFEnvironment.namespace) && - Objects.equals(this.resourceClass, tgUDFEnvironment.resourceClass) && - Objects.equals(this.resources, tgUDFEnvironment.resources) && - Objects.equals(this.runClientSide, tgUDFEnvironment.runClientSide) && - Objects.equals(this.timeout, tgUDFEnvironment.timeout)&& - Objects.equals(this.additionalProperties, tgUDFEnvironment.additionalProperties); - } - - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); - } - - @Override - public int hashCode() { - return Objects.hash(language, languageVersion, imageName, accessCredentialsName, namespace, resourceClass, resources, runClientSide, timeout, additionalProperties); - } - - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class TGUDFEnvironment {\n"); - sb.append(" language: ").append(toIndentedString(language)).append("\n"); - sb.append(" languageVersion: ").append(toIndentedString(languageVersion)).append("\n"); - sb.append(" imageName: ").append(toIndentedString(imageName)).append("\n"); - sb.append(" accessCredentialsName: ").append(toIndentedString(accessCredentialsName)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" resourceClass: ").append(toIndentedString(resourceClass)).append("\n"); - sb.append(" resources: ").append(toIndentedString(resources)).append("\n"); - sb.append(" runClientSide: ").append(toIndentedString(runClientSide)).append("\n"); - sb.append(" timeout: ").append(toIndentedString(timeout)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("language"); - openapiFields.add("language_version"); - openapiFields.add("image_name"); - openapiFields.add("access_credentials_name"); - openapiFields.add("namespace"); - openapiFields.add("resource_class"); - openapiFields.add("resources"); - openapiFields.add("run_client_side"); - openapiFields.add("timeout"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to TGUDFEnvironment - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (TGUDFEnvironment.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in TGUDFEnvironment is not found in the empty JSON string", TGUDFEnvironment.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("language_version") != null && !jsonObj.get("language_version").isJsonNull()) && !jsonObj.get("language_version").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `language_version` to be a primitive type in the JSON string but got `%s`", jsonObj.get("language_version").toString())); - } - if ((jsonObj.get("image_name") != null && !jsonObj.get("image_name").isJsonNull()) && !jsonObj.get("image_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `image_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("image_name").toString())); - } - if ((jsonObj.get("access_credentials_name") != null && !jsonObj.get("access_credentials_name").isJsonNull()) && !jsonObj.get("access_credentials_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `access_credentials_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("access_credentials_name").toString())); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - if ((jsonObj.get("resource_class") != null && !jsonObj.get("resource_class").isJsonNull()) && !jsonObj.get("resource_class").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `resource_class` to be a primitive type in the JSON string but got `%s`", jsonObj.get("resource_class").toString())); - } - // validate the optional field `resources` - if (jsonObj.get("resources") != null && !jsonObj.get("resources").isJsonNull()) { - TGUDFEnvironmentResources.validateJsonObject(jsonObj.getAsJsonObject("resources")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!TGUDFEnvironment.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'TGUDFEnvironment' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(TGUDFEnvironment.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, TGUDFEnvironment value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public TGUDFEnvironment read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - TGUDFEnvironment instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of TGUDFEnvironment given an JSON string - * - * @param jsonString JSON string - * @return An instance of TGUDFEnvironment - * @throws IOException if the JSON string is invalid with respect to TGUDFEnvironment - */ - public static TGUDFEnvironment fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, TGUDFEnvironment.class); - } - - /** - * Convert an instance of TGUDFEnvironment to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGUDFEnvironmentResources.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGUDFEnvironmentResources.java deleted file mode 100644 index e140ad4..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGUDFEnvironmentResources.java +++ /dev/null @@ -1,328 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * The resources requested for this particular node. If resources are not specified resource_class is used, if it is not set the standard resource // defaults are used - */ -@ApiModel(description = "The resources requested for this particular node. If resources are not specified resource_class is used, if it is not set the standard resource // defaults are used ") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class TGUDFEnvironmentResources { - public static final String SERIALIZED_NAME_CPU = "cpu"; - @SerializedName(SERIALIZED_NAME_CPU) - private String cpu; - - public static final String SERIALIZED_NAME_MEMORY = "memory"; - @SerializedName(SERIALIZED_NAME_MEMORY) - private String memory; - - public static final String SERIALIZED_NAME_GPU = "gpu"; - @SerializedName(SERIALIZED_NAME_GPU) - private Integer gpu; - - public TGUDFEnvironmentResources() { - } - - public TGUDFEnvironmentResources cpu(String cpu) { - - this.cpu = cpu; - return this; - } - - /** - * Get cpu - * @return cpu - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "500m", value = "") - - public String getCpu() { - return cpu; - } - - - public void setCpu(String cpu) { - this.cpu = cpu; - } - - - public TGUDFEnvironmentResources memory(String memory) { - - this.memory = memory; - return this; - } - - /** - * Get memory - * @return memory - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "8Gi", value = "") - - public String getMemory() { - return memory; - } - - - public void setMemory(String memory) { - this.memory = memory; - } - - - public TGUDFEnvironmentResources gpu(Integer gpu) { - - this.gpu = gpu; - return this; - } - - /** - * Get gpu - * @return gpu - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "1", value = "") - - public Integer getGpu() { - return gpu; - } - - - public void setGpu(Integer gpu) { - this.gpu = gpu; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public TGUDFEnvironmentResources putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - TGUDFEnvironmentResources tgUDFEnvironmentResources = (TGUDFEnvironmentResources) o; - return Objects.equals(this.cpu, tgUDFEnvironmentResources.cpu) && - Objects.equals(this.memory, tgUDFEnvironmentResources.memory) && - Objects.equals(this.gpu, tgUDFEnvironmentResources.gpu)&& - Objects.equals(this.additionalProperties, tgUDFEnvironmentResources.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(cpu, memory, gpu, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class TGUDFEnvironmentResources {\n"); - sb.append(" cpu: ").append(toIndentedString(cpu)).append("\n"); - sb.append(" memory: ").append(toIndentedString(memory)).append("\n"); - sb.append(" gpu: ").append(toIndentedString(gpu)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("cpu"); - openapiFields.add("memory"); - openapiFields.add("gpu"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to TGUDFEnvironmentResources - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (TGUDFEnvironmentResources.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in TGUDFEnvironmentResources is not found in the empty JSON string", TGUDFEnvironmentResources.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("cpu") != null && !jsonObj.get("cpu").isJsonNull()) && !jsonObj.get("cpu").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `cpu` to be a primitive type in the JSON string but got `%s`", jsonObj.get("cpu").toString())); - } - if ((jsonObj.get("memory") != null && !jsonObj.get("memory").isJsonNull()) && !jsonObj.get("memory").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `memory` to be a primitive type in the JSON string but got `%s`", jsonObj.get("memory").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!TGUDFEnvironmentResources.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'TGUDFEnvironmentResources' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(TGUDFEnvironmentResources.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, TGUDFEnvironmentResources value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public TGUDFEnvironmentResources read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - TGUDFEnvironmentResources instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of TGUDFEnvironmentResources given an JSON string - * - * @param jsonString JSON string - * @return An instance of TGUDFEnvironmentResources - * @throws IOException if the JSON string is invalid with respect to TGUDFEnvironmentResources - */ - public static TGUDFEnvironmentResources fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, TGUDFEnvironmentResources.class); - } - - /** - * Convert an instance of TGUDFEnvironmentResources to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGUDFNodeData.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGUDFNodeData.java deleted file mode 100644 index 62fac3e..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TGUDFNodeData.java +++ /dev/null @@ -1,461 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import org.openapitools.jackson.nullable.JsonNullable; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * A node specifying the execution of a user-defined function. - */ -@ApiModel(description = "A node specifying the execution of a user-defined function.") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class TGUDFNodeData { - public static final String SERIALIZED_NAME_REGISTERED_UDF_NAME = "registered_udf_name"; - @SerializedName(SERIALIZED_NAME_REGISTERED_UDF_NAME) - private String registeredUdfName; - - public static final String SERIALIZED_NAME_EXECUTABLE_CODE = "executable_code"; - @SerializedName(SERIALIZED_NAME_EXECUTABLE_CODE) - private String executableCode; - - public static final String SERIALIZED_NAME_SOURCE_TEXT = "source_text"; - @SerializedName(SERIALIZED_NAME_SOURCE_TEXT) - private String sourceText; - - public static final String SERIALIZED_NAME_ENVIRONMENT = "environment"; - @SerializedName(SERIALIZED_NAME_ENVIRONMENT) - private TGUDFEnvironment environment; - - public static final String SERIALIZED_NAME_ARGUMENTS = "arguments"; - @SerializedName(SERIALIZED_NAME_ARGUMENTS) - private List arguments = null; - - public static final String SERIALIZED_NAME_RESULT_FORMAT = "result_format"; - @SerializedName(SERIALIZED_NAME_RESULT_FORMAT) - private ResultFormat resultFormat; - - public TGUDFNodeData() { - } - - public TGUDFNodeData registeredUdfName(String registeredUdfName) { - - this.registeredUdfName = registeredUdfName; - return this; - } - - /** - * If set, the name of the registered UDF to execute, in the format `namespace/name`. Either this or `executable_code` should be set, but not both. - * @return registeredUdfName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "If set, the name of the registered UDF to execute, in the format `namespace/name`. Either this or `executable_code` should be set, but not both. ") - - public String getRegisteredUdfName() { - return registeredUdfName; - } - - - public void setRegisteredUdfName(String registeredUdfName) { - this.registeredUdfName = registeredUdfName; - } - - - public TGUDFNodeData executableCode(String executableCode) { - - this.executableCode = executableCode; - return this; - } - - /** - * If set, the base64 serialization of the code for this step, encoded in a language-specific format (e.g. Pickle for Python, serialization for R). - * @return executableCode - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "If set, the base64 serialization of the code for this step, encoded in a language-specific format (e.g. Pickle for Python, serialization for R). ") - - public String getExecutableCode() { - return executableCode; - } - - - public void setExecutableCode(String executableCode) { - this.executableCode = executableCode; - } - - - public TGUDFNodeData sourceText(String sourceText) { - - this.sourceText = sourceText; - return this; - } - - /** - * Optionally, the source text for the code passed in `executable_code`. *For reference only; only the code in `executable_code` is actually executed.* This will be included in activity logs and may be useful for debugging. - * @return sourceText - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Optionally, the source text for the code passed in `executable_code`. *For reference only; only the code in `executable_code` is actually executed.* This will be included in activity logs and may be useful for debugging. ") - - public String getSourceText() { - return sourceText; - } - - - public void setSourceText(String sourceText) { - this.sourceText = sourceText; - } - - - public TGUDFNodeData environment(TGUDFEnvironment environment) { - - this.environment = environment; - return this; - } - - /** - * Get environment - * @return environment - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public TGUDFEnvironment getEnvironment() { - return environment; - } - - - public void setEnvironment(TGUDFEnvironment environment) { - this.environment = environment; - } - - - public TGUDFNodeData arguments(List arguments) { - - this.arguments = arguments; - return this; - } - - public TGUDFNodeData addArgumentsItem(TGUDFArgument argumentsItem) { - if (this.arguments == null) { - this.arguments = new ArrayList<>(); - } - this.arguments.add(argumentsItem); - return this; - } - - /** - * The arguments to a UDF function. This encompasses both named and positional arguments. The format is designed to provide compatibility across languages like Python which have a fairly traditional split between positional arguments and named arguments, and languages like R which has a rather unique way of specifying arguments. For Python (and most other languages), all positional arguments will come before all named arguments (if any are present): // fn(arg1, arg2, arg3) [ {value: arg1}, {value: arg2}, {value: arg3}, ] // fn(arg1, arg2, n=kw1, a=kw2) [ {value: arg1}, {value: arg2}, {name: \"n\", value: kw1}, {name: \"a\", value: kw2}, ] // fn(kw=k1, only=k2) [ {name: \"kw\", value: k1}, {name: \"only\", value: k2}, ] However, in R, named and positional arguments may be intermixed freely: // fn(arg, n=kw1, arg2) [ {value: arg}, {name: \"n\", value: kw1}, {value: arg2}, ] - * @return arguments - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The arguments to a UDF function. This encompasses both named and positional arguments. The format is designed to provide compatibility across languages like Python which have a fairly traditional split between positional arguments and named arguments, and languages like R which has a rather unique way of specifying arguments. For Python (and most other languages), all positional arguments will come before all named arguments (if any are present): // fn(arg1, arg2, arg3) [ {value: arg1}, {value: arg2}, {value: arg3}, ] // fn(arg1, arg2, n=kw1, a=kw2) [ {value: arg1}, {value: arg2}, {name: \"n\", value: kw1}, {name: \"a\", value: kw2}, ] // fn(kw=k1, only=k2) [ {name: \"kw\", value: k1}, {name: \"only\", value: k2}, ] However, in R, named and positional arguments may be intermixed freely: // fn(arg, n=kw1, arg2) [ {value: arg}, {name: \"n\", value: kw1}, {value: arg2}, ] ") - - public List getArguments() { - return arguments; - } - - - public void setArguments(List arguments) { - this.arguments = arguments; - } - - - public TGUDFNodeData resultFormat(ResultFormat resultFormat) { - - this.resultFormat = resultFormat; - return this; - } - - /** - * Get resultFormat - * @return resultFormat - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public ResultFormat getResultFormat() { - return resultFormat; - } - - - public void setResultFormat(ResultFormat resultFormat) { - this.resultFormat = resultFormat; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public TGUDFNodeData putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - TGUDFNodeData tgUDFNodeData = (TGUDFNodeData) o; - return Objects.equals(this.registeredUdfName, tgUDFNodeData.registeredUdfName) && - Objects.equals(this.executableCode, tgUDFNodeData.executableCode) && - Objects.equals(this.sourceText, tgUDFNodeData.sourceText) && - Objects.equals(this.environment, tgUDFNodeData.environment) && - Objects.equals(this.arguments, tgUDFNodeData.arguments) && - Objects.equals(this.resultFormat, tgUDFNodeData.resultFormat)&& - Objects.equals(this.additionalProperties, tgUDFNodeData.additionalProperties); - } - - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); - } - - @Override - public int hashCode() { - return Objects.hash(registeredUdfName, executableCode, sourceText, environment, arguments, resultFormat, additionalProperties); - } - - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class TGUDFNodeData {\n"); - sb.append(" registeredUdfName: ").append(toIndentedString(registeredUdfName)).append("\n"); - sb.append(" executableCode: ").append(toIndentedString(executableCode)).append("\n"); - sb.append(" sourceText: ").append(toIndentedString(sourceText)).append("\n"); - sb.append(" environment: ").append(toIndentedString(environment)).append("\n"); - sb.append(" arguments: ").append(toIndentedString(arguments)).append("\n"); - sb.append(" resultFormat: ").append(toIndentedString(resultFormat)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("registered_udf_name"); - openapiFields.add("executable_code"); - openapiFields.add("source_text"); - openapiFields.add("environment"); - openapiFields.add("arguments"); - openapiFields.add("result_format"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to TGUDFNodeData - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (TGUDFNodeData.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in TGUDFNodeData is not found in the empty JSON string", TGUDFNodeData.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("registered_udf_name") != null && !jsonObj.get("registered_udf_name").isJsonNull()) && !jsonObj.get("registered_udf_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `registered_udf_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("registered_udf_name").toString())); - } - if ((jsonObj.get("executable_code") != null && !jsonObj.get("executable_code").isJsonNull()) && !jsonObj.get("executable_code").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `executable_code` to be a primitive type in the JSON string but got `%s`", jsonObj.get("executable_code").toString())); - } - if ((jsonObj.get("source_text") != null && !jsonObj.get("source_text").isJsonNull()) && !jsonObj.get("source_text").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `source_text` to be a primitive type in the JSON string but got `%s`", jsonObj.get("source_text").toString())); - } - // validate the optional field `environment` - if (jsonObj.get("environment") != null && !jsonObj.get("environment").isJsonNull()) { - TGUDFEnvironment.validateJsonObject(jsonObj.getAsJsonObject("environment")); - } - JsonArray jsonArrayarguments = jsonObj.getAsJsonArray("arguments"); - if (jsonArrayarguments != null) { - // ensure the json data is an array - if (!jsonObj.get("arguments").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `arguments` to be an array in the JSON string but got `%s`", jsonObj.get("arguments").toString())); - } - - // validate the optional field `arguments` (array) - for (int i = 0; i < jsonArrayarguments.size(); i++) { - TGUDFArgument.validateJsonObject(jsonArrayarguments.get(i).getAsJsonObject()); - }; - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!TGUDFNodeData.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'TGUDFNodeData' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(TGUDFNodeData.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, TGUDFNodeData value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public TGUDFNodeData read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - TGUDFNodeData instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of TGUDFNodeData given an JSON string - * - * @param jsonString JSON string - * @return An instance of TGUDFNodeData - * @throws IOException if the JSON string is invalid with respect to TGUDFNodeData - */ - public static TGUDFNodeData fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, TGUDFNodeData.class); - } - - /** - * Convert an instance of TGUDFNodeData to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraph.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraph.java deleted file mode 100644 index ea3e8aa..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraph.java +++ /dev/null @@ -1,570 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.time.OffsetDateTime; -import java.util.ArrayList; -import java.util.List; - -import org.openapitools.jackson.nullable.JsonNullable; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Information about a task graph. - */ -@ApiModel(description = "Information about a task graph.") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class TaskGraph { - public static final String SERIALIZED_NAME_UUID = "uuid"; - @SerializedName(SERIALIZED_NAME_UUID) - private String uuid; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public static final String SERIALIZED_NAME_CREATED_BY = "created_by"; - @SerializedName(SERIALIZED_NAME_CREATED_BY) - private String createdBy; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_CREATED_AT = "created_at"; - @SerializedName(SERIALIZED_NAME_CREATED_AT) - private OffsetDateTime createdAt; - - public static final String SERIALIZED_NAME_NODES = "nodes"; - @SerializedName(SERIALIZED_NAME_NODES) - private List nodes = null; - - public static final String SERIALIZED_NAME_PARALLELISM = "parallelism"; - @SerializedName(SERIALIZED_NAME_PARALLELISM) - private Long parallelism; - - public static final String SERIALIZED_NAME_RETRY_STRATEGY = "retry_strategy"; - @SerializedName(SERIALIZED_NAME_RETRY_STRATEGY) - private RetryStrategy retryStrategy; - - public static final String SERIALIZED_NAME_DEADLINE = "deadline"; - @SerializedName(SERIALIZED_NAME_DEADLINE) - private Long deadline; - - public static final String SERIALIZED_NAME_TASK_GRAPH_TYPE = "task_graph_type"; - @SerializedName(SERIALIZED_NAME_TASK_GRAPH_TYPE) - private TaskGraphType taskGraphType; - - public TaskGraph() { - } - - - public TaskGraph( - String uuid, - String createdBy, - OffsetDateTime createdAt - ) { - this(); - this.uuid = uuid; - this.createdBy = createdBy; - this.createdAt = createdAt; - } - - /** - * The server-generated UUID of the task graph. - * @return uuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The server-generated UUID of the task graph.") - - public String getUuid() { - return uuid; - } - - - - - public TaskGraph namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * The namespace that owns this task graph. When creating a task graph log, this is used as the namespace to create the log in; thereafter it is read-only. - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The namespace that owns this task graph. When creating a task graph log, this is used as the namespace to create the log in; thereafter it is read-only. ") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - - /** - * The name of the user who created this task graph log. - * @return createdBy - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The name of the user who created this task graph log.") - - public String getCreatedBy() { - return createdBy; - } - - - - - public TaskGraph name(String name) { - - this.name = name; - return this; - } - - /** - * A name for this task graph, displayed in the UI. Does not need to be unique. - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "A name for this task graph, displayed in the UI. Does not need to be unique. ") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - /** - * The date/time when this task graph was originally created. - * @return createdAt - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The date/time when this task graph was originally created. ") - - public OffsetDateTime getCreatedAt() { - return createdAt; - } - - - - - public TaskGraph nodes(List nodes) { - - this.nodes = nodes; - return this; - } - - public TaskGraph addNodesItem(TaskGraphNode nodesItem) { - if (this.nodes == null) { - this.nodes = new ArrayList<>(); - } - this.nodes.add(nodesItem); - return this; - } - - /** - * The structure of the graph. This is provided by the client when first setting up the task graph. This must be topographically sorted; that is, each node must appear after all nodes that it depends upon. - * @return nodes - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The structure of the graph. This is provided by the client when first setting up the task graph. This must be topographically sorted; that is, each node must appear after all nodes that it depends upon. ") - - public List getNodes() { - return nodes; - } - - - public void setNodes(List nodes) { - this.nodes = nodes; - } - - - public TaskGraph parallelism(Long parallelism) { - - this.parallelism = parallelism; - return this; - } - - /** - * Parallelism limits the max total parallel pods that can execute at the same time in a workflow. - * @return parallelism - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Parallelism limits the max total parallel pods that can execute at the same time in a workflow. ") - - public Long getParallelism() { - return parallelism; - } - - - public void setParallelism(Long parallelism) { - this.parallelism = parallelism; - } - - - public TaskGraph retryStrategy(RetryStrategy retryStrategy) { - - this.retryStrategy = retryStrategy; - return this; - } - - /** - * Get retryStrategy - * @return retryStrategy - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public RetryStrategy getRetryStrategy() { - return retryStrategy; - } - - - public void setRetryStrategy(RetryStrategy retryStrategy) { - this.retryStrategy = retryStrategy; - } - - - public TaskGraph deadline(Long deadline) { - - this.deadline = deadline; - return this; - } - - /** - * Duration in seconds relative to the workflow start time which the workflow is allowed to run before it gets terminated. - * @return deadline - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Duration in seconds relative to the workflow start time which the workflow is allowed to run before it gets terminated. ") - - public Long getDeadline() { - return deadline; - } - - - public void setDeadline(Long deadline) { - this.deadline = deadline; - } - - - public TaskGraph taskGraphType(TaskGraphType taskGraphType) { - - this.taskGraphType = taskGraphType; - return this; - } - - /** - * Get taskGraphType - * @return taskGraphType - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public TaskGraphType getTaskGraphType() { - return taskGraphType; - } - - - public void setTaskGraphType(TaskGraphType taskGraphType) { - this.taskGraphType = taskGraphType; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public TaskGraph putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - TaskGraph taskGraph = (TaskGraph) o; - return Objects.equals(this.uuid, taskGraph.uuid) && - Objects.equals(this.namespace, taskGraph.namespace) && - Objects.equals(this.createdBy, taskGraph.createdBy) && - Objects.equals(this.name, taskGraph.name) && - Objects.equals(this.createdAt, taskGraph.createdAt) && - Objects.equals(this.nodes, taskGraph.nodes) && - Objects.equals(this.parallelism, taskGraph.parallelism) && - Objects.equals(this.retryStrategy, taskGraph.retryStrategy) && - Objects.equals(this.deadline, taskGraph.deadline) && - Objects.equals(this.taskGraphType, taskGraph.taskGraphType)&& - Objects.equals(this.additionalProperties, taskGraph.additionalProperties); - } - - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); - } - - @Override - public int hashCode() { - return Objects.hash(uuid, namespace, createdBy, name, createdAt, nodes, parallelism, retryStrategy, deadline, taskGraphType, additionalProperties); - } - - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class TaskGraph {\n"); - sb.append(" uuid: ").append(toIndentedString(uuid)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" createdBy: ").append(toIndentedString(createdBy)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); - sb.append(" nodes: ").append(toIndentedString(nodes)).append("\n"); - sb.append(" parallelism: ").append(toIndentedString(parallelism)).append("\n"); - sb.append(" retryStrategy: ").append(toIndentedString(retryStrategy)).append("\n"); - sb.append(" deadline: ").append(toIndentedString(deadline)).append("\n"); - sb.append(" taskGraphType: ").append(toIndentedString(taskGraphType)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("uuid"); - openapiFields.add("namespace"); - openapiFields.add("created_by"); - openapiFields.add("name"); - openapiFields.add("created_at"); - openapiFields.add("nodes"); - openapiFields.add("parallelism"); - openapiFields.add("retry_strategy"); - openapiFields.add("deadline"); - openapiFields.add("task_graph_type"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to TaskGraph - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (TaskGraph.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in TaskGraph is not found in the empty JSON string", TaskGraph.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("uuid") != null && !jsonObj.get("uuid").isJsonNull()) && !jsonObj.get("uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("uuid").toString())); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - if ((jsonObj.get("created_by") != null && !jsonObj.get("created_by").isJsonNull()) && !jsonObj.get("created_by").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `created_by` to be a primitive type in the JSON string but got `%s`", jsonObj.get("created_by").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - JsonArray jsonArraynodes = jsonObj.getAsJsonArray("nodes"); - if (jsonArraynodes != null) { - // ensure the json data is an array - if (!jsonObj.get("nodes").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `nodes` to be an array in the JSON string but got `%s`", jsonObj.get("nodes").toString())); - } - - // validate the optional field `nodes` (array) - for (int i = 0; i < jsonArraynodes.size(); i++) { - TaskGraphNode.validateJsonObject(jsonArraynodes.get(i).getAsJsonObject()); - }; - } - // validate the optional field `retry_strategy` - if (jsonObj.get("retry_strategy") != null && !jsonObj.get("retry_strategy").isJsonNull()) { - RetryStrategy.validateJsonObject(jsonObj.getAsJsonObject("retry_strategy")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!TaskGraph.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'TaskGraph' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(TaskGraph.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, TaskGraph value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public TaskGraph read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - TaskGraph instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of TaskGraph given an JSON string - * - * @param jsonString JSON string - * @return An instance of TaskGraph - * @throws IOException if the JSON string is invalid with respect to TaskGraph - */ - public static TaskGraph fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, TaskGraph.class); - } - - /** - * Convert an instance of TaskGraph to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphActions.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphActions.java deleted file mode 100644 index 77c3753..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphActions.java +++ /dev/null @@ -1,69 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * actions a user can take on a UDF - */ -@JsonAdapter(TaskGraphActions.Adapter.class) -public enum TaskGraphActions { - - FETCH_TASK_GRAPH("fetch_task_graph"), - - SHARE_TASK_GRAPH("share_task_graph"); - - private String value; - - TaskGraphActions(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static TaskGraphActions fromValue(String value) { - for (TaskGraphActions b : TaskGraphActions.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final TaskGraphActions enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public TaskGraphActions read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return TaskGraphActions.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphClientNodeStatus.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphClientNodeStatus.java deleted file mode 100644 index 7803981..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphClientNodeStatus.java +++ /dev/null @@ -1,295 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * A report of the execution status of a node that ran on the client side. - */ -@ApiModel(description = "A report of the execution status of a node that ran on the client side. ") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class TaskGraphClientNodeStatus { - public static final String SERIALIZED_NAME_CLIENT_NODE_UUID = "client_node_uuid"; - @SerializedName(SERIALIZED_NAME_CLIENT_NODE_UUID) - private String clientNodeUuid; - - public static final String SERIALIZED_NAME_STATUS = "status"; - @SerializedName(SERIALIZED_NAME_STATUS) - private ArrayTaskStatus status; - - public TaskGraphClientNodeStatus() { - } - - public TaskGraphClientNodeStatus clientNodeUuid(String clientNodeUuid) { - - this.clientNodeUuid = clientNodeUuid; - return this; - } - - /** - * Get clientNodeUuid - * @return clientNodeUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public String getClientNodeUuid() { - return clientNodeUuid; - } - - - public void setClientNodeUuid(String clientNodeUuid) { - this.clientNodeUuid = clientNodeUuid; - } - - - public TaskGraphClientNodeStatus status(ArrayTaskStatus status) { - - this.status = status; - return this; - } - - /** - * Get status - * @return status - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public ArrayTaskStatus getStatus() { - return status; - } - - - public void setStatus(ArrayTaskStatus status) { - this.status = status; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public TaskGraphClientNodeStatus putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - TaskGraphClientNodeStatus taskGraphClientNodeStatus = (TaskGraphClientNodeStatus) o; - return Objects.equals(this.clientNodeUuid, taskGraphClientNodeStatus.clientNodeUuid) && - Objects.equals(this.status, taskGraphClientNodeStatus.status)&& - Objects.equals(this.additionalProperties, taskGraphClientNodeStatus.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(clientNodeUuid, status, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class TaskGraphClientNodeStatus {\n"); - sb.append(" clientNodeUuid: ").append(toIndentedString(clientNodeUuid)).append("\n"); - sb.append(" status: ").append(toIndentedString(status)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("client_node_uuid"); - openapiFields.add("status"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to TaskGraphClientNodeStatus - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (TaskGraphClientNodeStatus.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in TaskGraphClientNodeStatus is not found in the empty JSON string", TaskGraphClientNodeStatus.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("client_node_uuid") != null && !jsonObj.get("client_node_uuid").isJsonNull()) && !jsonObj.get("client_node_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `client_node_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("client_node_uuid").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!TaskGraphClientNodeStatus.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'TaskGraphClientNodeStatus' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(TaskGraphClientNodeStatus.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, TaskGraphClientNodeStatus value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public TaskGraphClientNodeStatus read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - TaskGraphClientNodeStatus instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of TaskGraphClientNodeStatus given an JSON string - * - * @param jsonString JSON string - * @return An instance of TaskGraphClientNodeStatus - * @throws IOException if the JSON string is invalid with respect to TaskGraphClientNodeStatus - */ - public static TaskGraphClientNodeStatus fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, TaskGraphClientNodeStatus.class); - } - - /** - * Convert an instance of TaskGraphClientNodeStatus to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphLog.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphLog.java deleted file mode 100644 index d0f2dc6..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphLog.java +++ /dev/null @@ -1,747 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.math.BigDecimal; -import java.time.OffsetDateTime; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import org.openapitools.jackson.nullable.JsonNullable; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashSet; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Logging information about the execution of a task graph. - */ -@ApiModel(description = "Logging information about the execution of a task graph.") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class TaskGraphLog { - public static final String SERIALIZED_NAME_UUID = "uuid"; - @SerializedName(SERIALIZED_NAME_UUID) - private String uuid; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public static final String SERIALIZED_NAME_CREATED_BY = "created_by"; - @SerializedName(SERIALIZED_NAME_CREATED_BY) - private String createdBy; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_CREATED_AT = "created_at"; - @SerializedName(SERIALIZED_NAME_CREATED_AT) - private OffsetDateTime createdAt; - - public static final String SERIALIZED_NAME_START_TIME = "start_time"; - @SerializedName(SERIALIZED_NAME_START_TIME) - private OffsetDateTime startTime; - - public static final String SERIALIZED_NAME_END_TIME = "end_time"; - @SerializedName(SERIALIZED_NAME_END_TIME) - private OffsetDateTime endTime; - - public static final String SERIALIZED_NAME_STATUS = "status"; - @SerializedName(SERIALIZED_NAME_STATUS) - private TaskGraphLogStatus status; - - public static final String SERIALIZED_NAME_TOTAL_COST = "total_cost"; - @SerializedName(SERIALIZED_NAME_TOTAL_COST) - private BigDecimal totalCost; - - public static final String SERIALIZED_NAME_ACCESS_COST = "access_cost"; - @SerializedName(SERIALIZED_NAME_ACCESS_COST) - private BigDecimal accessCost; - - public static final String SERIALIZED_NAME_EGRESS_COST = "egress_cost"; - @SerializedName(SERIALIZED_NAME_EGRESS_COST) - private BigDecimal egressCost; - - public static final String SERIALIZED_NAME_EXECUTION_TIME = "execution_time"; - @SerializedName(SERIALIZED_NAME_EXECUTION_TIME) - private String executionTime; - - public static final String SERIALIZED_NAME_STATUS_COUNT = "status_count"; - @SerializedName(SERIALIZED_NAME_STATUS_COUNT) - private Map statusCount = null; - - public static final String SERIALIZED_NAME_NODES = "nodes"; - @SerializedName(SERIALIZED_NAME_NODES) - private List nodes = null; - - public static final String SERIALIZED_NAME_TASK_GRAPH_TYPE = "task_graph_type"; - @SerializedName(SERIALIZED_NAME_TASK_GRAPH_TYPE) - private TaskGraphType taskGraphType; - - public static final String SERIALIZED_NAME_TASK_GRAPH_ID = "task_graph_id"; - @SerializedName(SERIALIZED_NAME_TASK_GRAPH_ID) - private String taskGraphId; - - public TaskGraphLog() { - } - - - public TaskGraphLog( - String uuid, - String createdBy, - OffsetDateTime createdAt, - OffsetDateTime startTime, - OffsetDateTime endTime - ) { - this(); - this.uuid = uuid; - this.createdBy = createdBy; - this.createdAt = createdAt; - this.startTime = startTime; - this.endTime = endTime; - } - - /** - * The server-generated UUID of the task graph. - * @return uuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The server-generated UUID of the task graph.") - - public String getUuid() { - return uuid; - } - - - - - public TaskGraphLog namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * The namespace that owns this task graph log. When creating a task graph log, this is used as the namespace to create the log in; thereafter it is read-only. - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The namespace that owns this task graph log. When creating a task graph log, this is used as the namespace to create the log in; thereafter it is read-only. ") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - - /** - * The name of the user who created this task graph log. - * @return createdBy - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The name of the user who created this task graph log.") - - public String getCreatedBy() { - return createdBy; - } - - - - - public TaskGraphLog name(String name) { - - this.name = name; - return this; - } - - /** - * A name for this task graph log, displayed in the UI. Does not need to be unique. - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "A name for this task graph log, displayed in the UI. Does not need to be unique. ") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - /** - * The date/time when this task graph log was originally created. This is distinct from the execution start_time. - * @return createdAt - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The date/time when this task graph log was originally created. This is distinct from the execution start_time. ") - - public OffsetDateTime getCreatedAt() { - return createdAt; - } - - - - - /** - * The start time of the task graph, recorded when the server starts executing the first node. - * @return startTime - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The start time of the task graph, recorded when the server starts executing the first node. ") - - public OffsetDateTime getStartTime() { - return startTime; - } - - - - - /** - * The end time of the task graph, recorded when the client reports completion. - * @return endTime - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The end time of the task graph, recorded when the client reports completion. ") - - public OffsetDateTime getEndTime() { - return endTime; - } - - - - - public TaskGraphLog status(TaskGraphLogStatus status) { - - this.status = status; - return this; - } - - /** - * Get status - * @return status - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public TaskGraphLogStatus getStatus() { - return status; - } - - - public void setStatus(TaskGraphLogStatus status) { - this.status = status; - } - - - public TaskGraphLog totalCost(BigDecimal totalCost) { - - this.totalCost = totalCost; - return this; - } - - /** - * If present, the total cost of executing all nodes in this task graph. - * @return totalCost - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "If present, the total cost of executing all nodes in this task graph. ") - - public BigDecimal getTotalCost() { - return totalCost; - } - - - public void setTotalCost(BigDecimal totalCost) { - this.totalCost = totalCost; - } - - - public TaskGraphLog accessCost(BigDecimal accessCost) { - - this.accessCost = accessCost; - return this; - } - - /** - * If present, the total cost of access from execution of the nodes in this task graph. - * @return accessCost - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "If present, the total cost of access from execution of the nodes in this task graph. ") - - public BigDecimal getAccessCost() { - return accessCost; - } - - - public void setAccessCost(BigDecimal accessCost) { - this.accessCost = accessCost; - } - - - public TaskGraphLog egressCost(BigDecimal egressCost) { - - this.egressCost = egressCost; - return this; - } - - /** - * If present, the total cost of access from execution of the nodes in this task graph. - * @return egressCost - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "If present, the total cost of access from execution of the nodes in this task graph. ") - - public BigDecimal getEgressCost() { - return egressCost; - } - - - public void setEgressCost(BigDecimal egressCost) { - this.egressCost = egressCost; - } - - - public TaskGraphLog executionTime(String executionTime) { - - this.executionTime = executionTime; - return this; - } - - /** - * The total execution time of all the nodes in this graph, in ISO 8601 format with hours, minutes, and seconds. - * @return executionTime - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "P15H22M0.45S", value = "The total execution time of all the nodes in this graph, in ISO 8601 format with hours, minutes, and seconds. ") - - public String getExecutionTime() { - return executionTime; - } - - - public void setExecutionTime(String executionTime) { - this.executionTime = executionTime; - } - - - public TaskGraphLog statusCount(Map statusCount) { - - this.statusCount = statusCount; - return this; - } - - public TaskGraphLog putStatusCountItem(String key, BigDecimal statusCountItem) { - if (this.statusCount == null) { - this.statusCount = new HashMap<>(); - } - this.statusCount.put(key, statusCountItem); - return this; - } - - /** - * A mapping from `ArrayTaskStatus` string value to the number of nodes in this graph that are in that status. - * @return statusCount - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "A mapping from `ArrayTaskStatus` string value to the number of nodes in this graph that are in that status. ") - - public Map getStatusCount() { - return statusCount; - } - - - public void setStatusCount(Map statusCount) { - this.statusCount = statusCount; - } - - - public TaskGraphLog nodes(List nodes) { - - this.nodes = nodes; - return this; - } - - public TaskGraphLog addNodesItem(TaskGraphNodeMetadata nodesItem) { - if (this.nodes == null) { - this.nodes = new ArrayList<>(); - } - this.nodes.add(nodesItem); - return this; - } - - /** - * The structure of the graph. This is provided by the client when first setting up the task graph. Thereafter, it is read-only. This must be topographically sorted; that is, each node must appear after all nodes that it depends upon. - * @return nodes - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The structure of the graph. This is provided by the client when first setting up the task graph. Thereafter, it is read-only. This must be topographically sorted; that is, each node must appear after all nodes that it depends upon. ") - - public List getNodes() { - return nodes; - } - - - public void setNodes(List nodes) { - this.nodes = nodes; - } - - - public TaskGraphLog taskGraphType(TaskGraphType taskGraphType) { - - this.taskGraphType = taskGraphType; - return this; - } - - /** - * Get taskGraphType - * @return taskGraphType - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public TaskGraphType getTaskGraphType() { - return taskGraphType; - } - - - public void setTaskGraphType(TaskGraphType taskGraphType) { - this.taskGraphType = taskGraphType; - } - - - public TaskGraphLog taskGraphId(String taskGraphId) { - - this.taskGraphId = taskGraphId; - return this; - } - - /** - * The UUID of the task graph. - * @return taskGraphId - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The UUID of the task graph.") - - public String getTaskGraphId() { - return taskGraphId; - } - - - public void setTaskGraphId(String taskGraphId) { - this.taskGraphId = taskGraphId; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public TaskGraphLog putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - TaskGraphLog taskGraphLog = (TaskGraphLog) o; - return Objects.equals(this.uuid, taskGraphLog.uuid) && - Objects.equals(this.namespace, taskGraphLog.namespace) && - Objects.equals(this.createdBy, taskGraphLog.createdBy) && - Objects.equals(this.name, taskGraphLog.name) && - Objects.equals(this.createdAt, taskGraphLog.createdAt) && - Objects.equals(this.startTime, taskGraphLog.startTime) && - Objects.equals(this.endTime, taskGraphLog.endTime) && - Objects.equals(this.status, taskGraphLog.status) && - Objects.equals(this.totalCost, taskGraphLog.totalCost) && - Objects.equals(this.accessCost, taskGraphLog.accessCost) && - Objects.equals(this.egressCost, taskGraphLog.egressCost) && - Objects.equals(this.executionTime, taskGraphLog.executionTime) && - Objects.equals(this.statusCount, taskGraphLog.statusCount) && - Objects.equals(this.nodes, taskGraphLog.nodes) && - Objects.equals(this.taskGraphType, taskGraphLog.taskGraphType) && - Objects.equals(this.taskGraphId, taskGraphLog.taskGraphId)&& - Objects.equals(this.additionalProperties, taskGraphLog.additionalProperties); - } - - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); - } - - @Override - public int hashCode() { - return Objects.hash(uuid, namespace, createdBy, name, createdAt, startTime, endTime, status, totalCost, accessCost, egressCost, executionTime, statusCount, nodes, taskGraphType, taskGraphId, additionalProperties); - } - - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class TaskGraphLog {\n"); - sb.append(" uuid: ").append(toIndentedString(uuid)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" createdBy: ").append(toIndentedString(createdBy)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); - sb.append(" startTime: ").append(toIndentedString(startTime)).append("\n"); - sb.append(" endTime: ").append(toIndentedString(endTime)).append("\n"); - sb.append(" status: ").append(toIndentedString(status)).append("\n"); - sb.append(" totalCost: ").append(toIndentedString(totalCost)).append("\n"); - sb.append(" accessCost: ").append(toIndentedString(accessCost)).append("\n"); - sb.append(" egressCost: ").append(toIndentedString(egressCost)).append("\n"); - sb.append(" executionTime: ").append(toIndentedString(executionTime)).append("\n"); - sb.append(" statusCount: ").append(toIndentedString(statusCount)).append("\n"); - sb.append(" nodes: ").append(toIndentedString(nodes)).append("\n"); - sb.append(" taskGraphType: ").append(toIndentedString(taskGraphType)).append("\n"); - sb.append(" taskGraphId: ").append(toIndentedString(taskGraphId)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("uuid"); - openapiFields.add("namespace"); - openapiFields.add("created_by"); - openapiFields.add("name"); - openapiFields.add("created_at"); - openapiFields.add("start_time"); - openapiFields.add("end_time"); - openapiFields.add("status"); - openapiFields.add("total_cost"); - openapiFields.add("access_cost"); - openapiFields.add("egress_cost"); - openapiFields.add("execution_time"); - openapiFields.add("status_count"); - openapiFields.add("nodes"); - openapiFields.add("task_graph_type"); - openapiFields.add("task_graph_id"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to TaskGraphLog - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (TaskGraphLog.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in TaskGraphLog is not found in the empty JSON string", TaskGraphLog.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("uuid") != null && !jsonObj.get("uuid").isJsonNull()) && !jsonObj.get("uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("uuid").toString())); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - if ((jsonObj.get("created_by") != null && !jsonObj.get("created_by").isJsonNull()) && !jsonObj.get("created_by").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `created_by` to be a primitive type in the JSON string but got `%s`", jsonObj.get("created_by").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - if ((jsonObj.get("execution_time") != null && !jsonObj.get("execution_time").isJsonNull()) && !jsonObj.get("execution_time").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `execution_time` to be a primitive type in the JSON string but got `%s`", jsonObj.get("execution_time").toString())); - } - JsonArray jsonArraynodes = jsonObj.getAsJsonArray("nodes"); - if (jsonArraynodes != null) { - // ensure the json data is an array - if (!jsonObj.get("nodes").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `nodes` to be an array in the JSON string but got `%s`", jsonObj.get("nodes").toString())); - } - - // validate the optional field `nodes` (array) - for (int i = 0; i < jsonArraynodes.size(); i++) { - TaskGraphNodeMetadata.validateJsonObject(jsonArraynodes.get(i).getAsJsonObject()); - }; - } - if ((jsonObj.get("task_graph_id") != null && !jsonObj.get("task_graph_id").isJsonNull()) && !jsonObj.get("task_graph_id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `task_graph_id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("task_graph_id").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!TaskGraphLog.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'TaskGraphLog' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(TaskGraphLog.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, TaskGraphLog value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public TaskGraphLog read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - TaskGraphLog instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of TaskGraphLog given an JSON string - * - * @param jsonString JSON string - * @return An instance of TaskGraphLog - * @throws IOException if the JSON string is invalid with respect to TaskGraphLog - */ - public static TaskGraphLog fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, TaskGraphLog.class); - } - - /** - * Convert an instance of TaskGraphLog to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphLogRunLocation.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphLogRunLocation.java deleted file mode 100644 index d3a52bb..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphLogRunLocation.java +++ /dev/null @@ -1,71 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * The location where an individual node of a task graph is executed. - */ -@JsonAdapter(TaskGraphLogRunLocation.Adapter.class) -public enum TaskGraphLogRunLocation { - - SERVER("server"), - - CLIENT("client"), - - VIRTUAL("virtual"); - - private String value; - - TaskGraphLogRunLocation(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static TaskGraphLogRunLocation fromValue(String value) { - for (TaskGraphLogRunLocation b : TaskGraphLogRunLocation.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final TaskGraphLogRunLocation enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public TaskGraphLogRunLocation read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return TaskGraphLogRunLocation.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphLogStatus.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphLogStatus.java deleted file mode 100644 index 49307e6..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphLogStatus.java +++ /dev/null @@ -1,79 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * The status of a given task graph execution. - */ -@JsonAdapter(TaskGraphLogStatus.Adapter.class) -public enum TaskGraphLogStatus { - - SUBMITTED("submitted"), - - RUNNING("running"), - - IDLE("idle"), - - ABANDONED("abandoned"), - - SUCCEEDED("succeeded"), - - FAILED("failed"), - - CANCELLED("cancelled"); - - private String value; - - TaskGraphLogStatus(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static TaskGraphLogStatus fromValue(String value) { - for (TaskGraphLogStatus b : TaskGraphLogStatus.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final TaskGraphLogStatus enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public TaskGraphLogStatus read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return TaskGraphLogStatus.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphLogsData.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphLogsData.java deleted file mode 100644 index 6d191da..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphLogsData.java +++ /dev/null @@ -1,319 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Response data for a task graph list, including pagination metadata. - */ -@ApiModel(description = "Response data for a task graph list, including pagination metadata.") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class TaskGraphLogsData { - public static final String SERIALIZED_NAME_TASK_GRAPH_LOGS = "task_graph_logs"; - @SerializedName(SERIALIZED_NAME_TASK_GRAPH_LOGS) - private List taskGraphLogs = null; - - public static final String SERIALIZED_NAME_PAGINATION_METADATA = "pagination_metadata"; - @SerializedName(SERIALIZED_NAME_PAGINATION_METADATA) - private PaginationMetadata paginationMetadata; - - public TaskGraphLogsData() { - } - - public TaskGraphLogsData taskGraphLogs(List taskGraphLogs) { - - this.taskGraphLogs = taskGraphLogs; - return this; - } - - public TaskGraphLogsData addTaskGraphLogsItem(TaskGraphLog taskGraphLogsItem) { - if (this.taskGraphLogs == null) { - this.taskGraphLogs = new ArrayList<>(); - } - this.taskGraphLogs.add(taskGraphLogsItem); - return this; - } - - /** - * The requested task graph logs. - * @return taskGraphLogs - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The requested task graph logs.") - - public List getTaskGraphLogs() { - return taskGraphLogs; - } - - - public void setTaskGraphLogs(List taskGraphLogs) { - this.taskGraphLogs = taskGraphLogs; - } - - - public TaskGraphLogsData paginationMetadata(PaginationMetadata paginationMetadata) { - - this.paginationMetadata = paginationMetadata; - return this; - } - - /** - * Get paginationMetadata - * @return paginationMetadata - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public PaginationMetadata getPaginationMetadata() { - return paginationMetadata; - } - - - public void setPaginationMetadata(PaginationMetadata paginationMetadata) { - this.paginationMetadata = paginationMetadata; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public TaskGraphLogsData putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - TaskGraphLogsData taskGraphLogsData = (TaskGraphLogsData) o; - return Objects.equals(this.taskGraphLogs, taskGraphLogsData.taskGraphLogs) && - Objects.equals(this.paginationMetadata, taskGraphLogsData.paginationMetadata)&& - Objects.equals(this.additionalProperties, taskGraphLogsData.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(taskGraphLogs, paginationMetadata, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class TaskGraphLogsData {\n"); - sb.append(" taskGraphLogs: ").append(toIndentedString(taskGraphLogs)).append("\n"); - sb.append(" paginationMetadata: ").append(toIndentedString(paginationMetadata)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("task_graph_logs"); - openapiFields.add("pagination_metadata"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to TaskGraphLogsData - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (TaskGraphLogsData.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in TaskGraphLogsData is not found in the empty JSON string", TaskGraphLogsData.openapiRequiredFields.toString())); - } - } - JsonArray jsonArraytaskGraphLogs = jsonObj.getAsJsonArray("task_graph_logs"); - if (jsonArraytaskGraphLogs != null) { - // ensure the json data is an array - if (!jsonObj.get("task_graph_logs").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `task_graph_logs` to be an array in the JSON string but got `%s`", jsonObj.get("task_graph_logs").toString())); - } - - // validate the optional field `task_graph_logs` (array) - for (int i = 0; i < jsonArraytaskGraphLogs.size(); i++) { - TaskGraphLog.validateJsonObject(jsonArraytaskGraphLogs.get(i).getAsJsonObject()); - }; - } - // validate the optional field `pagination_metadata` - if (jsonObj.get("pagination_metadata") != null && !jsonObj.get("pagination_metadata").isJsonNull()) { - PaginationMetadata.validateJsonObject(jsonObj.getAsJsonObject("pagination_metadata")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!TaskGraphLogsData.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'TaskGraphLogsData' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(TaskGraphLogsData.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, TaskGraphLogsData value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public TaskGraphLogsData read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - TaskGraphLogsData instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of TaskGraphLogsData given an JSON string - * - * @param jsonString JSON string - * @return An instance of TaskGraphLogsData - * @throws IOException if the JSON string is invalid with respect to TaskGraphLogsData - */ - public static TaskGraphLogsData fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, TaskGraphLogsData.class); - } - - /** - * Convert an instance of TaskGraphLogsData to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphNode.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphNode.java deleted file mode 100644 index ba1584a..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphNode.java +++ /dev/null @@ -1,588 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import org.openapitools.jackson.nullable.JsonNullable; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Information about a single node within a registered task graph. A single node represents one piece of data or a computational step; either as an input value, a data source, or a computation that acts upon earlier nodes. The structure parallels the existing `TaskGraphNodeMetadata`. - */ -@ApiModel(description = "Information about a single node within a registered task graph. A single node represents one piece of data or a computational step; either as an input value, a data source, or a computation that acts upon earlier nodes. The structure parallels the existing `TaskGraphNodeMetadata`. ") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class TaskGraphNode { - public static final String SERIALIZED_NAME_CLIENT_NODE_ID = "client_node_id"; - @SerializedName(SERIALIZED_NAME_CLIENT_NODE_ID) - private String clientNodeId; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_DEPENDS_ON = "depends_on"; - @SerializedName(SERIALIZED_NAME_DEPENDS_ON) - private List dependsOn = null; - - public static final String SERIALIZED_NAME_ARRAY_NODE = "array_node"; - @SerializedName(SERIALIZED_NAME_ARRAY_NODE) - private UDFArrayDetails arrayNode; - - public static final String SERIALIZED_NAME_INPUT_NODE = "input_node"; - @SerializedName(SERIALIZED_NAME_INPUT_NODE) - private TGInputNodeData inputNode; - - public static final String SERIALIZED_NAME_SQL_NODE = "sql_node"; - @SerializedName(SERIALIZED_NAME_SQL_NODE) - private TGSQLNodeData sqlNode; - - public static final String SERIALIZED_NAME_UDF_NODE = "udf_node"; - @SerializedName(SERIALIZED_NAME_UDF_NODE) - private TGUDFNodeData udfNode; - - public static final String SERIALIZED_NAME_RETRY_STRATEGY = "retry_strategy"; - @SerializedName(SERIALIZED_NAME_RETRY_STRATEGY) - private RetryStrategy retryStrategy; - - public static final String SERIALIZED_NAME_EXPAND_NODE_OUTPUT = "expand_node_output"; - @SerializedName(SERIALIZED_NAME_EXPAND_NODE_OUTPUT) - private String expandNodeOutput; - - public static final String SERIALIZED_NAME_DEADLINE = "deadline"; - @SerializedName(SERIALIZED_NAME_DEADLINE) - private Long deadline; - - public TaskGraphNode() { - } - - public TaskGraphNode clientNodeId(String clientNodeId) { - - this.clientNodeId = clientNodeId; - return this; - } - - /** - * The client-generated UUID of the given graph node. - * @return clientNodeId - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The client-generated UUID of the given graph node.") - - public String getClientNodeId() { - return clientNodeId; - } - - - public void setClientNodeId(String clientNodeId) { - this.clientNodeId = clientNodeId; - } - - - public TaskGraphNode name(String name) { - - this.name = name; - return this; - } - - /** - * A client-specified name for the node. If provided, this must be unique. - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "A client-specified name for the node. If provided, this must be unique. ") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public TaskGraphNode dependsOn(List dependsOn) { - - this.dependsOn = dependsOn; - return this; - } - - public TaskGraphNode addDependsOnItem(String dependsOnItem) { - if (this.dependsOn == null) { - this.dependsOn = new ArrayList<>(); - } - this.dependsOn.add(dependsOnItem); - return this; - } - - /** - * The client_node_uuid of each node that this node depends upon. Used to define the structure of the graph. - * @return dependsOn - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The client_node_uuid of each node that this node depends upon. Used to define the structure of the graph. ") - - public List getDependsOn() { - return dependsOn; - } - - - public void setDependsOn(List dependsOn) { - this.dependsOn = dependsOn; - } - - - public TaskGraphNode arrayNode(UDFArrayDetails arrayNode) { - - this.arrayNode = arrayNode; - return this; - } - - /** - * Get arrayNode - * @return arrayNode - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public UDFArrayDetails getArrayNode() { - return arrayNode; - } - - - public void setArrayNode(UDFArrayDetails arrayNode) { - this.arrayNode = arrayNode; - } - - - public TaskGraphNode inputNode(TGInputNodeData inputNode) { - - this.inputNode = inputNode; - return this; - } - - /** - * Get inputNode - * @return inputNode - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public TGInputNodeData getInputNode() { - return inputNode; - } - - - public void setInputNode(TGInputNodeData inputNode) { - this.inputNode = inputNode; - } - - - public TaskGraphNode sqlNode(TGSQLNodeData sqlNode) { - - this.sqlNode = sqlNode; - return this; - } - - /** - * Get sqlNode - * @return sqlNode - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public TGSQLNodeData getSqlNode() { - return sqlNode; - } - - - public void setSqlNode(TGSQLNodeData sqlNode) { - this.sqlNode = sqlNode; - } - - - public TaskGraphNode udfNode(TGUDFNodeData udfNode) { - - this.udfNode = udfNode; - return this; - } - - /** - * Get udfNode - * @return udfNode - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public TGUDFNodeData getUdfNode() { - return udfNode; - } - - - public void setUdfNode(TGUDFNodeData udfNode) { - this.udfNode = udfNode; - } - - - public TaskGraphNode retryStrategy(RetryStrategy retryStrategy) { - - this.retryStrategy = retryStrategy; - return this; - } - - /** - * Get retryStrategy - * @return retryStrategy - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public RetryStrategy getRetryStrategy() { - return retryStrategy; - } - - - public void setRetryStrategy(RetryStrategy retryStrategy) { - this.retryStrategy = retryStrategy; - } - - - public TaskGraphNode expandNodeOutput(String expandNodeOutput) { - - this.expandNodeOutput = expandNodeOutput; - return this; - } - - /** - * Used to create dynamic tasks based on the output of another node. The other node's output must be a JSON list of values. The expansion process creates one task per item in the output list. The item is also passed as an argument to each task. The value is the client_node_uuid of the node that we want to expand. - * @return expandNodeOutput - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Used to create dynamic tasks based on the output of another node. The other node's output must be a JSON list of values. The expansion process creates one task per item in the output list. The item is also passed as an argument to each task. The value is the client_node_uuid of the node that we want to expand. ") - - public String getExpandNodeOutput() { - return expandNodeOutput; - } - - - public void setExpandNodeOutput(String expandNodeOutput) { - this.expandNodeOutput = expandNodeOutput; - } - - - public TaskGraphNode deadline(Long deadline) { - - this.deadline = deadline; - return this; - } - - /** - * Duration in seconds relative to the node start time which the node is allowed to run before it gets terminated. - * @return deadline - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Duration in seconds relative to the node start time which the node is allowed to run before it gets terminated. ") - - public Long getDeadline() { - return deadline; - } - - - public void setDeadline(Long deadline) { - this.deadline = deadline; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public TaskGraphNode putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - TaskGraphNode taskGraphNode = (TaskGraphNode) o; - return Objects.equals(this.clientNodeId, taskGraphNode.clientNodeId) && - Objects.equals(this.name, taskGraphNode.name) && - Objects.equals(this.dependsOn, taskGraphNode.dependsOn) && - Objects.equals(this.arrayNode, taskGraphNode.arrayNode) && - Objects.equals(this.inputNode, taskGraphNode.inputNode) && - Objects.equals(this.sqlNode, taskGraphNode.sqlNode) && - Objects.equals(this.udfNode, taskGraphNode.udfNode) && - Objects.equals(this.retryStrategy, taskGraphNode.retryStrategy) && - Objects.equals(this.expandNodeOutput, taskGraphNode.expandNodeOutput) && - Objects.equals(this.deadline, taskGraphNode.deadline)&& - Objects.equals(this.additionalProperties, taskGraphNode.additionalProperties); - } - - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); - } - - @Override - public int hashCode() { - return Objects.hash(clientNodeId, name, dependsOn, arrayNode, inputNode, sqlNode, udfNode, retryStrategy, expandNodeOutput, deadline, additionalProperties); - } - - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class TaskGraphNode {\n"); - sb.append(" clientNodeId: ").append(toIndentedString(clientNodeId)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" dependsOn: ").append(toIndentedString(dependsOn)).append("\n"); - sb.append(" arrayNode: ").append(toIndentedString(arrayNode)).append("\n"); - sb.append(" inputNode: ").append(toIndentedString(inputNode)).append("\n"); - sb.append(" sqlNode: ").append(toIndentedString(sqlNode)).append("\n"); - sb.append(" udfNode: ").append(toIndentedString(udfNode)).append("\n"); - sb.append(" retryStrategy: ").append(toIndentedString(retryStrategy)).append("\n"); - sb.append(" expandNodeOutput: ").append(toIndentedString(expandNodeOutput)).append("\n"); - sb.append(" deadline: ").append(toIndentedString(deadline)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("client_node_id"); - openapiFields.add("name"); - openapiFields.add("depends_on"); - openapiFields.add("array_node"); - openapiFields.add("input_node"); - openapiFields.add("sql_node"); - openapiFields.add("udf_node"); - openapiFields.add("retry_strategy"); - openapiFields.add("expand_node_output"); - openapiFields.add("deadline"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to TaskGraphNode - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (TaskGraphNode.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in TaskGraphNode is not found in the empty JSON string", TaskGraphNode.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("client_node_id") != null && !jsonObj.get("client_node_id").isJsonNull()) && !jsonObj.get("client_node_id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `client_node_id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("client_node_id").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("depends_on") != null && !jsonObj.get("depends_on").isJsonNull()) && !jsonObj.get("depends_on").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `depends_on` to be an array in the JSON string but got `%s`", jsonObj.get("depends_on").toString())); - } - // validate the optional field `array_node` - if (jsonObj.get("array_node") != null && !jsonObj.get("array_node").isJsonNull()) { - UDFArrayDetails.validateJsonObject(jsonObj.getAsJsonObject("array_node")); - } - // validate the optional field `input_node` - if (jsonObj.get("input_node") != null && !jsonObj.get("input_node").isJsonNull()) { - TGInputNodeData.validateJsonObject(jsonObj.getAsJsonObject("input_node")); - } - // validate the optional field `sql_node` - if (jsonObj.get("sql_node") != null && !jsonObj.get("sql_node").isJsonNull()) { - TGSQLNodeData.validateJsonObject(jsonObj.getAsJsonObject("sql_node")); - } - // validate the optional field `udf_node` - if (jsonObj.get("udf_node") != null && !jsonObj.get("udf_node").isJsonNull()) { - TGUDFNodeData.validateJsonObject(jsonObj.getAsJsonObject("udf_node")); - } - // validate the optional field `retry_strategy` - if (jsonObj.get("retry_strategy") != null && !jsonObj.get("retry_strategy").isJsonNull()) { - RetryStrategy.validateJsonObject(jsonObj.getAsJsonObject("retry_strategy")); - } - if ((jsonObj.get("expand_node_output") != null && !jsonObj.get("expand_node_output").isJsonNull()) && !jsonObj.get("expand_node_output").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `expand_node_output` to be a primitive type in the JSON string but got `%s`", jsonObj.get("expand_node_output").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!TaskGraphNode.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'TaskGraphNode' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(TaskGraphNode.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, TaskGraphNode value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public TaskGraphNode read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - TaskGraphNode instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of TaskGraphNode given an JSON string - * - * @param jsonString JSON string - * @return An instance of TaskGraphNode - * @throws IOException if the JSON string is invalid with respect to TaskGraphNode - */ - public static TaskGraphNode fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, TaskGraphNode.class); - } - - /** - * Convert an instance of TaskGraphNode to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphNodeMetadata.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphNodeMetadata.java deleted file mode 100644 index 8afb209..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphNodeMetadata.java +++ /dev/null @@ -1,490 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import org.openapitools.jackson.nullable.JsonNullable; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Metadata about an individual node in a task graph. - */ -@ApiModel(description = "Metadata about an individual node in a task graph.") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class TaskGraphNodeMetadata { - public static final String SERIALIZED_NAME_CLIENT_NODE_UUID = "client_node_uuid"; - @SerializedName(SERIALIZED_NAME_CLIENT_NODE_UUID) - private String clientNodeUuid; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_DEPENDS_ON = "depends_on"; - @SerializedName(SERIALIZED_NAME_DEPENDS_ON) - private List dependsOn = null; - - public static final String SERIALIZED_NAME_RUN_LOCATION = "run_location"; - @SerializedName(SERIALIZED_NAME_RUN_LOCATION) - private TaskGraphLogRunLocation runLocation; - - public static final String SERIALIZED_NAME_STATUS = "status"; - @SerializedName(SERIALIZED_NAME_STATUS) - private ArrayTaskStatus status; - - public static final String SERIALIZED_NAME_STATUS_MESSAGE = "status_message"; - @SerializedName(SERIALIZED_NAME_STATUS_MESSAGE) - private String statusMessage; - - public static final String SERIALIZED_NAME_EXECUTIONS = "executions"; - @SerializedName(SERIALIZED_NAME_EXECUTIONS) - private List executions = null; - - public TaskGraphNodeMetadata() { - } - - - public TaskGraphNodeMetadata( - List executions - ) { - this(); - this.executions = executions; - } - - public TaskGraphNodeMetadata clientNodeUuid(String clientNodeUuid) { - - this.clientNodeUuid = clientNodeUuid; - return this; - } - - /** - * The client-generated UUID of the given graph node. - * @return clientNodeUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The client-generated UUID of the given graph node.") - - public String getClientNodeUuid() { - return clientNodeUuid; - } - - - public void setClientNodeUuid(String clientNodeUuid) { - this.clientNodeUuid = clientNodeUuid; - } - - - public TaskGraphNodeMetadata name(String name) { - - this.name = name; - return this; - } - - /** - * The client-generated name of the node. This is not guaranteed to be unique. - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The client-generated name of the node. This is not guaranteed to be unique. ") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public TaskGraphNodeMetadata dependsOn(List dependsOn) { - - this.dependsOn = dependsOn; - return this; - } - - public TaskGraphNodeMetadata addDependsOnItem(String dependsOnItem) { - if (this.dependsOn == null) { - this.dependsOn = new ArrayList<>(); - } - this.dependsOn.add(dependsOnItem); - return this; - } - - /** - * The client_node_uuid of each node that this node depends upon. Used to define the structure of the graph. - * @return dependsOn - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The client_node_uuid of each node that this node depends upon. Used to define the structure of the graph. ") - - public List getDependsOn() { - return dependsOn; - } - - - public void setDependsOn(List dependsOn) { - this.dependsOn = dependsOn; - } - - - public TaskGraphNodeMetadata runLocation(TaskGraphLogRunLocation runLocation) { - - this.runLocation = runLocation; - return this; - } - - /** - * Get runLocation - * @return runLocation - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public TaskGraphLogRunLocation getRunLocation() { - return runLocation; - } - - - public void setRunLocation(TaskGraphLogRunLocation runLocation) { - this.runLocation = runLocation; - } - - - public TaskGraphNodeMetadata status(ArrayTaskStatus status) { - - this.status = status; - return this; - } - - /** - * Get status - * @return status - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public ArrayTaskStatus getStatus() { - return status; - } - - - public void setStatus(ArrayTaskStatus status) { - this.status = status; - } - - - public TaskGraphNodeMetadata statusMessage(String statusMessage) { - - this.statusMessage = statusMessage; - return this; - } - - /** - * The reason the array task status is in the state - * @return statusMessage - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The reason the array task status is in the state") - - public String getStatusMessage() { - return statusMessage; - } - - - public void setStatusMessage(String statusMessage) { - this.statusMessage = statusMessage; - } - - - /** - * ArrayTasks representing each execution attempt for this node. For nodes that have never been submitted, this will be empty. For nodes that have been retried, this may have multiple entries. The last one in the list represents the most recent execution. This is read-only and generated by the server based on the tasks it has actually executed. - * @return executions - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "ArrayTasks representing each execution attempt for this node. For nodes that have never been submitted, this will be empty. For nodes that have been retried, this may have multiple entries. The last one in the list represents the most recent execution. This is read-only and generated by the server based on the tasks it has actually executed. ") - - public List getExecutions() { - return executions; - } - - - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public TaskGraphNodeMetadata putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - TaskGraphNodeMetadata taskGraphNodeMetadata = (TaskGraphNodeMetadata) o; - return Objects.equals(this.clientNodeUuid, taskGraphNodeMetadata.clientNodeUuid) && - Objects.equals(this.name, taskGraphNodeMetadata.name) && - Objects.equals(this.dependsOn, taskGraphNodeMetadata.dependsOn) && - Objects.equals(this.runLocation, taskGraphNodeMetadata.runLocation) && - Objects.equals(this.status, taskGraphNodeMetadata.status) && - Objects.equals(this.statusMessage, taskGraphNodeMetadata.statusMessage) && - Objects.equals(this.executions, taskGraphNodeMetadata.executions)&& - Objects.equals(this.additionalProperties, taskGraphNodeMetadata.additionalProperties); - } - - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); - } - - @Override - public int hashCode() { - return Objects.hash(clientNodeUuid, name, dependsOn, runLocation, status, statusMessage, executions, additionalProperties); - } - - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class TaskGraphNodeMetadata {\n"); - sb.append(" clientNodeUuid: ").append(toIndentedString(clientNodeUuid)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" dependsOn: ").append(toIndentedString(dependsOn)).append("\n"); - sb.append(" runLocation: ").append(toIndentedString(runLocation)).append("\n"); - sb.append(" status: ").append(toIndentedString(status)).append("\n"); - sb.append(" statusMessage: ").append(toIndentedString(statusMessage)).append("\n"); - sb.append(" executions: ").append(toIndentedString(executions)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("client_node_uuid"); - openapiFields.add("name"); - openapiFields.add("depends_on"); - openapiFields.add("run_location"); - openapiFields.add("status"); - openapiFields.add("status_message"); - openapiFields.add("executions"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to TaskGraphNodeMetadata - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (TaskGraphNodeMetadata.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in TaskGraphNodeMetadata is not found in the empty JSON string", TaskGraphNodeMetadata.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("client_node_uuid") != null && !jsonObj.get("client_node_uuid").isJsonNull()) && !jsonObj.get("client_node_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `client_node_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("client_node_uuid").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("depends_on") != null && !jsonObj.get("depends_on").isJsonNull()) && !jsonObj.get("depends_on").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `depends_on` to be an array in the JSON string but got `%s`", jsonObj.get("depends_on").toString())); - } - if ((jsonObj.get("status_message") != null && !jsonObj.get("status_message").isJsonNull()) && !jsonObj.get("status_message").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `status_message` to be a primitive type in the JSON string but got `%s`", jsonObj.get("status_message").toString())); - } - JsonArray jsonArrayexecutions = jsonObj.getAsJsonArray("executions"); - if (jsonArrayexecutions != null) { - // ensure the json data is an array - if (!jsonObj.get("executions").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `executions` to be an array in the JSON string but got `%s`", jsonObj.get("executions").toString())); - } - - // validate the optional field `executions` (array) - for (int i = 0; i < jsonArrayexecutions.size(); i++) { - ArrayTask.validateJsonObject(jsonArrayexecutions.get(i).getAsJsonObject()); - }; - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!TaskGraphNodeMetadata.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'TaskGraphNodeMetadata' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(TaskGraphNodeMetadata.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, TaskGraphNodeMetadata value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public TaskGraphNodeMetadata read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - TaskGraphNodeMetadata instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of TaskGraphNodeMetadata given an JSON string - * - * @param jsonString JSON string - * @return An instance of TaskGraphNodeMetadata - * @throws IOException if the JSON string is invalid with respect to TaskGraphNodeMetadata - */ - public static TaskGraphNodeMetadata fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, TaskGraphNodeMetadata.class); - } - - /** - * Convert an instance of TaskGraphNodeMetadata to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphSharing.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphSharing.java deleted file mode 100644 index a050dbf..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphSharing.java +++ /dev/null @@ -1,342 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * details for sharing a given registered task graph - */ -@ApiModel(description = "details for sharing a given registered task graph") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class TaskGraphSharing { - public static final String SERIALIZED_NAME_ACTIONS = "actions"; - @SerializedName(SERIALIZED_NAME_ACTIONS) - private List actions = null; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public static final String SERIALIZED_NAME_NAMESPACE_TYPE = "namespace_type"; - @SerializedName(SERIALIZED_NAME_NAMESPACE_TYPE) - private String namespaceType; - - public TaskGraphSharing() { - } - - public TaskGraphSharing actions(List actions) { - - this.actions = actions; - return this; - } - - public TaskGraphSharing addActionsItem(TaskGraphActions actionsItem) { - if (this.actions == null) { - this.actions = new ArrayList<>(); - } - this.actions.add(actionsItem); - return this; - } - - /** - * List of permitted actions - * @return actions - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "[fetch_task_graph, share_task_graph]", value = "List of permitted actions") - - public List getActions() { - return actions; - } - - - public void setActions(List actions) { - this.actions = actions; - } - - - public TaskGraphSharing namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * namespace being granted array access can be a user or organization - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "MyOrganization", value = "namespace being granted array access can be a user or organization") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - - public TaskGraphSharing namespaceType(String namespaceType) { - - this.namespaceType = namespaceType; - return this; - } - - /** - * details on if the namespace is a organization or user - * @return namespaceType - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "organization", value = "details on if the namespace is a organization or user") - - public String getNamespaceType() { - return namespaceType; - } - - - public void setNamespaceType(String namespaceType) { - this.namespaceType = namespaceType; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public TaskGraphSharing putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - TaskGraphSharing taskGraphSharing = (TaskGraphSharing) o; - return Objects.equals(this.actions, taskGraphSharing.actions) && - Objects.equals(this.namespace, taskGraphSharing.namespace) && - Objects.equals(this.namespaceType, taskGraphSharing.namespaceType)&& - Objects.equals(this.additionalProperties, taskGraphSharing.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(actions, namespace, namespaceType, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class TaskGraphSharing {\n"); - sb.append(" actions: ").append(toIndentedString(actions)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" namespaceType: ").append(toIndentedString(namespaceType)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("actions"); - openapiFields.add("namespace"); - openapiFields.add("namespace_type"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to TaskGraphSharing - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (TaskGraphSharing.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in TaskGraphSharing is not found in the empty JSON string", TaskGraphSharing.openapiRequiredFields.toString())); - } - } - // ensure the json data is an array - if ((jsonObj.get("actions") != null && !jsonObj.get("actions").isJsonNull()) && !jsonObj.get("actions").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `actions` to be an array in the JSON string but got `%s`", jsonObj.get("actions").toString())); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - if ((jsonObj.get("namespace_type") != null && !jsonObj.get("namespace_type").isJsonNull()) && !jsonObj.get("namespace_type").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace_type` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace_type").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!TaskGraphSharing.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'TaskGraphSharing' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(TaskGraphSharing.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, TaskGraphSharing value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public TaskGraphSharing read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - TaskGraphSharing instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of TaskGraphSharing given an JSON string - * - * @param jsonString JSON string - * @return An instance of TaskGraphSharing - * @throws IOException if the JSON string is invalid with respect to TaskGraphSharing - */ - public static TaskGraphSharing fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, TaskGraphSharing.class); - } - - /** - * Convert an instance of TaskGraphSharing to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphType.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphType.java deleted file mode 100644 index 0ee78bd..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphType.java +++ /dev/null @@ -1,69 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * The type of a task graph. - */ -@JsonAdapter(TaskGraphType.Adapter.class) -public enum TaskGraphType { - - BATCH("batch"), - - REALTIME("realtime"); - - private String value; - - TaskGraphType(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static TaskGraphType fromValue(String value) { - for (TaskGraphType b : TaskGraphType.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final TaskGraphType enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public TaskGraphType read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return TaskGraphType.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphs.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphs.java deleted file mode 100644 index e2a25bd..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TaskGraphs.java +++ /dev/null @@ -1,285 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Information about a series of task graphs. - */ -@ApiModel(description = "Information about a series of task graphs.") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class TaskGraphs { - public static final String SERIALIZED_NAME_GRAPHS = "graphs"; - @SerializedName(SERIALIZED_NAME_GRAPHS) - private List graphs = null; - - public TaskGraphs() { - } - - public TaskGraphs graphs(List graphs) { - - this.graphs = graphs; - return this; - } - - public TaskGraphs addGraphsItem(TaskGraph graphsItem) { - if (this.graphs == null) { - this.graphs = new ArrayList<>(); - } - this.graphs.add(graphsItem); - return this; - } - - /** - * The series of graphs. - * @return graphs - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The series of graphs. ") - - public List getGraphs() { - return graphs; - } - - - public void setGraphs(List graphs) { - this.graphs = graphs; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public TaskGraphs putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - TaskGraphs taskGraphs = (TaskGraphs) o; - return Objects.equals(this.graphs, taskGraphs.graphs)&& - Objects.equals(this.additionalProperties, taskGraphs.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(graphs, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class TaskGraphs {\n"); - sb.append(" graphs: ").append(toIndentedString(graphs)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("graphs"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to TaskGraphs - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (TaskGraphs.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in TaskGraphs is not found in the empty JSON string", TaskGraphs.openapiRequiredFields.toString())); - } - } - JsonArray jsonArraygraphs = jsonObj.getAsJsonArray("graphs"); - if (jsonArraygraphs != null) { - // ensure the json data is an array - if (!jsonObj.get("graphs").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `graphs` to be an array in the JSON string but got `%s`", jsonObj.get("graphs").toString())); - } - - // validate the optional field `graphs` (array) - for (int i = 0; i < jsonArraygraphs.size(); i++) { - TaskGraph.validateJsonObject(jsonArraygraphs.get(i).getAsJsonObject()); - }; - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!TaskGraphs.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'TaskGraphs' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(TaskGraphs.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, TaskGraphs value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public TaskGraphs read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - TaskGraphs instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of TaskGraphs given an JSON string - * - * @param jsonString JSON string - * @return An instance of TaskGraphs - * @throws IOException if the JSON string is invalid with respect to TaskGraphs - */ - public static TaskGraphs fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, TaskGraphs.class); - } - - /** - * Convert an instance of TaskGraphs to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TileDBConfig.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TileDBConfig.java deleted file mode 100644 index 920d2cf..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TileDBConfig.java +++ /dev/null @@ -1,285 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * TileDB config used for interaction with the embedded library - */ -@ApiModel(description = "TileDB config used for interaction with the embedded library") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class TileDBConfig { - public static final String SERIALIZED_NAME_ENTRIES = "entries"; - @SerializedName(SERIALIZED_NAME_ENTRIES) - private List entries = null; - - public TileDBConfig() { - } - - public TileDBConfig entries(List entries) { - - this.entries = entries; - return this; - } - - public TileDBConfig addEntriesItem(TileDBConfigEntriesInner entriesItem) { - if (this.entries == null) { - this.entries = new ArrayList<>(); - } - this.entries.add(entriesItem); - return this; - } - - /** - * Get entries - * @return entries - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List getEntries() { - return entries; - } - - - public void setEntries(List entries) { - this.entries = entries; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public TileDBConfig putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - TileDBConfig tileDBConfig = (TileDBConfig) o; - return Objects.equals(this.entries, tileDBConfig.entries)&& - Objects.equals(this.additionalProperties, tileDBConfig.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(entries, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class TileDBConfig {\n"); - sb.append(" entries: ").append(toIndentedString(entries)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("entries"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to TileDBConfig - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (TileDBConfig.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in TileDBConfig is not found in the empty JSON string", TileDBConfig.openapiRequiredFields.toString())); - } - } - JsonArray jsonArrayentries = jsonObj.getAsJsonArray("entries"); - if (jsonArrayentries != null) { - // ensure the json data is an array - if (!jsonObj.get("entries").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `entries` to be an array in the JSON string but got `%s`", jsonObj.get("entries").toString())); - } - - // validate the optional field `entries` (array) - for (int i = 0; i < jsonArrayentries.size(); i++) { - TileDBConfigEntriesInner.validateJsonObject(jsonArrayentries.get(i).getAsJsonObject()); - }; - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!TileDBConfig.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'TileDBConfig' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(TileDBConfig.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, TileDBConfig value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public TileDBConfig read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - TileDBConfig instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of TileDBConfig given an JSON string - * - * @param jsonString JSON string - * @return An instance of TileDBConfig - * @throws IOException if the JSON string is invalid with respect to TileDBConfig - */ - public static TileDBConfig fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, TileDBConfig.class); - } - - /** - * Convert an instance of TileDBConfig to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TileDBConfigEntriesInner.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TileDBConfigEntriesInner.java deleted file mode 100644 index 744cd13..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TileDBConfigEntriesInner.java +++ /dev/null @@ -1,296 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * TileDBConfigEntriesInner - */ -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class TileDBConfigEntriesInner { - public static final String SERIALIZED_NAME_KEY = "key"; - @SerializedName(SERIALIZED_NAME_KEY) - private String key; - - public static final String SERIALIZED_NAME_VALUE = "value"; - @SerializedName(SERIALIZED_NAME_VALUE) - private String value; - - public TileDBConfigEntriesInner() { - } - - public TileDBConfigEntriesInner key(String key) { - - this.key = key; - return this; - } - - /** - * Get key - * @return key - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public String getKey() { - return key; - } - - - public void setKey(String key) { - this.key = key; - } - - - public TileDBConfigEntriesInner value(String value) { - - this.value = value; - return this; - } - - /** - * Get value - * @return value - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public String getValue() { - return value; - } - - - public void setValue(String value) { - this.value = value; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public TileDBConfigEntriesInner putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - TileDBConfigEntriesInner tileDBConfigEntriesInner = (TileDBConfigEntriesInner) o; - return Objects.equals(this.key, tileDBConfigEntriesInner.key) && - Objects.equals(this.value, tileDBConfigEntriesInner.value)&& - Objects.equals(this.additionalProperties, tileDBConfigEntriesInner.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(key, value, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class TileDBConfigEntriesInner {\n"); - sb.append(" key: ").append(toIndentedString(key)).append("\n"); - sb.append(" value: ").append(toIndentedString(value)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("key"); - openapiFields.add("value"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to TileDBConfigEntriesInner - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (TileDBConfigEntriesInner.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in TileDBConfigEntriesInner is not found in the empty JSON string", TileDBConfigEntriesInner.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("key") != null && !jsonObj.get("key").isJsonNull()) && !jsonObj.get("key").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `key` to be a primitive type in the JSON string but got `%s`", jsonObj.get("key").toString())); - } - if ((jsonObj.get("value") != null && !jsonObj.get("value").isJsonNull()) && !jsonObj.get("value").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `value` to be a primitive type in the JSON string but got `%s`", jsonObj.get("value").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!TileDBConfigEntriesInner.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'TileDBConfigEntriesInner' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(TileDBConfigEntriesInner.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, TileDBConfigEntriesInner value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public TileDBConfigEntriesInner read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - TileDBConfigEntriesInner instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of TileDBConfigEntriesInner given an JSON string - * - * @param jsonString JSON string - * @return An instance of TileDBConfigEntriesInner - * @throws IOException if the JSON string is invalid with respect to TileDBConfigEntriesInner - */ - public static TileDBConfigEntriesInner fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, TileDBConfigEntriesInner.class); - } - - /** - * Convert an instance of TileDBConfigEntriesInner to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Token.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/Token.java deleted file mode 100644 index 2fbef4c..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Token.java +++ /dev/null @@ -1,403 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.time.OffsetDateTime; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * A api token and its metadata - */ -@ApiModel(description = "A api token and its metadata") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class Token { - public static final String SERIALIZED_NAME_TOKEN = "token"; - @SerializedName(SERIALIZED_NAME_TOKEN) - private String token; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_ISSUED_AT = "issued_at"; - @SerializedName(SERIALIZED_NAME_ISSUED_AT) - private OffsetDateTime issuedAt; - - public static final String SERIALIZED_NAME_EXPIRES_AT = "expires_at"; - @SerializedName(SERIALIZED_NAME_EXPIRES_AT) - private OffsetDateTime expiresAt; - - public static final String SERIALIZED_NAME_SCOPE = "scope"; - @SerializedName(SERIALIZED_NAME_SCOPE) - private List scope = null; - - public Token() { - } - - public Token token(String token) { - - this.token = token; - return this; - } - - /** - * A api token - * @return token - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "A api token") - - public String getToken() { - return token; - } - - - public void setToken(String token) { - this.token = token; - } - - - public Token name(String name) { - - this.name = name; - return this; - } - - /** - * Name of token to revoke - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Name of token to revoke") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public Token issuedAt(OffsetDateTime issuedAt) { - - this.issuedAt = issuedAt; - return this; - } - - /** - * datetime the token was created - * @return issuedAt - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "datetime the token was created") - - public OffsetDateTime getIssuedAt() { - return issuedAt; - } - - - public void setIssuedAt(OffsetDateTime issuedAt) { - this.issuedAt = issuedAt; - } - - - public Token expiresAt(OffsetDateTime expiresAt) { - - this.expiresAt = expiresAt; - return this; - } - - /** - * datetime the token when token will expire - * @return expiresAt - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "datetime the token when token will expire") - - public OffsetDateTime getExpiresAt() { - return expiresAt; - } - - - public void setExpiresAt(OffsetDateTime expiresAt) { - this.expiresAt = expiresAt; - } - - - public Token scope(List scope) { - - this.scope = scope; - return this; - } - - public Token addScopeItem(TokenScope scopeItem) { - if (this.scope == null) { - this.scope = new ArrayList<>(); - } - this.scope.add(scopeItem); - return this; - } - - /** - * Optional scope to limit token, defaults to all permissions, current supported values are password_reset or * - * @return scope - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Optional scope to limit token, defaults to all permissions, current supported values are password_reset or *") - - public List getScope() { - return scope; - } - - - public void setScope(List scope) { - this.scope = scope; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public Token putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Token token = (Token) o; - return Objects.equals(this.token, token.token) && - Objects.equals(this.name, token.name) && - Objects.equals(this.issuedAt, token.issuedAt) && - Objects.equals(this.expiresAt, token.expiresAt) && - Objects.equals(this.scope, token.scope)&& - Objects.equals(this.additionalProperties, token.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(token, name, issuedAt, expiresAt, scope, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Token {\n"); - sb.append(" token: ").append(toIndentedString(token)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" issuedAt: ").append(toIndentedString(issuedAt)).append("\n"); - sb.append(" expiresAt: ").append(toIndentedString(expiresAt)).append("\n"); - sb.append(" scope: ").append(toIndentedString(scope)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("token"); - openapiFields.add("name"); - openapiFields.add("issued_at"); - openapiFields.add("expires_at"); - openapiFields.add("scope"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to Token - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (Token.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in Token is not found in the empty JSON string", Token.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("token") != null && !jsonObj.get("token").isJsonNull()) && !jsonObj.get("token").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `token` to be a primitive type in the JSON string but got `%s`", jsonObj.get("token").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("scope") != null && !jsonObj.get("scope").isJsonNull()) && !jsonObj.get("scope").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `scope` to be an array in the JSON string but got `%s`", jsonObj.get("scope").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!Token.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'Token' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(Token.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, Token value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public Token read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - Token instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of Token given an JSON string - * - * @param jsonString JSON string - * @return An instance of Token - * @throws IOException if the JSON string is invalid with respect to Token - */ - public static Token fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, Token.class); - } - - /** - * Convert an instance of Token to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TokenRequest.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TokenRequest.java deleted file mode 100644 index ba0265e..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TokenRequest.java +++ /dev/null @@ -1,340 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.time.OffsetDateTime; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * A request from a user for an api token - */ -@ApiModel(description = "A request from a user for an api token") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class TokenRequest { - public static final String SERIALIZED_NAME_EXPIRES = "expires"; - @SerializedName(SERIALIZED_NAME_EXPIRES) - private OffsetDateTime expires; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_SCOPE = "scope"; - @SerializedName(SERIALIZED_NAME_SCOPE) - private List scope = null; - - public TokenRequest() { - } - - public TokenRequest expires(OffsetDateTime expires) { - - this.expires = expires; - return this; - } - - /** - * Expiration date for token, if empty token defaults to 30 minutes - * @return expires - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "2018-12-31T12:13:14Z", value = "Expiration date for token, if empty token defaults to 30 minutes") - - public OffsetDateTime getExpires() { - return expires; - } - - - public void setExpires(OffsetDateTime expires) { - this.expires = expires; - } - - - public TokenRequest name(String name) { - - this.name = name; - return this; - } - - /** - * Optional name for token, if the name already exists for the user it will be auto incremented (i.e. myToken-1) - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "myToken", value = "Optional name for token, if the name already exists for the user it will be auto incremented (i.e. myToken-1)") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public TokenRequest scope(List scope) { - - this.scope = scope; - return this; - } - - public TokenRequest addScopeItem(TokenScope scopeItem) { - if (this.scope == null) { - this.scope = new ArrayList<>(); - } - this.scope.add(scopeItem); - return this; - } - - /** - * Optional scope to limit token, defaults to all permissions, current supported values are password_reset or * - * @return scope - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Optional scope to limit token, defaults to all permissions, current supported values are password_reset or *") - - public List getScope() { - return scope; - } - - - public void setScope(List scope) { - this.scope = scope; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public TokenRequest putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - TokenRequest tokenRequest = (TokenRequest) o; - return Objects.equals(this.expires, tokenRequest.expires) && - Objects.equals(this.name, tokenRequest.name) && - Objects.equals(this.scope, tokenRequest.scope)&& - Objects.equals(this.additionalProperties, tokenRequest.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(expires, name, scope, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class TokenRequest {\n"); - sb.append(" expires: ").append(toIndentedString(expires)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" scope: ").append(toIndentedString(scope)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("expires"); - openapiFields.add("name"); - openapiFields.add("scope"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to TokenRequest - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (TokenRequest.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in TokenRequest is not found in the empty JSON string", TokenRequest.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("scope") != null && !jsonObj.get("scope").isJsonNull()) && !jsonObj.get("scope").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `scope` to be an array in the JSON string but got `%s`", jsonObj.get("scope").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!TokenRequest.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'TokenRequest' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(TokenRequest.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, TokenRequest value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public TokenRequest read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - TokenRequest instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of TokenRequest given an JSON string - * - * @param jsonString JSON string - * @return An instance of TokenRequest - * @throws IOException if the JSON string is invalid with respect to TokenRequest - */ - public static TokenRequest fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, TokenRequest.class); - } - - /** - * Convert an instance of TokenRequest to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TokenScope.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/TokenScope.java deleted file mode 100644 index ba93430..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/TokenScope.java +++ /dev/null @@ -1,95 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * An api token scope available for creation - */ -@JsonAdapter(TokenScope.Adapter.class) -public enum TokenScope { - - PASSWORD_RESET("password_reset"), - - CONFIRM_EMAIL("confirm_email"), - - STAR("*"), - - USER_READ("user:read"), - - USER_READ_WRITE("user:read-write"), - - USER_ADMIN("user:admin"), - - ARRAY_READ("array:read"), - - ARRAY_READ_WRITE("array:read-write"), - - ARRAY_ADMIN("array:admin"), - - ORGANIZATION_READ("organization:read"), - - ORGANIZATION_READ_WRITE("organization:read-write"), - - ORGANIZATION_ADMIN("organization:admin"), - - GROUP_READ("group:read"), - - GROUP_READ_WRITE("group:read-write"), - - GROUP_ADMIN("group:admin"); - - private String value; - - TokenScope(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static TokenScope fromValue(String value) { - for (TokenScope b : TokenScope.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final TokenScope enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public TokenScope read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return TokenScope.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFActions.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFActions.java deleted file mode 100644 index 840f7c0..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFActions.java +++ /dev/null @@ -1,69 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * actions a user can take on a UDF - */ -@JsonAdapter(UDFActions.Adapter.class) -public enum UDFActions { - - FETCH_UDF("fetch_udf"), - - SHARE_UDF("share_udf"); - - private String value; - - UDFActions(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static UDFActions fromValue(String value) { - for (UDFActions b : UDFActions.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final UDFActions enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public UDFActions read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return UDFActions.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFArrayDetails.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFArrayDetails.java deleted file mode 100644 index bb95a19..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFArrayDetails.java +++ /dev/null @@ -1,389 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import org.openapitools.jackson.nullable.JsonNullable; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Contains array details for multi-array query including uri, ranges buffers - */ -@ApiModel(description = "Contains array details for multi-array query including uri, ranges buffers") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class UDFArrayDetails { - public static final String SERIALIZED_NAME_PARAMETER_ID = "parameter_id"; - @SerializedName(SERIALIZED_NAME_PARAMETER_ID) - private String parameterId; - - public static final String SERIALIZED_NAME_URI = "uri"; - @SerializedName(SERIALIZED_NAME_URI) - private String uri; - - public static final String SERIALIZED_NAME_RANGES = "ranges"; - @SerializedName(SERIALIZED_NAME_RANGES) - private QueryRanges ranges; - - public static final String SERIALIZED_NAME_BUFFERS = "buffers"; - @SerializedName(SERIALIZED_NAME_BUFFERS) - private List buffers = null; - - public UDFArrayDetails() { - } - - public UDFArrayDetails parameterId(String parameterId) { - - this.parameterId = parameterId; - return this; - } - - /** - * An optional client-generated identifier to distinguish between multiple range/buffer requests from the same array in the same call. This may be set for MultiArrayUDFs that use the `argument_json` style of passing arrays. - * @return parameterId - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "An optional client-generated identifier to distinguish between multiple range/buffer requests from the same array in the same call. This may be set for MultiArrayUDFs that use the `argument_json` style of passing arrays. ") - - public String getParameterId() { - return parameterId; - } - - - public void setParameterId(String parameterId) { - this.parameterId = parameterId; - } - - - public UDFArrayDetails uri(String uri) { - - this.uri = uri; - return this; - } - - /** - * array to set ranges and buffers on, must be in tiledb:// format - * @return uri - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "array to set ranges and buffers on, must be in tiledb:// format") - - public String getUri() { - return uri; - } - - - public void setUri(String uri) { - this.uri = uri; - } - - - public UDFArrayDetails ranges(QueryRanges ranges) { - - this.ranges = ranges; - return this; - } - - /** - * Get ranges - * @return ranges - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public QueryRanges getRanges() { - return ranges; - } - - - public void setRanges(QueryRanges ranges) { - this.ranges = ranges; - } - - - public UDFArrayDetails buffers(List buffers) { - - this.buffers = buffers; - return this; - } - - public UDFArrayDetails addBuffersItem(String buffersItem) { - if (this.buffers == null) { - this.buffers = new ArrayList<>(); - } - this.buffers.add(buffersItem); - return this; - } - - /** - * List of buffers to fetch (attributes + dimensions) - * @return buffers - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "List of buffers to fetch (attributes + dimensions)") - - public List getBuffers() { - return buffers; - } - - - public void setBuffers(List buffers) { - this.buffers = buffers; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public UDFArrayDetails putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - UDFArrayDetails udFArrayDetails = (UDFArrayDetails) o; - return Objects.equals(this.parameterId, udFArrayDetails.parameterId) && - Objects.equals(this.uri, udFArrayDetails.uri) && - Objects.equals(this.ranges, udFArrayDetails.ranges) && - Objects.equals(this.buffers, udFArrayDetails.buffers)&& - Objects.equals(this.additionalProperties, udFArrayDetails.additionalProperties); - } - - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); - } - - @Override - public int hashCode() { - return Objects.hash(parameterId, uri, ranges, buffers, additionalProperties); - } - - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class UDFArrayDetails {\n"); - sb.append(" parameterId: ").append(toIndentedString(parameterId)).append("\n"); - sb.append(" uri: ").append(toIndentedString(uri)).append("\n"); - sb.append(" ranges: ").append(toIndentedString(ranges)).append("\n"); - sb.append(" buffers: ").append(toIndentedString(buffers)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("parameter_id"); - openapiFields.add("uri"); - openapiFields.add("ranges"); - openapiFields.add("buffers"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to UDFArrayDetails - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (UDFArrayDetails.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in UDFArrayDetails is not found in the empty JSON string", UDFArrayDetails.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("parameter_id") != null && !jsonObj.get("parameter_id").isJsonNull()) && !jsonObj.get("parameter_id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `parameter_id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("parameter_id").toString())); - } - if ((jsonObj.get("uri") != null && !jsonObj.get("uri").isJsonNull()) && !jsonObj.get("uri").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `uri` to be a primitive type in the JSON string but got `%s`", jsonObj.get("uri").toString())); - } - // validate the optional field `ranges` - if (jsonObj.get("ranges") != null && !jsonObj.get("ranges").isJsonNull()) { - QueryRanges.validateJsonObject(jsonObj.getAsJsonObject("ranges")); - } - // ensure the json data is an array - if ((jsonObj.get("buffers") != null && !jsonObj.get("buffers").isJsonNull()) && !jsonObj.get("buffers").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `buffers` to be an array in the JSON string but got `%s`", jsonObj.get("buffers").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!UDFArrayDetails.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'UDFArrayDetails' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(UDFArrayDetails.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, UDFArrayDetails value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public UDFArrayDetails read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - UDFArrayDetails instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of UDFArrayDetails given an JSON string - * - * @param jsonString JSON string - * @return An instance of UDFArrayDetails - * @throws IOException if the JSON string is invalid with respect to UDFArrayDetails - */ - public static UDFArrayDetails fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, UDFArrayDetails.class); - } - - /** - * Convert an instance of UDFArrayDetails to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFCopied.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFCopied.java deleted file mode 100644 index 0af18ed..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFCopied.java +++ /dev/null @@ -1,372 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Copied udf uri and information - */ -@ApiModel(description = "Copied udf uri and information") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class UDFCopied { - public static final String SERIALIZED_NAME_OUTPUT_URI = "output_uri"; - @SerializedName(SERIALIZED_NAME_OUTPUT_URI) - private String outputUri; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_ID = "id"; - @SerializedName(SERIALIZED_NAME_ID) - private String id; - - public UDFCopied() { - } - - public UDFCopied outputUri(String outputUri) { - - this.outputUri = outputUri; - return this; - } - - /** - * output location of the TileDB udf - * @return outputUri - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "output location of the TileDB udf") - - public String getOutputUri() { - return outputUri; - } - - - public void setOutputUri(String outputUri) { - this.outputUri = outputUri; - } - - - public UDFCopied namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * namespace of the copied udf - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "namespace of the copied udf") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - - public UDFCopied name(String name) { - - this.name = name; - return this; - } - - /** - * name of the copied udf - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "name of the copied udf") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public UDFCopied id(String id) { - - this.id = id; - return this; - } - - /** - * unique ID of the copied udf - * @return id - **/ - @javax.annotation.Nonnull - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", required = true, value = "unique ID of the copied udf") - - public String getId() { - return id; - } - - - public void setId(String id) { - this.id = id; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public UDFCopied putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - UDFCopied udFCopied = (UDFCopied) o; - return Objects.equals(this.outputUri, udFCopied.outputUri) && - Objects.equals(this.namespace, udFCopied.namespace) && - Objects.equals(this.name, udFCopied.name) && - Objects.equals(this.id, udFCopied.id)&& - Objects.equals(this.additionalProperties, udFCopied.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(outputUri, namespace, name, id, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class UDFCopied {\n"); - sb.append(" outputUri: ").append(toIndentedString(outputUri)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("output_uri"); - openapiFields.add("namespace"); - openapiFields.add("name"); - openapiFields.add("id"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - openapiRequiredFields.add("id"); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to UDFCopied - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (UDFCopied.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in UDFCopied is not found in the empty JSON string", UDFCopied.openapiRequiredFields.toString())); - } - } - - // check to make sure all required properties/fields are present in the JSON string - for (String requiredField : UDFCopied.openapiRequiredFields) { - if (jsonObj.get(requiredField) == null) { - throw new IllegalArgumentException(String.format("The required field `%s` is not found in the JSON string: %s", requiredField, jsonObj.toString())); - } - } - if ((jsonObj.get("output_uri") != null && !jsonObj.get("output_uri").isJsonNull()) && !jsonObj.get("output_uri").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `output_uri` to be a primitive type in the JSON string but got `%s`", jsonObj.get("output_uri").toString())); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) && !jsonObj.get("id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("id").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!UDFCopied.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'UDFCopied' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(UDFCopied.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, UDFCopied value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public UDFCopied read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - UDFCopied instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of UDFCopied given an JSON string - * - * @param jsonString JSON string - * @return An instance of UDFCopied - * @throws IOException if the JSON string is invalid with respect to UDFCopied - */ - public static UDFCopied fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, UDFCopied.class); - } - - /** - * Convert an instance of UDFCopied to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFCopy.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFCopy.java deleted file mode 100644 index 233fe66..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFCopy.java +++ /dev/null @@ -1,331 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * information required to copy a udf - */ -@ApiModel(description = "information required to copy a udf") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class UDFCopy { - public static final String SERIALIZED_NAME_OUTPUT_URI = "output_uri"; - @SerializedName(SERIALIZED_NAME_OUTPUT_URI) - private String outputUri; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public UDFCopy() { - } - - public UDFCopy outputUri(String outputUri) { - - this.outputUri = outputUri; - return this; - } - - /** - * output location of the TileDB File - * @return outputUri - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "output location of the TileDB File") - - public String getOutputUri() { - return outputUri; - } - - - public void setOutputUri(String outputUri) { - this.outputUri = outputUri; - } - - - public UDFCopy namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * namespace to register the copy. If empty use the namespace of the request user - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "namespace to register the copy. If empty use the namespace of the request user") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - - public UDFCopy name(String name) { - - this.name = name; - return this; - } - - /** - * name to set for the copy. If empty use the name as the original udf, if it not already used in the namespace - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "name to set for the copy. If empty use the name as the original udf, if it not already used in the namespace") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public UDFCopy putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - UDFCopy udFCopy = (UDFCopy) o; - return Objects.equals(this.outputUri, udFCopy.outputUri) && - Objects.equals(this.namespace, udFCopy.namespace) && - Objects.equals(this.name, udFCopy.name)&& - Objects.equals(this.additionalProperties, udFCopy.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(outputUri, namespace, name, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class UDFCopy {\n"); - sb.append(" outputUri: ").append(toIndentedString(outputUri)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("output_uri"); - openapiFields.add("namespace"); - openapiFields.add("name"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to UDFCopy - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (UDFCopy.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in UDFCopy is not found in the empty JSON string", UDFCopy.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("output_uri") != null && !jsonObj.get("output_uri").isJsonNull()) && !jsonObj.get("output_uri").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `output_uri` to be a primitive type in the JSON string but got `%s`", jsonObj.get("output_uri").toString())); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!UDFCopy.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'UDFCopy' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(UDFCopy.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, UDFCopy value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public UDFCopy read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - UDFCopy instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of UDFCopy given an JSON string - * - * @param jsonString JSON string - * @return An instance of UDFCopy - * @throws IOException if the JSON string is invalid with respect to UDFCopy - */ - public static UDFCopy fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, UDFCopy.class); - } - - /** - * Convert an instance of UDFCopy to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFFavorite.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFFavorite.java deleted file mode 100644 index 018dc48..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFFavorite.java +++ /dev/null @@ -1,331 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * A user-favorite UDF item - */ -@ApiModel(description = "A user-favorite UDF item") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class UDFFavorite { - public static final String SERIALIZED_NAME_UDF_UUID = "udf_uuid"; - @SerializedName(SERIALIZED_NAME_UDF_UUID) - private String udfUuid; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public UDFFavorite() { - } - - public UDFFavorite udfUuid(String udfUuid) { - - this.udfUuid = udfUuid; - return this; - } - - /** - * unique UUID of the UDF - * @return udfUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "unique UUID of the UDF") - - public String getUdfUuid() { - return udfUuid; - } - - - public void setUdfUuid(String udfUuid) { - this.udfUuid = udfUuid; - } - - - public UDFFavorite namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * the namespace of the UDF - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "the namespace of the UDF") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - - public UDFFavorite name(String name) { - - this.name = name; - return this; - } - - /** - * the name of the UDF - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "the name of the UDF") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public UDFFavorite putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - UDFFavorite udFFavorite = (UDFFavorite) o; - return Objects.equals(this.udfUuid, udFFavorite.udfUuid) && - Objects.equals(this.namespace, udFFavorite.namespace) && - Objects.equals(this.name, udFFavorite.name)&& - Objects.equals(this.additionalProperties, udFFavorite.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(udfUuid, namespace, name, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class UDFFavorite {\n"); - sb.append(" udfUuid: ").append(toIndentedString(udfUuid)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("udf_uuid"); - openapiFields.add("namespace"); - openapiFields.add("name"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to UDFFavorite - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (UDFFavorite.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in UDFFavorite is not found in the empty JSON string", UDFFavorite.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("udf_uuid") != null && !jsonObj.get("udf_uuid").isJsonNull()) && !jsonObj.get("udf_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `udf_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("udf_uuid").toString())); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!UDFFavorite.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'UDFFavorite' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(UDFFavorite.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, UDFFavorite value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public UDFFavorite read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - UDFFavorite instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of UDFFavorite given an JSON string - * - * @param jsonString JSON string - * @return An instance of UDFFavorite - * @throws IOException if the JSON string is invalid with respect to UDFFavorite - */ - public static UDFFavorite fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, UDFFavorite.class); - } - - /** - * Convert an instance of UDFFavorite to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFFavoritesData.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFFavoritesData.java deleted file mode 100644 index 5d05aa6..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFFavoritesData.java +++ /dev/null @@ -1,319 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Object including UDF favorites and pagination metadata - */ -@ApiModel(description = "Object including UDF favorites and pagination metadata") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class UDFFavoritesData { - public static final String SERIALIZED_NAME_UDFS = "udfs"; - @SerializedName(SERIALIZED_NAME_UDFS) - private List udfs = null; - - public static final String SERIALIZED_NAME_PAGINATION_METADATA = "pagination_metadata"; - @SerializedName(SERIALIZED_NAME_PAGINATION_METADATA) - private PaginationMetadata paginationMetadata; - - public UDFFavoritesData() { - } - - public UDFFavoritesData udfs(List udfs) { - - this.udfs = udfs; - return this; - } - - public UDFFavoritesData addUdfsItem(ArrayInfo udfsItem) { - if (this.udfs == null) { - this.udfs = new ArrayList<>(); - } - this.udfs.add(udfsItem); - return this; - } - - /** - * List of UDF infos - * @return udfs - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "List of UDF infos") - - public List getUdfs() { - return udfs; - } - - - public void setUdfs(List udfs) { - this.udfs = udfs; - } - - - public UDFFavoritesData paginationMetadata(PaginationMetadata paginationMetadata) { - - this.paginationMetadata = paginationMetadata; - return this; - } - - /** - * Get paginationMetadata - * @return paginationMetadata - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public PaginationMetadata getPaginationMetadata() { - return paginationMetadata; - } - - - public void setPaginationMetadata(PaginationMetadata paginationMetadata) { - this.paginationMetadata = paginationMetadata; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public UDFFavoritesData putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - UDFFavoritesData udFFavoritesData = (UDFFavoritesData) o; - return Objects.equals(this.udfs, udFFavoritesData.udfs) && - Objects.equals(this.paginationMetadata, udFFavoritesData.paginationMetadata)&& - Objects.equals(this.additionalProperties, udFFavoritesData.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(udfs, paginationMetadata, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class UDFFavoritesData {\n"); - sb.append(" udfs: ").append(toIndentedString(udfs)).append("\n"); - sb.append(" paginationMetadata: ").append(toIndentedString(paginationMetadata)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("udfs"); - openapiFields.add("pagination_metadata"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to UDFFavoritesData - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (UDFFavoritesData.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in UDFFavoritesData is not found in the empty JSON string", UDFFavoritesData.openapiRequiredFields.toString())); - } - } - JsonArray jsonArrayudfs = jsonObj.getAsJsonArray("udfs"); - if (jsonArrayudfs != null) { - // ensure the json data is an array - if (!jsonObj.get("udfs").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `udfs` to be an array in the JSON string but got `%s`", jsonObj.get("udfs").toString())); - } - - // validate the optional field `udfs` (array) - for (int i = 0; i < jsonArrayudfs.size(); i++) { - ArrayInfo.validateJsonObject(jsonArrayudfs.get(i).getAsJsonObject()); - }; - } - // validate the optional field `pagination_metadata` - if (jsonObj.get("pagination_metadata") != null && !jsonObj.get("pagination_metadata").isJsonNull()) { - PaginationMetadata.validateJsonObject(jsonObj.getAsJsonObject("pagination_metadata")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!UDFFavoritesData.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'UDFFavoritesData' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(UDFFavoritesData.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, UDFFavoritesData value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public UDFFavoritesData read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - UDFFavoritesData instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of UDFFavoritesData given an JSON string - * - * @param jsonString JSON string - * @return An instance of UDFFavoritesData - * @throws IOException if the JSON string is invalid with respect to UDFFavoritesData - */ - public static UDFFavoritesData fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, UDFFavoritesData.class); - } - - /** - * Convert an instance of UDFFavoritesData to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFImage.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFImage.java deleted file mode 100644 index 16eb6e8..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFImage.java +++ /dev/null @@ -1,328 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Defines a set of images related to a specific name - */ -@ApiModel(description = "Defines a set of images related to a specific name") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class UDFImage { - public static final String SERIALIZED_NAME_ID = "id"; - @SerializedName(SERIALIZED_NAME_ID) - private String id; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_LANGUAGE = "language"; - @SerializedName(SERIALIZED_NAME_LANGUAGE) - private UDFLanguage language; - - public UDFImage() { - } - - public UDFImage id(String id) { - - this.id = id; - return this; - } - - /** - * Unique ID of set of images - * @return id - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "Unique ID of set of images") - - public String getId() { - return id; - } - - - public void setId(String id) { - this.id = id; - } - - - public UDFImage name(String name) { - - this.name = name; - return this; - } - - /** - * name of UDF - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "name of UDF") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public UDFImage language(UDFLanguage language) { - - this.language = language; - return this; - } - - /** - * Get language - * @return language - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public UDFLanguage getLanguage() { - return language; - } - - - public void setLanguage(UDFLanguage language) { - this.language = language; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public UDFImage putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - UDFImage udFImage = (UDFImage) o; - return Objects.equals(this.id, udFImage.id) && - Objects.equals(this.name, udFImage.name) && - Objects.equals(this.language, udFImage.language)&& - Objects.equals(this.additionalProperties, udFImage.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(id, name, language, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class UDFImage {\n"); - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" language: ").append(toIndentedString(language)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("id"); - openapiFields.add("name"); - openapiFields.add("language"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to UDFImage - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (UDFImage.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in UDFImage is not found in the empty JSON string", UDFImage.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) && !jsonObj.get("id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("id").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!UDFImage.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'UDFImage' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(UDFImage.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, UDFImage value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public UDFImage read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - UDFImage instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of UDFImage given an JSON string - * - * @param jsonString JSON string - * @return An instance of UDFImage - * @throws IOException if the JSON string is invalid with respect to UDFImage - */ - public static UDFImage fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, UDFImage.class); - } - - /** - * Convert an instance of UDFImage to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFImageVersion.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFImageVersion.java deleted file mode 100644 index 2931460..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFImageVersion.java +++ /dev/null @@ -1,455 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.math.BigDecimal; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Defines an image that belongs to a set of images having a version - */ -@ApiModel(description = "Defines an image that belongs to a set of images having a version") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class UDFImageVersion { - public static final String SERIALIZED_NAME_ID = "id"; - @SerializedName(SERIALIZED_NAME_ID) - private String id; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_UDF_IMAGE_UUID = "udf_image_uuid"; - @SerializedName(SERIALIZED_NAME_UDF_IMAGE_UUID) - private String udfImageUuid; - - public static final String SERIALIZED_NAME_DOCKER_IMAGE = "docker_image"; - @SerializedName(SERIALIZED_NAME_DOCKER_IMAGE) - private String dockerImage; - - public static final String SERIALIZED_NAME_VERSION = "version"; - @SerializedName(SERIALIZED_NAME_VERSION) - private BigDecimal version; - - public static final String SERIALIZED_NAME_DEFAULT = "default"; - @SerializedName(SERIALIZED_NAME_DEFAULT) - private Boolean _default; - - public static final String SERIALIZED_NAME_LATEST = "latest"; - @SerializedName(SERIALIZED_NAME_LATEST) - private Boolean latest; - - public UDFImageVersion() { - } - - public UDFImageVersion id(String id) { - - this.id = id; - return this; - } - - /** - * Unique ID of a versioned image - * @return id - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "Unique ID of a versioned image") - - public String getId() { - return id; - } - - - public void setId(String id) { - this.id = id; - } - - - public UDFImageVersion name(String name) { - - this.name = name; - return this; - } - - /** - * name of UDFImageVersion - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "name of UDFImageVersion") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public UDFImageVersion udfImageUuid(String udfImageUuid) { - - this.udfImageUuid = udfImageUuid; - return this; - } - - /** - * Unique ID of the UDF image set - * @return udfImageUuid - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "Unique ID of the UDF image set") - - public String getUdfImageUuid() { - return udfImageUuid; - } - - - public void setUdfImageUuid(String udfImageUuid) { - this.udfImageUuid = udfImageUuid; - } - - - public UDFImageVersion dockerImage(String dockerImage) { - - this.dockerImage = dockerImage; - return this; - } - - /** - * Uri of docker image related to current entry - * @return dockerImage - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Uri of docker image related to current entry") - - public String getDockerImage() { - return dockerImage; - } - - - public void setDockerImage(String dockerImage) { - this.dockerImage = dockerImage; - } - - - public UDFImageVersion version(BigDecimal version) { - - this.version = version; - return this; - } - - /** - * Image-specific version - * @return version - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "2.0", value = "Image-specific version") - - public BigDecimal getVersion() { - return version; - } - - - public void setVersion(BigDecimal version) { - this.version = version; - } - - - public UDFImageVersion _default(Boolean _default) { - - this._default = _default; - return this; - } - - /** - * If current image is default version - * @return _default - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "true", value = "If current image is default version") - - public Boolean getDefault() { - return _default; - } - - - public void setDefault(Boolean _default) { - this._default = _default; - } - - - public UDFImageVersion latest(Boolean latest) { - - this.latest = latest; - return this; - } - - /** - * If current image is latest version - * @return latest - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "true", value = "If current image is latest version") - - public Boolean getLatest() { - return latest; - } - - - public void setLatest(Boolean latest) { - this.latest = latest; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public UDFImageVersion putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - UDFImageVersion udFImageVersion = (UDFImageVersion) o; - return Objects.equals(this.id, udFImageVersion.id) && - Objects.equals(this.name, udFImageVersion.name) && - Objects.equals(this.udfImageUuid, udFImageVersion.udfImageUuid) && - Objects.equals(this.dockerImage, udFImageVersion.dockerImage) && - Objects.equals(this.version, udFImageVersion.version) && - Objects.equals(this._default, udFImageVersion._default) && - Objects.equals(this.latest, udFImageVersion.latest)&& - Objects.equals(this.additionalProperties, udFImageVersion.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(id, name, udfImageUuid, dockerImage, version, _default, latest, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class UDFImageVersion {\n"); - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" udfImageUuid: ").append(toIndentedString(udfImageUuid)).append("\n"); - sb.append(" dockerImage: ").append(toIndentedString(dockerImage)).append("\n"); - sb.append(" version: ").append(toIndentedString(version)).append("\n"); - sb.append(" _default: ").append(toIndentedString(_default)).append("\n"); - sb.append(" latest: ").append(toIndentedString(latest)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("id"); - openapiFields.add("name"); - openapiFields.add("udf_image_uuid"); - openapiFields.add("docker_image"); - openapiFields.add("version"); - openapiFields.add("default"); - openapiFields.add("latest"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to UDFImageVersion - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (UDFImageVersion.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in UDFImageVersion is not found in the empty JSON string", UDFImageVersion.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) && !jsonObj.get("id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("id").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - if ((jsonObj.get("udf_image_uuid") != null && !jsonObj.get("udf_image_uuid").isJsonNull()) && !jsonObj.get("udf_image_uuid").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `udf_image_uuid` to be a primitive type in the JSON string but got `%s`", jsonObj.get("udf_image_uuid").toString())); - } - if ((jsonObj.get("docker_image") != null && !jsonObj.get("docker_image").isJsonNull()) && !jsonObj.get("docker_image").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `docker_image` to be a primitive type in the JSON string but got `%s`", jsonObj.get("docker_image").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!UDFImageVersion.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'UDFImageVersion' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(UDFImageVersion.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, UDFImageVersion value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public UDFImageVersion read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - UDFImageVersion instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of UDFImageVersion given an JSON string - * - * @param jsonString JSON string - * @return An instance of UDFImageVersion - * @throws IOException if the JSON string is invalid with respect to UDFImageVersion - */ - public static UDFImageVersion fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, UDFImageVersion.class); - } - - /** - * Convert an instance of UDFImageVersion to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFInfo.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFInfo.java deleted file mode 100644 index d803839..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFInfo.java +++ /dev/null @@ -1,501 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * User-defined function that can persist in db, used and shared multiple times - */ -@ApiModel(description = "User-defined function that can persist in db, used and shared multiple times") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class UDFInfo { - public static final String SERIALIZED_NAME_ID = "id"; - @SerializedName(SERIALIZED_NAME_ID) - private String id; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_LANGUAGE = "language"; - @SerializedName(SERIALIZED_NAME_LANGUAGE) - private UDFLanguage language; - - public static final String SERIALIZED_NAME_TYPE = "type"; - @SerializedName(SERIALIZED_NAME_TYPE) - private UDFType type; - - public static final String SERIALIZED_NAME_README = "readme"; - @SerializedName(SERIALIZED_NAME_README) - private String readme; - - public static final String SERIALIZED_NAME_LICENSE_ID = "license_id"; - @SerializedName(SERIALIZED_NAME_LICENSE_ID) - private String licenseId; - - public static final String SERIALIZED_NAME_LICENSE_TEXT = "license_text"; - @SerializedName(SERIALIZED_NAME_LICENSE_TEXT) - private String licenseText; - - public static final String SERIALIZED_NAME_TAGS = "tags"; - @SerializedName(SERIALIZED_NAME_TAGS) - private List tags = null; - - public UDFInfo() { - } - - public UDFInfo id(String id) { - - this.id = id; - return this; - } - - /** - * Unique ID of UDF - * @return id - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "Unique ID of UDF") - - public String getId() { - return id; - } - - - public void setId(String id) { - this.id = id; - } - - - public UDFInfo name(String name) { - - this.name = name; - return this; - } - - /** - * name of UDF - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "name of UDF") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public UDFInfo language(UDFLanguage language) { - - this.language = language; - return this; - } - - /** - * Get language - * @return language - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public UDFLanguage getLanguage() { - return language; - } - - - public void setLanguage(UDFLanguage language) { - this.language = language; - } - - - public UDFInfo type(UDFType type) { - - this.type = type; - return this; - } - - /** - * Get type - * @return type - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public UDFType getType() { - return type; - } - - - public void setType(UDFType type) { - this.type = type; - } - - - public UDFInfo readme(String readme) { - - this.readme = readme; - return this; - } - - /** - * Markdown readme of UDFs - * @return readme - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Markdown readme of UDFs") - - public String getReadme() { - return readme; - } - - - public void setReadme(String readme) { - this.readme = readme; - } - - - public UDFInfo licenseId(String licenseId) { - - this.licenseId = licenseId; - return this; - } - - /** - * License identifier from SPDX License List or Custom - * @return licenseId - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "License identifier from SPDX License List or Custom") - - public String getLicenseId() { - return licenseId; - } - - - public void setLicenseId(String licenseId) { - this.licenseId = licenseId; - } - - - public UDFInfo licenseText(String licenseText) { - - this.licenseText = licenseText; - return this; - } - - /** - * License text - * @return licenseText - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "License text") - - public String getLicenseText() { - return licenseText; - } - - - public void setLicenseText(String licenseText) { - this.licenseText = licenseText; - } - - - public UDFInfo tags(List tags) { - - this.tags = tags; - return this; - } - - public UDFInfo addTagsItem(String tagsItem) { - if (this.tags == null) { - this.tags = new ArrayList<>(); - } - this.tags.add(tagsItem); - return this; - } - - /** - * optional tags for UDF - * @return tags - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "optional tags for UDF") - - public List getTags() { - return tags; - } - - - public void setTags(List tags) { - this.tags = tags; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public UDFInfo putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - UDFInfo udFInfo = (UDFInfo) o; - return Objects.equals(this.id, udFInfo.id) && - Objects.equals(this.name, udFInfo.name) && - Objects.equals(this.language, udFInfo.language) && - Objects.equals(this.type, udFInfo.type) && - Objects.equals(this.readme, udFInfo.readme) && - Objects.equals(this.licenseId, udFInfo.licenseId) && - Objects.equals(this.licenseText, udFInfo.licenseText) && - Objects.equals(this.tags, udFInfo.tags)&& - Objects.equals(this.additionalProperties, udFInfo.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(id, name, language, type, readme, licenseId, licenseText, tags, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class UDFInfo {\n"); - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" language: ").append(toIndentedString(language)).append("\n"); - sb.append(" type: ").append(toIndentedString(type)).append("\n"); - sb.append(" readme: ").append(toIndentedString(readme)).append("\n"); - sb.append(" licenseId: ").append(toIndentedString(licenseId)).append("\n"); - sb.append(" licenseText: ").append(toIndentedString(licenseText)).append("\n"); - sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("id"); - openapiFields.add("name"); - openapiFields.add("language"); - openapiFields.add("type"); - openapiFields.add("readme"); - openapiFields.add("license_id"); - openapiFields.add("license_text"); - openapiFields.add("tags"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to UDFInfo - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (UDFInfo.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in UDFInfo is not found in the empty JSON string", UDFInfo.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) && !jsonObj.get("id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("id").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - if ((jsonObj.get("readme") != null && !jsonObj.get("readme").isJsonNull()) && !jsonObj.get("readme").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `readme` to be a primitive type in the JSON string but got `%s`", jsonObj.get("readme").toString())); - } - if ((jsonObj.get("license_id") != null && !jsonObj.get("license_id").isJsonNull()) && !jsonObj.get("license_id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `license_id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("license_id").toString())); - } - if ((jsonObj.get("license_text") != null && !jsonObj.get("license_text").isJsonNull()) && !jsonObj.get("license_text").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `license_text` to be a primitive type in the JSON string but got `%s`", jsonObj.get("license_text").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("tags") != null && !jsonObj.get("tags").isJsonNull()) && !jsonObj.get("tags").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `tags` to be an array in the JSON string but got `%s`", jsonObj.get("tags").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!UDFInfo.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'UDFInfo' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(UDFInfo.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, UDFInfo value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public UDFInfo read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - UDFInfo instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of UDFInfo given an JSON string - * - * @param jsonString JSON string - * @return An instance of UDFInfo - * @throws IOException if the JSON string is invalid with respect to UDFInfo - */ - public static UDFInfo fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, UDFInfo.class); - } - - /** - * Convert an instance of UDFInfo to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFInfoUpdate.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFInfoUpdate.java deleted file mode 100644 index 7b6701f..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFInfoUpdate.java +++ /dev/null @@ -1,600 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * User-defined function that can persist in db, used and shared multiple times - */ -@ApiModel(description = "User-defined function that can persist in db, used and shared multiple times") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class UDFInfoUpdate { - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_LANGUAGE = "language"; - @SerializedName(SERIALIZED_NAME_LANGUAGE) - private UDFLanguage language; - - public static final String SERIALIZED_NAME_VERSION = "version"; - @SerializedName(SERIALIZED_NAME_VERSION) - private String version; - - public static final String SERIALIZED_NAME_IMAGE_NAME = "image_name"; - @SerializedName(SERIALIZED_NAME_IMAGE_NAME) - private String imageName; - - public static final String SERIALIZED_NAME_TYPE = "type"; - @SerializedName(SERIALIZED_NAME_TYPE) - private UDFType type; - - public static final String SERIALIZED_NAME_EXEC = "exec"; - @SerializedName(SERIALIZED_NAME_EXEC) - private String exec; - - public static final String SERIALIZED_NAME_EXEC_RAW = "exec_raw"; - @SerializedName(SERIALIZED_NAME_EXEC_RAW) - private String execRaw; - - public static final String SERIALIZED_NAME_README = "readme"; - @SerializedName(SERIALIZED_NAME_README) - private String readme; - - public static final String SERIALIZED_NAME_LICENSE_ID = "license_id"; - @SerializedName(SERIALIZED_NAME_LICENSE_ID) - private String licenseId; - - public static final String SERIALIZED_NAME_LICENSE_TEXT = "license_text"; - @SerializedName(SERIALIZED_NAME_LICENSE_TEXT) - private String licenseText; - - public static final String SERIALIZED_NAME_TAGS = "tags"; - @SerializedName(SERIALIZED_NAME_TAGS) - private List tags = null; - - public UDFInfoUpdate() { - } - - public UDFInfoUpdate name(String name) { - - this.name = name; - return this; - } - - /** - * name of UDF - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "name of UDF") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public UDFInfoUpdate language(UDFLanguage language) { - - this.language = language; - return this; - } - - /** - * Get language - * @return language - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public UDFLanguage getLanguage() { - return language; - } - - - public void setLanguage(UDFLanguage language) { - this.language = language; - } - - - public UDFInfoUpdate version(String version) { - - this.version = version; - return this; - } - - /** - * Type-specific version - * @return version - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Type-specific version") - - public String getVersion() { - return version; - } - - - public void setVersion(String version) { - this.version = version; - } - - - public UDFInfoUpdate imageName(String imageName) { - - this.imageName = imageName; - return this; - } - - /** - * Docker image name to use for UDF - * @return imageName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Docker image name to use for UDF") - - public String getImageName() { - return imageName; - } - - - public void setImageName(String imageName) { - this.imageName = imageName; - } - - - public UDFInfoUpdate type(UDFType type) { - - this.type = type; - return this; - } - - /** - * Get type - * @return type - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public UDFType getType() { - return type; - } - - - public void setType(UDFType type) { - this.type = type; - } - - - public UDFInfoUpdate exec(String exec) { - - this.exec = exec; - return this; - } - - /** - * Type-specific executable text - * @return exec - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Type-specific executable text") - - public String getExec() { - return exec; - } - - - public void setExec(String exec) { - this.exec = exec; - } - - - public UDFInfoUpdate execRaw(String execRaw) { - - this.execRaw = execRaw; - return this; - } - - /** - * optional raw text to store of serialized function, used for showing in UI - * @return execRaw - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "optional raw text to store of serialized function, used for showing in UI") - - public String getExecRaw() { - return execRaw; - } - - - public void setExecRaw(String execRaw) { - this.execRaw = execRaw; - } - - - public UDFInfoUpdate readme(String readme) { - - this.readme = readme; - return this; - } - - /** - * Markdown readme of UDFs - * @return readme - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Markdown readme of UDFs") - - public String getReadme() { - return readme; - } - - - public void setReadme(String readme) { - this.readme = readme; - } - - - public UDFInfoUpdate licenseId(String licenseId) { - - this.licenseId = licenseId; - return this; - } - - /** - * License identifier from SPDX License List or Custom - * @return licenseId - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "License identifier from SPDX License List or Custom") - - public String getLicenseId() { - return licenseId; - } - - - public void setLicenseId(String licenseId) { - this.licenseId = licenseId; - } - - - public UDFInfoUpdate licenseText(String licenseText) { - - this.licenseText = licenseText; - return this; - } - - /** - * License text - * @return licenseText - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "License text") - - public String getLicenseText() { - return licenseText; - } - - - public void setLicenseText(String licenseText) { - this.licenseText = licenseText; - } - - - public UDFInfoUpdate tags(List tags) { - - this.tags = tags; - return this; - } - - public UDFInfoUpdate addTagsItem(String tagsItem) { - if (this.tags == null) { - this.tags = new ArrayList<>(); - } - this.tags.add(tagsItem); - return this; - } - - /** - * optional tags for UDF - * @return tags - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "optional tags for UDF") - - public List getTags() { - return tags; - } - - - public void setTags(List tags) { - this.tags = tags; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public UDFInfoUpdate putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - UDFInfoUpdate udFInfoUpdate = (UDFInfoUpdate) o; - return Objects.equals(this.name, udFInfoUpdate.name) && - Objects.equals(this.language, udFInfoUpdate.language) && - Objects.equals(this.version, udFInfoUpdate.version) && - Objects.equals(this.imageName, udFInfoUpdate.imageName) && - Objects.equals(this.type, udFInfoUpdate.type) && - Objects.equals(this.exec, udFInfoUpdate.exec) && - Objects.equals(this.execRaw, udFInfoUpdate.execRaw) && - Objects.equals(this.readme, udFInfoUpdate.readme) && - Objects.equals(this.licenseId, udFInfoUpdate.licenseId) && - Objects.equals(this.licenseText, udFInfoUpdate.licenseText) && - Objects.equals(this.tags, udFInfoUpdate.tags)&& - Objects.equals(this.additionalProperties, udFInfoUpdate.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(name, language, version, imageName, type, exec, execRaw, readme, licenseId, licenseText, tags, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class UDFInfoUpdate {\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" language: ").append(toIndentedString(language)).append("\n"); - sb.append(" version: ").append(toIndentedString(version)).append("\n"); - sb.append(" imageName: ").append(toIndentedString(imageName)).append("\n"); - sb.append(" type: ").append(toIndentedString(type)).append("\n"); - sb.append(" exec: ").append(toIndentedString(exec)).append("\n"); - sb.append(" execRaw: ").append(toIndentedString(execRaw)).append("\n"); - sb.append(" readme: ").append(toIndentedString(readme)).append("\n"); - sb.append(" licenseId: ").append(toIndentedString(licenseId)).append("\n"); - sb.append(" licenseText: ").append(toIndentedString(licenseText)).append("\n"); - sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("name"); - openapiFields.add("language"); - openapiFields.add("version"); - openapiFields.add("image_name"); - openapiFields.add("type"); - openapiFields.add("exec"); - openapiFields.add("exec_raw"); - openapiFields.add("readme"); - openapiFields.add("license_id"); - openapiFields.add("license_text"); - openapiFields.add("tags"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to UDFInfoUpdate - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (UDFInfoUpdate.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in UDFInfoUpdate is not found in the empty JSON string", UDFInfoUpdate.openapiRequiredFields.toString())); - } - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - if ((jsonObj.get("version") != null && !jsonObj.get("version").isJsonNull()) && !jsonObj.get("version").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `version` to be a primitive type in the JSON string but got `%s`", jsonObj.get("version").toString())); - } - if ((jsonObj.get("image_name") != null && !jsonObj.get("image_name").isJsonNull()) && !jsonObj.get("image_name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `image_name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("image_name").toString())); - } - if ((jsonObj.get("exec") != null && !jsonObj.get("exec").isJsonNull()) && !jsonObj.get("exec").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `exec` to be a primitive type in the JSON string but got `%s`", jsonObj.get("exec").toString())); - } - if ((jsonObj.get("exec_raw") != null && !jsonObj.get("exec_raw").isJsonNull()) && !jsonObj.get("exec_raw").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `exec_raw` to be a primitive type in the JSON string but got `%s`", jsonObj.get("exec_raw").toString())); - } - if ((jsonObj.get("readme") != null && !jsonObj.get("readme").isJsonNull()) && !jsonObj.get("readme").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `readme` to be a primitive type in the JSON string but got `%s`", jsonObj.get("readme").toString())); - } - if ((jsonObj.get("license_id") != null && !jsonObj.get("license_id").isJsonNull()) && !jsonObj.get("license_id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `license_id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("license_id").toString())); - } - if ((jsonObj.get("license_text") != null && !jsonObj.get("license_text").isJsonNull()) && !jsonObj.get("license_text").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `license_text` to be a primitive type in the JSON string but got `%s`", jsonObj.get("license_text").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("tags") != null && !jsonObj.get("tags").isJsonNull()) && !jsonObj.get("tags").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `tags` to be an array in the JSON string but got `%s`", jsonObj.get("tags").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!UDFInfoUpdate.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'UDFInfoUpdate' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(UDFInfoUpdate.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, UDFInfoUpdate value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public UDFInfoUpdate read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - UDFInfoUpdate instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of UDFInfoUpdate given an JSON string - * - * @param jsonString JSON string - * @return An instance of UDFInfoUpdate - * @throws IOException if the JSON string is invalid with respect to UDFInfoUpdate - */ - public static UDFInfoUpdate fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, UDFInfoUpdate.class); - } - - /** - * Convert an instance of UDFInfoUpdate to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFLanguage.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFLanguage.java deleted file mode 100644 index fe5172e..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFLanguage.java +++ /dev/null @@ -1,69 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * UDF Type - */ -@JsonAdapter(UDFLanguage.Adapter.class) -public enum UDFLanguage { - - PYTHON("python"), - - R("r"); - - private String value; - - UDFLanguage(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static UDFLanguage fromValue(String value) { - for (UDFLanguage b : UDFLanguage.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final UDFLanguage enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public UDFLanguage read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return UDFLanguage.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFSharing.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFSharing.java deleted file mode 100644 index 920f496..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFSharing.java +++ /dev/null @@ -1,342 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * details for sharing a given UDF - */ -@ApiModel(description = "details for sharing a given UDF") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class UDFSharing { - public static final String SERIALIZED_NAME_ACTIONS = "actions"; - @SerializedName(SERIALIZED_NAME_ACTIONS) - private List actions = null; - - public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; - @SerializedName(SERIALIZED_NAME_NAMESPACE) - private String namespace; - - public static final String SERIALIZED_NAME_NAMESPACE_TYPE = "namespace_type"; - @SerializedName(SERIALIZED_NAME_NAMESPACE_TYPE) - private String namespaceType; - - public UDFSharing() { - } - - public UDFSharing actions(List actions) { - - this.actions = actions; - return this; - } - - public UDFSharing addActionsItem(UDFActions actionsItem) { - if (this.actions == null) { - this.actions = new ArrayList<>(); - } - this.actions.add(actionsItem); - return this; - } - - /** - * List of permitted actions - * @return actions - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "[fetch, share]", value = "List of permitted actions") - - public List getActions() { - return actions; - } - - - public void setActions(List actions) { - this.actions = actions; - } - - - public UDFSharing namespace(String namespace) { - - this.namespace = namespace; - return this; - } - - /** - * namespace being granted array access can be a user or organization - * @return namespace - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "MyOrganization", value = "namespace being granted array access can be a user or organization") - - public String getNamespace() { - return namespace; - } - - - public void setNamespace(String namespace) { - this.namespace = namespace; - } - - - public UDFSharing namespaceType(String namespaceType) { - - this.namespaceType = namespaceType; - return this; - } - - /** - * details on if the namespace is a organization or user - * @return namespaceType - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "organization", value = "details on if the namespace is a organization or user") - - public String getNamespaceType() { - return namespaceType; - } - - - public void setNamespaceType(String namespaceType) { - this.namespaceType = namespaceType; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public UDFSharing putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - UDFSharing udFSharing = (UDFSharing) o; - return Objects.equals(this.actions, udFSharing.actions) && - Objects.equals(this.namespace, udFSharing.namespace) && - Objects.equals(this.namespaceType, udFSharing.namespaceType)&& - Objects.equals(this.additionalProperties, udFSharing.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(actions, namespace, namespaceType, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class UDFSharing {\n"); - sb.append(" actions: ").append(toIndentedString(actions)).append("\n"); - sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); - sb.append(" namespaceType: ").append(toIndentedString(namespaceType)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("actions"); - openapiFields.add("namespace"); - openapiFields.add("namespace_type"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to UDFSharing - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (UDFSharing.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in UDFSharing is not found in the empty JSON string", UDFSharing.openapiRequiredFields.toString())); - } - } - // ensure the json data is an array - if ((jsonObj.get("actions") != null && !jsonObj.get("actions").isJsonNull()) && !jsonObj.get("actions").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `actions` to be an array in the JSON string but got `%s`", jsonObj.get("actions").toString())); - } - if ((jsonObj.get("namespace") != null && !jsonObj.get("namespace").isJsonNull()) && !jsonObj.get("namespace").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace").toString())); - } - if ((jsonObj.get("namespace_type") != null && !jsonObj.get("namespace_type").isJsonNull()) && !jsonObj.get("namespace_type").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `namespace_type` to be a primitive type in the JSON string but got `%s`", jsonObj.get("namespace_type").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!UDFSharing.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'UDFSharing' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(UDFSharing.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, UDFSharing value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public UDFSharing read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - UDFSharing instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of UDFSharing given an JSON string - * - * @param jsonString JSON string - * @return An instance of UDFSharing - * @throws IOException if the JSON string is invalid with respect to UDFSharing - */ - public static UDFSharing fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, UDFSharing.class); - } - - /** - * Convert an instance of UDFSharing to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFSubarray.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFSubarray.java deleted file mode 100644 index 2b34b52..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFSubarray.java +++ /dev/null @@ -1,315 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Subarray bounds to query for a UDF to operate on - */ -@ApiModel(description = "Subarray bounds to query for a UDF to operate on") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class UDFSubarray { - public static final String SERIALIZED_NAME_LAYOUT = "layout"; - @SerializedName(SERIALIZED_NAME_LAYOUT) - private Layout layout; - - public static final String SERIALIZED_NAME_RANGES = "ranges"; - @SerializedName(SERIALIZED_NAME_RANGES) - private List ranges = null; - - public UDFSubarray() { - } - - public UDFSubarray layout(Layout layout) { - - this.layout = layout; - return this; - } - - /** - * Get layout - * @return layout - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Layout getLayout() { - return layout; - } - - - public void setLayout(Layout layout) { - this.layout = layout; - } - - - public UDFSubarray ranges(List ranges) { - - this.ranges = ranges; - return this; - } - - public UDFSubarray addRangesItem(UDFSubarrayRange rangesItem) { - if (this.ranges == null) { - this.ranges = new ArrayList<>(); - } - this.ranges.add(rangesItem); - return this; - } - - /** - * List of ranges, - * @return ranges - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "List of ranges,") - - public List getRanges() { - return ranges; - } - - - public void setRanges(List ranges) { - this.ranges = ranges; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public UDFSubarray putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - UDFSubarray udFSubarray = (UDFSubarray) o; - return Objects.equals(this.layout, udFSubarray.layout) && - Objects.equals(this.ranges, udFSubarray.ranges)&& - Objects.equals(this.additionalProperties, udFSubarray.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(layout, ranges, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class UDFSubarray {\n"); - sb.append(" layout: ").append(toIndentedString(layout)).append("\n"); - sb.append(" ranges: ").append(toIndentedString(ranges)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("layout"); - openapiFields.add("ranges"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to UDFSubarray - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (UDFSubarray.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in UDFSubarray is not found in the empty JSON string", UDFSubarray.openapiRequiredFields.toString())); - } - } - JsonArray jsonArrayranges = jsonObj.getAsJsonArray("ranges"); - if (jsonArrayranges != null) { - // ensure the json data is an array - if (!jsonObj.get("ranges").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `ranges` to be an array in the JSON string but got `%s`", jsonObj.get("ranges").toString())); - } - - // validate the optional field `ranges` (array) - for (int i = 0; i < jsonArrayranges.size(); i++) { - UDFSubarrayRange.validateJsonObject(jsonArrayranges.get(i).getAsJsonObject()); - }; - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!UDFSubarray.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'UDFSubarray' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(UDFSubarray.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, UDFSubarray value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public UDFSubarray read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - UDFSubarray instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of UDFSubarray given an JSON string - * - * @param jsonString JSON string - * @return An instance of UDFSubarray - * @throws IOException if the JSON string is invalid with respect to UDFSubarray - */ - public static UDFSubarray fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, UDFSubarray.class); - } - - /** - * Convert an instance of UDFSubarray to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFSubarrayRange.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFSubarrayRange.java deleted file mode 100644 index 021ffd6..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFSubarrayRange.java +++ /dev/null @@ -1,330 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * A dimension range to query - */ -@ApiModel(description = "A dimension range to query") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class UDFSubarrayRange { - public static final String SERIALIZED_NAME_DIMENSION_ID = "dimension_id"; - @SerializedName(SERIALIZED_NAME_DIMENSION_ID) - private Integer dimensionId; - - public static final String SERIALIZED_NAME_RANGE_START = "range_start"; - @SerializedName(SERIALIZED_NAME_RANGE_START) - private DimensionCoordinate rangeStart; - - public static final String SERIALIZED_NAME_RANGE_END = "range_end"; - @SerializedName(SERIALIZED_NAME_RANGE_END) - private DimensionCoordinate rangeEnd; - - public UDFSubarrayRange() { - } - - public UDFSubarrayRange dimensionId(Integer dimensionId) { - - this.dimensionId = dimensionId; - return this; - } - - /** - * The dimension index - * @return dimensionId - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The dimension index") - - public Integer getDimensionId() { - return dimensionId; - } - - - public void setDimensionId(Integer dimensionId) { - this.dimensionId = dimensionId; - } - - - public UDFSubarrayRange rangeStart(DimensionCoordinate rangeStart) { - - this.rangeStart = rangeStart; - return this; - } - - /** - * Get rangeStart - * @return rangeStart - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public DimensionCoordinate getRangeStart() { - return rangeStart; - } - - - public void setRangeStart(DimensionCoordinate rangeStart) { - this.rangeStart = rangeStart; - } - - - public UDFSubarrayRange rangeEnd(DimensionCoordinate rangeEnd) { - - this.rangeEnd = rangeEnd; - return this; - } - - /** - * Get rangeEnd - * @return rangeEnd - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public DimensionCoordinate getRangeEnd() { - return rangeEnd; - } - - - public void setRangeEnd(DimensionCoordinate rangeEnd) { - this.rangeEnd = rangeEnd; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public UDFSubarrayRange putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - UDFSubarrayRange udFSubarrayRange = (UDFSubarrayRange) o; - return Objects.equals(this.dimensionId, udFSubarrayRange.dimensionId) && - Objects.equals(this.rangeStart, udFSubarrayRange.rangeStart) && - Objects.equals(this.rangeEnd, udFSubarrayRange.rangeEnd)&& - Objects.equals(this.additionalProperties, udFSubarrayRange.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(dimensionId, rangeStart, rangeEnd, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class UDFSubarrayRange {\n"); - sb.append(" dimensionId: ").append(toIndentedString(dimensionId)).append("\n"); - sb.append(" rangeStart: ").append(toIndentedString(rangeStart)).append("\n"); - sb.append(" rangeEnd: ").append(toIndentedString(rangeEnd)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("dimension_id"); - openapiFields.add("range_start"); - openapiFields.add("range_end"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to UDFSubarrayRange - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (UDFSubarrayRange.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in UDFSubarrayRange is not found in the empty JSON string", UDFSubarrayRange.openapiRequiredFields.toString())); - } - } - // validate the optional field `range_start` - if (jsonObj.get("range_start") != null && !jsonObj.get("range_start").isJsonNull()) { - DimensionCoordinate.validateJsonObject(jsonObj.getAsJsonObject("range_start")); - } - // validate the optional field `range_end` - if (jsonObj.get("range_end") != null && !jsonObj.get("range_end").isJsonNull()) { - DimensionCoordinate.validateJsonObject(jsonObj.getAsJsonObject("range_end")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!UDFSubarrayRange.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'UDFSubarrayRange' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(UDFSubarrayRange.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, UDFSubarrayRange value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public UDFSubarrayRange read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - UDFSubarrayRange instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of UDFSubarrayRange given an JSON string - * - * @param jsonString JSON string - * @return An instance of UDFSubarrayRange - * @throws IOException if the JSON string is invalid with respect to UDFSubarrayRange - */ - public static UDFSubarrayRange fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, UDFSubarrayRange.class); - } - - /** - * Convert an instance of UDFSubarrayRange to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFType.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFType.java deleted file mode 100644 index dcbd37c..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/UDFType.java +++ /dev/null @@ -1,71 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.io.IOException; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -/** - * UDF Type - */ -@JsonAdapter(UDFType.Adapter.class) -public enum UDFType { - - MULTI_ARRAY("multi_array"), - - SINGLE_ARRAY("single_array"), - - GENERIC("generic"); - - private String value; - - UDFType(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static UDFType fromValue(String value) { - for (UDFType b : UDFType.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final UDFType enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public UDFType read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return UDFType.fromValue(value); - } - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/User.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/User.java deleted file mode 100644 index 6e3e97e..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/User.java +++ /dev/null @@ -1,829 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import org.openapitools.jackson.nullable.JsonNullable; - -import com.google.gson.Gson; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * User - */ -@ApiModel(description = "User") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class User { - public static final String SERIALIZED_NAME_ID = "id"; - @SerializedName(SERIALIZED_NAME_ID) - private String id; - - public static final String SERIALIZED_NAME_USERNAME = "username"; - @SerializedName(SERIALIZED_NAME_USERNAME) - private String username; - - public static final String SERIALIZED_NAME_PASSWORD = "password"; - @SerializedName(SERIALIZED_NAME_PASSWORD) - private String password; - - public static final String SERIALIZED_NAME_NAME = "name"; - @SerializedName(SERIALIZED_NAME_NAME) - private String name; - - public static final String SERIALIZED_NAME_EMAIL = "email"; - @SerializedName(SERIALIZED_NAME_EMAIL) - private String email; - - public static final String SERIALIZED_NAME_IS_VALID_EMAIL = "is_valid_email"; - @SerializedName(SERIALIZED_NAME_IS_VALID_EMAIL) - private Boolean isValidEmail; - - public static final String SERIALIZED_NAME_STRIPE_CONNECT = "stripe_connect"; - @SerializedName(SERIALIZED_NAME_STRIPE_CONNECT) - private Boolean stripeConnect; - - public static final String SERIALIZED_NAME_COMPANY = "company"; - @SerializedName(SERIALIZED_NAME_COMPANY) - private String company; - - public static final String SERIALIZED_NAME_LOGO = "logo"; - @SerializedName(SERIALIZED_NAME_LOGO) - private String logo; - - public static final String SERIALIZED_NAME_TIMEZONE = "timezone"; - @SerializedName(SERIALIZED_NAME_TIMEZONE) - private String timezone; - - public static final String SERIALIZED_NAME_ORGANIZATIONS = "organizations"; - @SerializedName(SERIALIZED_NAME_ORGANIZATIONS) - private List organizations = null; - - public static final String SERIALIZED_NAME_ALLOWED_ACTIONS = "allowed_actions"; - @SerializedName(SERIALIZED_NAME_ALLOWED_ACTIONS) - private List allowedActions = null; - - public static final String SERIALIZED_NAME_ENABLED_FEATURES = "enabled_features"; - @SerializedName(SERIALIZED_NAME_ENABLED_FEATURES) - private List enabledFeatures = null; - - public static final String SERIALIZED_NAME_UNPAID_SUBSCRIPTION = "unpaid_subscription"; - @SerializedName(SERIALIZED_NAME_UNPAID_SUBSCRIPTION) - private Boolean unpaidSubscription; - - public static final String SERIALIZED_NAME_DEFAULT_S3_PATH = "default_s3_path"; - @SerializedName(SERIALIZED_NAME_DEFAULT_S3_PATH) - private String defaultS3Path; - - public static final String SERIALIZED_NAME_DEFAULT_S3_PATH_CREDENTIALS_NAME = "default_s3_path_credentials_name"; - @SerializedName(SERIALIZED_NAME_DEFAULT_S3_PATH_CREDENTIALS_NAME) - private Object defaultS3PathCredentialsName; - - public static final String SERIALIZED_NAME_ASSET_LOCATIONS = "asset_locations"; - @SerializedName(SERIALIZED_NAME_ASSET_LOCATIONS) - private AssetLocations assetLocations; - - public static final String SERIALIZED_NAME_DEFAULT_NAMESPACE_CHARGED = "default_namespace_charged"; - @SerializedName(SERIALIZED_NAME_DEFAULT_NAMESPACE_CHARGED) - private String defaultNamespaceCharged; - - public User() { - } - - - public User( - Boolean isValidEmail, - Boolean stripeConnect, - List organizations, - List enabledFeatures, - Boolean unpaidSubscription - ) { - this(); - this.isValidEmail = isValidEmail; - this.stripeConnect = stripeConnect; - this.organizations = organizations; - this.enabledFeatures = enabledFeatures; - this.unpaidSubscription = unpaidSubscription; - } - - public User id(String id) { - - this.id = id; - return this; - } - - /** - * unique ID of user - * @return id - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "00000000-0000-0000-0000-000000000000", value = "unique ID of user") - - public String getId() { - return id; - } - - - public void setId(String id) { - this.id = id; - } - - - public User username(String username) { - - this.username = username; - return this; - } - - /** - * username must be unique - * @return username - **/ - @javax.annotation.Nonnull - @ApiModelProperty(example = "username", required = true, value = "username must be unique") - - public String getUsername() { - return username; - } - - - public void setUsername(String username) { - this.username = username; - } - - - public User password(String password) { - - this.password = password; - return this; - } - - /** - * password - * @return password - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "password", value = "password") - - public String getPassword() { - return password; - } - - - public void setPassword(String password) { - this.password = password; - } - - - public User name(String name) { - - this.name = name; - return this; - } - - /** - * the user's full, real name - * @return name - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "Jane Doe", value = "the user's full, real name") - - public String getName() { - return name; - } - - - public void setName(String name) { - this.name = name; - } - - - public User email(String email) { - - this.email = email; - return this; - } - - /** - * the user's email - * @return email - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "jane.doe@example.com", value = "the user's email") - - public String getEmail() { - return email; - } - - - public void setEmail(String email) { - this.email = email; - } - - - /** - * user's email is validated to be correct - * @return isValidEmail - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "false", value = "user's email is validated to be correct") - - public Boolean getIsValidEmail() { - return isValidEmail; - } - - - - - /** - * Denotes that the user is able to apply pricing to arrays by means of Stripe Connect - * @return stripeConnect - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "false", value = "Denotes that the user is able to apply pricing to arrays by means of Stripe Connect") - - public Boolean getStripeConnect() { - return stripeConnect; - } - - - - - public User company(String company) { - - this.company = company; - return this; - } - - /** - * the user's company - * @return company - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "TileDB", value = "the user's company") - - public String getCompany() { - return company; - } - - - public void setCompany(String company) { - this.company = company; - } - - - public User logo(String logo) { - - this.logo = logo; - return this; - } - - /** - * the user's logo - * @return logo - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "the user's logo") - - public String getLogo() { - return logo; - } - - - public void setLogo(String logo) { - this.logo = logo; - } - - - public User timezone(String timezone) { - - this.timezone = timezone; - return this; - } - - /** - * Get timezone - * @return timezone - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "Europe/Athens", value = "") - - public String getTimezone() { - return timezone; - } - - - public void setTimezone(String timezone) { - this.timezone = timezone; - } - - - /** - * Array of organizations a user is part of and their roles - * @return organizations - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Array of organizations a user is part of and their roles") - - public List getOrganizations() { - return organizations; - } - - - - - public User allowedActions(List allowedActions) { - - this.allowedActions = allowedActions; - return this; - } - - public User addAllowedActionsItem(NamespaceActions allowedActionsItem) { - if (this.allowedActions == null) { - this.allowedActions = new ArrayList<>(); - } - this.allowedActions.add(allowedActionsItem); - return this; - } - - /** - * list of actions user is allowed to do on this organization - * @return allowedActions - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "list of actions user is allowed to do on this organization") - - public List getAllowedActions() { - return allowedActions; - } - - - public void setAllowedActions(List allowedActions) { - this.allowedActions = allowedActions; - } - - - /** - * List of extra/optional/beta features to enable for namespace - * @return enabledFeatures - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "List of extra/optional/beta features to enable for namespace") - - public List getEnabledFeatures() { - return enabledFeatures; - } - - - - - /** - * A notice that the user has an unpaid subscription - * @return unpaidSubscription - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "A notice that the user has an unpaid subscription") - - public Boolean getUnpaidSubscription() { - return unpaidSubscription; - } - - - - - public User defaultS3Path(String defaultS3Path) { - - this.defaultS3Path = defaultS3Path; - return this; - } - - /** - * The default location to store newly-created notebooks and other assets like UDFs. The name `default_s3_path` is a legacy holdover; it may refer to any supported storage location. - * @return defaultS3Path - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The default location to store newly-created notebooks and other assets like UDFs. The name `default_s3_path` is a legacy holdover; it may refer to any supported storage location. ") - - public String getDefaultS3Path() { - return defaultS3Path; - } - - - public void setDefaultS3Path(String defaultS3Path) { - this.defaultS3Path = defaultS3Path; - } - - - public User defaultS3PathCredentialsName(Object defaultS3PathCredentialsName) { - - this.defaultS3PathCredentialsName = defaultS3PathCredentialsName; - return this; - } - - /** - * The name of the credentials used to create and access files in the `default_s3_path`, if needed. - * @return defaultS3PathCredentialsName - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "The name of the credentials used to create and access files in the `default_s3_path`, if needed. ") - - public Object getDefaultS3PathCredentialsName() { - return defaultS3PathCredentialsName; - } - - - public void setDefaultS3PathCredentialsName(Object defaultS3PathCredentialsName) { - this.defaultS3PathCredentialsName = defaultS3PathCredentialsName; - } - - - public User assetLocations(AssetLocations assetLocations) { - - this.assetLocations = assetLocations; - return this; - } - - /** - * Get assetLocations - * @return assetLocations - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public AssetLocations getAssetLocations() { - return assetLocations; - } - - - public void setAssetLocations(AssetLocations assetLocations) { - this.assetLocations = assetLocations; - } - - - public User defaultNamespaceCharged(String defaultNamespaceCharged) { - - this.defaultNamespaceCharged = defaultNamespaceCharged; - return this; - } - - /** - * Override the default namespace charged for actions when no namespace is specified - * @return defaultNamespaceCharged - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "Override the default namespace charged for actions when no namespace is specified") - - public String getDefaultNamespaceCharged() { - return defaultNamespaceCharged; - } - - - public void setDefaultNamespaceCharged(String defaultNamespaceCharged) { - this.defaultNamespaceCharged = defaultNamespaceCharged; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public User putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - User user = (User) o; - return Objects.equals(this.id, user.id) && - Objects.equals(this.username, user.username) && - Objects.equals(this.password, user.password) && - Objects.equals(this.name, user.name) && - Objects.equals(this.email, user.email) && - Objects.equals(this.isValidEmail, user.isValidEmail) && - Objects.equals(this.stripeConnect, user.stripeConnect) && - Objects.equals(this.company, user.company) && - Objects.equals(this.logo, user.logo) && - Objects.equals(this.timezone, user.timezone) && - Objects.equals(this.organizations, user.organizations) && - Objects.equals(this.allowedActions, user.allowedActions) && - Objects.equals(this.enabledFeatures, user.enabledFeatures) && - Objects.equals(this.unpaidSubscription, user.unpaidSubscription) && - Objects.equals(this.defaultS3Path, user.defaultS3Path) && - Objects.equals(this.defaultS3PathCredentialsName, user.defaultS3PathCredentialsName) && - Objects.equals(this.assetLocations, user.assetLocations) && - Objects.equals(this.defaultNamespaceCharged, user.defaultNamespaceCharged)&& - Objects.equals(this.additionalProperties, user.additionalProperties); - } - - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); - } - - @Override - public int hashCode() { - return Objects.hash(id, username, password, name, email, isValidEmail, stripeConnect, company, logo, timezone, organizations, allowedActions, enabledFeatures, unpaidSubscription, defaultS3Path, defaultS3PathCredentialsName, assetLocations, defaultNamespaceCharged, additionalProperties); - } - - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class User {\n"); - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" username: ").append(toIndentedString(username)).append("\n"); - sb.append(" password: ").append(toIndentedString(password)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" email: ").append(toIndentedString(email)).append("\n"); - sb.append(" isValidEmail: ").append(toIndentedString(isValidEmail)).append("\n"); - sb.append(" stripeConnect: ").append(toIndentedString(stripeConnect)).append("\n"); - sb.append(" company: ").append(toIndentedString(company)).append("\n"); - sb.append(" logo: ").append(toIndentedString(logo)).append("\n"); - sb.append(" timezone: ").append(toIndentedString(timezone)).append("\n"); - sb.append(" organizations: ").append(toIndentedString(organizations)).append("\n"); - sb.append(" allowedActions: ").append(toIndentedString(allowedActions)).append("\n"); - sb.append(" enabledFeatures: ").append(toIndentedString(enabledFeatures)).append("\n"); - sb.append(" unpaidSubscription: ").append(toIndentedString(unpaidSubscription)).append("\n"); - sb.append(" defaultS3Path: ").append(toIndentedString(defaultS3Path)).append("\n"); - sb.append(" defaultS3PathCredentialsName: ").append(toIndentedString(defaultS3PathCredentialsName)).append("\n"); - sb.append(" assetLocations: ").append(toIndentedString(assetLocations)).append("\n"); - sb.append(" defaultNamespaceCharged: ").append(toIndentedString(defaultNamespaceCharged)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("id"); - openapiFields.add("username"); - openapiFields.add("password"); - openapiFields.add("name"); - openapiFields.add("email"); - openapiFields.add("is_valid_email"); - openapiFields.add("stripe_connect"); - openapiFields.add("company"); - openapiFields.add("logo"); - openapiFields.add("timezone"); - openapiFields.add("organizations"); - openapiFields.add("allowed_actions"); - openapiFields.add("enabled_features"); - openapiFields.add("unpaid_subscription"); - openapiFields.add("default_s3_path"); - openapiFields.add("default_s3_path_credentials_name"); - openapiFields.add("asset_locations"); - openapiFields.add("default_namespace_charged"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - openapiRequiredFields.add("username"); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to User - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (User.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in User is not found in the empty JSON string", User.openapiRequiredFields.toString())); - } - } - - // check to make sure all required properties/fields are present in the JSON string - for (String requiredField : User.openapiRequiredFields) { - if (jsonObj.get(requiredField) == null) { - throw new IllegalArgumentException(String.format("The required field `%s` is not found in the JSON string: %s", requiredField, jsonObj.toString())); - } - } - if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) && !jsonObj.get("id").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("id").toString())); - } - if ((jsonObj.get("username") != null && !jsonObj.get("username").isJsonNull()) && !jsonObj.get("username").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `username` to be a primitive type in the JSON string but got `%s`", jsonObj.get("username").toString())); - } - if ((jsonObj.get("password") != null && !jsonObj.get("password").isJsonNull()) && !jsonObj.get("password").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `password` to be a primitive type in the JSON string but got `%s`", jsonObj.get("password").toString())); - } - if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); - } - if ((jsonObj.get("email") != null && !jsonObj.get("email").isJsonNull()) && !jsonObj.get("email").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `email` to be a primitive type in the JSON string but got `%s`", jsonObj.get("email").toString())); - } - if ((jsonObj.get("company") != null && !jsonObj.get("company").isJsonNull()) && !jsonObj.get("company").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `company` to be a primitive type in the JSON string but got `%s`", jsonObj.get("company").toString())); - } - if ((jsonObj.get("logo") != null && !jsonObj.get("logo").isJsonNull()) && !jsonObj.get("logo").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `logo` to be a primitive type in the JSON string but got `%s`", jsonObj.get("logo").toString())); - } - if ((jsonObj.get("timezone") != null && !jsonObj.get("timezone").isJsonNull()) && !jsonObj.get("timezone").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `timezone` to be a primitive type in the JSON string but got `%s`", jsonObj.get("timezone").toString())); - } - JsonArray jsonArrayorganizations = jsonObj.getAsJsonArray("organizations"); - if (jsonArrayorganizations != null) { - // ensure the json data is an array - if (!jsonObj.get("organizations").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `organizations` to be an array in the JSON string but got `%s`", jsonObj.get("organizations").toString())); - } - - // validate the optional field `organizations` (array) - for (int i = 0; i < jsonArrayorganizations.size(); i++) { - OrganizationUser.validateJsonObject(jsonArrayorganizations.get(i).getAsJsonObject()); - }; - } - // ensure the json data is an array - if ((jsonObj.get("allowed_actions") != null && !jsonObj.get("allowed_actions").isJsonNull()) && !jsonObj.get("allowed_actions").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `allowed_actions` to be an array in the JSON string but got `%s`", jsonObj.get("allowed_actions").toString())); - } - // ensure the json data is an array - if ((jsonObj.get("enabled_features") != null && !jsonObj.get("enabled_features").isJsonNull()) && !jsonObj.get("enabled_features").isJsonArray()) { - throw new IllegalArgumentException(String.format("Expected the field `enabled_features` to be an array in the JSON string but got `%s`", jsonObj.get("enabled_features").toString())); - } - if ((jsonObj.get("default_s3_path") != null && !jsonObj.get("default_s3_path").isJsonNull()) && !jsonObj.get("default_s3_path").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `default_s3_path` to be a primitive type in the JSON string but got `%s`", jsonObj.get("default_s3_path").toString())); - } - // validate the optional field `asset_locations` - if (jsonObj.get("asset_locations") != null && !jsonObj.get("asset_locations").isJsonNull()) { - AssetLocations.validateJsonObject(jsonObj.getAsJsonObject("asset_locations")); - } - if ((jsonObj.get("default_namespace_charged") != null && !jsonObj.get("default_namespace_charged").isJsonNull()) && !jsonObj.get("default_namespace_charged").isJsonPrimitive()) { - throw new IllegalArgumentException(String.format("Expected the field `default_namespace_charged` to be a primitive type in the JSON string but got `%s`", jsonObj.get("default_namespace_charged").toString())); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!User.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'User' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(User.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, User value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public User read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - User instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of User given an JSON string - * - * @param jsonString JSON string - * @return An instance of User - * @throws IOException if the JSON string is invalid with respect to User - */ - public static User fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, User.class); - } - - /** - * Convert an instance of User to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Writer.java b/src/main/java/io/tiledb/cloud/rest_api/v1/model/Writer.java deleted file mode 100644 index b219472..0000000 --- a/src/main/java/io/tiledb/cloud/rest_api/v1/model/Writer.java +++ /dev/null @@ -1,354 +0,0 @@ -/* - * TileDB Storage Platform API - * TileDB Storage Platform REST API - * - * The version of the OpenAPI document: 2.2.19 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package io.tiledb.cloud.rest_api.v1.model; - -import java.util.Objects; - -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.TypeAdapterFactory; -import com.google.gson.reflect.TypeToken; - -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import io.tiledb.cloud.rest_api.v1.JSON; - -/** - * Writer - */ -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-02T12:25:58.319138+03:00[Europe/Athens]") -public class Writer { - public static final String SERIALIZED_NAME_CHECK_COORD_DUPS = "checkCoordDups"; - @SerializedName(SERIALIZED_NAME_CHECK_COORD_DUPS) - private Boolean checkCoordDups; - - public static final String SERIALIZED_NAME_CHECK_COORD_O_O_B = "checkCoordOOB"; - @SerializedName(SERIALIZED_NAME_CHECK_COORD_O_O_B) - private Boolean checkCoordOOB; - - public static final String SERIALIZED_NAME_DEDUP_COORDS = "dedupCoords"; - @SerializedName(SERIALIZED_NAME_DEDUP_COORDS) - private Boolean dedupCoords; - - public static final String SERIALIZED_NAME_SUBARRAY = "subarray"; - @SerializedName(SERIALIZED_NAME_SUBARRAY) - private DomainArray subarray; - - public Writer() { - } - - public Writer checkCoordDups(Boolean checkCoordDups) { - - this.checkCoordDups = checkCoordDups; - return this; - } - - /** - * Get checkCoordDups - * @return checkCoordDups - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Boolean getCheckCoordDups() { - return checkCoordDups; - } - - - public void setCheckCoordDups(Boolean checkCoordDups) { - this.checkCoordDups = checkCoordDups; - } - - - public Writer checkCoordOOB(Boolean checkCoordOOB) { - - this.checkCoordOOB = checkCoordOOB; - return this; - } - - /** - * Get checkCoordOOB - * @return checkCoordOOB - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Boolean getCheckCoordOOB() { - return checkCoordOOB; - } - - - public void setCheckCoordOOB(Boolean checkCoordOOB) { - this.checkCoordOOB = checkCoordOOB; - } - - - public Writer dedupCoords(Boolean dedupCoords) { - - this.dedupCoords = dedupCoords; - return this; - } - - /** - * Get dedupCoords - * @return dedupCoords - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Boolean getDedupCoords() { - return dedupCoords; - } - - - public void setDedupCoords(Boolean dedupCoords) { - this.dedupCoords = dedupCoords; - } - - - public Writer subarray(DomainArray subarray) { - - this.subarray = subarray; - return this; - } - - /** - * Get subarray - * @return subarray - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public DomainArray getSubarray() { - return subarray; - } - - - public void setSubarray(DomainArray subarray) { - this.subarray = subarray; - } - - /** - * A container for additional, undeclared properties. - * This is a holder for any undeclared properties as specified with - * the 'additionalProperties' keyword in the OAS document. - */ - private Map additionalProperties; - - /** - * Set the additional (undeclared) property with the specified name and value. - * If the property does not already exist, create it otherwise replace it. - */ - public Writer putAdditionalProperty(String key, Object value) { - if (this.additionalProperties == null) { - this.additionalProperties = new HashMap(); - } - this.additionalProperties.put(key, value); - return this; - } - - /** - * Return the additional (undeclared) property. - */ - public Map getAdditionalProperties() { - return additionalProperties; - } - - /** - * Return the additional (undeclared) property with the specified name. - */ - public Object getAdditionalProperty(String key) { - if (this.additionalProperties == null) { - return null; - } - return this.additionalProperties.get(key); - } - - - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Writer writer = (Writer) o; - return Objects.equals(this.checkCoordDups, writer.checkCoordDups) && - Objects.equals(this.checkCoordOOB, writer.checkCoordOOB) && - Objects.equals(this.dedupCoords, writer.dedupCoords) && - Objects.equals(this.subarray, writer.subarray)&& - Objects.equals(this.additionalProperties, writer.additionalProperties); - } - - @Override - public int hashCode() { - return Objects.hash(checkCoordDups, checkCoordOOB, dedupCoords, subarray, additionalProperties); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Writer {\n"); - sb.append(" checkCoordDups: ").append(toIndentedString(checkCoordDups)).append("\n"); - sb.append(" checkCoordOOB: ").append(toIndentedString(checkCoordOOB)).append("\n"); - sb.append(" dedupCoords: ").append(toIndentedString(dedupCoords)).append("\n"); - sb.append(" subarray: ").append(toIndentedString(subarray)).append("\n"); - sb.append(" additionalProperties: ").append(toIndentedString(additionalProperties)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - - - public static HashSet openapiFields; - public static HashSet openapiRequiredFields; - - static { - // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(); - openapiFields.add("checkCoordDups"); - openapiFields.add("checkCoordOOB"); - openapiFields.add("dedupCoords"); - openapiFields.add("subarray"); - - // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(); - } - - /** - * Validates the JSON Object and throws an exception if issues found - * - * @param jsonObj JSON Object - * @throws IOException if the JSON Object is invalid with respect to Writer - */ - public static void validateJsonObject(JsonObject jsonObj) throws IOException { - if (jsonObj == null) { - if (Writer.openapiRequiredFields.isEmpty()) { - return; - } else { // has required fields - throw new IllegalArgumentException(String.format("The required field(s) %s in Writer is not found in the empty JSON string", Writer.openapiRequiredFields.toString())); - } - } - // validate the optional field `subarray` - if (jsonObj.get("subarray") != null && !jsonObj.get("subarray").isJsonNull()) { - DomainArray.validateJsonObject(jsonObj.getAsJsonObject("subarray")); - } - } - - public static class CustomTypeAdapterFactory implements TypeAdapterFactory { - @SuppressWarnings("unchecked") - @Override - public TypeAdapter create(Gson gson, TypeToken type) { - if (!Writer.class.isAssignableFrom(type.getRawType())) { - return null; // this class only serializes 'Writer' and its subtypes - } - final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); - final TypeAdapter thisAdapter - = gson.getDelegateAdapter(this, TypeToken.get(Writer.class)); - - return (TypeAdapter) new TypeAdapter() { - @Override - public void write(JsonWriter out, Writer value) throws IOException { - JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); - obj.remove("additionalProperties"); - // serialize additonal properties - if (value.getAdditionalProperties() != null) { - for (Map.Entry entry : value.getAdditionalProperties().entrySet()) { - if (entry.getValue() instanceof String) - obj.addProperty(entry.getKey(), (String) entry.getValue()); - else if (entry.getValue() instanceof Number) - obj.addProperty(entry.getKey(), (Number) entry.getValue()); - else if (entry.getValue() instanceof Boolean) - obj.addProperty(entry.getKey(), (Boolean) entry.getValue()); - else if (entry.getValue() instanceof Character) - obj.addProperty(entry.getKey(), (Character) entry.getValue()); - else { - obj.add(entry.getKey(), gson.toJsonTree(entry.getValue()).getAsJsonObject()); - } - } - } - elementAdapter.write(out, obj); - } - - @Override - public Writer read(JsonReader in) throws IOException { - JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject(); - validateJsonObject(jsonObj); - // store additional fields in the deserialized instance - Writer instance = thisAdapter.fromJsonTree(jsonObj); - for (Map.Entry entry : jsonObj.entrySet()) { - if (!openapiFields.contains(entry.getKey())) { - if (entry.getValue().isJsonPrimitive()) { // primitive type - if (entry.getValue().getAsJsonPrimitive().isString()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsString()); - else if (entry.getValue().getAsJsonPrimitive().isNumber()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsNumber()); - else if (entry.getValue().getAsJsonPrimitive().isBoolean()) - instance.putAdditionalProperty(entry.getKey(), entry.getValue().getAsBoolean()); - else - throw new IllegalArgumentException(String.format("The field `%s` has unknown primitive type. Value: %s", entry.getKey(), entry.getValue().toString())); - } else { // non-primitive type - instance.putAdditionalProperty(entry.getKey(), gson.fromJson(entry.getValue(), HashMap.class)); - } - } - } - return instance; - } - - }.nullSafe(); - } - } - - /** - * Create an instance of Writer given an JSON string - * - * @param jsonString JSON string - * @return An instance of Writer - * @throws IOException if the JSON string is invalid with respect to Writer - */ - public static Writer fromJson(String jsonString) throws IOException { - return JSON.getGson().fromJson(jsonString, Writer.class); - } - - /** - * Convert an instance of Writer to an JSON string - * - * @return JSON string - */ - public String toJson() { - return JSON.getGson().toJson(this); - } -} - diff --git a/src/main/java/io/tiledb/cloud/rest_api/v2/ApiException.java b/src/main/java/io/tiledb/cloud/rest_api/v2/ApiException.java index ab7eb58..0e12b5b 100644 --- a/src/main/java/io/tiledb/cloud/rest_api/v2/ApiException.java +++ b/src/main/java/io/tiledb/cloud/rest_api/v2/ApiException.java @@ -23,10 +23,6 @@ */ @SuppressWarnings("serial") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2024-07-02T18:54:48.746612+03:00[Europe/Athens]") -/** - * @deprecated This class is now moved to io.tiledb.cloud.rest_api.v1.auth - */ -@Deprecated public class ApiException extends Exception { private int code = 0; private Map> responseHeaders = null;