forked from loafle/openapi-generator-original
[Objc] Class not identified due to Circular imports (#6069)
* [Objc] Class not identified due to Circular imports * Pet store generated sample
This commit is contained in:
parent
bf74de3a5a
commit
93415af92d
@ -5,6 +5,11 @@
|
|||||||
|
|
||||||
{{#imports}}#import "{{import}}.h"
|
{{#imports}}#import "{{import}}.h"
|
||||||
{{/imports}}
|
{{/imports}}
|
||||||
|
{{#imports}}
|
||||||
|
@protocol {{import}};
|
||||||
|
@class {{import}};
|
||||||
|
{{/imports}}
|
||||||
|
|
||||||
{{newline}}
|
{{newline}}
|
||||||
{{#models}}
|
{{#models}}
|
||||||
{{#model}}
|
{{#model}}
|
||||||
|
@ -69,7 +69,7 @@ SWGDefaultConfiguration *apiConfig = [SWGDefaultConfiguration sharedConfig];
|
|||||||
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];
|
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];
|
||||||
|
|
||||||
|
|
||||||
SWGPet* *body = [[Pet alloc] init]; // Pet object that needs to be added to the store (optional)
|
SWGPet* *body = [[SWGPet alloc] init]; // Pet object that needs to be added to the store (optional)
|
||||||
|
|
||||||
SWGPetApi *apiInstance = [[SWGPetApi alloc] init];
|
SWGPetApi *apiInstance = [[SWGPetApi alloc] init];
|
||||||
|
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@protocol SWGCategory
|
@protocol SWGCategory
|
||||||
@end
|
@end
|
||||||
|
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@protocol SWGOrder
|
@protocol SWGOrder
|
||||||
@end
|
@end
|
||||||
|
|
||||||
|
@ -16,6 +16,11 @@
|
|||||||
|
|
||||||
#import "SWGCategory.h"
|
#import "SWGCategory.h"
|
||||||
#import "SWGTag.h"
|
#import "SWGTag.h"
|
||||||
|
@protocol SWGCategory;
|
||||||
|
@class SWGCategory;
|
||||||
|
@protocol SWGTag;
|
||||||
|
@class SWGTag;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@protocol SWGPet
|
@protocol SWGPet
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@protocol SWGTag
|
@protocol SWGTag
|
||||||
@end
|
@end
|
||||||
|
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@protocol SWGUser
|
@protocol SWGUser
|
||||||
@end
|
@end
|
||||||
|
|
||||||
|
@ -32,7 +32,7 @@ SWGDefaultConfiguration *apiConfig = [SWGDefaultConfiguration sharedConfig];
|
|||||||
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];
|
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];
|
||||||
|
|
||||||
|
|
||||||
SWGPet* body = [[Pet alloc] init]; // Pet object that needs to be added to the store (optional)
|
SWGPet* body = [[SWGPet alloc] init]; // Pet object that needs to be added to the store (optional)
|
||||||
|
|
||||||
SWGPetApi*apiInstance = [[SWGPetApi alloc] init];
|
SWGPetApi*apiInstance = [[SWGPetApi alloc] init];
|
||||||
|
|
||||||
@ -49,7 +49,7 @@ SWGPetApi*apiInstance = [[SWGPetApi alloc] init];
|
|||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**body** | [**SWGPet***](Pet.md)| Pet object that needs to be added to the store | [optional]
|
**body** | [**SWGPet***](SWGPet.md)| Pet object that needs to be added to the store | [optional]
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
@ -310,7 +310,7 @@ SWGDefaultConfiguration *apiConfig = [SWGDefaultConfiguration sharedConfig];
|
|||||||
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];
|
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];
|
||||||
|
|
||||||
|
|
||||||
SWGPet* body = [[Pet alloc] init]; // Pet object that needs to be added to the store (optional)
|
SWGPet* body = [[SWGPet alloc] init]; // Pet object that needs to be added to the store (optional)
|
||||||
|
|
||||||
SWGPetApi*apiInstance = [[SWGPetApi alloc] init];
|
SWGPetApi*apiInstance = [[SWGPetApi alloc] init];
|
||||||
|
|
||||||
@ -327,7 +327,7 @@ SWGPetApi*apiInstance = [[SWGPetApi alloc] init];
|
|||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**body** | [**SWGPet***](Pet.md)| Pet object that needs to be added to the store | [optional]
|
**body** | [**SWGPet***](SWGPet.md)| Pet object that needs to be added to the store | [optional]
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
|
@ -173,7 +173,7 @@ Place an order for a pet
|
|||||||
### Example
|
### Example
|
||||||
```objc
|
```objc
|
||||||
|
|
||||||
SWGOrder* body = [[Order alloc] init]; // order placed for purchasing the pet (optional)
|
SWGOrder* body = [[SWGOrder alloc] init]; // order placed for purchasing the pet (optional)
|
||||||
|
|
||||||
SWGStoreApi*apiInstance = [[SWGStoreApi alloc] init];
|
SWGStoreApi*apiInstance = [[SWGStoreApi alloc] init];
|
||||||
|
|
||||||
@ -193,7 +193,7 @@ SWGStoreApi*apiInstance = [[SWGStoreApi alloc] init];
|
|||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**body** | [**SWGOrder***](Order.md)| order placed for purchasing the pet | [optional]
|
**body** | [**SWGOrder***](SWGOrder.md)| order placed for purchasing the pet | [optional]
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
|
@ -27,7 +27,7 @@ This can only be done by the logged in user.
|
|||||||
### Example
|
### Example
|
||||||
```objc
|
```objc
|
||||||
|
|
||||||
SWGUser* body = [[User alloc] init]; // Created user object (optional)
|
SWGUser* body = [[SWGUser alloc] init]; // Created user object (optional)
|
||||||
|
|
||||||
SWGUserApi*apiInstance = [[SWGUserApi alloc] init];
|
SWGUserApi*apiInstance = [[SWGUserApi alloc] init];
|
||||||
|
|
||||||
@ -44,7 +44,7 @@ SWGUserApi*apiInstance = [[SWGUserApi alloc] init];
|
|||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**body** | [**SWGUser***](User.md)| Created user object | [optional]
|
**body** | [**SWGUser***](SWGUser.md)| Created user object | [optional]
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
@ -364,7 +364,7 @@ This can only be done by the logged in user.
|
|||||||
```objc
|
```objc
|
||||||
|
|
||||||
NSString* username = @"username_example"; // name that need to be deleted
|
NSString* username = @"username_example"; // name that need to be deleted
|
||||||
SWGUser* body = [[User alloc] init]; // Updated user object (optional)
|
SWGUser* body = [[SWGUser alloc] init]; // Updated user object (optional)
|
||||||
|
|
||||||
SWGUserApi*apiInstance = [[SWGUserApi alloc] init];
|
SWGUserApi*apiInstance = [[SWGUserApi alloc] init];
|
||||||
|
|
||||||
@ -383,7 +383,7 @@ SWGUserApi*apiInstance = [[SWGUserApi alloc] init];
|
|||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**username** | **NSString***| name that need to be deleted |
|
**username** | **NSString***| name that need to be deleted |
|
||||||
**body** | [**SWGUser***](User.md)| Updated user object | [optional]
|
**body** | [**SWGUser***](SWGUser.md)| Updated user object | [optional]
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user