Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ try {
{{#returnType}}
print(response);
{{/returnType}}
} catch on DioException (e) {
} on DioException catch (e) {
print("Exception when calling {{classname}}->{{operationId}}: $e\n");
}
{{/-first}}{{/operation}}{{/operations}}{{/-first}}{{/apis}}{{/apiInfo}}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ try {
{{#returnType}}
print(response);
{{/returnType}}
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling {{classname}}->{{operationId}}: $e\n');
}
```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ final api = Openapi().getDefaultApi();
try {
final response = await api.binaryResponse();
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print("Exception when calling DefaultApi->binaryResponse: $e\n");
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ final api = Openapi().getDefaultApi();
try {
final response = api.binaryResponse();
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling DefaultApi->binaryResponse: $e\n');
}
```
Expand Down
2 changes: 1 addition & 1 deletion samples/openapi3/client/petstore/dart-dio/oneof/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ final api = Openapi().getDefaultApi();
try {
final response = await api.rootGet();
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print("Exception when calling DefaultApi->rootGet: $e\n");
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ final api = Openapi().getDefaultApi();
try {
final response = api.rootGet();
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling DefaultApi->rootGet: $e\n');
}
```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ final BarCreate barCreate = ; // BarCreate |
try {
final response = await api.createBar(barCreate);
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print("Exception when calling BarApi->createBar: $e\n");
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ final BarCreate barCreate = ; // BarCreate |
try {
final response = api.createBar(barCreate);
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling BarApi->createBar: $e\n');
}
```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ final Foo foo = ; // Foo | The Foo to be created
try {
final response = api.createFoo(foo);
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling FooApi->createFoo: $e\n');
}
```
Expand Down Expand Up @@ -68,7 +68,7 @@ final api = Openapi().getFooApi();
try {
final response = api.getAllFoos();
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling FooApi->getAllFoos: $e\n');
}
```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ final api = Openapi().getDefaultApi();
try {
final response = await api.list();
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print("Exception when calling DefaultApi->list: $e\n");
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ final api = Openapi().getDefaultApi();
try {
final response = api.list();
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling DefaultApi->list: $e\n');
}
```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ final Pet pet = ; // Pet | Pet object that needs to be added to the store
try {
final response = await api.addPet(pet);
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print("Exception when calling PetApi->addPet: $e\n");
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ final Pet pet = ; // Pet | Pet object that needs to be added to the store
try {
final response = api.addPet(pet);
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling PetApi->addPet: $e\n');
}
```
Expand Down Expand Up @@ -83,7 +83,7 @@ final String apiKey = apiKey_example; // String |
try {
api.deletePet(petId, apiKey);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling PetApi->deletePet: $e\n');
}
```
Expand Down Expand Up @@ -129,7 +129,7 @@ final BuiltList<String> status = ; // BuiltList<String> | Status values that nee
try {
final response = api.findPetsByStatus(status);
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling PetApi->findPetsByStatus: $e\n');
}
```
Expand Down Expand Up @@ -174,7 +174,7 @@ final BuiltList<String> tags = ; // BuiltList<String> | Tags to filter by
try {
final response = api.findPetsByTags(tags);
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling PetApi->findPetsByTags: $e\n');
}
```
Expand Down Expand Up @@ -221,7 +221,7 @@ final int petId = 789; // int | ID of pet to return
try {
final response = api.getPetById(petId);
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling PetApi->getPetById: $e\n');
}
```
Expand Down Expand Up @@ -266,7 +266,7 @@ final Pet pet = ; // Pet | Pet object that needs to be added to the store
try {
final response = api.updatePet(pet);
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling PetApi->updatePet: $e\n');
}
```
Expand Down Expand Up @@ -312,7 +312,7 @@ final String status = status_example; // String | Updated status of the pet
try {
api.updatePetWithForm(petId, name, status);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling PetApi->updatePetWithForm: $e\n');
}
```
Expand Down Expand Up @@ -361,7 +361,7 @@ final MultipartFile file = BINARY_DATA_HERE; // MultipartFile | file to upload
try {
final response = api.uploadFile(petId, additionalMetadata, file);
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling PetApi->uploadFile: $e\n');
}
```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ final String orderId = orderId_example; // String | ID of the order that needs t
try {
api.deleteOrder(orderId);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling StoreApi->deleteOrder: $e\n');
}
```
Expand Down Expand Up @@ -77,7 +77,7 @@ final api = Openapi().getStoreApi();
try {
final response = api.getInventory();
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling StoreApi->getInventory: $e\n');
}
```
Expand Down Expand Up @@ -117,7 +117,7 @@ final int orderId = 789; // int | ID of pet that needs to be fetched
try {
final response = api.getOrderById(orderId);
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling StoreApi->getOrderById: $e\n');
}
```
Expand Down Expand Up @@ -160,7 +160,7 @@ final Order order = ; // Order | order placed for purchasing the pet
try {
final response = api.placeOrder(order);
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling StoreApi->placeOrder: $e\n');
}
```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ final User user = ; // User | Created user object
try {
api.createUser(user);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling UserApi->createUser: $e\n');
}
```
Expand Down Expand Up @@ -85,7 +85,7 @@ final BuiltList<User> user = ; // BuiltList<User> | List of user object
try {
api.createUsersWithArrayInput(user);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling UserApi->createUsersWithArrayInput: $e\n');
}
```
Expand Down Expand Up @@ -131,7 +131,7 @@ final BuiltList<User> user = ; // BuiltList<User> | List of user object
try {
api.createUsersWithListInput(user);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling UserApi->createUsersWithListInput: $e\n');
}
```
Expand Down Expand Up @@ -177,7 +177,7 @@ final String username = username_example; // String | The name that needs to be
try {
api.deleteUser(username);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling UserApi->deleteUser: $e\n');
}
```
Expand Down Expand Up @@ -220,7 +220,7 @@ final String username = username_example; // String | The name that needs to be
try {
final response = api.getUserByName(username);
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling UserApi->getUserByName: $e\n');
}
```
Expand Down Expand Up @@ -264,7 +264,7 @@ final String password = password_example; // String | The password for login in
try {
final response = api.loginUser(username, password);
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling UserApi->loginUser: $e\n');
}
```
Expand Down Expand Up @@ -310,7 +310,7 @@ final api = Openapi().getUserApi();
try {
api.logoutUser();
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling UserApi->logoutUser: $e\n');
}
```
Expand Down Expand Up @@ -354,7 +354,7 @@ final User user = ; // User | Updated user object
try {
api.updateUser(username, user);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling UserApi->updateUser: $e\n');
}
```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ final ModelClient modelClient = ; // ModelClient | client model
try {
final response = await api.call123testSpecialTags(modelClient);
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print("Exception when calling AnotherFakeApi->call123testSpecialTags: $e\n");
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ final ModelClient modelClient = ; // ModelClient | client model
try {
final response = api.call123testSpecialTags(modelClient);
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling AnotherFakeApi->call123testSpecialTags: $e\n');
}
```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ final api = Openapi().getDefaultApi();
try {
final response = api.fooGet();
print(response);
} catch on DioException (e) {
} on DioException catch (e) {
print('Exception when calling DefaultApi->fooGet: $e\n');
}
```
Expand Down
Loading
Loading