Skip to content

Commit 68fe1ea

Browse files
committed
Merge branch 'develop'
2 parents f4048fd + 573c751 commit 68fe1ea

20 files changed

+335
-37
lines changed

README.md

+4-3
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ Add this dependency to your project's POM:
3939
<dependency>
4040
<groupId>org.omg.sysml</groupId>
4141
<artifactId>sysml-v2-api-client</artifactId>
42-
<version>2020-03-p1</version>
42+
<version>2020-05-rc1</version>
4343
<scope>compile</scope>
4444
</dependency>
4545
```
@@ -49,7 +49,7 @@ Add this dependency to your project's POM:
4949
Add this dependency to your project's build file:
5050

5151
```groovy
52-
compile "org.omg.sysml:sysml-v2-api-client:2020-03-p1"
52+
compile "org.omg.sysml:sysml-v2-api-client:2020-05-rc1"
5353
```
5454

5555
### Others
@@ -62,7 +62,7 @@ mvn clean package
6262

6363
Then manually install the following JARs:
6464

65-
* `target/sysml-v2-api-client-2020-03-p1.jar`
65+
* `target/sysml-v2-api-client-2020-05-rc1.jar`
6666
* `target/lib/*.jar`
6767

6868
## Getting Started
@@ -113,6 +113,7 @@ Class | Method | HTTP request | Description
113113
*CommitApi* | [**postCommitByProject**](docs/CommitApi.md#postCommitByProject) | **POST** /projects/{projectId}/commits | Create commit by project
114114
*ElementApi* | [**getElementByProjectCommitId**](docs/ElementApi.md#getElementByProjectCommitId) | **GET** /projects/{projectId}/commits/{commitId}/elements/{elementId} | Get element by project, commit and ID
115115
*ElementApi* | [**getElementsByProjectCommit**](docs/ElementApi.md#getElementsByProjectCommit) | **GET** /projects/{projectId}/commits/{commitId}/elements | Get elements by project and commit
116+
*ElementApi* | [**getRootsByProjectCommit**](docs/ElementApi.md#getRootsByProjectCommit) | **GET** /projects/{projectId}/commits/{commitId}/roots | Get root elements by project and commit
116117
*ProjectApi* | [**getProjectById**](docs/ProjectApi.md#getProjectById) | **GET** /projects/{projectId} | Get project by ID
117118
*ProjectApi* | [**getProjects**](docs/ProjectApi.md#getProjects) | **GET** /projects | Get projects
118119
*ProjectApi* | [**postProject**](docs/ProjectApi.md#postProject) | **POST** /projects | Create project

build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ apply plugin: 'eclipse'
33
apply plugin: 'java'
44

55
group = 'org.omg.sysml'
6-
version = '2020-03-p1'
6+
version = '2020-05-rc1'
77

88
buildscript {
99
repositories {

build.sbt

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ lazy val root = (project in file(".")).
22
settings(
33
organization := "org.omg.sysml",
44
name := "sysml-v2-api-client",
5-
version := "2020-03-p1",
5+
version := "2020-05-rc1",
66
scalaVersion := "2.11.4",
77
scalacOptions ++= Seq("-feature"),
88
javacOptions in compile ++= Seq("-Xlint:deprecation"),

docs/Element.md

+1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
Name | Type | Description | Notes
88
------------ | ------------- | ------------- | -------------
99
**atType** | **String** | | [optional]
10+
**atId** | [**UUID**](UUID.md) | | [optional]
1011
**identifier** | [**UUID**](UUID.md) | | [optional]
1112

1213

docs/ElementApi.md

+69-2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ Method | HTTP request | Description
66
------------- | ------------- | -------------
77
[**getElementByProjectCommitId**](ElementApi.md#getElementByProjectCommitId) | **GET** /projects/{projectId}/commits/{commitId}/elements/{elementId} | Get element by project, commit and ID
88
[**getElementsByProjectCommit**](ElementApi.md#getElementsByProjectCommit) | **GET** /projects/{projectId}/commits/{commitId}/elements | Get elements by project and commit
9+
[**getRootsByProjectCommit**](ElementApi.md#getRootsByProjectCommit) | **GET** /projects/{projectId}/commits/{commitId}/roots | Get root elements by project and commit
910

1011

1112
<a name="getElementByProjectCommitId"></a>
@@ -65,7 +66,7 @@ No authorization required
6566
### HTTP request headers
6667

6768
- **Content-Type**: Not defined
68-
- **Accept**: application/json
69+
- **Accept**: application/ld+json, application/json
6970

7071
### HTTP response details
7172
| Status code | Description | Response headers |
@@ -131,7 +132,73 @@ No authorization required
131132
### HTTP request headers
132133

133134
- **Content-Type**: Not defined
134-
- **Accept**: application/json
135+
- **Accept**: application/ld+json, application/json
136+
137+
### HTTP response details
138+
| Status code | Description | Response headers |
139+
|-------------|-------------|------------------|
140+
**200** | Ok | - |
141+
**404** | Not found. | - |
142+
**415** | The requested content type is not acceptable. | - |
143+
**500** | Internal server error. | - |
144+
**0** | Unexpected response. | - |
145+
146+
<a name="getRootsByProjectCommit"></a>
147+
# **getRootsByProjectCommit**
148+
> List&lt;Element&gt; getRootsByProjectCommit(projectId, commitId)
149+
150+
Get root elements by project and commit
151+
152+
### Example
153+
```java
154+
// Import classes:
155+
import org.omg.sysml.ApiClient;
156+
import org.omg.sysml.ApiException;
157+
import org.omg.sysml.Configuration;
158+
import org.omg.sysml.models.*;
159+
import org.omg.sysml.api.ElementApi;
160+
161+
public class Example {
162+
public static void main(String[] args) {
163+
ApiClient defaultClient = Configuration.getDefaultApiClient();
164+
defaultClient.setBasePath("http://localhost");
165+
166+
ElementApi apiInstance = new ElementApi(defaultClient);
167+
UUID projectId = new UUID(); // UUID | ID of the project
168+
UUID commitId = new UUID(); // UUID | ID of the commit
169+
try {
170+
List<Element> result = apiInstance.getRootsByProjectCommit(projectId, commitId);
171+
System.out.println(result);
172+
} catch (ApiException e) {
173+
System.err.println("Exception when calling ElementApi#getRootsByProjectCommit");
174+
System.err.println("Status code: " + e.getCode());
175+
System.err.println("Reason: " + e.getResponseBody());
176+
System.err.println("Response headers: " + e.getResponseHeaders());
177+
e.printStackTrace();
178+
}
179+
}
180+
}
181+
```
182+
183+
### Parameters
184+
185+
Name | Type | Description | Notes
186+
------------- | ------------- | ------------- | -------------
187+
**projectId** | [**UUID**](.md)| ID of the project |
188+
**commitId** | [**UUID**](.md)| ID of the commit |
189+
190+
### Return type
191+
192+
[**List&lt;Element&gt;**](Element.md)
193+
194+
### Authorization
195+
196+
No authorization required
197+
198+
### HTTP request headers
199+
200+
- **Content-Type**: Not defined
201+
- **Accept**: application/ld+json, application/json
135202

136203
### HTTP response details
137204
| Status code | Description | Response headers |

docs/Identified.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
Name | Type | Description | Notes
88
------------ | ------------- | ------------- | -------------
9-
**identifier** | [**UUID**](UUID.md) | | [optional]
9+
**atId** | [**UUID**](UUID.md) | | [optional]
1010

1111

1212

docs/Relationship.md

+1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
Name | Type | Description | Notes
88
------------ | ------------- | ------------- | -------------
99
**atType** | **String** | | [optional]
10+
**atId** | [**UUID**](UUID.md) | | [optional]
1011
**identifier** | [**UUID**](UUID.md) | | [optional]
1112
**source** | [**List&lt;Identified&gt;**](Identified.md) | | [optional]
1213
**target** | [**List&lt;Identified&gt;**](Identified.md) | | [optional]

docs/RelationshipApi.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ No authorization required
6464
### HTTP request headers
6565

6666
- **Content-Type**: Not defined
67-
- **Accept**: application/json
67+
- **Accept**: application/ld+json, application/json
6868

6969
### HTTP response details
7070
| Status code | Description | Response headers |

pom.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<artifactId>sysml-v2-api-client</artifactId>
66
<packaging>jar</packaging>
77
<name>sysml-v2-api-client</name>
8-
<version>2020-03-p1</version>
8+
<version>2020-05-rc1</version>
99
<url>https://github.com/openapitools/openapi-generator</url>
1010
<description>OpenAPI Java</description>
1111
<scm>

src/main/java/org/omg/sysml/ApiClient.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ private void init() {
9797
json = new JSON();
9898

9999
// Set default User-Agent.
100-
setUserAgent("OpenAPI-Generator/2020-03-p1/java");
100+
setUserAgent("OpenAPI-Generator/2020-05-rc1/java");
101101

102102
authentications = new HashMap<String, Authentication>();
103103
}

src/main/java/org/omg/sysml/api/ElementApi.java

+139-2
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ public okhttp3.Call getElementByProjectCommitIdCall(UUID projectId, UUID commitI
8989
Map<String, String> localVarCookieParams = new HashMap<String, String>();
9090
Map<String, Object> localVarFormParams = new HashMap<String, Object>();
9191
final String[] localVarAccepts = {
92-
"application/json"
92+
"application/ld+json", "application/json"
9393
};
9494
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
9595
if (localVarAccept != null) {
@@ -234,7 +234,7 @@ public okhttp3.Call getElementsByProjectCommitCall(UUID projectId, UUID commitId
234234
Map<String, String> localVarCookieParams = new HashMap<String, String>();
235235
Map<String, Object> localVarFormParams = new HashMap<String, Object>();
236236
final String[] localVarAccepts = {
237-
"application/json"
237+
"application/ld+json", "application/json"
238238
};
239239
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
240240
if (localVarAccept != null) {
@@ -340,4 +340,141 @@ public okhttp3.Call getElementsByProjectCommitAsync(UUID projectId, UUID commitI
340340
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
341341
return localVarCall;
342342
}
343+
/**
344+
* Build call for getRootsByProjectCommit
345+
* @param projectId ID of the project (required)
346+
* @param commitId ID of the commit (required)
347+
* @param _callback Callback for upload/download progress
348+
* @return Call to execute
349+
* @throws ApiException If fail to serialize the request body object
350+
* @http.response.details
351+
<table summary="Response Details" border="1">
352+
<tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
353+
<tr><td> 200 </td><td> Ok </td><td> - </td></tr>
354+
<tr><td> 404 </td><td> Not found. </td><td> - </td></tr>
355+
<tr><td> 415 </td><td> The requested content type is not acceptable. </td><td> - </td></tr>
356+
<tr><td> 500 </td><td> Internal server error. </td><td> - </td></tr>
357+
<tr><td> 0 </td><td> Unexpected response. </td><td> - </td></tr>
358+
</table>
359+
*/
360+
public okhttp3.Call getRootsByProjectCommitCall(UUID projectId, UUID commitId, final ApiCallback _callback) throws ApiException {
361+
Object localVarPostBody = null;
362+
363+
// create path and map variables
364+
String localVarPath = "/projects/{projectId}/commits/{commitId}/roots"
365+
.replaceAll("\\{" + "projectId" + "\\}", localVarApiClient.escapeString(projectId.toString()))
366+
.replaceAll("\\{" + "commitId" + "\\}", localVarApiClient.escapeString(commitId.toString()));
367+
368+
List<Pair> localVarQueryParams = new ArrayList<Pair>();
369+
List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
370+
Map<String, String> localVarHeaderParams = new HashMap<String, String>();
371+
Map<String, String> localVarCookieParams = new HashMap<String, String>();
372+
Map<String, Object> localVarFormParams = new HashMap<String, Object>();
373+
final String[] localVarAccepts = {
374+
"application/ld+json", "application/json"
375+
};
376+
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
377+
if (localVarAccept != null) {
378+
localVarHeaderParams.put("Accept", localVarAccept);
379+
}
380+
381+
final String[] localVarContentTypes = {
382+
383+
};
384+
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
385+
localVarHeaderParams.put("Content-Type", localVarContentType);
386+
387+
String[] localVarAuthNames = new String[] { };
388+
return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
389+
}
390+
391+
@SuppressWarnings("rawtypes")
392+
private okhttp3.Call getRootsByProjectCommitValidateBeforeCall(UUID projectId, UUID commitId, final ApiCallback _callback) throws ApiException {
393+
394+
// verify the required parameter 'projectId' is set
395+
if (projectId == null) {
396+
throw new ApiException("Missing the required parameter 'projectId' when calling getRootsByProjectCommit(Async)");
397+
}
398+
399+
// verify the required parameter 'commitId' is set
400+
if (commitId == null) {
401+
throw new ApiException("Missing the required parameter 'commitId' when calling getRootsByProjectCommit(Async)");
402+
}
403+
404+
405+
okhttp3.Call localVarCall = getRootsByProjectCommitCall(projectId, commitId, _callback);
406+
return localVarCall;
407+
408+
}
409+
410+
/**
411+
* Get root elements by project and commit
412+
*
413+
* @param projectId ID of the project (required)
414+
* @param commitId ID of the commit (required)
415+
* @return List&lt;Element&gt;
416+
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
417+
* @http.response.details
418+
<table summary="Response Details" border="1">
419+
<tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
420+
<tr><td> 200 </td><td> Ok </td><td> - </td></tr>
421+
<tr><td> 404 </td><td> Not found. </td><td> - </td></tr>
422+
<tr><td> 415 </td><td> The requested content type is not acceptable. </td><td> - </td></tr>
423+
<tr><td> 500 </td><td> Internal server error. </td><td> - </td></tr>
424+
<tr><td> 0 </td><td> Unexpected response. </td><td> - </td></tr>
425+
</table>
426+
*/
427+
public List<Element> getRootsByProjectCommit(UUID projectId, UUID commitId) throws ApiException {
428+
ApiResponse<List<Element>> localVarResp = getRootsByProjectCommitWithHttpInfo(projectId, commitId);
429+
return localVarResp.getData();
430+
}
431+
432+
/**
433+
* Get root elements by project and commit
434+
*
435+
* @param projectId ID of the project (required)
436+
* @param commitId ID of the commit (required)
437+
* @return ApiResponse&lt;List&lt;Element&gt;&gt;
438+
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
439+
* @http.response.details
440+
<table summary="Response Details" border="1">
441+
<tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
442+
<tr><td> 200 </td><td> Ok </td><td> - </td></tr>
443+
<tr><td> 404 </td><td> Not found. </td><td> - </td></tr>
444+
<tr><td> 415 </td><td> The requested content type is not acceptable. </td><td> - </td></tr>
445+
<tr><td> 500 </td><td> Internal server error. </td><td> - </td></tr>
446+
<tr><td> 0 </td><td> Unexpected response. </td><td> - </td></tr>
447+
</table>
448+
*/
449+
public ApiResponse<List<Element>> getRootsByProjectCommitWithHttpInfo(UUID projectId, UUID commitId) throws ApiException {
450+
okhttp3.Call localVarCall = getRootsByProjectCommitValidateBeforeCall(projectId, commitId, null);
451+
Type localVarReturnType = new TypeToken<List<Element>>(){}.getType();
452+
return localVarApiClient.execute(localVarCall, localVarReturnType);
453+
}
454+
455+
/**
456+
* Get root elements by project and commit (asynchronously)
457+
*
458+
* @param projectId ID of the project (required)
459+
* @param commitId ID of the commit (required)
460+
* @param _callback The callback to be executed when the API call finishes
461+
* @return The request call
462+
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
463+
* @http.response.details
464+
<table summary="Response Details" border="1">
465+
<tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
466+
<tr><td> 200 </td><td> Ok </td><td> - </td></tr>
467+
<tr><td> 404 </td><td> Not found. </td><td> - </td></tr>
468+
<tr><td> 415 </td><td> The requested content type is not acceptable. </td><td> - </td></tr>
469+
<tr><td> 500 </td><td> Internal server error. </td><td> - </td></tr>
470+
<tr><td> 0 </td><td> Unexpected response. </td><td> - </td></tr>
471+
</table>
472+
*/
473+
public okhttp3.Call getRootsByProjectCommitAsync(UUID projectId, UUID commitId, final ApiCallback<List<Element>> _callback) throws ApiException {
474+
475+
okhttp3.Call localVarCall = getRootsByProjectCommitValidateBeforeCall(projectId, commitId, _callback);
476+
Type localVarReturnType = new TypeToken<List<Element>>(){}.getType();
477+
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
478+
return localVarCall;
479+
}
343480
}

src/main/java/org/omg/sysml/api/RelationshipApi.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ public okhttp3.Call getRelationshipsByProjectCommitRelatedElementCall(UUID proje
8888
Map<String, String> localVarCookieParams = new HashMap<String, String>();
8989
Map<String, Object> localVarFormParams = new HashMap<String, Object>();
9090
final String[] localVarAccepts = {
91-
"application/json"
91+
"application/ld+json", "application/json"
9292
};
9393
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
9494
if (localVarAccept != null) {

0 commit comments

Comments
 (0)