387 lines
11 KiB
Dart
387 lines
11 KiB
Dart
//
|
|
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
|
//
|
|
// @dart=2.18
|
|
|
|
// ignore_for_file: unused_element, unused_import
|
|
// ignore_for_file: always_put_required_named_parameters_first
|
|
// ignore_for_file: constant_identifier_names
|
|
// ignore_for_file: lines_longer_than_80_chars
|
|
|
|
part of openapi.api;
|
|
|
|
class SectionParcoursApi {
|
|
SectionParcoursApi([ApiClient? apiClient])
|
|
: apiClient = apiClient ?? defaultApiClient;
|
|
|
|
final ApiClient apiClient;
|
|
|
|
/// Performs an HTTP 'GET /api/SectionParcours/{sectionParcoursId}/guided-path' operation and returns the [Response].
|
|
Future<Response> sectionParcoursGetAllGuidedPathFromSectionWithHttpInfo(
|
|
String sectionParcoursId,
|
|
) async {
|
|
// ignore: prefer_const_declarations
|
|
final path = r'/api/SectionParcours/{sectionParcoursId}/guided-path'
|
|
.replaceAll('{sectionParcoursId}', sectionParcoursId);
|
|
|
|
// ignore: prefer_final_locals
|
|
Object? postBody;
|
|
|
|
final queryParams = <QueryParam>[];
|
|
final headerParams = <String, String>{};
|
|
final formParams = <String, String>{};
|
|
|
|
const contentTypes = <String>[];
|
|
|
|
return apiClient.invokeAPI(
|
|
path,
|
|
'GET',
|
|
queryParams,
|
|
postBody,
|
|
headerParams,
|
|
formParams,
|
|
contentTypes.isEmpty ? null : contentTypes.first,
|
|
);
|
|
}
|
|
|
|
Future<List<GuidedPathDTO>?> sectionParcoursGetAllGuidedPathFromSection(
|
|
String sectionParcoursId,
|
|
) async {
|
|
final response =
|
|
await sectionParcoursGetAllGuidedPathFromSectionWithHttpInfo(
|
|
sectionParcoursId,
|
|
);
|
|
if (response.statusCode >= HttpStatus.badRequest) {
|
|
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
|
}
|
|
if (response.body.isNotEmpty &&
|
|
response.statusCode != HttpStatus.noContent) {
|
|
final responseBody = await _decodeBodyBytes(response);
|
|
return (await apiClient.deserializeAsync(responseBody, 'List<GuidedPathDTO>') as List)
|
|
.cast<GuidedPathDTO>()
|
|
.toList(growable: false);
|
|
}
|
|
return null;
|
|
}
|
|
|
|
/// Performs an HTTP 'POST /api/SectionParcours/{sectionParcoursId}/guided-path' operation and returns the [Response].
|
|
Future<Response> sectionParcoursCreateGuidedPathWithHttpInfo(
|
|
String sectionParcoursId,
|
|
GuidedPathDTO guidedPathDTO,
|
|
) async {
|
|
// ignore: prefer_const_declarations
|
|
final path = r'/api/SectionParcours/{sectionParcoursId}/guided-path'
|
|
.replaceAll('{sectionParcoursId}', sectionParcoursId);
|
|
|
|
// ignore: prefer_final_locals
|
|
Object? postBody = guidedPathDTO;
|
|
|
|
final queryParams = <QueryParam>[];
|
|
final headerParams = <String, String>{};
|
|
final formParams = <String, String>{};
|
|
|
|
const contentTypes = <String>['application/json'];
|
|
|
|
return apiClient.invokeAPI(
|
|
path,
|
|
'POST',
|
|
queryParams,
|
|
postBody,
|
|
headerParams,
|
|
formParams,
|
|
contentTypes.isEmpty ? null : contentTypes.first,
|
|
);
|
|
}
|
|
|
|
Future<GuidedPathDTO?> sectionParcoursCreateGuidedPath(
|
|
String sectionParcoursId,
|
|
GuidedPathDTO guidedPathDTO,
|
|
) async {
|
|
final response = await sectionParcoursCreateGuidedPathWithHttpInfo(
|
|
sectionParcoursId,
|
|
guidedPathDTO,
|
|
);
|
|
if (response.statusCode >= HttpStatus.badRequest) {
|
|
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
|
}
|
|
if (response.body.isNotEmpty &&
|
|
response.statusCode != HttpStatus.noContent) {
|
|
return await apiClient.deserializeAsync(
|
|
await _decodeBodyBytes(response),
|
|
'GuidedPathDTO',
|
|
) as GuidedPathDTO;
|
|
}
|
|
return null;
|
|
}
|
|
|
|
/// Performs an HTTP 'PUT /api/SectionParcours/guided-path' operation and returns the [Response].
|
|
Future<Response> sectionParcoursUpdateGuidedPathWithHttpInfo(
|
|
GuidedPathDTO guidedPathDTO,
|
|
) async {
|
|
// ignore: prefer_const_declarations
|
|
final path = r'/api/SectionParcours/guided-path';
|
|
|
|
// ignore: prefer_final_locals
|
|
Object? postBody = guidedPathDTO;
|
|
|
|
final queryParams = <QueryParam>[];
|
|
final headerParams = <String, String>{};
|
|
final formParams = <String, String>{};
|
|
|
|
const contentTypes = <String>['application/json'];
|
|
|
|
return apiClient.invokeAPI(
|
|
path,
|
|
'PUT',
|
|
queryParams,
|
|
postBody,
|
|
headerParams,
|
|
formParams,
|
|
contentTypes.isEmpty ? null : contentTypes.first,
|
|
);
|
|
}
|
|
|
|
Future<GuidedPathDTO?> sectionParcoursUpdateGuidedPath(
|
|
GuidedPathDTO guidedPathDTO,
|
|
) async {
|
|
final response = await sectionParcoursUpdateGuidedPathWithHttpInfo(
|
|
guidedPathDTO,
|
|
);
|
|
if (response.statusCode >= HttpStatus.badRequest) {
|
|
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
|
}
|
|
if (response.body.isNotEmpty &&
|
|
response.statusCode != HttpStatus.noContent) {
|
|
return await apiClient.deserializeAsync(
|
|
await _decodeBodyBytes(response),
|
|
'GuidedPathDTO',
|
|
) as GuidedPathDTO;
|
|
}
|
|
return null;
|
|
}
|
|
|
|
/// Performs an HTTP 'DELETE /api/SectionParcours/guided-path/{guidedPathId}' operation and returns the [Response].
|
|
Future<Response> sectionParcoursDeleteGuidedPathWithHttpInfo(
|
|
String guidedPathId,
|
|
) async {
|
|
// ignore: prefer_const_declarations
|
|
final path = r'/api/SectionParcours/guided-path/{guidedPathId}'
|
|
.replaceAll('{guidedPathId}', guidedPathId);
|
|
|
|
// ignore: prefer_final_locals
|
|
Object? postBody;
|
|
|
|
final queryParams = <QueryParam>[];
|
|
final headerParams = <String, String>{};
|
|
final formParams = <String, String>{};
|
|
|
|
const contentTypes = <String>[];
|
|
|
|
return apiClient.invokeAPI(
|
|
path,
|
|
'DELETE',
|
|
queryParams,
|
|
postBody,
|
|
headerParams,
|
|
formParams,
|
|
contentTypes.isEmpty ? null : contentTypes.first,
|
|
);
|
|
}
|
|
|
|
Future<void> sectionParcoursDeleteGuidedPath(
|
|
String guidedPathId,
|
|
) async {
|
|
final response = await sectionParcoursDeleteGuidedPathWithHttpInfo(
|
|
guidedPathId,
|
|
);
|
|
if (response.statusCode >= HttpStatus.badRequest) {
|
|
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
|
}
|
|
}
|
|
|
|
/// Performs an HTTP 'GET /api/SectionParcours/guided-path/{guidedPathId}/guided-step' operation and returns the [Response].
|
|
Future<Response> sectionParcoursGetAllGuidedStepFromGuidedPathWithHttpInfo(
|
|
String guidedPathId,
|
|
) async {
|
|
// ignore: prefer_const_declarations
|
|
final path =
|
|
r'/api/SectionParcours/guided-path/{guidedPathId}/guided-step'
|
|
.replaceAll('{guidedPathId}', guidedPathId);
|
|
|
|
// ignore: prefer_final_locals
|
|
Object? postBody;
|
|
|
|
final queryParams = <QueryParam>[];
|
|
final headerParams = <String, String>{};
|
|
final formParams = <String, String>{};
|
|
|
|
const contentTypes = <String>[];
|
|
|
|
return apiClient.invokeAPI(
|
|
path,
|
|
'GET',
|
|
queryParams,
|
|
postBody,
|
|
headerParams,
|
|
formParams,
|
|
contentTypes.isEmpty ? null : contentTypes.first,
|
|
);
|
|
}
|
|
|
|
Future<List<GuidedStepDTO>?> sectionParcoursGetAllGuidedStepFromGuidedPath(
|
|
String guidedPathId,
|
|
) async {
|
|
final response =
|
|
await sectionParcoursGetAllGuidedStepFromGuidedPathWithHttpInfo(
|
|
guidedPathId,
|
|
);
|
|
if (response.statusCode >= HttpStatus.badRequest) {
|
|
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
|
}
|
|
if (response.body.isNotEmpty &&
|
|
response.statusCode != HttpStatus.noContent) {
|
|
final responseBody = await _decodeBodyBytes(response);
|
|
return (await apiClient.deserializeAsync(responseBody, 'List<GuidedStepDTO>') as List)
|
|
.cast<GuidedStepDTO>()
|
|
.toList(growable: false);
|
|
}
|
|
return null;
|
|
}
|
|
|
|
/// Performs an HTTP 'POST /api/SectionParcours/guided-path/{guidedPathId}/guided-step' operation and returns the [Response].
|
|
Future<Response> sectionParcoursCreateGuidedStepWithHttpInfo(
|
|
String guidedPathId,
|
|
GuidedStepDTO guidedStepDTO,
|
|
) async {
|
|
// ignore: prefer_const_declarations
|
|
final path =
|
|
r'/api/SectionParcours/guided-path/{guidedPathId}/guided-step'
|
|
.replaceAll('{guidedPathId}', guidedPathId);
|
|
|
|
// ignore: prefer_final_locals
|
|
Object? postBody = guidedStepDTO;
|
|
|
|
final queryParams = <QueryParam>[];
|
|
final headerParams = <String, String>{};
|
|
final formParams = <String, String>{};
|
|
|
|
const contentTypes = <String>['application/json'];
|
|
|
|
return apiClient.invokeAPI(
|
|
path,
|
|
'POST',
|
|
queryParams,
|
|
postBody,
|
|
headerParams,
|
|
formParams,
|
|
contentTypes.isEmpty ? null : contentTypes.first,
|
|
);
|
|
}
|
|
|
|
Future<GuidedStepDTO?> sectionParcoursCreateGuidedStep(
|
|
String guidedPathId,
|
|
GuidedStepDTO guidedStepDTO,
|
|
) async {
|
|
final response = await sectionParcoursCreateGuidedStepWithHttpInfo(
|
|
guidedPathId,
|
|
guidedStepDTO,
|
|
);
|
|
if (response.statusCode >= HttpStatus.badRequest) {
|
|
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
|
}
|
|
if (response.body.isNotEmpty &&
|
|
response.statusCode != HttpStatus.noContent) {
|
|
return await apiClient.deserializeAsync(
|
|
await _decodeBodyBytes(response),
|
|
'GuidedStepDTO',
|
|
) as GuidedStepDTO;
|
|
}
|
|
return null;
|
|
}
|
|
|
|
/// Performs an HTTP 'PUT /api/SectionParcours/guided-step' operation and returns the [Response].
|
|
Future<Response> sectionParcoursUpdateGuidedStepWithHttpInfo(
|
|
GuidedStepDTO guidedStepDTO,
|
|
) async {
|
|
// ignore: prefer_const_declarations
|
|
final path = r'/api/SectionParcours/guided-step';
|
|
|
|
// ignore: prefer_final_locals
|
|
Object? postBody = guidedStepDTO;
|
|
|
|
final queryParams = <QueryParam>[];
|
|
final headerParams = <String, String>{};
|
|
final formParams = <String, String>{};
|
|
|
|
const contentTypes = <String>['application/json'];
|
|
|
|
return apiClient.invokeAPI(
|
|
path,
|
|
'PUT',
|
|
queryParams,
|
|
postBody,
|
|
headerParams,
|
|
formParams,
|
|
contentTypes.isEmpty ? null : contentTypes.first,
|
|
);
|
|
}
|
|
|
|
Future<GuidedStepDTO?> sectionParcoursUpdateGuidedStep(
|
|
GuidedStepDTO guidedStepDTO,
|
|
) async {
|
|
final response = await sectionParcoursUpdateGuidedStepWithHttpInfo(
|
|
guidedStepDTO,
|
|
);
|
|
if (response.statusCode >= HttpStatus.badRequest) {
|
|
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
|
}
|
|
if (response.body.isNotEmpty &&
|
|
response.statusCode != HttpStatus.noContent) {
|
|
return await apiClient.deserializeAsync(
|
|
await _decodeBodyBytes(response),
|
|
'GuidedStepDTO',
|
|
) as GuidedStepDTO;
|
|
}
|
|
return null;
|
|
}
|
|
|
|
/// Performs an HTTP 'DELETE /api/SectionParcours/guided-step/{guidedStepId}' operation and returns the [Response].
|
|
Future<Response> sectionParcoursDeleteGuidedStepWithHttpInfo(
|
|
String guidedStepId,
|
|
) async {
|
|
// ignore: prefer_const_declarations
|
|
final path = r'/api/SectionParcours/guided-step/{guidedStepId}'
|
|
.replaceAll('{guidedStepId}', guidedStepId);
|
|
|
|
// ignore: prefer_final_locals
|
|
Object? postBody;
|
|
|
|
final queryParams = <QueryParam>[];
|
|
final headerParams = <String, String>{};
|
|
final formParams = <String, String>{};
|
|
|
|
const contentTypes = <String>[];
|
|
|
|
return apiClient.invokeAPI(
|
|
path,
|
|
'DELETE',
|
|
queryParams,
|
|
postBody,
|
|
headerParams,
|
|
formParams,
|
|
contentTypes.isEmpty ? null : contentTypes.first,
|
|
);
|
|
}
|
|
|
|
Future<void> sectionParcoursDeleteGuidedStep(
|
|
String guidedStepId,
|
|
) async {
|
|
final response = await sectionParcoursDeleteGuidedStepWithHttpInfo(
|
|
guidedStepId,
|
|
);
|
|
if (response.statusCode >= HttpStatus.badRequest) {
|
|
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
|
}
|
|
}
|
|
}
|