From 3a7bf3e36b03af01fdabd2c554b7931d70b69dd0 Mon Sep 17 00:00:00 2001 From: Ivan Gomes Date: Sat, 21 Mar 2020 15:24:06 -0700 Subject: [PATCH 1/2] ST5AS-26 Regenerate for SysML-v2-API-Services 2020-03-rc2 --- .idea/.gitignore | 2 + .idea/.name | 1 + .idea/codeStyles/codeStyleConfig.xml | 5 + .idea/gradle.xml | 21 + .idea/jarRepositories.xml | 20 + .idea/misc.xml | 5 + .idea/sbt.xml | 6 + .idea/vcs.xml | 6 + .openapi-generator/VERSION | 2 +- LICENSE | 165 ----- README.md | 48 +- build-shadow.gradle | 2 +- build.gradle | 8 +- build.sbt | 6 +- docs/Commit.md | 23 + docs/CommitApi.md | 271 ++++++++ docs/Element.md | 1 - docs/ElementApi.md | 233 +------ docs/ElementIdentity.md | 21 + docs/ElementVersion.md | 23 + docs/Project.md | 12 +- docs/ProjectApi.md | 72 +-- docs/Record.md | 12 + docs/Relationship.md | 1 - docs/RelationshipAllOf.md | 13 - docs/RelationshipApi.md | 211 +------ gradle/wrapper/gradle-wrapper.jar | Bin 55190 -> 58702 bytes gradle/wrapper/gradle-wrapper.properties | 2 +- gradlew | 51 +- gradlew.bat | 18 +- pom.xml | 6 +- src/main/java/org/omg/sysml/ApiClient.java | 107 ++-- .../java/org/omg/sysml/api/CommitApi.java | 582 ++++++++++++++++++ .../java/org/omg/sysml/api/ElementApi.java | 484 +++------------ .../java/org/omg/sysml/api/ProjectApi.java | 168 ++--- .../org/omg/sysml/api/RelationshipApi.java | 419 ++----------- .../java/org/omg/sysml/auth/ApiKeyAuth.java | 4 +- .../org/omg/sysml/auth/Authentication.java | 3 +- .../org/omg/sysml/auth/HttpBasicAuth.java | 2 +- .../org/omg/sysml/auth/HttpBearerAuth.java | 2 +- src/main/java/org/omg/sysml/model/Commit.java | 244 ++++++++ .../java/org/omg/sysml/model/Element.java | 35 +- .../org/omg/sysml/model/ElementIdentity.java | 174 ++++++ .../org/omg/sysml/model/ElementVersion.java | 234 +++++++ src/main/java/org/omg/sysml/model/Error.java | 1 - .../java/org/omg/sysml/model/Identified.java | 1 - .../java/org/omg/sysml/model/Project.java | 104 +++- src/main/java/org/omg/sysml/model/Record.java | 100 +++ .../org/omg/sysml/model/Relationship.java | 38 +- .../omg/sysml/model/RelationshipAllOf.java | 149 ----- .../java/org/omg/sysml/api/CommitApiTest.java | 103 ++++ .../org/omg/sysml/api/ElementApiTest.java | 68 +- .../org/omg/sysml/api/ProjectApiTest.java | 23 +- .../omg/sysml/api/RelationshipApiTest.java | 58 +- .../java/org/omg/sysml/model/CommitTest.java | 80 +++ ...llOfTest.java => ElementIdentityTest.java} | 28 +- .../java/org/omg/sysml/model/ElementTest.java | 9 - .../omg/sysml/model/ElementVersionTest.java | 78 +++ .../java/org/omg/sysml/model/ProjectTest.java | 12 +- .../java/org/omg/sysml/model/RecordTest.java | 52 ++ .../org/omg/sysml/model/RelationshipTest.java | 10 - test-sysml-v2-api-java-client.jsh | 52 ++ 62 files changed, 2692 insertions(+), 1999 deletions(-) create mode 100644 .idea/.gitignore create mode 100644 .idea/.name create mode 100644 .idea/codeStyles/codeStyleConfig.xml create mode 100644 .idea/gradle.xml create mode 100644 .idea/jarRepositories.xml create mode 100644 .idea/misc.xml create mode 100644 .idea/sbt.xml create mode 100644 .idea/vcs.xml delete mode 100644 LICENSE create mode 100644 docs/Commit.md create mode 100644 docs/CommitApi.md create mode 100644 docs/ElementIdentity.md create mode 100644 docs/ElementVersion.md create mode 100644 docs/Record.md delete mode 100644 docs/RelationshipAllOf.md mode change 100644 => 100755 gradlew.bat create mode 100644 src/main/java/org/omg/sysml/api/CommitApi.java create mode 100644 src/main/java/org/omg/sysml/model/Commit.java create mode 100644 src/main/java/org/omg/sysml/model/ElementIdentity.java create mode 100644 src/main/java/org/omg/sysml/model/ElementVersion.java create mode 100644 src/main/java/org/omg/sysml/model/Record.java delete mode 100644 src/main/java/org/omg/sysml/model/RelationshipAllOf.java create mode 100644 src/test/java/org/omg/sysml/api/CommitApiTest.java create mode 100644 src/test/java/org/omg/sysml/model/CommitTest.java rename src/test/java/org/omg/sysml/model/{RelationshipAllOfTest.java => ElementIdentityTest.java} (61%) create mode 100644 src/test/java/org/omg/sysml/model/ElementVersionTest.java create mode 100644 src/test/java/org/omg/sysml/model/RecordTest.java create mode 100755 test-sysml-v2-api-java-client.jsh diff --git a/.idea/.gitignore b/.idea/.gitignore new file mode 100644 index 0000000..5c98b42 --- /dev/null +++ b/.idea/.gitignore @@ -0,0 +1,2 @@ +# Default ignored files +/workspace.xml \ No newline at end of file diff --git a/.idea/.name b/.idea/.name new file mode 100644 index 0000000..4274503 --- /dev/null +++ b/.idea/.name @@ -0,0 +1 @@ +sysml-v2-api-client \ No newline at end of file diff --git a/.idea/codeStyles/codeStyleConfig.xml b/.idea/codeStyles/codeStyleConfig.xml new file mode 100644 index 0000000..a55e7a1 --- /dev/null +++ b/.idea/codeStyles/codeStyleConfig.xml @@ -0,0 +1,5 @@ + + + + \ No newline at end of file diff --git a/.idea/gradle.xml b/.idea/gradle.xml new file mode 100644 index 0000000..cae81d0 --- /dev/null +++ b/.idea/gradle.xml @@ -0,0 +1,21 @@ + + + + + + + \ No newline at end of file diff --git a/.idea/jarRepositories.xml b/.idea/jarRepositories.xml new file mode 100644 index 0000000..efa4625 --- /dev/null +++ b/.idea/jarRepositories.xml @@ -0,0 +1,20 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/.idea/misc.xml b/.idea/misc.xml new file mode 100644 index 0000000..25d34a4 --- /dev/null +++ b/.idea/misc.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/.idea/sbt.xml b/.idea/sbt.xml new file mode 100644 index 0000000..2018743 --- /dev/null +++ b/.idea/sbt.xml @@ -0,0 +1,6 @@ + + + + + \ No newline at end of file diff --git a/.idea/vcs.xml b/.idea/vcs.xml new file mode 100644 index 0000000..35eb1dd --- /dev/null +++ b/.idea/vcs.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/.openapi-generator/VERSION b/.openapi-generator/VERSION index 8c7fafd..ec87108 100644 --- a/.openapi-generator/VERSION +++ b/.openapi-generator/VERSION @@ -1 +1 @@ -4.1.3 \ No newline at end of file +4.2.3 \ No newline at end of file diff --git a/LICENSE b/LICENSE deleted file mode 100644 index 0a04128..0000000 --- a/LICENSE +++ /dev/null @@ -1,165 +0,0 @@ - GNU LESSER GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - - This version of the GNU Lesser General Public License incorporates -the terms and conditions of version 3 of the GNU General Public -License, supplemented by the additional permissions listed below. - - 0. Additional Definitions. - - As used herein, "this License" refers to version 3 of the GNU Lesser -General Public License, and the "GNU GPL" refers to version 3 of the GNU -General Public License. - - "The Library" refers to a covered work governed by this License, -other than an Application or a Combined Work as defined below. - - An "Application" is any work that makes use of an interface provided -by the Library, but which is not otherwise based on the Library. -Defining a subclass of a class defined by the Library is deemed a mode -of using an interface provided by the Library. - - A "Combined Work" is a work produced by combining or linking an -Application with the Library. The particular version of the Library -with which the Combined Work was made is also called the "Linked -Version". - - The "Minimal Corresponding Source" for a Combined Work means the -Corresponding Source for the Combined Work, excluding any source code -for portions of the Combined Work that, considered in isolation, are -based on the Application, and not on the Linked Version. - - The "Corresponding Application Code" for a Combined Work means the -object code and/or source code for the Application, including any data -and utility programs needed for reproducing the Combined Work from the -Application, but excluding the System Libraries of the Combined Work. - - 1. Exception to Section 3 of the GNU GPL. - - You may convey a covered work under sections 3 and 4 of this License -without being bound by section 3 of the GNU GPL. - - 2. Conveying Modified Versions. - - If you modify a copy of the Library, and, in your modifications, a -facility refers to a function or data to be supplied by an Application -that uses the facility (other than as an argument passed when the -facility is invoked), then you may convey a copy of the modified -version: - - a) under this License, provided that you make a good faith effort to - ensure that, in the event an Application does not supply the - function or data, the facility still operates, and performs - whatever part of its purpose remains meaningful, or - - b) under the GNU GPL, with none of the additional permissions of - this License applicable to that copy. - - 3. Object Code Incorporating Material from Library Header Files. - - The object code form of an Application may incorporate material from -a header file that is part of the Library. You may convey such object -code under terms of your choice, provided that, if the incorporated -material is not limited to numerical parameters, data structure -layouts and accessors, or small macros, inline functions and templates -(ten or fewer lines in length), you do both of the following: - - a) Give prominent notice with each copy of the object code that the - Library is used in it and that the Library and its use are - covered by this License. - - b) Accompany the object code with a copy of the GNU GPL and this license - document. - - 4. Combined Works. - - You may convey a Combined Work under terms of your choice that, -taken together, effectively do not restrict modification of the -portions of the Library contained in the Combined Work and reverse -engineering for debugging such modifications, if you also do each of -the following: - - a) Give prominent notice with each copy of the Combined Work that - the Library is used in it and that the Library and its use are - covered by this License. - - b) Accompany the Combined Work with a copy of the GNU GPL and this license - document. - - c) For a Combined Work that displays copyright notices during - execution, include the copyright notice for the Library among - these notices, as well as a reference directing the user to the - copies of the GNU GPL and this license document. - - d) Do one of the following: - - 0) Convey the Minimal Corresponding Source under the terms of this - License, and the Corresponding Application Code in a form - suitable for, and under terms that permit, the user to - recombine or relink the Application with a modified version of - the Linked Version to produce a modified Combined Work, in the - manner specified by section 6 of the GNU GPL for conveying - Corresponding Source. - - 1) Use a suitable shared library mechanism for linking with the - Library. A suitable mechanism is one that (a) uses at run time - a copy of the Library already present on the user's computer - system, and (b) will operate properly with a modified version - of the Library that is interface-compatible with the Linked - Version. - - e) Provide Installation Information, but only if you would otherwise - be required to provide such information under section 6 of the - GNU GPL, and only to the extent that such information is - necessary to install and execute a modified version of the - Combined Work produced by recombining or relinking the - Application with a modified version of the Linked Version. (If - you use option 4d0, the Installation Information must accompany - the Minimal Corresponding Source and Corresponding Application - Code. If you use option 4d1, you must provide the Installation - Information in the manner specified by section 6 of the GNU GPL - for conveying Corresponding Source.) - - 5. Combined Libraries. - - You may place library facilities that are a work based on the -Library side by side in a single library together with other library -facilities that are not Applications and are not covered by this -License, and convey such a combined library under terms of your -choice, if you do both of the following: - - a) Accompany the combined library with a copy of the same work based - on the Library, uncombined with any other library facilities, - conveyed under the terms of this License. - - b) Give prominent notice with the combined library that part of it - is a work based on the Library, and explaining where to find the - accompanying uncombined form of the same work. - - 6. Revised Versions of the GNU Lesser General Public License. - - The Free Software Foundation may publish revised and/or new versions -of the GNU Lesser General Public License from time to time. Such new -versions will be similar in spirit to the present version, but may -differ in detail to address new problems or concerns. - - Each version is given a distinguishing version number. If the -Library as you received it specifies that a certain numbered version -of the GNU Lesser General Public License "or any later version" -applies to it, you have the option of following the terms and -conditions either of that published version or of any later version -published by the Free Software Foundation. If the Library as you -received it does not specify a version number of the GNU Lesser -General Public License, you may choose any version of the GNU Lesser -General Public License ever published by the Free Software Foundation. - - If the Library as you received it specifies that a proxy can decide -whether future versions of the GNU Lesser General Public License shall -apply, that proxy's public statement of acceptance of any version is -permanent authorization for you to choose that version for the -Library. diff --git a/README.md b/README.md index ecbe8f3..f9930a4 100644 --- a/README.md +++ b/README.md @@ -39,7 +39,7 @@ Add this dependency to your project's POM: org.omg.sysml sysml-v2-api-client - 2019-09 + 2020-03 compile ``` @@ -49,7 +49,7 @@ Add this dependency to your project's POM: Add this dependency to your project's build file: ```groovy -compile "org.omg.sysml:sysml-v2-api-client:2019-09" +compile "org.omg.sysml:sysml-v2-api-client:2020-03" ``` ### Others @@ -62,7 +62,7 @@ mvn clean package Then manually install the following JARs: -* `target/sysml-v2-api-client-2019-09.jar` +* `target/sysml-v2-api-client-2020-03.jar` * `target/lib/*.jar` ## Getting Started @@ -76,20 +76,21 @@ import org.omg.sysml.ApiClient; import org.omg.sysml.ApiException; import org.omg.sysml.Configuration; import org.omg.sysml.models.*; -import org.omg.sysml.api.ElementApi; +import org.omg.sysml.api.CommitApi; public class Example { public static void main(String[] args) { ApiClient defaultClient = Configuration.getDefaultApiClient(); defaultClient.setBasePath("http://localhost"); - ElementApi apiInstance = new ElementApi(defaultClient); - Map body = null; // Map | + CommitApi apiInstance = new CommitApi(defaultClient); + String projectId = "projectId_example"; // String | ID of the project + String commitId = "commitId_example"; // String | ID of the commit try { - Element result = apiInstance.createElement(body); + Commit result = apiInstance.getCommitByProjectAndId(projectId, commitId); System.out.println(result); } catch (ApiException e) { - System.err.println("Exception when calling ElementApi#createElement"); + System.err.println("Exception when calling CommitApi#getCommitByProjectAndId"); System.err.println("Status code: " + e.getCode()); System.err.println("Reason: " + e.getResponseBody()); System.err.println("Response headers: " + e.getResponseHeaders()); @@ -106,26 +107,33 @@ All URIs are relative to *http://localhost* Class | Method | HTTP request | Description ------------ | ------------- | ------------- | ------------- -*ElementApi* | [**createElement**](docs/ElementApi.md#createElement) | **POST** /elements | Add a new element -*ElementApi* | [**getElement**](docs/ElementApi.md#getElement) | **GET** /elements/{identifier} | Get element by its ID -*ElementApi* | [**getElementByProjectAndId**](docs/ElementApi.md#getElementByProjectAndId) | **GET** /projects/{project_identifier}/elements/{element_identifier} | Get element by project ID and its ID -*ElementApi* | [**getElements**](docs/ElementApi.md#getElements) | **GET** /elements | Get all elements -*ElementApi* | [**getElementsInProject**](docs/ElementApi.md#getElementsInProject) | **GET** /projects/{project_identifier}/elements | Get all elements in the project -*ProjectApi* | [**createProject**](docs/ProjectApi.md#createProject) | **POST** /projects | Add a new project -*ProjectApi* | [**getProject**](docs/ProjectApi.md#getProject) | **GET** /projects/{identifier} | Get project by its ID -*ProjectApi* | [**getProjects**](docs/ProjectApi.md#getProjects) | **GET** /projects | Get all projects -*RelationshipApi* | [**createRelationship**](docs/RelationshipApi.md#createRelationship) | **POST** /relationships | Add a new relationship -*RelationshipApi* | [**getRelationship**](docs/RelationshipApi.md#getRelationship) | **GET** /relationships/{identifier} | Get relationship by its ID -*RelationshipApi* | [**getRelationships**](docs/RelationshipApi.md#getRelationships) | **GET** /relationships | Get all relationships -*RelationshipApi* | [**getRelationshipsByProject**](docs/RelationshipApi.md#getRelationshipsByProject) | **GET** /projects/{project_identifier}/relationships | Get all relationships in the project +*CommitApi* | [**getCommitByProjectAndId**](docs/CommitApi.md#getCommitByProjectAndId) | **GET** /projects/{projectId}/commits/{commitId} | Get commit by project and ID +*CommitApi* | [**getCommitsByProject**](docs/CommitApi.md#getCommitsByProject) | **GET** /projects/{projectId}/commits | Get commits by project +*CommitApi* | [**getHeadCommitByProject**](docs/CommitApi.md#getHeadCommitByProject) | **GET** /projects/{projectId}/head | Get head commit by project +*CommitApi* | [**postCommitByProject**](docs/CommitApi.md#postCommitByProject) | **POST** /projects/{projectId}/commits | Create commit by project +*ElementApi* | [**getElementByProjectCommitId**](docs/ElementApi.md#getElementByProjectCommitId) | **GET** /projects/{projectId}/commits/{commitId}/elements/{elementId} | Get element by project, commit and ID +*ElementApi* | [**getElementsByProjectCommit**](docs/ElementApi.md#getElementsByProjectCommit) | **GET** /projects/{projectId}/commits/{commitId}/elements | Get elements by project and commit +*ProjectApi* | [**getProjectById**](docs/ProjectApi.md#getProjectById) | **GET** /projects/{projectId} | Get project by ID +*ProjectApi* | [**getProjects**](docs/ProjectApi.md#getProjects) | **GET** /projects | Get projects +*ProjectApi* | [**postProject**](docs/ProjectApi.md#postProject) | **POST** /projects | Create project +*RelationshipApi* | [**getRelationshipsByProjectCommitRelatedElement**](docs/RelationshipApi.md#getRelationshipsByProjectCommitRelatedElement) | **GET** /projects/{projectId}/commits/{commitId}/elements/{relatedElementId}/relationships | Get relationships by project, commit, and related element. ## Documentation for Models + - [Commit](docs/Commit.md) + - [CommitAllOf](docs/CommitAllOf.md) - [Element](docs/Element.md) + - [ElementAllOf](docs/ElementAllOf.md) + - [ElementIdentity](docs/ElementIdentity.md) + - [ElementIdentityAllOf](docs/ElementIdentityAllOf.md) + - [ElementVersion](docs/ElementVersion.md) + - [ElementVersionAllOf](docs/ElementVersionAllOf.md) - [Error](docs/Error.md) - [Identified](docs/Identified.md) - [Project](docs/Project.md) + - [ProjectAllOf](docs/ProjectAllOf.md) + - [Record](docs/Record.md) - [Relationship](docs/Relationship.md) - [RelationshipAllOf](docs/RelationshipAllOf.md) diff --git a/build-shadow.gradle b/build-shadow.gradle index 0651cb7..14801b5 100644 --- a/build-shadow.gradle +++ b/build-shadow.gradle @@ -5,7 +5,7 @@ buildscript { jcenter() } dependencies { - classpath 'com.github.jengelman.gradle.plugins:shadow:1.2.4' + classpath 'com.github.jengelman.gradle.plugins:shadow:5.2.0' } } diff --git a/build.gradle b/build.gradle index eb86a88..cd24037 100644 --- a/build.gradle +++ b/build.gradle @@ -3,11 +3,11 @@ apply plugin: 'eclipse' apply plugin: 'java' group = 'org.omg.sysml' -version = '2019-09' +version = '2020-03' buildscript { repositories { - mavenCentral() + maven { url "https://repo1.maven.org/maven2" } jcenter() } dependencies { @@ -105,8 +105,8 @@ dependencies { compile 'com.google.code.gson:gson:2.8.5' compile 'io.gsonfire:gson-fire:1.8.3' compile group: 'org.apache.commons', name: 'commons-lang3', version: '3.9' - compile 'org.threeten:threetenbp:1.3.5' - testCompile 'junit:junit:4.12' + compile 'org.threeten:threetenbp:1.4.0' + testCompile 'junit:junit:4.13' } javadoc { diff --git a/build.sbt b/build.sbt index c855338..429c195 100644 --- a/build.sbt +++ b/build.sbt @@ -2,7 +2,7 @@ lazy val root = (project in file(".")). settings( organization := "org.omg.sysml", name := "sysml-v2-api-client", - version := "2019-09", + version := "2020-03", scalaVersion := "2.11.4", scalacOptions ++= Seq("-feature"), javacOptions in compile ++= Seq("-Xlint:deprecation"), @@ -14,10 +14,10 @@ lazy val root = (project in file(".")). "com.squareup.okhttp3" % "logging-interceptor" % "3.14.2", "com.google.code.gson" % "gson" % "2.8.5", "org.apache.commons" % "commons-lang3" % "3.9", - "org.threeten" % "threetenbp" % "1.3.5" % "compile", + "org.threeten" % "threetenbp" % "1.4.0" % "compile", "io.gsonfire" % "gson-fire" % "1.8.3" % "compile", "javax.annotation" % "jsr250-api" % "1.0" % "compile", - "junit" % "junit" % "4.12" % "test", + "junit" % "junit" % "4.13" % "test", "com.novocode" % "junit-interface" % "0.10" % "test" ) ) diff --git a/docs/Commit.md b/docs/Commit.md new file mode 100644 index 0000000..eede996 --- /dev/null +++ b/docs/Commit.md @@ -0,0 +1,23 @@ + + +# Commit + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**atType** | [**AtTypeEnum**](#AtTypeEnum) | | [optional] +**changes** | [**List<ElementVersion>**](ElementVersion.md) | | [optional] +**id** | [**UUID**](UUID.md) | | [optional] +**previousCommit** | [**Record**](Record.md) | | [optional] + + + +## Enum: AtTypeEnum + +Name | Value +---- | ----- +COMMIT | "Commit" + + + diff --git a/docs/CommitApi.md b/docs/CommitApi.md new file mode 100644 index 0000000..1f7913f --- /dev/null +++ b/docs/CommitApi.md @@ -0,0 +1,271 @@ +# CommitApi + +All URIs are relative to *http://localhost* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getCommitByProjectAndId**](CommitApi.md#getCommitByProjectAndId) | **GET** /projects/{projectId}/commits/{commitId} | Get commit by project and ID +[**getCommitsByProject**](CommitApi.md#getCommitsByProject) | **GET** /projects/{projectId}/commits | Get commits by project +[**getHeadCommitByProject**](CommitApi.md#getHeadCommitByProject) | **GET** /projects/{projectId}/head | Get head commit by project +[**postCommitByProject**](CommitApi.md#postCommitByProject) | **POST** /projects/{projectId}/commits | Create commit by project + + + +# **getCommitByProjectAndId** +> Commit getCommitByProjectAndId(projectId, commitId) + +Get commit by project and ID + +### Example +```java +// Import classes: +import org.omg.sysml.ApiClient; +import org.omg.sysml.ApiException; +import org.omg.sysml.Configuration; +import org.omg.sysml.models.*; +import org.omg.sysml.api.CommitApi; + +public class Example { + public static void main(String[] args) { + ApiClient defaultClient = Configuration.getDefaultApiClient(); + defaultClient.setBasePath("http://localhost"); + + CommitApi apiInstance = new CommitApi(defaultClient); + String projectId = "projectId_example"; // String | ID of the project + String commitId = "commitId_example"; // String | ID of the commit + try { + Commit result = apiInstance.getCommitByProjectAndId(projectId, commitId); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Exception when calling CommitApi#getCommitByProjectAndId"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **projectId** | **String**| ID of the project | + **commitId** | **String**| ID of the commit | + +### Return type + +[**Commit**](Commit.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | Ok | - | +**404** | Not found. | - | +**415** | The requested content type is not acceptable. | - | +**500** | Internal server error. | - | +**0** | Unexpected response. | - | + + +# **getCommitsByProject** +> Commit getCommitsByProject(projectId) + +Get commits by project + +### Example +```java +// Import classes: +import org.omg.sysml.ApiClient; +import org.omg.sysml.ApiException; +import org.omg.sysml.Configuration; +import org.omg.sysml.models.*; +import org.omg.sysml.api.CommitApi; + +public class Example { + public static void main(String[] args) { + ApiClient defaultClient = Configuration.getDefaultApiClient(); + defaultClient.setBasePath("http://localhost"); + + CommitApi apiInstance = new CommitApi(defaultClient); + UUID projectId = new UUID(); // UUID | ID of the project + try { + Commit result = apiInstance.getCommitsByProject(projectId); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Exception when calling CommitApi#getCommitsByProject"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **projectId** | [**UUID**](.md)| ID of the project | + +### Return type + +[**Commit**](Commit.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | Ok | - | +**404** | Not found. | - | +**415** | The requested content type is not acceptable. | - | +**500** | Internal server error. | - | +**0** | Unexpected response. | - | + + +# **getHeadCommitByProject** +> Commit getHeadCommitByProject(projectId) + +Get head commit by project + +### Example +```java +// Import classes: +import org.omg.sysml.ApiClient; +import org.omg.sysml.ApiException; +import org.omg.sysml.Configuration; +import org.omg.sysml.models.*; +import org.omg.sysml.api.CommitApi; + +public class Example { + public static void main(String[] args) { + ApiClient defaultClient = Configuration.getDefaultApiClient(); + defaultClient.setBasePath("http://localhost"); + + CommitApi apiInstance = new CommitApi(defaultClient); + String projectId = "projectId_example"; // String | ID of the project + try { + Commit result = apiInstance.getHeadCommitByProject(projectId); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Exception when calling CommitApi#getHeadCommitByProject"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **projectId** | **String**| ID of the project | + +### Return type + +[**Commit**](Commit.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | Ok | - | +**404** | Not found. | - | +**415** | The requested content type is not acceptable. | - | +**500** | Internal server error. | - | +**0** | Unexpected response. | - | + + +# **postCommitByProject** +> Commit postCommitByProject(projectId, body) + +Create commit by project + +### Example +```java +// Import classes: +import org.omg.sysml.ApiClient; +import org.omg.sysml.ApiException; +import org.omg.sysml.Configuration; +import org.omg.sysml.models.*; +import org.omg.sysml.api.CommitApi; + +public class Example { + public static void main(String[] args) { + ApiClient defaultClient = Configuration.getDefaultApiClient(); + defaultClient.setBasePath("http://localhost"); + + CommitApi apiInstance = new CommitApi(defaultClient); + UUID projectId = new UUID(); // UUID | ID of the project + Commit body = new Commit(); // Commit | + try { + Commit result = apiInstance.postCommitByProject(projectId, body); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Exception when calling CommitApi#postCommitByProject"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **projectId** | [**UUID**](.md)| ID of the project | + **body** | [**Commit**](Commit.md)| | + +### Return type + +[**Commit**](Commit.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | Created | - | +**415** | The requested content type is not acceptable. | - | +**500** | Internal server error. | - | +**0** | Unexpected response. | - | + diff --git a/docs/Element.md b/docs/Element.md index 1e52b40..fccd324 100644 --- a/docs/Element.md +++ b/docs/Element.md @@ -7,7 +7,6 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **atType** | **String** | | [optional] -**containingProject** | [**Identified**](Identified.md) | | [optional] **identifier** | [**UUID**](UUID.md) | | [optional] diff --git a/docs/ElementApi.md b/docs/ElementApi.md index d895702..963a554 100644 --- a/docs/ElementApi.md +++ b/docs/ElementApi.md @@ -4,18 +4,15 @@ All URIs are relative to *http://localhost* Method | HTTP request | Description ------------- | ------------- | ------------- -[**createElement**](ElementApi.md#createElement) | **POST** /elements | Add a new element -[**getElement**](ElementApi.md#getElement) | **GET** /elements/{identifier} | Get element by its ID -[**getElementByProjectAndId**](ElementApi.md#getElementByProjectAndId) | **GET** /projects/{project_identifier}/elements/{element_identifier} | Get element by project ID and its ID -[**getElements**](ElementApi.md#getElements) | **GET** /elements | Get all elements -[**getElementsInProject**](ElementApi.md#getElementsInProject) | **GET** /projects/{project_identifier}/elements | Get all elements in the project +[**getElementByProjectCommitId**](ElementApi.md#getElementByProjectCommitId) | **GET** /projects/{projectId}/commits/{commitId}/elements/{elementId} | Get element by project, commit and ID +[**getElementsByProjectCommit**](ElementApi.md#getElementsByProjectCommit) | **GET** /projects/{projectId}/commits/{commitId}/elements | Get elements by project and commit - -# **createElement** -> Element createElement(body) + +# **getElementByProjectCommitId** +> Element getElementByProjectCommitId(projectId, commitId, elementId) -Add a new element +Get element by project, commit and ID ### Example ```java @@ -32,12 +29,14 @@ public class Example { defaultClient.setBasePath("http://localhost"); ElementApi apiInstance = new ElementApi(defaultClient); - Map body = null; // Map | + UUID projectId = new UUID(); // UUID | ID of the project + UUID commitId = new UUID(); // UUID | ID of the commit + UUID elementId = new UUID(); // UUID | ID of the element try { - Element result = apiInstance.createElement(body); + Element result = apiInstance.getElementByProjectCommitId(projectId, commitId, elementId); System.out.println(result); } catch (ApiException e) { - System.err.println("Exception when calling ElementApi#createElement"); + System.err.println("Exception when calling ElementApi#getElementByProjectCommitId"); System.err.println("Status code: " + e.getCode()); System.err.println("Reason: " + e.getResponseBody()); System.err.println("Response headers: " + e.getResponseHeaders()); @@ -51,136 +50,9 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**Map<String, Object>**](Object.md)| | - -### Return type - -[**Element**](Element.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json - - **Accept**: application/json - -### HTTP response details -| Status code | Description | Response headers | -|-------------|-------------|------------------| -**201** | Created | - | -**415** | The requested content type is not acceptable. | - | -**500** | Internal server error. | - | -**0** | Unexpected response. | - | - - -# **getElement** -> Element getElement(identifier) - -Get element by its ID - -### Example -```java -// Import classes: -import org.omg.sysml.ApiClient; -import org.omg.sysml.ApiException; -import org.omg.sysml.Configuration; -import org.omg.sysml.models.*; -import org.omg.sysml.api.ElementApi; - -public class Example { - public static void main(String[] args) { - ApiClient defaultClient = Configuration.getDefaultApiClient(); - defaultClient.setBasePath("http://localhost"); - - ElementApi apiInstance = new ElementApi(defaultClient); - String identifier = "identifier_example"; // String | ID of the element - try { - Element result = apiInstance.getElement(identifier); - System.out.println(result); - } catch (ApiException e) { - System.err.println("Exception when calling ElementApi#getElement"); - System.err.println("Status code: " + e.getCode()); - System.err.println("Reason: " + e.getResponseBody()); - System.err.println("Response headers: " + e.getResponseHeaders()); - e.printStackTrace(); - } - } -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **identifier** | **String**| ID of the element | - -### Return type - -[**Element**](Element.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json - -### HTTP response details -| Status code | Description | Response headers | -|-------------|-------------|------------------| -**200** | Ok | - | -**404** | Not found. | - | -**415** | The requested content type is not acceptable. | - | -**500** | Internal server error. | - | -**0** | Unexpected response. | - | - - -# **getElementByProjectAndId** -> Element getElementByProjectAndId(projectIdentifier, elementIdentifier) - -Get element by project ID and its ID - -### Example -```java -// Import classes: -import org.omg.sysml.ApiClient; -import org.omg.sysml.ApiException; -import org.omg.sysml.Configuration; -import org.omg.sysml.models.*; -import org.omg.sysml.api.ElementApi; - -public class Example { - public static void main(String[] args) { - ApiClient defaultClient = Configuration.getDefaultApiClient(); - defaultClient.setBasePath("http://localhost"); - - ElementApi apiInstance = new ElementApi(defaultClient); - String projectIdentifier = "projectIdentifier_example"; // String | ID of the project - String elementIdentifier = "elementIdentifier_example"; // String | ID of the element - try { - Element result = apiInstance.getElementByProjectAndId(projectIdentifier, elementIdentifier); - System.out.println(result); - } catch (ApiException e) { - System.err.println("Exception when calling ElementApi#getElementByProjectAndId"); - System.err.println("Status code: " + e.getCode()); - System.err.println("Reason: " + e.getResponseBody()); - System.err.println("Response headers: " + e.getResponseHeaders()); - e.printStackTrace(); - } - } -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **projectIdentifier** | **String**| ID of the project | - **elementIdentifier** | **String**| ID of the element | + **projectId** | [**UUID**](.md)| ID of the project | + **commitId** | [**UUID**](.md)| ID of the commit | + **elementId** | [**UUID**](.md)| ID of the element | ### Return type @@ -204,70 +76,11 @@ No authorization required **500** | Internal server error. | - | **0** | Unexpected response. | - | - -# **getElements** -> List<Element> getElements() - -Get all elements - -### Example -```java -// Import classes: -import org.omg.sysml.ApiClient; -import org.omg.sysml.ApiException; -import org.omg.sysml.Configuration; -import org.omg.sysml.models.*; -import org.omg.sysml.api.ElementApi; - -public class Example { - public static void main(String[] args) { - ApiClient defaultClient = Configuration.getDefaultApiClient(); - defaultClient.setBasePath("http://localhost"); - - ElementApi apiInstance = new ElementApi(defaultClient); - try { - List result = apiInstance.getElements(); - System.out.println(result); - } catch (ApiException e) { - System.err.println("Exception when calling ElementApi#getElements"); - System.err.println("Status code: " + e.getCode()); - System.err.println("Reason: " + e.getResponseBody()); - System.err.println("Response headers: " + e.getResponseHeaders()); - e.printStackTrace(); - } - } -} -``` - -### Parameters -This endpoint does not need any parameter. - -### Return type - -[**List<Element>**](Element.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json - -### HTTP response details -| Status code | Description | Response headers | -|-------------|-------------|------------------| -**200** | Ok | - | -**415** | The requested content type is not acceptable. | - | -**500** | Internal server error. | - | -**0** | Unexpected response. | - | - - -# **getElementsInProject** -> Element getElementsInProject(projectIdentifier) + +# **getElementsByProjectCommit** +> Element getElementsByProjectCommit(projectId, commitId) -Get all elements in the project +Get elements by project and commit ### Example ```java @@ -284,12 +97,13 @@ public class Example { defaultClient.setBasePath("http://localhost"); ElementApi apiInstance = new ElementApi(defaultClient); - String projectIdentifier = "projectIdentifier_example"; // String | ID of the project + UUID projectId = new UUID(); // UUID | ID of the project + UUID commitId = new UUID(); // UUID | ID of the commit try { - Element result = apiInstance.getElementsInProject(projectIdentifier); + Element result = apiInstance.getElementsByProjectCommit(projectId, commitId); System.out.println(result); } catch (ApiException e) { - System.err.println("Exception when calling ElementApi#getElementsInProject"); + System.err.println("Exception when calling ElementApi#getElementsByProjectCommit"); System.err.println("Status code: " + e.getCode()); System.err.println("Reason: " + e.getResponseBody()); System.err.println("Response headers: " + e.getResponseHeaders()); @@ -303,7 +117,8 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **projectIdentifier** | **String**| ID of the project | + **projectId** | [**UUID**](.md)| ID of the project | + **commitId** | [**UUID**](.md)| ID of the commit | ### Return type diff --git a/docs/ElementIdentity.md b/docs/ElementIdentity.md new file mode 100644 index 0000000..5eadd15 --- /dev/null +++ b/docs/ElementIdentity.md @@ -0,0 +1,21 @@ + + +# ElementIdentity + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**atType** | [**AtTypeEnum**](#AtTypeEnum) | | [optional] +**id** | [**UUID**](UUID.md) | | [optional] + + + +## Enum: AtTypeEnum + +Name | Value +---- | ----- +ELEMENTIDENTITY | "ElementIdentity" + + + diff --git a/docs/ElementVersion.md b/docs/ElementVersion.md new file mode 100644 index 0000000..f0e1980 --- /dev/null +++ b/docs/ElementVersion.md @@ -0,0 +1,23 @@ + + +# ElementVersion + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**atType** | [**AtTypeEnum**](#AtTypeEnum) | | [optional] +**data** | [**Element**](Element.md) | | [optional] +**id** | [**UUID**](UUID.md) | | [optional] +**identity** | [**ElementIdentity**](ElementIdentity.md) | | [optional] + + + +## Enum: AtTypeEnum + +Name | Value +---- | ----- +ELEMENTVERSION | "ElementVersion" + + + diff --git a/docs/Project.md b/docs/Project.md index 7e5b307..3b9d732 100644 --- a/docs/Project.md +++ b/docs/Project.md @@ -6,9 +6,17 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**atType** | **String** | | [optional] +**atType** | [**AtTypeEnum**](#AtTypeEnum) | | [optional] +**id** | [**UUID**](UUID.md) | | [optional] **name** | **String** | | [optional] -**identifier** | [**UUID**](UUID.md) | | [optional] + + + +## Enum: AtTypeEnum + +Name | Value +---- | ----- +PROJECT | "Project" diff --git a/docs/ProjectApi.md b/docs/ProjectApi.md index 7409662..3a81f68 100644 --- a/docs/ProjectApi.md +++ b/docs/ProjectApi.md @@ -4,16 +4,16 @@ All URIs are relative to *http://localhost* Method | HTTP request | Description ------------- | ------------- | ------------- -[**createProject**](ProjectApi.md#createProject) | **POST** /projects | Add a new project -[**getProject**](ProjectApi.md#getProject) | **GET** /projects/{identifier} | Get project by its ID -[**getProjects**](ProjectApi.md#getProjects) | **GET** /projects | Get all projects +[**getProjectById**](ProjectApi.md#getProjectById) | **GET** /projects/{projectId} | Get project by ID +[**getProjects**](ProjectApi.md#getProjects) | **GET** /projects | Get projects +[**postProject**](ProjectApi.md#postProject) | **POST** /projects | Create project - -# **createProject** -> Project createProject(body) + +# **getProjectById** +> Project getProjectById(projectId) -Add a new project +Get project by ID ### Example ```java @@ -30,12 +30,12 @@ public class Example { defaultClient.setBasePath("http://localhost"); ProjectApi apiInstance = new ProjectApi(defaultClient); - Project body = new Project(); // Project | + UUID projectId = new UUID(); // UUID | ID of the project try { - Project result = apiInstance.createProject(body); + Project result = apiInstance.getProjectById(projectId); System.out.println(result); } catch (ApiException e) { - System.err.println("Exception when calling ProjectApi#createProject"); + System.err.println("Exception when calling ProjectApi#getProjectById"); System.err.println("Status code: " + e.getCode()); System.err.println("Reason: " + e.getResponseBody()); System.err.println("Response headers: " + e.getResponseHeaders()); @@ -49,7 +49,7 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**Project**](Project.md)| | [optional] + **projectId** | [**UUID**](.md)| ID of the project | ### Return type @@ -61,22 +61,23 @@ No authorization required ### HTTP request headers - - **Content-Type**: application/json + - **Content-Type**: Not defined - **Accept**: application/json ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -**201** | Created | - | +**200** | Ok | - | +**404** | Not found. | - | **415** | The requested content type is not acceptable. | - | **500** | Internal server error. | - | **0** | Unexpected response. | - | - -# **getProject** -> Project getProject(identifier) + +# **getProjects** +> List<Project> getProjects() -Get project by its ID +Get projects ### Example ```java @@ -93,12 +94,11 @@ public class Example { defaultClient.setBasePath("http://localhost"); ProjectApi apiInstance = new ProjectApi(defaultClient); - String identifier = "identifier_example"; // String | ID of the project try { - Project result = apiInstance.getProject(identifier); + List result = apiInstance.getProjects(); System.out.println(result); } catch (ApiException e) { - System.err.println("Exception when calling ProjectApi#getProject"); + System.err.println("Exception when calling ProjectApi#getProjects"); System.err.println("Status code: " + e.getCode()); System.err.println("Reason: " + e.getResponseBody()); System.err.println("Response headers: " + e.getResponseHeaders()); @@ -109,14 +109,11 @@ public class Example { ``` ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **identifier** | **String**| ID of the project | +This endpoint does not need any parameter. ### Return type -[**Project**](Project.md) +[**List<Project>**](Project.md) ### Authorization @@ -131,16 +128,15 @@ No authorization required | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | Ok | - | -**404** | Not found. | - | **415** | The requested content type is not acceptable. | - | **500** | Internal server error. | - | **0** | Unexpected response. | - | - -# **getProjects** -> List<Project> getProjects() + +# **postProject** +> Project postProject(body) -Get all projects +Create project ### Example ```java @@ -157,11 +153,12 @@ public class Example { defaultClient.setBasePath("http://localhost"); ProjectApi apiInstance = new ProjectApi(defaultClient); + Project body = new Project(); // Project | try { - List result = apiInstance.getProjects(); + Project result = apiInstance.postProject(body); System.out.println(result); } catch (ApiException e) { - System.err.println("Exception when calling ProjectApi#getProjects"); + System.err.println("Exception when calling ProjectApi#postProject"); System.err.println("Status code: " + e.getCode()); System.err.println("Reason: " + e.getResponseBody()); System.err.println("Response headers: " + e.getResponseHeaders()); @@ -172,11 +169,14 @@ public class Example { ``` ### Parameters -This endpoint does not need any parameter. + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **body** | [**Project**](Project.md)| | [optional] ### Return type -[**List<Project>**](Project.md) +[**Project**](Project.md) ### Authorization @@ -184,13 +184,13 @@ No authorization required ### HTTP request headers - - **Content-Type**: Not defined + - **Content-Type**: application/json - **Accept**: application/json ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -**200** | Ok | - | +**201** | Created | - | **415** | The requested content type is not acceptable. | - | **500** | Internal server error. | - | **0** | Unexpected response. | - | diff --git a/docs/Record.md b/docs/Record.md new file mode 100644 index 0000000..c2a682b --- /dev/null +++ b/docs/Record.md @@ -0,0 +1,12 @@ + + +# Record + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | [**UUID**](UUID.md) | | [optional] + + + diff --git a/docs/Relationship.md b/docs/Relationship.md index 47af9f8..e21c2a7 100644 --- a/docs/Relationship.md +++ b/docs/Relationship.md @@ -7,7 +7,6 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **atType** | **String** | | [optional] -**containingProject** | [**Identified**](Identified.md) | | [optional] **identifier** | [**UUID**](UUID.md) | | [optional] **source** | [**List<Identified>**](Identified.md) | | [optional] **target** | [**List<Identified>**](Identified.md) | | [optional] diff --git a/docs/RelationshipAllOf.md b/docs/RelationshipAllOf.md deleted file mode 100644 index dd5b01b..0000000 --- a/docs/RelationshipAllOf.md +++ /dev/null @@ -1,13 +0,0 @@ - - -# RelationshipAllOf - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**source** | [**List<Identified>**](Identified.md) | | [optional] -**target** | [**List<Identified>**](Identified.md) | | [optional] - - - diff --git a/docs/RelationshipApi.md b/docs/RelationshipApi.md index fc593fc..02ba5e3 100644 --- a/docs/RelationshipApi.md +++ b/docs/RelationshipApi.md @@ -4,17 +4,14 @@ All URIs are relative to *http://localhost* Method | HTTP request | Description ------------- | ------------- | ------------- -[**createRelationship**](RelationshipApi.md#createRelationship) | **POST** /relationships | Add a new relationship -[**getRelationship**](RelationshipApi.md#getRelationship) | **GET** /relationships/{identifier} | Get relationship by its ID -[**getRelationships**](RelationshipApi.md#getRelationships) | **GET** /relationships | Get all relationships -[**getRelationshipsByProject**](RelationshipApi.md#getRelationshipsByProject) | **GET** /projects/{project_identifier}/relationships | Get all relationships in the project +[**getRelationshipsByProjectCommitRelatedElement**](RelationshipApi.md#getRelationshipsByProjectCommitRelatedElement) | **GET** /projects/{projectId}/commits/{commitId}/elements/{relatedElementId}/relationships | Get relationships by project, commit, and related element. - -# **createRelationship** -> Relationship createRelationship(body) + +# **getRelationshipsByProjectCommitRelatedElement** +> List<Relationship> getRelationshipsByProjectCommitRelatedElement(projectId, commitId, relatedElementId) -Add a new relationship +Get relationships by project, commit, and related element. ### Example ```java @@ -31,12 +28,14 @@ public class Example { defaultClient.setBasePath("http://localhost"); RelationshipApi apiInstance = new RelationshipApi(defaultClient); - Relationship body = new Relationship(); // Relationship | + UUID projectId = new UUID(); // UUID | ID of the project + UUID commitId = new UUID(); // UUID | ID of the commit + UUID relatedElementId = new UUID(); // UUID | ID of the related element try { - Relationship result = apiInstance.createRelationship(body); + List result = apiInstance.getRelationshipsByProjectCommitRelatedElement(projectId, commitId, relatedElementId); System.out.println(result); } catch (ApiException e) { - System.err.println("Exception when calling RelationshipApi#createRelationship"); + System.err.println("Exception when calling RelationshipApi#getRelationshipsByProjectCommitRelatedElement"); System.err.println("Status code: " + e.getCode()); System.err.println("Reason: " + e.getResponseBody()); System.err.println("Response headers: " + e.getResponseHeaders()); @@ -50,193 +49,9 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**Relationship**](Relationship.md)| | - -### Return type - -[**Relationship**](Relationship.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json - - **Accept**: application/json - -### HTTP response details -| Status code | Description | Response headers | -|-------------|-------------|------------------| -**201** | Created | - | -**415** | The requested content type is not acceptable. | - | -**500** | Internal server error. | - | -**0** | Unexpected response. | - | - - -# **getRelationship** -> Relationship getRelationship(identifier) - -Get relationship by its ID - -### Example -```java -// Import classes: -import org.omg.sysml.ApiClient; -import org.omg.sysml.ApiException; -import org.omg.sysml.Configuration; -import org.omg.sysml.models.*; -import org.omg.sysml.api.RelationshipApi; - -public class Example { - public static void main(String[] args) { - ApiClient defaultClient = Configuration.getDefaultApiClient(); - defaultClient.setBasePath("http://localhost"); - - RelationshipApi apiInstance = new RelationshipApi(defaultClient); - String identifier = "identifier_example"; // String | ID of the relationship - try { - Relationship result = apiInstance.getRelationship(identifier); - System.out.println(result); - } catch (ApiException e) { - System.err.println("Exception when calling RelationshipApi#getRelationship"); - System.err.println("Status code: " + e.getCode()); - System.err.println("Reason: " + e.getResponseBody()); - System.err.println("Response headers: " + e.getResponseHeaders()); - e.printStackTrace(); - } - } -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **identifier** | **String**| ID of the relationship | - -### Return type - -[**Relationship**](Relationship.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json - -### HTTP response details -| Status code | Description | Response headers | -|-------------|-------------|------------------| -**200** | Ok | - | -**404** | Not found. | - | -**415** | The requested content type is not acceptable. | - | -**500** | Internal server error. | - | -**0** | Unexpected response. | - | - - -# **getRelationships** -> List<Relationship> getRelationships() - -Get all relationships - -### Example -```java -// Import classes: -import org.omg.sysml.ApiClient; -import org.omg.sysml.ApiException; -import org.omg.sysml.Configuration; -import org.omg.sysml.models.*; -import org.omg.sysml.api.RelationshipApi; - -public class Example { - public static void main(String[] args) { - ApiClient defaultClient = Configuration.getDefaultApiClient(); - defaultClient.setBasePath("http://localhost"); - - RelationshipApi apiInstance = new RelationshipApi(defaultClient); - try { - List result = apiInstance.getRelationships(); - System.out.println(result); - } catch (ApiException e) { - System.err.println("Exception when calling RelationshipApi#getRelationships"); - System.err.println("Status code: " + e.getCode()); - System.err.println("Reason: " + e.getResponseBody()); - System.err.println("Response headers: " + e.getResponseHeaders()); - e.printStackTrace(); - } - } -} -``` - -### Parameters -This endpoint does not need any parameter. - -### Return type - -[**List<Relationship>**](Relationship.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json - -### HTTP response details -| Status code | Description | Response headers | -|-------------|-------------|------------------| -**200** | Ok | - | -**415** | The requested content type is not acceptable. | - | -**500** | Internal server error. | - | -**0** | Unexpected response. | - | - - -# **getRelationshipsByProject** -> List<Relationship> getRelationshipsByProject(projectIdentifier) - -Get all relationships in the project - -### Example -```java -// Import classes: -import org.omg.sysml.ApiClient; -import org.omg.sysml.ApiException; -import org.omg.sysml.Configuration; -import org.omg.sysml.models.*; -import org.omg.sysml.api.RelationshipApi; - -public class Example { - public static void main(String[] args) { - ApiClient defaultClient = Configuration.getDefaultApiClient(); - defaultClient.setBasePath("http://localhost"); - - RelationshipApi apiInstance = new RelationshipApi(defaultClient); - String projectIdentifier = "projectIdentifier_example"; // String | ID of the project - try { - List result = apiInstance.getRelationshipsByProject(projectIdentifier); - System.out.println(result); - } catch (ApiException e) { - System.err.println("Exception when calling RelationshipApi#getRelationshipsByProject"); - System.err.println("Status code: " + e.getCode()); - System.err.println("Reason: " + e.getResponseBody()); - System.err.println("Response headers: " + e.getResponseHeaders()); - e.printStackTrace(); - } - } -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **projectIdentifier** | **String**| ID of the project | + **projectId** | [**UUID**](.md)| ID of the project | + **commitId** | [**UUID**](.md)| ID of the commit | + **relatedElementId** | [**UUID**](.md)| ID of the related element | ### Return type diff --git a/gradle/wrapper/gradle-wrapper.jar b/gradle/wrapper/gradle-wrapper.jar index 87b738cbd051603d91cc39de6cb000dd98fe6b02..cc4fdc293d0e50b0ad9b65c16e7ddd1db2f6025b 100644 GIT binary patch delta 19358 zcmY(pV{o8d(5{ZQC{`wryj-XMelu)c1G&>snpi*Ij)j z*Zi0s|4~Z|ijYLUP}~Lz0)q1c1cWi+FDYh%JSaLq#>`-1Yvke*tvq4B@C%)Pq1BDK zIQT)#EAf|sl$A{%#~%o_xL*u(%5DKGvKPc@<2VxgFdyi696#%Je!Nf()}g^b>$x(! z5V=e*wLMSI7;FO|o)KLj_pJ?oIzX>>yJO{ukbK!7Fte=+HeCX=D}FQV5FD4Gw&K_n zY(<3u{AM$zj3&h>$KjLHMN4LUa^Cj2Z~-?-%;SU>^;GBsBTn}3O55XXDsz;y5~OAY zSYB7KBRi_r3vTl~W-U3cRKF;~ak&Gk)P0Es$0d*FWU|Vp$;Jy$CG;$sPCeGHsaTiP z4NncIlCZfeR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7m_*ycl{{;m0|}Y!~buyg#p%{K&4GpFg35gf&@6WDGK)P`%m2nM*+4hAp_O6aKNqr zK&LHBP-&pzCMoc9O9AXH^qsysml-v2-api-client jar sysml-v2-api-client - 2019-09 + 2020-03 https://github.com/openapitools/openapi-generator OpenAPI Java @@ -258,10 +258,10 @@ 3.14.2 2.8.5 3.9 - 1.3.8 + 1.4.0 1.0.0 1.0 - 4.12 + 4.13 UTF-8 diff --git a/src/main/java/org/omg/sysml/ApiClient.java b/src/main/java/org/omg/sysml/ApiClient.java index 497830a..a4e44cd 100644 --- a/src/main/java/org/omg/sysml/ApiClient.java +++ b/src/main/java/org/omg/sysml/ApiClient.java @@ -15,6 +15,7 @@ import okhttp3.*; import okhttp3.internal.http.HttpMethod; +import okhttp3.internal.tls.OkHostnameVerifier; import okhttp3.logging.HttpLoggingInterceptor; import okhttp3.logging.HttpLoggingInterceptor.Level; import okio.BufferedSink; @@ -55,6 +56,7 @@ public class ApiClient { private String basePath = "http://localhost"; private boolean debugging = false; private Map defaultHeaderMap = new HashMap(); + private Map defaultCookieMap = new HashMap(); private String tempFolderPath = null; private Map authentications; @@ -95,7 +97,7 @@ private void init() { json = new JSON(); // Set default User-Agent. - setUserAgent("OpenAPI-Generator/2019-09/java"); + setUserAgent("OpenAPI-Generator/2020-03/java"); authentications = new HashMap(); } @@ -363,6 +365,18 @@ public ApiClient addDefaultHeader(String key, String 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. * @@ -974,14 +988,15 @@ public T handleResponse(Response response, Type returnType) throws ApiExcept * @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 path, String method, List queryParams, List collectionQueryParams, Object body, Map headerParams, Map formParams, String[] authNames, ApiCallback callback) throws ApiException { - Request request = buildRequest(path, method, queryParams, collectionQueryParams, body, headerParams, formParams, authNames, callback); + public Call buildCall(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(path, method, queryParams, collectionQueryParams, body, headerParams, cookieParams, formParams, authNames, callback); return httpClient.newCall(request); } @@ -995,18 +1010,20 @@ public Call buildCall(String path, String method, List queryParams, List

queryParams, List collectionQueryParams, Object body, Map headerParams, Map formParams, String[] authNames, ApiCallback callback) throws ApiException { - updateParamsForAuth(authNames, queryParams, headerParams); + public Request buildRequest(String path, String method, List queryParams, List collectionQueryParams, Object body, Map headerParams, Map cookieParams, Map formParams, String[] authNames, ApiCallback callback) throws ApiException { + updateParamsForAuth(authNames, queryParams, headerParams, cookieParams); final String url = buildUrl(path, queryParams, collectionQueryParams); final Request.Builder reqBuilder = new Request.Builder().url(url); processHeaderParams(headerParams, reqBuilder); + processCookieParams(cookieParams, reqBuilder); String contentType = (String) headerParams.get("Content-Type"); // ensuring a default content type @@ -1101,8 +1118,8 @@ public String buildUrl(String path, List queryParams, List collectio /** * Set header parameters to the request builder, including default headers. * - * @param headerParams Header parameters in the ofrm of Map - * @param reqBuilder Reqeust.Builder + * @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()) { @@ -1115,20 +1132,38 @@ public void processHeaderParams(Map headerParams, Request.Builde } } + /** + * 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 */ - public void updateParamsForAuth(String[] authNames, List queryParams, Map headerParams) { + public void updateParamsForAuth(String[] authNames, List queryParams, Map headerParams, Map cookieParams) { for (String authName : authNames) { Authentication auth = authentications.get(authName); if (auth == null) { throw new RuntimeException("Authentication undefined: " + authName); } - auth.applyToParams(queryParams, headerParams); + auth.applyToParams(queryParams, headerParams, cookieParams); } } @@ -1211,8 +1246,8 @@ public Response intercept(Interceptor.Chain chain) throws IOException { */ private void applySslSettings() { try { - TrustManager[] trustManagers = null; - HostnameVerifier hostnameVerifier = null; + TrustManager[] trustManagers; + HostnameVerifier hostnameVerifier; if (!verifyingSsl) { trustManagers = new TrustManager[]{ new X509TrustManager() { @@ -1230,40 +1265,42 @@ public java.security.cert.X509Certificate[] getAcceptedIssuers() { } } }; - SSLContext sslContext = SSLContext.getInstance("TLS"); hostnameVerifier = new HostnameVerifier() { @Override public boolean verify(String hostname, SSLSession session) { return true; } }; - } else if (sslCaCert != null) { - 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); - } + } else { TrustManagerFactory trustManagerFactory = TrustManagerFactory.getInstance(TrustManagerFactory.getDefaultAlgorithm()); - trustManagerFactory.init(caKeyStore); - trustManagers = trustManagerFactory.getTrustManagers(); - } - if (keyManagers != null || trustManagers != null) { - SSLContext sslContext = SSLContext.getInstance("TLS"); - sslContext.init(keyManagers, trustManagers, new SecureRandom()); - httpClient = httpClient.newBuilder().sslSocketFactory(sslContext.getSocketFactory(), (X509TrustManager) trustManagers[0]).build(); - } else { - httpClient = httpClient.newBuilder().sslSocketFactory(null, (X509TrustManager) trustManagers[0]).build(); + 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; } - httpClient = httpClient.newBuilder().hostnameVerifier(hostnameVerifier).build(); + 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); } diff --git a/src/main/java/org/omg/sysml/api/CommitApi.java b/src/main/java/org/omg/sysml/api/CommitApi.java new file mode 100644 index 0000000..a18bb81 --- /dev/null +++ b/src/main/java/org/omg/sysml/api/CommitApi.java @@ -0,0 +1,582 @@ +/* + * SysML v2 API and Services + * REST/HTTP binding (PSM) for the SysML v2 standard API. + * + * The version of the OpenAPI document: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package org.omg.sysml.api; + +import org.omg.sysml.ApiCallback; +import org.omg.sysml.ApiClient; +import org.omg.sysml.ApiException; +import org.omg.sysml.ApiResponse; +import org.omg.sysml.Configuration; +import org.omg.sysml.Pair; +import org.omg.sysml.ProgressRequestBody; +import org.omg.sysml.ProgressResponseBody; + +import com.google.gson.reflect.TypeToken; + +import java.io.IOException; + + +import org.omg.sysml.model.Commit; +import org.omg.sysml.model.Error; +import java.util.UUID; + +import java.lang.reflect.Type; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class CommitApi { + private ApiClient localVarApiClient; + + public CommitApi() { + this(Configuration.getDefaultApiClient()); + } + + public CommitApi(ApiClient apiClient) { + this.localVarApiClient = apiClient; + } + + public ApiClient getApiClient() { + return localVarApiClient; + } + + public void setApiClient(ApiClient apiClient) { + this.localVarApiClient = apiClient; + } + + /** + * Build call for getCommitByProjectAndId + * @param projectId ID of the project (required) + * @param commitId ID of the commit (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 -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
+ */ + public okhttp3.Call getCommitByProjectAndIdCall(String projectId, String commitId, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = "/projects/{projectId}/commits/{commitId}" + .replaceAll("\\{" + "projectId" + "\\}", localVarApiClient.escapeString(projectId.toString())) + .replaceAll("\\{" + "commitId" + "\\}", localVarApiClient.escapeString(commitId.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); + localVarHeaderParams.put("Content-Type", localVarContentType); + + String[] localVarAuthNames = new String[] { }; + return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call getCommitByProjectAndIdValidateBeforeCall(String projectId, String commitId, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException("Missing the required parameter 'projectId' when calling getCommitByProjectAndId(Async)"); + } + + // verify the required parameter 'commitId' is set + if (commitId == null) { + throw new ApiException("Missing the required parameter 'commitId' when calling getCommitByProjectAndId(Async)"); + } + + + okhttp3.Call localVarCall = getCommitByProjectAndIdCall(projectId, commitId, _callback); + return localVarCall; + + } + + /** + * Get commit by project and ID + * + * @param projectId ID of the project (required) + * @param commitId ID of the commit (required) + * @return Commit + * @throws ApiException 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 -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
+ */ + public Commit getCommitByProjectAndId(String projectId, String commitId) throws ApiException { + ApiResponse localVarResp = getCommitByProjectAndIdWithHttpInfo(projectId, commitId); + return localVarResp.getData(); + } + + /** + * Get commit by project and ID + * + * @param projectId ID of the project (required) + * @param commitId ID of the commit (required) + * @return ApiResponse<Commit> + * @throws ApiException 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 -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
+ */ + public ApiResponse getCommitByProjectAndIdWithHttpInfo(String projectId, String commitId) throws ApiException { + okhttp3.Call localVarCall = getCommitByProjectAndIdValidateBeforeCall(projectId, commitId, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Get commit by project and ID (asynchronously) + * + * @param projectId ID of the project (required) + * @param commitId ID of the commit (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 -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
+ */ + public okhttp3.Call getCommitByProjectAndIdAsync(String projectId, String commitId, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = getCommitByProjectAndIdValidateBeforeCall(projectId, commitId, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } + /** + * Build call for getCommitsByProject + * @param projectId ID of the project (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 -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
+ */ + public okhttp3.Call getCommitsByProjectCall(UUID projectId, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = "/projects/{projectId}/commits" + .replaceAll("\\{" + "projectId" + "\\}", localVarApiClient.escapeString(projectId.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); + localVarHeaderParams.put("Content-Type", localVarContentType); + + String[] localVarAuthNames = new String[] { }; + return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call getCommitsByProjectValidateBeforeCall(UUID projectId, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException("Missing the required parameter 'projectId' when calling getCommitsByProject(Async)"); + } + + + okhttp3.Call localVarCall = getCommitsByProjectCall(projectId, _callback); + return localVarCall; + + } + + /** + * Get commits by project + * + * @param projectId ID of the project (required) + * @return Commit + * @throws ApiException 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 -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
+ */ + public Commit getCommitsByProject(UUID projectId) throws ApiException { + ApiResponse localVarResp = getCommitsByProjectWithHttpInfo(projectId); + return localVarResp.getData(); + } + + /** + * Get commits by project + * + * @param projectId ID of the project (required) + * @return ApiResponse<Commit> + * @throws ApiException 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 -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
+ */ + public ApiResponse getCommitsByProjectWithHttpInfo(UUID projectId) throws ApiException { + okhttp3.Call localVarCall = getCommitsByProjectValidateBeforeCall(projectId, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Get commits by project (asynchronously) + * + * @param projectId ID of the project (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 -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
+ */ + public okhttp3.Call getCommitsByProjectAsync(UUID projectId, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = getCommitsByProjectValidateBeforeCall(projectId, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } + /** + * Build call for getHeadCommitByProject + * @param projectId ID of the project (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 -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
+ */ + public okhttp3.Call getHeadCommitByProjectCall(String projectId, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = "/projects/{projectId}/head" + .replaceAll("\\{" + "projectId" + "\\}", localVarApiClient.escapeString(projectId.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); + localVarHeaderParams.put("Content-Type", localVarContentType); + + String[] localVarAuthNames = new String[] { }; + return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call getHeadCommitByProjectValidateBeforeCall(String projectId, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException("Missing the required parameter 'projectId' when calling getHeadCommitByProject(Async)"); + } + + + okhttp3.Call localVarCall = getHeadCommitByProjectCall(projectId, _callback); + return localVarCall; + + } + + /** + * Get head commit by project + * + * @param projectId ID of the project (required) + * @return Commit + * @throws ApiException 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 -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
+ */ + public Commit getHeadCommitByProject(String projectId) throws ApiException { + ApiResponse localVarResp = getHeadCommitByProjectWithHttpInfo(projectId); + return localVarResp.getData(); + } + + /** + * Get head commit by project + * + * @param projectId ID of the project (required) + * @return ApiResponse<Commit> + * @throws ApiException 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 -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
+ */ + public ApiResponse getHeadCommitByProjectWithHttpInfo(String projectId) throws ApiException { + okhttp3.Call localVarCall = getHeadCommitByProjectValidateBeforeCall(projectId, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Get head commit by project (asynchronously) + * + * @param projectId ID of the project (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 -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
+ */ + public okhttp3.Call getHeadCommitByProjectAsync(String projectId, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = getHeadCommitByProjectValidateBeforeCall(projectId, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } + /** + * Build call for postCommitByProject + * @param projectId ID of the project (required) + * @param body (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 Created -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
+ */ + public okhttp3.Call postCommitByProjectCall(UUID projectId, Commit body, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = body; + + // create path and map variables + String localVarPath = "/projects/{projectId}/commits" + .replaceAll("\\{" + "projectId" + "\\}", localVarApiClient.escapeString(projectId.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); + localVarHeaderParams.put("Content-Type", localVarContentType); + + String[] localVarAuthNames = new String[] { }; + return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call postCommitByProjectValidateBeforeCall(UUID projectId, Commit body, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException("Missing the required parameter 'projectId' when calling postCommitByProject(Async)"); + } + + // verify the required parameter 'body' is set + if (body == null) { + throw new ApiException("Missing the required parameter 'body' when calling postCommitByProject(Async)"); + } + + + okhttp3.Call localVarCall = postCommitByProjectCall(projectId, body, _callback); + return localVarCall; + + } + + /** + * Create commit by project + * + * @param projectId ID of the project (required) + * @param body (required) + * @return Commit + * @throws ApiException 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 Created -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
+ */ + public Commit postCommitByProject(UUID projectId, Commit body) throws ApiException { + ApiResponse localVarResp = postCommitByProjectWithHttpInfo(projectId, body); + return localVarResp.getData(); + } + + /** + * Create commit by project + * + * @param projectId ID of the project (required) + * @param body (required) + * @return ApiResponse<Commit> + * @throws ApiException 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 Created -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
+ */ + public ApiResponse postCommitByProjectWithHttpInfo(UUID projectId, Commit body) throws ApiException { + okhttp3.Call localVarCall = postCommitByProjectValidateBeforeCall(projectId, body, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Create commit by project (asynchronously) + * + * @param projectId ID of the project (required) + * @param body (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 Created -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
+ */ + public okhttp3.Call postCommitByProjectAsync(UUID projectId, Commit body, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = postCommitByProjectValidateBeforeCall(projectId, body, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } +} diff --git a/src/main/java/org/omg/sysml/api/ElementApi.java b/src/main/java/org/omg/sysml/api/ElementApi.java index 10114e8..51f28a5 100644 --- a/src/main/java/org/omg/sysml/api/ElementApi.java +++ b/src/main/java/org/omg/sysml/api/ElementApi.java @@ -29,6 +29,7 @@ import org.omg.sysml.model.Element; import org.omg.sysml.model.Error; +import java.util.UUID; import java.lang.reflect.Type; import java.util.ArrayList; @@ -56,129 +57,10 @@ public void setApiClient(ApiClient apiClient) { } /** - * Build call for createElement - * @param body (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 Created -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public okhttp3.Call createElementCall(Map body, final ApiCallback _callback) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/elements"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = 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); - localVarHeaderParams.put("Content-Type", localVarContentType); - - String[] localVarAuthNames = new String[] { }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call createElementValidateBeforeCall(Map body, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling createElement(Async)"); - } - - - okhttp3.Call localVarCall = createElementCall(body, _callback); - return localVarCall; - - } - - /** - * Add a new element - * - * @param body (required) - * @return Element - * @throws ApiException 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 Created -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public Element createElement(Map body) throws ApiException { - ApiResponse localVarResp = createElementWithHttpInfo(body); - return localVarResp.getData(); - } - - /** - * Add a new element - * - * @param body (required) - * @return ApiResponse<Element> - * @throws ApiException 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 Created -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public ApiResponse createElementWithHttpInfo(Map body) throws ApiException { - okhttp3.Call localVarCall = createElementValidateBeforeCall(body, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * Add a new element (asynchronously) - * - * @param body (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 Created -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public okhttp3.Call createElementAsync(Map body, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = createElementValidateBeforeCall(body, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getElement - * @param identifier ID of the element (required) + * Build call for getElementByProjectCommitId + * @param projectId ID of the project (required) + * @param commitId ID of the commit (required) + * @param elementId ID of the element (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -192,16 +74,19 @@ public okhttp3.Call createElementAsync(Map body, final ApiCallba 0 Unexpected response. - */ - public okhttp3.Call getElementCall(String identifier, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getElementByProjectCommitIdCall(UUID projectId, UUID commitId, UUID elementId, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables - String localVarPath = "/elements/{identifier}" - .replaceAll("\\{" + "identifier" + "\\}", localVarApiClient.escapeString(identifier.toString())); + String localVarPath = "/projects/{projectId}/commits/{commitId}/elements/{elementId}" + .replaceAll("\\{" + "projectId" + "\\}", localVarApiClient.escapeString(projectId.toString())) + .replaceAll("\\{" + "commitId" + "\\}", localVarApiClient.escapeString(commitId.toString())) + .replaceAll("\\{" + "elementId" + "\\}", localVarApiClient.escapeString(elementId.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" @@ -218,161 +103,39 @@ public okhttp3.Call getElementCall(String identifier, final ApiCallback _callbac localVarHeaderParams.put("Content-Type", localVarContentType); String[] localVarAuthNames = new String[] { }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") - private okhttp3.Call getElementValidateBeforeCall(String identifier, final ApiCallback _callback) throws ApiException { + private okhttp3.Call getElementByProjectCommitIdValidateBeforeCall(UUID projectId, UUID commitId, UUID elementId, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'identifier' is set - if (identifier == null) { - throw new ApiException("Missing the required parameter 'identifier' when calling getElement(Async)"); - } - - - okhttp3.Call localVarCall = getElementCall(identifier, _callback); - return localVarCall; - - } - - /** - * Get element by its ID - * - * @param identifier ID of the element (required) - * @return Element - * @throws ApiException 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 -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public Element getElement(String identifier) throws ApiException { - ApiResponse localVarResp = getElementWithHttpInfo(identifier); - return localVarResp.getData(); - } - - /** - * Get element by its ID - * - * @param identifier ID of the element (required) - * @return ApiResponse<Element> - * @throws ApiException 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 -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public ApiResponse getElementWithHttpInfo(String identifier) throws ApiException { - okhttp3.Call localVarCall = getElementValidateBeforeCall(identifier, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * Get element by its ID (asynchronously) - * - * @param identifier ID of the element (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 -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public okhttp3.Call getElementAsync(String identifier, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getElementValidateBeforeCall(identifier, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getElementByProjectAndId - * @param projectIdentifier ID of the project (required) - * @param elementIdentifier ID of the element (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 -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public okhttp3.Call getElementByProjectAndIdCall(String projectIdentifier, String elementIdentifier, final ApiCallback _callback) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/projects/{project_identifier}/elements/{element_identifier}" - .replaceAll("\\{" + "project_identifier" + "\\}", localVarApiClient.escapeString(projectIdentifier.toString())) - .replaceAll("\\{" + "element_identifier" + "\\}", localVarApiClient.escapeString(elementIdentifier.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarFormParams = new HashMap(); - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException("Missing the required parameter 'projectId' when calling getElementByProjectCommitId(Async)"); } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - String[] localVarAuthNames = new String[] { }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getElementByProjectAndIdValidateBeforeCall(String projectIdentifier, String elementIdentifier, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectIdentifier' is set - if (projectIdentifier == null) { - throw new ApiException("Missing the required parameter 'projectIdentifier' when calling getElementByProjectAndId(Async)"); + // verify the required parameter 'commitId' is set + if (commitId == null) { + throw new ApiException("Missing the required parameter 'commitId' when calling getElementByProjectCommitId(Async)"); } - // verify the required parameter 'elementIdentifier' is set - if (elementIdentifier == null) { - throw new ApiException("Missing the required parameter 'elementIdentifier' when calling getElementByProjectAndId(Async)"); + // verify the required parameter 'elementId' is set + if (elementId == null) { + throw new ApiException("Missing the required parameter 'elementId' when calling getElementByProjectCommitId(Async)"); } - okhttp3.Call localVarCall = getElementByProjectAndIdCall(projectIdentifier, elementIdentifier, _callback); + okhttp3.Call localVarCall = getElementByProjectCommitIdCall(projectId, commitId, elementId, _callback); return localVarCall; } /** - * Get element by project ID and its ID + * Get element by project, commit and ID * - * @param projectIdentifier ID of the project (required) - * @param elementIdentifier ID of the element (required) + * @param projectId ID of the project (required) + * @param commitId ID of the commit (required) + * @param elementId ID of the element (required) * @return Element * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -385,16 +148,17 @@ private okhttp3.Call getElementByProjectAndIdValidateBeforeCall(String projectId 0 Unexpected response. - */ - public Element getElementByProjectAndId(String projectIdentifier, String elementIdentifier) throws ApiException { - ApiResponse localVarResp = getElementByProjectAndIdWithHttpInfo(projectIdentifier, elementIdentifier); + public Element getElementByProjectCommitId(UUID projectId, UUID commitId, UUID elementId) throws ApiException { + ApiResponse localVarResp = getElementByProjectCommitIdWithHttpInfo(projectId, commitId, elementId); return localVarResp.getData(); } /** - * Get element by project ID and its ID + * Get element by project, commit and ID * - * @param projectIdentifier ID of the project (required) - * @param elementIdentifier ID of the element (required) + * @param projectId ID of the project (required) + * @param commitId ID of the commit (required) + * @param elementId ID of the element (required) * @return ApiResponse<Element> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -407,17 +171,18 @@ public Element getElementByProjectAndId(String projectIdentifier, String element 0 Unexpected response. - */ - public ApiResponse getElementByProjectAndIdWithHttpInfo(String projectIdentifier, String elementIdentifier) throws ApiException { - okhttp3.Call localVarCall = getElementByProjectAndIdValidateBeforeCall(projectIdentifier, elementIdentifier, null); + public ApiResponse getElementByProjectCommitIdWithHttpInfo(UUID projectId, UUID commitId, UUID elementId) throws ApiException { + okhttp3.Call localVarCall = getElementByProjectCommitIdValidateBeforeCall(projectId, commitId, elementId, null); Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get element by project ID and its ID (asynchronously) + * Get element by project, commit and ID (asynchronously) * - * @param projectIdentifier ID of the project (required) - * @param elementIdentifier ID of the element (required) + * @param projectId ID of the project (required) + * @param commitId ID of the commit (required) + * @param elementId ID of the element (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 @@ -431,15 +196,17 @@ public ApiResponse getElementByProjectAndIdWithHttpInfo(String projectI 0 Unexpected response. - */ - public okhttp3.Call getElementByProjectAndIdAsync(String projectIdentifier, String elementIdentifier, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getElementByProjectCommitIdAsync(UUID projectId, UUID commitId, UUID elementId, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getElementByProjectAndIdValidateBeforeCall(projectIdentifier, elementIdentifier, _callback); + okhttp3.Call localVarCall = getElementByProjectCommitIdValidateBeforeCall(projectId, commitId, elementId, _callback); Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getElements + * Build call for getElementsByProjectCommit + * @param projectId ID of the project (required) + * @param commitId ID of the commit (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -447,20 +214,24 @@ public okhttp3.Call getElementByProjectAndIdAsync(String projectIdentifier, Stri +
Status Code Description Response Headers
200 Ok -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
*/ - public okhttp3.Call getElementsCall(final ApiCallback _callback) throws ApiException { + public okhttp3.Call getElementsByProjectCommitCall(UUID projectId, UUID commitId, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables - String localVarPath = "/elements"; + String localVarPath = "/projects/{projectId}/commits/{commitId}/elements" + .replaceAll("\\{" + "projectId" + "\\}", localVarApiClient.escapeString(projectId.toString())) + .replaceAll("\\{" + "commitId" + "\\}", localVarApiClient.escapeString(commitId.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" @@ -477,142 +248,33 @@ public okhttp3.Call getElementsCall(final ApiCallback _callback) throws ApiExcep localVarHeaderParams.put("Content-Type", localVarContentType); String[] localVarAuthNames = new String[] { }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") - private okhttp3.Call getElementsValidateBeforeCall(final ApiCallback _callback) throws ApiException { + private okhttp3.Call getElementsByProjectCommitValidateBeforeCall(UUID projectId, UUID commitId, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getElementsCall(_callback); - return localVarCall; - - } - - /** - * Get all elements - * - * @return List<Element> - * @throws ApiException 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 -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public List getElements() throws ApiException { - ApiResponse> localVarResp = getElementsWithHttpInfo(); - return localVarResp.getData(); - } - - /** - * Get all elements - * - * @return ApiResponse<List<Element>> - * @throws ApiException 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 -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public ApiResponse> getElementsWithHttpInfo() throws ApiException { - okhttp3.Call localVarCall = getElementsValidateBeforeCall(null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * Get all elements (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 Ok -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public okhttp3.Call getElementsAsync(final ApiCallback> _callback) throws ApiException { - - okhttp3.Call localVarCall = getElementsValidateBeforeCall(_callback); - Type localVarReturnType = new TypeToken>(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getElementsInProject - * @param projectIdentifier ID of the project (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 -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public okhttp3.Call getElementsInProjectCall(String projectIdentifier, final ApiCallback _callback) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/projects/{project_identifier}/elements" - .replaceAll("\\{" + "project_identifier" + "\\}", localVarApiClient.escapeString(projectIdentifier.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarFormParams = new HashMap(); - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException("Missing the required parameter 'projectId' when calling getElementsByProjectCommit(Async)"); } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - String[] localVarAuthNames = new String[] { }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getElementsInProjectValidateBeforeCall(String projectIdentifier, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectIdentifier' is set - if (projectIdentifier == null) { - throw new ApiException("Missing the required parameter 'projectIdentifier' when calling getElementsInProject(Async)"); + // verify the required parameter 'commitId' is set + if (commitId == null) { + throw new ApiException("Missing the required parameter 'commitId' when calling getElementsByProjectCommit(Async)"); } - okhttp3.Call localVarCall = getElementsInProjectCall(projectIdentifier, _callback); + okhttp3.Call localVarCall = getElementsByProjectCommitCall(projectId, commitId, _callback); return localVarCall; } /** - * Get all elements in the project + * Get elements by project and commit * - * @param projectIdentifier ID of the project (required) + * @param projectId ID of the project (required) + * @param commitId ID of the commit (required) * @return Element * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -625,15 +287,16 @@ private okhttp3.Call getElementsInProjectValidateBeforeCall(String projectIdenti 0 Unexpected response. - */ - public Element getElementsInProject(String projectIdentifier) throws ApiException { - ApiResponse localVarResp = getElementsInProjectWithHttpInfo(projectIdentifier); + public Element getElementsByProjectCommit(UUID projectId, UUID commitId) throws ApiException { + ApiResponse localVarResp = getElementsByProjectCommitWithHttpInfo(projectId, commitId); return localVarResp.getData(); } /** - * Get all elements in the project + * Get elements by project and commit * - * @param projectIdentifier ID of the project (required) + * @param projectId ID of the project (required) + * @param commitId ID of the commit (required) * @return ApiResponse<Element> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -646,16 +309,17 @@ public Element getElementsInProject(String projectIdentifier) throws ApiExceptio 0 Unexpected response. - */ - public ApiResponse getElementsInProjectWithHttpInfo(String projectIdentifier) throws ApiException { - okhttp3.Call localVarCall = getElementsInProjectValidateBeforeCall(projectIdentifier, null); + public ApiResponse getElementsByProjectCommitWithHttpInfo(UUID projectId, UUID commitId) throws ApiException { + okhttp3.Call localVarCall = getElementsByProjectCommitValidateBeforeCall(projectId, commitId, null); Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get all elements in the project (asynchronously) + * Get elements by project and commit (asynchronously) * - * @param projectIdentifier ID of the project (required) + * @param projectId ID of the project (required) + * @param commitId ID of the commit (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 @@ -669,9 +333,9 @@ public ApiResponse getElementsInProjectWithHttpInfo(String projectIdent 0 Unexpected response. - */ - public okhttp3.Call getElementsInProjectAsync(String projectIdentifier, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getElementsByProjectCommitAsync(UUID projectId, UUID commitId, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getElementsInProjectValidateBeforeCall(projectIdentifier, _callback); + okhttp3.Call localVarCall = getElementsByProjectCommitValidateBeforeCall(projectId, commitId, _callback); Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; diff --git a/src/main/java/org/omg/sysml/api/ProjectApi.java b/src/main/java/org/omg/sysml/api/ProjectApi.java index c118bc3..8e03302 100644 --- a/src/main/java/org/omg/sysml/api/ProjectApi.java +++ b/src/main/java/org/omg/sysml/api/ProjectApi.java @@ -29,6 +29,7 @@ import org.omg.sysml.model.Error; import org.omg.sysml.model.Project; +import java.util.UUID; import java.lang.reflect.Type; import java.util.ArrayList; @@ -56,29 +57,32 @@ public void setApiClient(ApiClient apiClient) { } /** - * Build call for createProject - * @param body (optional) + * Build call for getProjectById + * @param projectId ID of the project (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 Created -
200 Ok -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
*/ - public okhttp3.Call createProjectCall(Project body, final ApiCallback _callback) throws ApiException { - Object localVarPostBody = body; + public okhttp3.Call getProjectByIdCall(UUID projectId, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = null; // create path and map variables - String localVarPath = "/projects"; + String localVarPath = "/projects/{projectId}" + .replaceAll("\\{" + "projectId" + "\\}", localVarApiClient.escapeString(projectId.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" @@ -89,91 +93,98 @@ public okhttp3.Call createProjectCall(Project body, final ApiCallback _callback) } final String[] localVarContentTypes = { - "application/json" + }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); localVarHeaderParams.put("Content-Type", localVarContentType); String[] localVarAuthNames = new String[] { }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") - private okhttp3.Call createProjectValidateBeforeCall(Project body, final ApiCallback _callback) throws ApiException { + private okhttp3.Call getProjectByIdValidateBeforeCall(UUID projectId, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException("Missing the required parameter 'projectId' when calling getProjectById(Async)"); + } - okhttp3.Call localVarCall = createProjectCall(body, _callback); + okhttp3.Call localVarCall = getProjectByIdCall(projectId, _callback); return localVarCall; } /** - * Add a new project + * Get project by ID * - * @param body (optional) + * @param projectId ID of the project (required) * @return Project * @throws ApiException 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 Created -
200 Ok -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
*/ - public Project createProject(Project body) throws ApiException { - ApiResponse localVarResp = createProjectWithHttpInfo(body); + public Project getProjectById(UUID projectId) throws ApiException { + ApiResponse localVarResp = getProjectByIdWithHttpInfo(projectId); return localVarResp.getData(); } /** - * Add a new project + * Get project by ID * - * @param body (optional) + * @param projectId ID of the project (required) * @return ApiResponse<Project> * @throws ApiException 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 Created -
200 Ok -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
*/ - public ApiResponse createProjectWithHttpInfo(Project body) throws ApiException { - okhttp3.Call localVarCall = createProjectValidateBeforeCall(body, null); + public ApiResponse getProjectByIdWithHttpInfo(UUID projectId) throws ApiException { + okhttp3.Call localVarCall = getProjectByIdValidateBeforeCall(projectId, null); Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Add a new project (asynchronously) + * Get project by ID (asynchronously) * - * @param body (optional) + * @param projectId ID of the project (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 Created -
200 Ok -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
*/ - public okhttp3.Call createProjectAsync(Project body, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getProjectByIdAsync(UUID projectId, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = createProjectValidateBeforeCall(body, _callback); + okhttp3.Call localVarCall = getProjectByIdValidateBeforeCall(projectId, _callback); Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getProject - * @param identifier ID of the project (required) + * Build call for getProjects * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -181,22 +192,21 @@ public okhttp3.Call createProjectAsync(Project body, final ApiCallback -
Status Code Description Response Headers
200 Ok -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
*/ - public okhttp3.Call getProjectCall(String identifier, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getProjectsCall(final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables - String localVarPath = "/projects/{identifier}" - .replaceAll("\\{" + "identifier" + "\\}", localVarApiClient.escapeString(identifier.toString())); + String localVarPath = "/projects"; 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" @@ -213,70 +223,60 @@ public okhttp3.Call getProjectCall(String identifier, final ApiCallback _callbac localVarHeaderParams.put("Content-Type", localVarContentType); String[] localVarAuthNames = new String[] { }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") - private okhttp3.Call getProjectValidateBeforeCall(String identifier, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'identifier' is set - if (identifier == null) { - throw new ApiException("Missing the required parameter 'identifier' when calling getProject(Async)"); - } + private okhttp3.Call getProjectsValidateBeforeCall(final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getProjectCall(identifier, _callback); + okhttp3.Call localVarCall = getProjectsCall(_callback); return localVarCall; } /** - * Get project by its ID + * Get projects * - * @param identifier ID of the project (required) - * @return Project + * @return List<Project> * @throws ApiException 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 -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
*/ - public Project getProject(String identifier) throws ApiException { - ApiResponse localVarResp = getProjectWithHttpInfo(identifier); + public List getProjects() throws ApiException { + ApiResponse> localVarResp = getProjectsWithHttpInfo(); return localVarResp.getData(); } /** - * Get project by its ID + * Get projects * - * @param identifier ID of the project (required) - * @return ApiResponse<Project> + * @return ApiResponse<List<Project>> * @throws ApiException 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 -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
*/ - public ApiResponse getProjectWithHttpInfo(String identifier) throws ApiException { - okhttp3.Call localVarCall = getProjectValidateBeforeCall(identifier, null); - Type localVarReturnType = new TypeToken(){}.getType(); + public ApiResponse> getProjectsWithHttpInfo() throws ApiException { + okhttp3.Call localVarCall = getProjectsValidateBeforeCall(null); + Type localVarReturnType = new TypeToken>(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get project by its ID (asynchronously) + * Get projects (asynchronously) * - * @param identifier ID of the project (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 @@ -284,35 +284,35 @@ public ApiResponse getProjectWithHttpInfo(String identifier) throws Api -
Status Code Description Response Headers
200 Ok -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
*/ - public okhttp3.Call getProjectAsync(String identifier, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getProjectsAsync(final ApiCallback> _callback) throws ApiException { - okhttp3.Call localVarCall = getProjectValidateBeforeCall(identifier, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + okhttp3.Call localVarCall = getProjectsValidateBeforeCall(_callback); + Type localVarReturnType = new TypeToken>(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getProjects + * Build call for postProject + * @param body (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 Ok -
201 Created -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
*/ - public okhttp3.Call getProjectsCall(final ApiCallback _callback) throws ApiException { - Object localVarPostBody = null; + public okhttp3.Call postProjectCall(Project body, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = body; // create path and map variables String localVarPath = "/projects"; @@ -320,6 +320,7 @@ public okhttp3.Call getProjectsCall(final ApiCallback _callback) throws ApiExcep 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" @@ -330,82 +331,85 @@ public okhttp3.Call getProjectsCall(final ApiCallback _callback) throws ApiExcep } final String[] localVarContentTypes = { - + "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); localVarHeaderParams.put("Content-Type", localVarContentType); String[] localVarAuthNames = new String[] { }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") - private okhttp3.Call getProjectsValidateBeforeCall(final ApiCallback _callback) throws ApiException { + private okhttp3.Call postProjectValidateBeforeCall(Project body, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getProjectsCall(_callback); + okhttp3.Call localVarCall = postProjectCall(body, _callback); return localVarCall; } /** - * Get all projects + * Create project * - * @return List<Project> + * @param body (optional) + * @return Project * @throws ApiException 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 -
201 Created -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
*/ - public List getProjects() throws ApiException { - ApiResponse> localVarResp = getProjectsWithHttpInfo(); + public Project postProject(Project body) throws ApiException { + ApiResponse localVarResp = postProjectWithHttpInfo(body); return localVarResp.getData(); } /** - * Get all projects + * Create project * - * @return ApiResponse<List<Project>> + * @param body (optional) + * @return ApiResponse<Project> * @throws ApiException 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 -
201 Created -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
*/ - public ApiResponse> getProjectsWithHttpInfo() throws ApiException { - okhttp3.Call localVarCall = getProjectsValidateBeforeCall(null); - Type localVarReturnType = new TypeToken>(){}.getType(); + public ApiResponse postProjectWithHttpInfo(Project body) throws ApiException { + okhttp3.Call localVarCall = postProjectValidateBeforeCall(body, null); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get all projects (asynchronously) + * Create project (asynchronously) * + * @param body (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 Ok -
201 Created -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
*/ - public okhttp3.Call getProjectsAsync(final ApiCallback> _callback) throws ApiException { + public okhttp3.Call postProjectAsync(Project body, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getProjectsValidateBeforeCall(_callback); - Type localVarReturnType = new TypeToken>(){}.getType(); + okhttp3.Call localVarCall = postProjectValidateBeforeCall(body, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } diff --git a/src/main/java/org/omg/sysml/api/RelationshipApi.java b/src/main/java/org/omg/sysml/api/RelationshipApi.java index 077674b..b57daed 100644 --- a/src/main/java/org/omg/sysml/api/RelationshipApi.java +++ b/src/main/java/org/omg/sysml/api/RelationshipApi.java @@ -29,6 +29,7 @@ import org.omg.sysml.model.Error; import org.omg.sysml.model.Relationship; +import java.util.UUID; import java.lang.reflect.Type; import java.util.ArrayList; @@ -56,129 +57,10 @@ public void setApiClient(ApiClient apiClient) { } /** - * Build call for createRelationship - * @param body (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 Created -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public okhttp3.Call createRelationshipCall(Relationship body, final ApiCallback _callback) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/relationships"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = 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); - localVarHeaderParams.put("Content-Type", localVarContentType); - - String[] localVarAuthNames = new String[] { }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call createRelationshipValidateBeforeCall(Relationship body, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling createRelationship(Async)"); - } - - - okhttp3.Call localVarCall = createRelationshipCall(body, _callback); - return localVarCall; - - } - - /** - * Add a new relationship - * - * @param body (required) - * @return Relationship - * @throws ApiException 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 Created -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public Relationship createRelationship(Relationship body) throws ApiException { - ApiResponse localVarResp = createRelationshipWithHttpInfo(body); - return localVarResp.getData(); - } - - /** - * Add a new relationship - * - * @param body (required) - * @return ApiResponse<Relationship> - * @throws ApiException 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 Created -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public ApiResponse createRelationshipWithHttpInfo(Relationship body) throws ApiException { - okhttp3.Call localVarCall = createRelationshipValidateBeforeCall(body, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * Add a new relationship (asynchronously) - * - * @param body (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 Created -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public okhttp3.Call createRelationshipAsync(Relationship body, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = createRelationshipValidateBeforeCall(body, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getRelationship - * @param identifier ID of the relationship (required) + * Build call for getRelationshipsByProjectCommitRelatedElement + * @param projectId ID of the project (required) + * @param commitId ID of the commit (required) + * @param relatedElementId ID of the related element (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -186,22 +68,24 @@ public okhttp3.Call createRelationshipAsync(Relationship body, final ApiCallback -
Status Code Description Response Headers
200 Ok -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
*/ - public okhttp3.Call getRelationshipCall(String identifier, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getRelationshipsByProjectCommitRelatedElementCall(UUID projectId, UUID commitId, UUID relatedElementId, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables - String localVarPath = "/relationships/{identifier}" - .replaceAll("\\{" + "identifier" + "\\}", localVarApiClient.escapeString(identifier.toString())); + String localVarPath = "/projects/{projectId}/commits/{commitId}/elements/{relatedElementId}/relationships" + .replaceAll("\\{" + "projectId" + "\\}", localVarApiClient.escapeString(projectId.toString())) + .replaceAll("\\{" + "commitId" + "\\}", localVarApiClient.escapeString(commitId.toString())) + .replaceAll("\\{" + "relatedElementId" + "\\}", localVarApiClient.escapeString(relatedElementId.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" @@ -218,264 +102,39 @@ public okhttp3.Call getRelationshipCall(String identifier, final ApiCallback _ca localVarHeaderParams.put("Content-Type", localVarContentType); String[] localVarAuthNames = new String[] { }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") - private okhttp3.Call getRelationshipValidateBeforeCall(String identifier, final ApiCallback _callback) throws ApiException { + private okhttp3.Call getRelationshipsByProjectCommitRelatedElementValidateBeforeCall(UUID projectId, UUID commitId, UUID relatedElementId, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'identifier' is set - if (identifier == null) { - throw new ApiException("Missing the required parameter 'identifier' when calling getRelationship(Async)"); - } - - - okhttp3.Call localVarCall = getRelationshipCall(identifier, _callback); - return localVarCall; - - } - - /** - * Get relationship by its ID - * - * @param identifier ID of the relationship (required) - * @return Relationship - * @throws ApiException 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 -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public Relationship getRelationship(String identifier) throws ApiException { - ApiResponse localVarResp = getRelationshipWithHttpInfo(identifier); - return localVarResp.getData(); - } - - /** - * Get relationship by its ID - * - * @param identifier ID of the relationship (required) - * @return ApiResponse<Relationship> - * @throws ApiException 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 -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public ApiResponse getRelationshipWithHttpInfo(String identifier) throws ApiException { - okhttp3.Call localVarCall = getRelationshipValidateBeforeCall(identifier, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * Get relationship by its ID (asynchronously) - * - * @param identifier ID of the relationship (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 -
404 Not found. -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public okhttp3.Call getRelationshipAsync(String identifier, final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getRelationshipValidateBeforeCall(identifier, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getRelationships - * @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 -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public okhttp3.Call getRelationshipsCall(final ApiCallback _callback) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/relationships"; - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarFormParams = new HashMap(); - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException("Missing the required parameter 'projectId' when calling getRelationshipsByProjectCommitRelatedElement(Async)"); } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - String[] localVarAuthNames = new String[] { }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getRelationshipsValidateBeforeCall(final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = getRelationshipsCall(_callback); - return localVarCall; - - } - - /** - * Get all relationships - * - * @return List<Relationship> - * @throws ApiException 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 -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public List getRelationships() throws ApiException { - ApiResponse> localVarResp = getRelationshipsWithHttpInfo(); - return localVarResp.getData(); - } - - /** - * Get all relationships - * - * @return ApiResponse<List<Relationship>> - * @throws ApiException 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 -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public ApiResponse> getRelationshipsWithHttpInfo() throws ApiException { - okhttp3.Call localVarCall = getRelationshipsValidateBeforeCall(null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); - } - - /** - * Get all relationships (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 Ok -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public okhttp3.Call getRelationshipsAsync(final ApiCallback> _callback) throws ApiException { - - okhttp3.Call localVarCall = getRelationshipsValidateBeforeCall(_callback); - Type localVarReturnType = new TypeToken>(){}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); - return localVarCall; - } - /** - * Build call for getRelationshipsByProject - * @param projectIdentifier ID of the project (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 -
415 The requested content type is not acceptable. -
500 Internal server error. -
0 Unexpected response. -
- */ - public okhttp3.Call getRelationshipsByProjectCall(String projectIdentifier, final ApiCallback _callback) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/projects/{project_identifier}/relationships" - .replaceAll("\\{" + "project_identifier" + "\\}", localVarApiClient.escapeString(projectIdentifier.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarFormParams = new HashMap(); - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); + // verify the required parameter 'commitId' is set + if (commitId == null) { + throw new ApiException("Missing the required parameter 'commitId' when calling getRelationshipsByProjectCommitRelatedElement(Async)"); } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - String[] localVarAuthNames = new String[] { }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getRelationshipsByProjectValidateBeforeCall(String projectIdentifier, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectIdentifier' is set - if (projectIdentifier == null) { - throw new ApiException("Missing the required parameter 'projectIdentifier' when calling getRelationshipsByProject(Async)"); + // verify the required parameter 'relatedElementId' is set + if (relatedElementId == null) { + throw new ApiException("Missing the required parameter 'relatedElementId' when calling getRelationshipsByProjectCommitRelatedElement(Async)"); } - okhttp3.Call localVarCall = getRelationshipsByProjectCall(projectIdentifier, _callback); + okhttp3.Call localVarCall = getRelationshipsByProjectCommitRelatedElementCall(projectId, commitId, relatedElementId, _callback); return localVarCall; } /** - * Get all relationships in the project + * Get relationships by project, commit, and related element. * - * @param projectIdentifier ID of the project (required) + * @param projectId ID of the project (required) + * @param commitId ID of the commit (required) + * @param relatedElementId ID of the related element (required) * @return List<Relationship> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -487,15 +146,17 @@ private okhttp3.Call getRelationshipsByProjectValidateBeforeCall(String projectI 0 Unexpected response. - */ - public List getRelationshipsByProject(String projectIdentifier) throws ApiException { - ApiResponse> localVarResp = getRelationshipsByProjectWithHttpInfo(projectIdentifier); + public List getRelationshipsByProjectCommitRelatedElement(UUID projectId, UUID commitId, UUID relatedElementId) throws ApiException { + ApiResponse> localVarResp = getRelationshipsByProjectCommitRelatedElementWithHttpInfo(projectId, commitId, relatedElementId); return localVarResp.getData(); } /** - * Get all relationships in the project + * Get relationships by project, commit, and related element. * - * @param projectIdentifier ID of the project (required) + * @param projectId ID of the project (required) + * @param commitId ID of the commit (required) + * @param relatedElementId ID of the related element (required) * @return ApiResponse<List<Relationship>> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -507,16 +168,18 @@ public List getRelationshipsByProject(String projectIdentifier) th 0 Unexpected response. - */ - public ApiResponse> getRelationshipsByProjectWithHttpInfo(String projectIdentifier) throws ApiException { - okhttp3.Call localVarCall = getRelationshipsByProjectValidateBeforeCall(projectIdentifier, null); + public ApiResponse> getRelationshipsByProjectCommitRelatedElementWithHttpInfo(UUID projectId, UUID commitId, UUID relatedElementId) throws ApiException { + okhttp3.Call localVarCall = getRelationshipsByProjectCommitRelatedElementValidateBeforeCall(projectId, commitId, relatedElementId, null); Type localVarReturnType = new TypeToken>(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get all relationships in the project (asynchronously) + * Get relationships by project, commit, and related element. (asynchronously) * - * @param projectIdentifier ID of the project (required) + * @param projectId ID of the project (required) + * @param commitId ID of the commit (required) + * @param relatedElementId ID of the related element (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 @@ -529,9 +192,9 @@ public ApiResponse> getRelationshipsByProjectWithHttpInfo(Str 0 Unexpected response. - */ - public okhttp3.Call getRelationshipsByProjectAsync(String projectIdentifier, final ApiCallback> _callback) throws ApiException { + public okhttp3.Call getRelationshipsByProjectCommitRelatedElementAsync(UUID projectId, UUID commitId, UUID relatedElementId, final ApiCallback> _callback) throws ApiException { - okhttp3.Call localVarCall = getRelationshipsByProjectValidateBeforeCall(projectIdentifier, _callback); + okhttp3.Call localVarCall = getRelationshipsByProjectCommitRelatedElementValidateBeforeCall(projectId, commitId, relatedElementId, _callback); Type localVarReturnType = new TypeToken>(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; diff --git a/src/main/java/org/omg/sysml/auth/ApiKeyAuth.java b/src/main/java/org/omg/sysml/auth/ApiKeyAuth.java index 8396764..148c2af 100644 --- a/src/main/java/org/omg/sysml/auth/ApiKeyAuth.java +++ b/src/main/java/org/omg/sysml/auth/ApiKeyAuth.java @@ -56,7 +56,7 @@ public void setApiKeyPrefix(String apiKeyPrefix) { } @Override - public void applyToParams(List queryParams, Map headerParams) { + public void applyToParams(List queryParams, Map headerParams, Map cookieParams) { if (apiKey == null) { return; } @@ -70,6 +70,8 @@ public void applyToParams(List queryParams, Map headerPara 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/org/omg/sysml/auth/Authentication.java b/src/main/java/org/omg/sysml/auth/Authentication.java index 7648ffc..d4e03b1 100644 --- a/src/main/java/org/omg/sysml/auth/Authentication.java +++ b/src/main/java/org/omg/sysml/auth/Authentication.java @@ -24,6 +24,7 @@ public interface Authentication { * * @param queryParams List of query parameters * @param headerParams Map of header parameters + * @param cookieParams Map of cookie parameters */ - void applyToParams(List queryParams, Map headerParams); + void applyToParams(List queryParams, Map headerParams, Map cookieParams); } diff --git a/src/main/java/org/omg/sysml/auth/HttpBasicAuth.java b/src/main/java/org/omg/sysml/auth/HttpBasicAuth.java index eb2ad08..aee276a 100644 --- a/src/main/java/org/omg/sysml/auth/HttpBasicAuth.java +++ b/src/main/java/org/omg/sysml/auth/HttpBasicAuth.java @@ -43,7 +43,7 @@ public void setPassword(String password) { } @Override - public void applyToParams(List queryParams, Map headerParams) { + public void applyToParams(List queryParams, Map headerParams, Map cookieParams) { if (username == null && password == null) { return; } diff --git a/src/main/java/org/omg/sysml/auth/HttpBearerAuth.java b/src/main/java/org/omg/sysml/auth/HttpBearerAuth.java index ccfda10..fb2b7b4 100644 --- a/src/main/java/org/omg/sysml/auth/HttpBearerAuth.java +++ b/src/main/java/org/omg/sysml/auth/HttpBearerAuth.java @@ -46,7 +46,7 @@ public void setBearerToken(String bearerToken) { } @Override - public void applyToParams(List queryParams, Map headerParams) { + public void applyToParams(List queryParams, Map headerParams, Map cookieParams) { if(bearerToken == null) { return; } diff --git a/src/main/java/org/omg/sysml/model/Commit.java b/src/main/java/org/omg/sysml/model/Commit.java new file mode 100644 index 0000000..c357d7d --- /dev/null +++ b/src/main/java/org/omg/sysml/model/Commit.java @@ -0,0 +1,244 @@ +/* + * SysML v2 API and Services + * REST/HTTP binding (PSM) for the SysML v2 standard API. + * + * The version of the OpenAPI document: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package org.omg.sysml.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +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 java.util.UUID; +import org.omg.sysml.model.ElementVersion; +import org.omg.sysml.model.Record; + +/** + * Commit + */ + +public class Commit { + /** + * Gets or Sets atType + */ + @JsonAdapter(AtTypeEnum.Adapter.class) + public enum AtTypeEnum { + COMMIT("Commit"); + + private String value; + + AtTypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static AtTypeEnum fromValue(String value) { + for (AtTypeEnum b : AtTypeEnum.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 AtTypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public AtTypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return AtTypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_AT_TYPE = "@type"; + @SerializedName(SERIALIZED_NAME_AT_TYPE) + private AtTypeEnum atType; + + public static final String SERIALIZED_NAME_CHANGES = "changes"; + @SerializedName(SERIALIZED_NAME_CHANGES) + private List changes = null; + + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private UUID id; + + public static final String SERIALIZED_NAME_PREVIOUS_COMMIT = "previousCommit"; + @SerializedName(SERIALIZED_NAME_PREVIOUS_COMMIT) + private Record previousCommit; + + + public Commit atType(AtTypeEnum atType) { + + this.atType = atType; + return this; + } + + /** + * Get atType + * @return atType + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public AtTypeEnum getAtType() { + return atType; + } + + + public void setAtType(AtTypeEnum atType) { + this.atType = atType; + } + + + public Commit changes(List changes) { + + this.changes = changes; + return this; + } + + public Commit addChangesItem(ElementVersion changesItem) { + if (this.changes == null) { + this.changes = new ArrayList(); + } + this.changes.add(changesItem); + return this; + } + + /** + * Get changes + * @return changes + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public List getChanges() { + return changes; + } + + + public void setChanges(List changes) { + this.changes = changes; + } + + + public Commit id(UUID id) { + + this.id = id; + return this; + } + + /** + * Get id + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public UUID getId() { + return id; + } + + + public void setId(UUID id) { + this.id = id; + } + + + public Commit previousCommit(Record previousCommit) { + + this.previousCommit = previousCommit; + return this; + } + + /** + * Get previousCommit + * @return previousCommit + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public Record getPreviousCommit() { + return previousCommit; + } + + + public void setPreviousCommit(Record previousCommit) { + this.previousCommit = previousCommit; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + Commit commit = (Commit) o; + return Objects.equals(this.atType, commit.atType) && + Objects.equals(this.changes, commit.changes) && + Objects.equals(this.id, commit.id) && + Objects.equals(this.previousCommit, commit.previousCommit); + } + + @Override + public int hashCode() { + return Objects.hash(atType, changes, id, previousCommit); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class Commit {\n"); + sb.append(" atType: ").append(toIndentedString(atType)).append("\n"); + sb.append(" changes: ").append(toIndentedString(changes)).append("\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" previousCommit: ").append(toIndentedString(previousCommit)).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(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/org/omg/sysml/model/Element.java b/src/main/java/org/omg/sysml/model/Element.java index 259f544..53b2d25 100644 --- a/src/main/java/org/omg/sysml/model/Element.java +++ b/src/main/java/org/omg/sysml/model/Element.java @@ -26,7 +26,6 @@ import java.util.HashMap; import java.util.Map; import java.util.UUID; -import org.omg.sysml.model.Identified; /** * Element @@ -37,10 +36,6 @@ public class Element extends HashMap { @SerializedName(SERIALIZED_NAME_AT_TYPE) private String atType; - public static final String SERIALIZED_NAME_CONTAINING_PROJECT = "containingProject"; - @SerializedName(SERIALIZED_NAME_CONTAINING_PROJECT) - private Identified containingProject; - public static final String SERIALIZED_NAME_IDENTIFIER = "identifier"; @SerializedName(SERIALIZED_NAME_IDENTIFIER) private UUID identifier; @@ -64,36 +59,11 @@ public String getAtType() { } - public void setAtType(String atType) { this.atType = atType; } - public Element containingProject(Identified containingProject) { - - this.containingProject = containingProject; - return this; - } - - /** - * Get containingProject - * @return containingProject - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Identified getContainingProject() { - return containingProject; - } - - - - public void setContainingProject(Identified containingProject) { - this.containingProject = containingProject; - } - - public Element identifier(UUID identifier) { this.identifier = identifier; @@ -112,7 +82,6 @@ public UUID getIdentifier() { } - public void setIdentifier(UUID identifier) { this.identifier = identifier; } @@ -128,14 +97,13 @@ public boolean equals(java.lang.Object o) { } Element element = (Element) o; return Objects.equals(this.atType, element.atType) && - Objects.equals(this.containingProject, element.containingProject) && Objects.equals(this.identifier, element.identifier) && super.equals(o); } @Override public int hashCode() { - return Objects.hash(atType, containingProject, identifier, super.hashCode()); + return Objects.hash(atType, identifier, super.hashCode()); } @@ -145,7 +113,6 @@ public String toString() { sb.append("class Element {\n"); sb.append(" ").append(toIndentedString(super.toString())).append("\n"); sb.append(" atType: ").append(toIndentedString(atType)).append("\n"); - sb.append(" containingProject: ").append(toIndentedString(containingProject)).append("\n"); sb.append(" identifier: ").append(toIndentedString(identifier)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/org/omg/sysml/model/ElementIdentity.java b/src/main/java/org/omg/sysml/model/ElementIdentity.java new file mode 100644 index 0000000..7ef4977 --- /dev/null +++ b/src/main/java/org/omg/sysml/model/ElementIdentity.java @@ -0,0 +1,174 @@ +/* + * SysML v2 API and Services + * REST/HTTP binding (PSM) for the SysML v2 standard API. + * + * The version of the OpenAPI document: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package org.omg.sysml.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +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.UUID; + +/** + * ElementIdentity + */ + +public class ElementIdentity { + /** + * Gets or Sets atType + */ + @JsonAdapter(AtTypeEnum.Adapter.class) + public enum AtTypeEnum { + ELEMENTIDENTITY("ElementIdentity"); + + private String value; + + AtTypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static AtTypeEnum fromValue(String value) { + for (AtTypeEnum b : AtTypeEnum.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 AtTypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public AtTypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return AtTypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_AT_TYPE = "@type"; + @SerializedName(SERIALIZED_NAME_AT_TYPE) + private AtTypeEnum atType; + + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private UUID id; + + + public ElementIdentity atType(AtTypeEnum atType) { + + this.atType = atType; + return this; + } + + /** + * Get atType + * @return atType + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public AtTypeEnum getAtType() { + return atType; + } + + + public void setAtType(AtTypeEnum atType) { + this.atType = atType; + } + + + public ElementIdentity id(UUID id) { + + this.id = id; + return this; + } + + /** + * Get id + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public UUID getId() { + return id; + } + + + public void setId(UUID id) { + this.id = id; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ElementIdentity elementIdentity = (ElementIdentity) o; + return Objects.equals(this.atType, elementIdentity.atType) && + Objects.equals(this.id, elementIdentity.id); + } + + @Override + public int hashCode() { + return Objects.hash(atType, id); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ElementIdentity {\n"); + sb.append(" atType: ").append(toIndentedString(atType)).append("\n"); + sb.append(" id: ").append(toIndentedString(id)).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(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/org/omg/sysml/model/ElementVersion.java b/src/main/java/org/omg/sysml/model/ElementVersion.java new file mode 100644 index 0000000..aeaaafe --- /dev/null +++ b/src/main/java/org/omg/sysml/model/ElementVersion.java @@ -0,0 +1,234 @@ +/* + * SysML v2 API and Services + * REST/HTTP binding (PSM) for the SysML v2 standard API. + * + * The version of the OpenAPI document: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package org.omg.sysml.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +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.UUID; +import org.omg.sysml.model.Element; +import org.omg.sysml.model.ElementIdentity; + +/** + * ElementVersion + */ + +public class ElementVersion { + /** + * Gets or Sets atType + */ + @JsonAdapter(AtTypeEnum.Adapter.class) + public enum AtTypeEnum { + ELEMENTVERSION("ElementVersion"); + + private String value; + + AtTypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static AtTypeEnum fromValue(String value) { + for (AtTypeEnum b : AtTypeEnum.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 AtTypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public AtTypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return AtTypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_AT_TYPE = "@type"; + @SerializedName(SERIALIZED_NAME_AT_TYPE) + private AtTypeEnum atType; + + public static final String SERIALIZED_NAME_DATA = "data"; + @SerializedName(SERIALIZED_NAME_DATA) + private Element data; + + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private UUID id; + + public static final String SERIALIZED_NAME_IDENTITY = "identity"; + @SerializedName(SERIALIZED_NAME_IDENTITY) + private ElementIdentity identity; + + + public ElementVersion atType(AtTypeEnum atType) { + + this.atType = atType; + return this; + } + + /** + * Get atType + * @return atType + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public AtTypeEnum getAtType() { + return atType; + } + + + public void setAtType(AtTypeEnum atType) { + this.atType = atType; + } + + + public ElementVersion data(Element data) { + + this.data = data; + return this; + } + + /** + * Get data + * @return data + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public Element getData() { + return data; + } + + + public void setData(Element data) { + this.data = data; + } + + + public ElementVersion id(UUID id) { + + this.id = id; + return this; + } + + /** + * Get id + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public UUID getId() { + return id; + } + + + public void setId(UUID id) { + this.id = id; + } + + + public ElementVersion identity(ElementIdentity identity) { + + this.identity = identity; + return this; + } + + /** + * Get identity + * @return identity + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public ElementIdentity getIdentity() { + return identity; + } + + + public void setIdentity(ElementIdentity identity) { + this.identity = identity; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ElementVersion elementVersion = (ElementVersion) o; + return Objects.equals(this.atType, elementVersion.atType) && + Objects.equals(this.data, elementVersion.data) && + Objects.equals(this.id, elementVersion.id) && + Objects.equals(this.identity, elementVersion.identity); + } + + @Override + public int hashCode() { + return Objects.hash(atType, data, id, identity); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ElementVersion {\n"); + sb.append(" atType: ").append(toIndentedString(atType)).append("\n"); + sb.append(" data: ").append(toIndentedString(data)).append("\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" identity: ").append(toIndentedString(identity)).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(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/org/omg/sysml/model/Error.java b/src/main/java/org/omg/sysml/model/Error.java index ce7173d..8307a21 100644 --- a/src/main/java/org/omg/sysml/model/Error.java +++ b/src/main/java/org/omg/sysml/model/Error.java @@ -52,7 +52,6 @@ public String getError() { } - public void setError(String error) { this.error = error; } diff --git a/src/main/java/org/omg/sysml/model/Identified.java b/src/main/java/org/omg/sysml/model/Identified.java index c1fb054..b125a7c 100644 --- a/src/main/java/org/omg/sysml/model/Identified.java +++ b/src/main/java/org/omg/sysml/model/Identified.java @@ -53,7 +53,6 @@ public UUID getIdentifier() { } - public void setIdentifier(UUID identifier) { this.identifier = identifier; } diff --git a/src/main/java/org/omg/sysml/model/Project.java b/src/main/java/org/omg/sysml/model/Project.java index f43e538..cca46ab 100644 --- a/src/main/java/org/omg/sysml/model/Project.java +++ b/src/main/java/org/omg/sysml/model/Project.java @@ -30,20 +30,65 @@ */ public class Project { + /** + * Gets or Sets atType + */ + @JsonAdapter(AtTypeEnum.Adapter.class) + public enum AtTypeEnum { + PROJECT("Project"); + + private String value; + + AtTypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static AtTypeEnum fromValue(String value) { + for (AtTypeEnum b : AtTypeEnum.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 AtTypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public AtTypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return AtTypeEnum.fromValue(value); + } + } + } + public static final String SERIALIZED_NAME_AT_TYPE = "@type"; @SerializedName(SERIALIZED_NAME_AT_TYPE) - private String atType; + private AtTypeEnum atType; + + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private UUID id; public static final String SERIALIZED_NAME_NAME = "name"; @SerializedName(SERIALIZED_NAME_NAME) private String name; - public static final String SERIALIZED_NAME_IDENTIFIER = "identifier"; - @SerializedName(SERIALIZED_NAME_IDENTIFIER) - private UUID identifier; - - public Project atType(String atType) { + public Project atType(AtTypeEnum atType) { this.atType = atType; return this; @@ -56,62 +101,59 @@ public Project atType(String atType) { @javax.annotation.Nullable @ApiModelProperty(value = "") - public String getAtType() { + public AtTypeEnum getAtType() { return atType; } - - public void setAtType(String atType) { + public void setAtType(AtTypeEnum atType) { this.atType = atType; } - public Project name(String name) { + public Project id(UUID id) { - this.name = name; + this.id = id; return this; } /** - * Get name - * @return name + * Get id + * @return id **/ @javax.annotation.Nullable @ApiModelProperty(value = "") - public String getName() { - return name; + public UUID getId() { + return id; } - - public void setName(String name) { - this.name = name; + public void setId(UUID id) { + this.id = id; } - public Project identifier(UUID identifier) { + public Project name(String name) { - this.identifier = identifier; + this.name = name; return this; } /** - * Get identifier - * @return identifier + * Get name + * @return name **/ @javax.annotation.Nullable @ApiModelProperty(value = "") - public UUID getIdentifier() { - return identifier; + public String getName() { + return name; } - - public void setIdentifier(UUID identifier) { - this.identifier = identifier; + public void setName(String name) { + this.name = name; } @@ -125,13 +167,13 @@ public boolean equals(java.lang.Object o) { } Project project = (Project) o; return Objects.equals(this.atType, project.atType) && - Objects.equals(this.name, project.name) && - Objects.equals(this.identifier, project.identifier); + Objects.equals(this.id, project.id) && + Objects.equals(this.name, project.name); } @Override public int hashCode() { - return Objects.hash(atType, name, identifier); + return Objects.hash(atType, id, name); } @@ -140,8 +182,8 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class Project {\n"); sb.append(" atType: ").append(toIndentedString(atType)).append("\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" identifier: ").append(toIndentedString(identifier)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/org/omg/sysml/model/Record.java b/src/main/java/org/omg/sysml/model/Record.java new file mode 100644 index 0000000..c50d207 --- /dev/null +++ b/src/main/java/org/omg/sysml/model/Record.java @@ -0,0 +1,100 @@ +/* + * SysML v2 API and Services + * REST/HTTP binding (PSM) for the SysML v2 standard API. + * + * The version of the OpenAPI document: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package org.omg.sysml.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +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.UUID; + +/** + * Record + */ + +public class Record { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private UUID id; + + + public Record id(UUID id) { + + this.id = id; + return this; + } + + /** + * Get id + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public UUID getId() { + return id; + } + + + public void setId(UUID id) { + this.id = id; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + Record record = (Record) o; + return Objects.equals(this.id, record.id); + } + + @Override + public int hashCode() { + return Objects.hash(id); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class Record {\n"); + sb.append(" id: ").append(toIndentedString(id)).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(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/org/omg/sysml/model/Relationship.java b/src/main/java/org/omg/sysml/model/Relationship.java index 0836cc9..89e5550 100644 --- a/src/main/java/org/omg/sysml/model/Relationship.java +++ b/src/main/java/org/omg/sysml/model/Relationship.java @@ -26,9 +26,7 @@ import java.util.ArrayList; import java.util.List; import java.util.UUID; -import org.omg.sysml.model.Element; import org.omg.sysml.model.Identified; -import org.omg.sysml.model.RelationshipAllOf; /** * Relationship @@ -39,10 +37,6 @@ public class Relationship { @SerializedName(SERIALIZED_NAME_AT_TYPE) private String atType; - public static final String SERIALIZED_NAME_CONTAINING_PROJECT = "containingProject"; - @SerializedName(SERIALIZED_NAME_CONTAINING_PROJECT) - private Identified containingProject; - public static final String SERIALIZED_NAME_IDENTIFIER = "identifier"; @SerializedName(SERIALIZED_NAME_IDENTIFIER) private UUID identifier; @@ -74,36 +68,11 @@ public String getAtType() { } - public void setAtType(String atType) { this.atType = atType; } - public Relationship containingProject(Identified containingProject) { - - this.containingProject = containingProject; - return this; - } - - /** - * Get containingProject - * @return containingProject - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Identified getContainingProject() { - return containingProject; - } - - - - public void setContainingProject(Identified containingProject) { - this.containingProject = containingProject; - } - - public Relationship identifier(UUID identifier) { this.identifier = identifier; @@ -122,7 +91,6 @@ public UUID getIdentifier() { } - public void setIdentifier(UUID identifier) { this.identifier = identifier; } @@ -154,7 +122,6 @@ public List getSource() { } - public void setSource(List source) { this.source = source; } @@ -186,7 +153,6 @@ public List getTarget() { } - public void setTarget(List target) { this.target = target; } @@ -202,7 +168,6 @@ public boolean equals(java.lang.Object o) { } Relationship relationship = (Relationship) o; return Objects.equals(this.atType, relationship.atType) && - Objects.equals(this.containingProject, relationship.containingProject) && Objects.equals(this.identifier, relationship.identifier) && Objects.equals(this.source, relationship.source) && Objects.equals(this.target, relationship.target); @@ -210,7 +175,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(atType, containingProject, identifier, source, target); + return Objects.hash(atType, identifier, source, target); } @@ -219,7 +184,6 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class Relationship {\n"); sb.append(" atType: ").append(toIndentedString(atType)).append("\n"); - sb.append(" containingProject: ").append(toIndentedString(containingProject)).append("\n"); sb.append(" identifier: ").append(toIndentedString(identifier)).append("\n"); sb.append(" source: ").append(toIndentedString(source)).append("\n"); sb.append(" target: ").append(toIndentedString(target)).append("\n"); diff --git a/src/main/java/org/omg/sysml/model/RelationshipAllOf.java b/src/main/java/org/omg/sysml/model/RelationshipAllOf.java deleted file mode 100644 index 312bade..0000000 --- a/src/main/java/org/omg/sysml/model/RelationshipAllOf.java +++ /dev/null @@ -1,149 +0,0 @@ -/* - * SysML v2 API and Services - * REST/HTTP binding (PSM) for the SysML v2 standard API. - * - * The version of the OpenAPI document: 1.0.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -package org.omg.sysml.model; - -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -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.omg.sysml.model.Identified; - -/** - * RelationshipAllOf - */ - -public class RelationshipAllOf { - public static final String SERIALIZED_NAME_SOURCE = "source"; - @SerializedName(SERIALIZED_NAME_SOURCE) - private List source = null; - - public static final String SERIALIZED_NAME_TARGET = "target"; - @SerializedName(SERIALIZED_NAME_TARGET) - private List target = null; - - - public RelationshipAllOf source(List source) { - - this.source = source; - return this; - } - - public RelationshipAllOf addSourceItem(Identified sourceItem) { - if (this.source == null) { - this.source = new ArrayList(); - } - this.source.add(sourceItem); - return this; - } - - /** - * Get source - * @return source - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List getSource() { - return source; - } - - - - public void setSource(List source) { - this.source = source; - } - - - public RelationshipAllOf target(List target) { - - this.target = target; - return this; - } - - public RelationshipAllOf addTargetItem(Identified targetItem) { - if (this.target == null) { - this.target = new ArrayList(); - } - this.target.add(targetItem); - return this; - } - - /** - * Get target - * @return target - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public List getTarget() { - return target; - } - - - - public void setTarget(List target) { - this.target = target; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - RelationshipAllOf relationshipAllOf = (RelationshipAllOf) o; - return Objects.equals(this.source, relationshipAllOf.source) && - Objects.equals(this.target, relationshipAllOf.target); - } - - @Override - public int hashCode() { - return Objects.hash(source, target); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class RelationshipAllOf {\n"); - sb.append(" source: ").append(toIndentedString(source)).append("\n"); - sb.append(" target: ").append(toIndentedString(target)).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(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/src/test/java/org/omg/sysml/api/CommitApiTest.java b/src/test/java/org/omg/sysml/api/CommitApiTest.java new file mode 100644 index 0000000..fe12c94 --- /dev/null +++ b/src/test/java/org/omg/sysml/api/CommitApiTest.java @@ -0,0 +1,103 @@ +/* + * SysML v2 API and Services + * REST/HTTP binding (PSM) for the SysML v2 standard API. + * + * The version of the OpenAPI document: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package org.omg.sysml.api; + +import org.omg.sysml.ApiException; +import org.omg.sysml.model.Commit; +import org.omg.sysml.model.Error; +import java.util.UUID; +import org.junit.Test; +import org.junit.Ignore; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +/** + * API tests for CommitApi + */ +@Ignore +public class CommitApiTest { + + private final CommitApi api = new CommitApi(); + + + /** + * Get commit by project and ID + * + * + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void getCommitByProjectAndIdTest() throws ApiException { + String projectId = null; + String commitId = null; + Commit response = api.getCommitByProjectAndId(projectId, commitId); + + // TODO: test validations + } + + /** + * Get commits by project + * + * + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void getCommitsByProjectTest() throws ApiException { + UUID projectId = null; + Commit response = api.getCommitsByProject(projectId); + + // TODO: test validations + } + + /** + * Get head commit by project + * + * + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void getHeadCommitByProjectTest() throws ApiException { + String projectId = null; + Commit response = api.getHeadCommitByProject(projectId); + + // TODO: test validations + } + + /** + * Create commit by project + * + * + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void postCommitByProjectTest() throws ApiException { + UUID projectId = null; + Commit body = null; + Commit response = api.postCommitByProject(projectId, body); + + // TODO: test validations + } + +} diff --git a/src/test/java/org/omg/sysml/api/ElementApiTest.java b/src/test/java/org/omg/sysml/api/ElementApiTest.java index 30cca16..4fa4b72 100644 --- a/src/test/java/org/omg/sysml/api/ElementApiTest.java +++ b/src/test/java/org/omg/sysml/api/ElementApiTest.java @@ -16,6 +16,7 @@ import org.omg.sysml.ApiException; import org.omg.sysml.model.Element; import org.omg.sysml.model.Error; +import java.util.UUID; import org.junit.Test; import org.junit.Ignore; @@ -34,7 +35,7 @@ public class ElementApiTest { /** - * Add a new element + * Get element by project, commit and ID * * * @@ -42,15 +43,17 @@ public class ElementApiTest { * if the Api call fails */ @Test - public void createElementTest() throws ApiException { - Map body = null; - Element response = api.createElement(body); + public void getElementByProjectCommitIdTest() throws ApiException { + UUID projectId = null; + UUID commitId = null; + UUID elementId = null; + Element response = api.getElementByProjectCommitId(projectId, commitId, elementId); // TODO: test validations } /** - * Get element by its ID + * Get elements by project and commit * * * @@ -58,57 +61,10 @@ public void createElementTest() throws ApiException { * if the Api call fails */ @Test - public void getElementTest() throws ApiException { - String identifier = null; - Element response = api.getElement(identifier); - - // TODO: test validations - } - - /** - * Get element by project ID and its ID - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getElementByProjectAndIdTest() throws ApiException { - String projectIdentifier = null; - String elementIdentifier = null; - Element response = api.getElementByProjectAndId(projectIdentifier, elementIdentifier); - - // TODO: test validations - } - - /** - * Get all elements - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getElementsTest() throws ApiException { - List response = api.getElements(); - - // TODO: test validations - } - - /** - * Get all elements in the project - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getElementsInProjectTest() throws ApiException { - String projectIdentifier = null; - Element response = api.getElementsInProject(projectIdentifier); + public void getElementsByProjectCommitTest() throws ApiException { + UUID projectId = null; + UUID commitId = null; + Element response = api.getElementsByProjectCommit(projectId, commitId); // TODO: test validations } diff --git a/src/test/java/org/omg/sysml/api/ProjectApiTest.java b/src/test/java/org/omg/sysml/api/ProjectApiTest.java index d042716..3960784 100644 --- a/src/test/java/org/omg/sysml/api/ProjectApiTest.java +++ b/src/test/java/org/omg/sysml/api/ProjectApiTest.java @@ -16,6 +16,7 @@ import org.omg.sysml.ApiException; import org.omg.sysml.model.Error; import org.omg.sysml.model.Project; +import java.util.UUID; import org.junit.Test; import org.junit.Ignore; @@ -34,7 +35,7 @@ public class ProjectApiTest { /** - * Add a new project + * Get project by ID * * * @@ -42,15 +43,15 @@ public class ProjectApiTest { * if the Api call fails */ @Test - public void createProjectTest() throws ApiException { - Project body = null; - Project response = api.createProject(body); + public void getProjectByIdTest() throws ApiException { + UUID projectId = null; + Project response = api.getProjectById(projectId); // TODO: test validations } /** - * Get project by its ID + * Get projects * * * @@ -58,15 +59,14 @@ public void createProjectTest() throws ApiException { * if the Api call fails */ @Test - public void getProjectTest() throws ApiException { - String identifier = null; - Project response = api.getProject(identifier); + public void getProjectsTest() throws ApiException { + List response = api.getProjects(); // TODO: test validations } /** - * Get all projects + * Create project * * * @@ -74,8 +74,9 @@ public void getProjectTest() throws ApiException { * if the Api call fails */ @Test - public void getProjectsTest() throws ApiException { - List response = api.getProjects(); + public void postProjectTest() throws ApiException { + Project body = null; + Project response = api.postProject(body); // TODO: test validations } diff --git a/src/test/java/org/omg/sysml/api/RelationshipApiTest.java b/src/test/java/org/omg/sysml/api/RelationshipApiTest.java index 7d39346..81a9cec 100644 --- a/src/test/java/org/omg/sysml/api/RelationshipApiTest.java +++ b/src/test/java/org/omg/sysml/api/RelationshipApiTest.java @@ -16,6 +16,7 @@ import org.omg.sysml.ApiException; import org.omg.sysml.model.Error; import org.omg.sysml.model.Relationship; +import java.util.UUID; import org.junit.Test; import org.junit.Ignore; @@ -34,7 +35,7 @@ public class RelationshipApiTest { /** - * Add a new relationship + * Get relationships by project, commit, and related element. * * * @@ -42,56 +43,11 @@ public class RelationshipApiTest { * if the Api call fails */ @Test - public void createRelationshipTest() throws ApiException { - Relationship body = null; - Relationship response = api.createRelationship(body); - - // TODO: test validations - } - - /** - * Get relationship by its ID - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getRelationshipTest() throws ApiException { - String identifier = null; - Relationship response = api.getRelationship(identifier); - - // TODO: test validations - } - - /** - * Get all relationships - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getRelationshipsTest() throws ApiException { - List response = api.getRelationships(); - - // TODO: test validations - } - - /** - * Get all relationships in the project - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getRelationshipsByProjectTest() throws ApiException { - String projectIdentifier = null; - List response = api.getRelationshipsByProject(projectIdentifier); + public void getRelationshipsByProjectCommitRelatedElementTest() throws ApiException { + UUID projectId = null; + UUID commitId = null; + UUID relatedElementId = null; + List response = api.getRelationshipsByProjectCommitRelatedElement(projectId, commitId, relatedElementId); // TODO: test validations } diff --git a/src/test/java/org/omg/sysml/model/CommitTest.java b/src/test/java/org/omg/sysml/model/CommitTest.java new file mode 100644 index 0000000..1be7b85 --- /dev/null +++ b/src/test/java/org/omg/sysml/model/CommitTest.java @@ -0,0 +1,80 @@ +/* + * SysML v2 API and Services + * REST/HTTP binding (PSM) for the SysML v2 standard API. + * + * The version of the OpenAPI document: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package org.omg.sysml.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +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 java.util.UUID; +import org.omg.sysml.model.ElementVersion; +import org.omg.sysml.model.Record; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for Commit + */ +public class CommitTest { + private final Commit model = new Commit(); + + /** + * Model tests for Commit + */ + @Test + public void testCommit() { + // TODO: test Commit + } + + /** + * Test the property 'atType' + */ + @Test + public void atTypeTest() { + // TODO: test atType + } + + /** + * Test the property 'changes' + */ + @Test + public void changesTest() { + // TODO: test changes + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'previousCommit' + */ + @Test + public void previousCommitTest() { + // TODO: test previousCommit + } + +} diff --git a/src/test/java/org/omg/sysml/model/RelationshipAllOfTest.java b/src/test/java/org/omg/sysml/model/ElementIdentityTest.java similarity index 61% rename from src/test/java/org/omg/sysml/model/RelationshipAllOfTest.java rename to src/test/java/org/omg/sysml/model/ElementIdentityTest.java index 3bbb089..879ba77 100644 --- a/src/test/java/org/omg/sysml/model/RelationshipAllOfTest.java +++ b/src/test/java/org/omg/sysml/model/ElementIdentityTest.java @@ -21,42 +21,40 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; -import java.util.ArrayList; -import java.util.List; -import org.omg.sysml.model.Identified; +import java.util.UUID; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; /** - * Model tests for RelationshipAllOf + * Model tests for ElementIdentity */ -public class RelationshipAllOfTest { - private final RelationshipAllOf model = new RelationshipAllOf(); +public class ElementIdentityTest { + private final ElementIdentity model = new ElementIdentity(); /** - * Model tests for RelationshipAllOf + * Model tests for ElementIdentity */ @Test - public void testRelationshipAllOf() { - // TODO: test RelationshipAllOf + public void testElementIdentity() { + // TODO: test ElementIdentity } /** - * Test the property 'source' + * Test the property 'atType' */ @Test - public void sourceTest() { - // TODO: test source + public void atTypeTest() { + // TODO: test atType } /** - * Test the property 'target' + * Test the property 'id' */ @Test - public void targetTest() { - // TODO: test target + public void idTest() { + // TODO: test id } } diff --git a/src/test/java/org/omg/sysml/model/ElementTest.java b/src/test/java/org/omg/sysml/model/ElementTest.java index 9251eea..61b5ec5 100644 --- a/src/test/java/org/omg/sysml/model/ElementTest.java +++ b/src/test/java/org/omg/sysml/model/ElementTest.java @@ -24,7 +24,6 @@ import java.util.HashMap; import java.util.Map; import java.util.UUID; -import org.omg.sysml.model.Identified; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -52,14 +51,6 @@ public void atTypeTest() { // TODO: test atType } - /** - * Test the property 'containingProject' - */ - @Test - public void containingProjectTest() { - // TODO: test containingProject - } - /** * Test the property 'identifier' */ diff --git a/src/test/java/org/omg/sysml/model/ElementVersionTest.java b/src/test/java/org/omg/sysml/model/ElementVersionTest.java new file mode 100644 index 0000000..b5e8d8b --- /dev/null +++ b/src/test/java/org/omg/sysml/model/ElementVersionTest.java @@ -0,0 +1,78 @@ +/* + * SysML v2 API and Services + * REST/HTTP binding (PSM) for the SysML v2 standard API. + * + * The version of the OpenAPI document: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package org.omg.sysml.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +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.UUID; +import org.omg.sysml.model.Element; +import org.omg.sysml.model.ElementIdentity; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for ElementVersion + */ +public class ElementVersionTest { + private final ElementVersion model = new ElementVersion(); + + /** + * Model tests for ElementVersion + */ + @Test + public void testElementVersion() { + // TODO: test ElementVersion + } + + /** + * Test the property 'atType' + */ + @Test + public void atTypeTest() { + // TODO: test atType + } + + /** + * Test the property 'data' + */ + @Test + public void dataTest() { + // TODO: test data + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'identity' + */ + @Test + public void identityTest() { + // TODO: test identity + } + +} diff --git a/src/test/java/org/omg/sysml/model/ProjectTest.java b/src/test/java/org/omg/sysml/model/ProjectTest.java index 9814656..6eb994e 100644 --- a/src/test/java/org/omg/sysml/model/ProjectTest.java +++ b/src/test/java/org/omg/sysml/model/ProjectTest.java @@ -50,19 +50,19 @@ public void atTypeTest() { } /** - * Test the property 'name' + * Test the property 'id' */ @Test - public void nameTest() { - // TODO: test name + public void idTest() { + // TODO: test id } /** - * Test the property 'identifier' + * Test the property 'name' */ @Test - public void identifierTest() { - // TODO: test identifier + public void nameTest() { + // TODO: test name } } diff --git a/src/test/java/org/omg/sysml/model/RecordTest.java b/src/test/java/org/omg/sysml/model/RecordTest.java new file mode 100644 index 0000000..12bb731 --- /dev/null +++ b/src/test/java/org/omg/sysml/model/RecordTest.java @@ -0,0 +1,52 @@ +/* + * SysML v2 API and Services + * REST/HTTP binding (PSM) for the SysML v2 standard API. + * + * The version of the OpenAPI document: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package org.omg.sysml.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +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.UUID; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for Record + */ +public class RecordTest { + private final Record model = new Record(); + + /** + * Model tests for Record + */ + @Test + public void testRecord() { + // TODO: test Record + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + +} diff --git a/src/test/java/org/omg/sysml/model/RelationshipTest.java b/src/test/java/org/omg/sysml/model/RelationshipTest.java index b35bb34..092243b 100644 --- a/src/test/java/org/omg/sysml/model/RelationshipTest.java +++ b/src/test/java/org/omg/sysml/model/RelationshipTest.java @@ -24,9 +24,7 @@ import java.util.ArrayList; import java.util.List; import java.util.UUID; -import org.omg.sysml.model.Element; import org.omg.sysml.model.Identified; -import org.omg.sysml.model.RelationshipAllOf; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -54,14 +52,6 @@ public void atTypeTest() { // TODO: test atType } - /** - * Test the property 'containingProject' - */ - @Test - public void containingProjectTest() { - // TODO: test containingProject - } - /** * Test the property 'identifier' */ diff --git a/test-sysml-v2-api-java-client.jsh b/test-sysml-v2-api-java-client.jsh new file mode 100755 index 0000000..29fb1b2 --- /dev/null +++ b/test-sysml-v2-api-java-client.jsh @@ -0,0 +1,52 @@ +//usr/bin/env jshell --show-version "$0" "$@"; exit $? +/env -class-path ~/SysML-v2-API-Java-Client/build/libs/sysml-v2-api-client-2020-03-all.jar + +import java.util.Arrays; +import java.util.UUID; + +import org.omg.sysml.ApiClient; +import org.omg.sysml.api.*; +import org.omg.sysml.model.*; + +var apiClient = new ApiClient(); +apiClient.setBasePath("http://localhost:9000"); + +var project = new Project(); +project.setName("MyProject"); + +var projectApi = new ProjectApi(apiClient); +var projectResponse = projectApi.postProject(project); +System.out.println("--- Project ---"); +System.out.println(projectResponse); + +var firstBlock = new Element(); +firstBlock.put("@type", "Block"); +// Fluent API getters/setters also supported +var firstIdentity = new ElementIdentity().id(UUID.fromString("b92bb8e8-740b-4eee-b621-91a82be67d6a")); +var firstElementVersion = new ElementVersion().data(firstBlock).identity(firstIdentity); +var secondBlock = new Element(); +secondBlock.put("@type", "Block"); +var secondIdentity = new ElementIdentity().id(UUID.fromString("a429229d-333a-4f2d-89b4-82354d29109d")); +var secondElementVersion = new ElementVersion().data(secondBlock).identity(secondIdentity); +var firstCommit = new Commit().changes(Arrays.asList(firstElementVersion, secondElementVersion)); + +var commitApi = new CommitApi(apiClient); +var firstCommitResponse = commitApi.postCommitByProject(projectResponse.getId(), firstCommit); +System.out.println("--- First Commit ---"); +System.out.println(firstCommitResponse); + +var generalization = new Element(); +generalization.put("@type", "Generalization"); +var firstBlockIdentified = new Identified().identifier(UUID.fromString("b92bb8e8-740b-4eee-b621-91a82be67d6a")); +generalization.put("source", Arrays.asList(firstBlockIdentified)); +var secondBlockIdentified = new Identified().identifier(UUID.fromString("a429229d-333a-4f2d-89b4-82354d29109d")); +generalization.put("target", Arrays.asList(secondBlockIdentified)); +// Note that no ElementIdentity is provided. Server will generate one when not provided. +var generalizationElementVersion = new ElementVersion().data(generalization); +var firstCommitRecord = new Record().id(firstCommitResponse.getId()); +var secondCommit = new Commit().previousCommit(firstCommitRecord).changes(Arrays.asList(generalizationElementVersion)); +var secondCommitResponse = commitApi.postCommitByProject(projectResponse.getId(), secondCommit); +System.out.println("--- Second Commit ---"); +System.out.println(secondCommitResponse); + +/exit \ No newline at end of file From 655de418f6313684d21698be886629a4bfb06b0c Mon Sep 17 00:00:00 2001 From: Ivan Gomes Date: Sat, 21 Mar 2020 15:30:22 -0700 Subject: [PATCH 2/2] Update version info for 2020-03-rc2 --- README.md | 12 +++--------- build.gradle | 2 +- build.sbt | 2 +- pom.xml | 2 +- src/main/java/org/omg/sysml/ApiClient.java | 2 +- 5 files changed, 7 insertions(+), 13 deletions(-) diff --git a/README.md b/README.md index f9930a4..b170d63 100644 --- a/README.md +++ b/README.md @@ -39,7 +39,7 @@ Add this dependency to your project's POM: org.omg.sysml sysml-v2-api-client - 2020-03 + 2020-03-rc2 compile ``` @@ -49,7 +49,7 @@ Add this dependency to your project's POM: Add this dependency to your project's build file: ```groovy -compile "org.omg.sysml:sysml-v2-api-client:2020-03" +compile "org.omg.sysml:sysml-v2-api-client:2020-03-rc2" ``` ### Others @@ -62,7 +62,7 @@ mvn clean package Then manually install the following JARs: -* `target/sysml-v2-api-client-2020-03.jar` +* `target/sysml-v2-api-client-2020-03-rc2.jar` * `target/lib/*.jar` ## Getting Started @@ -122,20 +122,14 @@ Class | Method | HTTP request | Description ## Documentation for Models - [Commit](docs/Commit.md) - - [CommitAllOf](docs/CommitAllOf.md) - [Element](docs/Element.md) - - [ElementAllOf](docs/ElementAllOf.md) - [ElementIdentity](docs/ElementIdentity.md) - - [ElementIdentityAllOf](docs/ElementIdentityAllOf.md) - [ElementVersion](docs/ElementVersion.md) - - [ElementVersionAllOf](docs/ElementVersionAllOf.md) - [Error](docs/Error.md) - [Identified](docs/Identified.md) - [Project](docs/Project.md) - - [ProjectAllOf](docs/ProjectAllOf.md) - [Record](docs/Record.md) - [Relationship](docs/Relationship.md) - - [RelationshipAllOf](docs/RelationshipAllOf.md) ## Documentation for Authorization diff --git a/build.gradle b/build.gradle index cd24037..ef2b64f 100644 --- a/build.gradle +++ b/build.gradle @@ -3,7 +3,7 @@ apply plugin: 'eclipse' apply plugin: 'java' group = 'org.omg.sysml' -version = '2020-03' +version = '2020-03-rc2' buildscript { repositories { diff --git a/build.sbt b/build.sbt index 429c195..512c306 100644 --- a/build.sbt +++ b/build.sbt @@ -2,7 +2,7 @@ lazy val root = (project in file(".")). settings( organization := "org.omg.sysml", name := "sysml-v2-api-client", - version := "2020-03", + version := "2020-03-rc2", scalaVersion := "2.11.4", scalacOptions ++= Seq("-feature"), javacOptions in compile ++= Seq("-Xlint:deprecation"), diff --git a/pom.xml b/pom.xml index 52253ef..04218ad 100644 --- a/pom.xml +++ b/pom.xml @@ -5,7 +5,7 @@ sysml-v2-api-client jar sysml-v2-api-client - 2020-03 + 2020-03-rc2 https://github.com/openapitools/openapi-generator OpenAPI Java diff --git a/src/main/java/org/omg/sysml/ApiClient.java b/src/main/java/org/omg/sysml/ApiClient.java index a4e44cd..b3b7ca4 100644 --- a/src/main/java/org/omg/sysml/ApiClient.java +++ b/src/main/java/org/omg/sysml/ApiClient.java @@ -97,7 +97,7 @@ private void init() { json = new JSON(); // Set default User-Agent. - setUserAgent("OpenAPI-Generator/2020-03/java"); + setUserAgent("OpenAPI-Generator/2020-03-rc2/java"); authentications = new HashMap(); }