forked from loafle/openapi-generator-original
[cpp C++] fix use of isBasic condition (#15535)
This commit is contained in:
parent
89e4b24295
commit
e7039f434e
@ -70,11 +70,11 @@ void Example::exampleFunction1(){
|
|||||||
apiInstance.setUsername("YOUR USERNAME");
|
apiInstance.setUsername("YOUR USERNAME");
|
||||||
apiInstance.setPassword("YOUR PASSWORD");{{/isBasicBasic}}{{#isBasicBearer}}
|
apiInstance.setPassword("YOUR PASSWORD");{{/isBasicBasic}}{{#isBasicBearer}}
|
||||||
// Configure HTTP bearer authorization: {{{name}}}
|
// Configure HTTP bearer authorization: {{{name}}}
|
||||||
apiInstance.setBearerToken("BEARER TOKEN");{{/isBasicBearer}}{{/isBasic}}{{#isApiKey}}
|
apiInstance.setBearerToken("BEARER TOKEN");{{/isBasicBearer}}{{#isHttpSignature}}
|
||||||
|
//No Http Signature Authentication supported right now{{/isHttpSignature}}{{/isBasic}}{{#isApiKey}}
|
||||||
// Configure API key authorization: {{{name}}}
|
// Configure API key authorization: {{{name}}}
|
||||||
apiInstance.setApiKey("YOUR API KEY NAME","YOUR API KEY");{{/isApiKey}}{{#isOAuth}}
|
apiInstance.setApiKey("YOUR API KEY NAME","YOUR API KEY");{{/isApiKey}}{{#isOAuth}}
|
||||||
//OAuth Authentication supported right now{{/isOAuth}}{{#isHttpSignature}}
|
//OAuth Authentication supported right now{{/isOAuth}}
|
||||||
//No Http Signature Authentication supported right now{{/isHttpSignature}}
|
|
||||||
{{/authMethods}}
|
{{/authMethods}}
|
||||||
{{/hasAuthMethods}}
|
{{/hasAuthMethods}}
|
||||||
{{#allParams}}
|
{{#allParams}}
|
||||||
@ -165,8 +165,13 @@ servers:
|
|||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
{{/isBasicBasic}}
|
{{/isBasicBasic}}
|
||||||
{{#isBasicBearer}}
|
{{#isBasicBearer}}
|
||||||
- **Type**: HTTP Bearer Token authentication
|
|
||||||
|
- **Type**: HTTP Bearer Token authentication{{#bearerFormat}} ({{{.}}}){{/bearerFormat}}
|
||||||
{{/isBasicBearer}}
|
{{/isBasicBearer}}
|
||||||
|
{{#isHttpSignature}}
|
||||||
|
|
||||||
|
- **Type**: HTTP signature authentication
|
||||||
|
{{/isHttpSignature}}
|
||||||
{{#isOAuth}}
|
{{#isOAuth}}
|
||||||
|
|
||||||
- **Type**: OAuth
|
- **Type**: OAuth
|
||||||
|
@ -256,9 +256,9 @@ pplx::task<{{{returnType}}}{{^returnType}}void{{/returnType}}> {{classname}}::{{
|
|||||||
}
|
}
|
||||||
{{/isKeyInQuery}}
|
{{/isKeyInQuery}}
|
||||||
{{/isApiKey}}
|
{{/isApiKey}}
|
||||||
{{#isBasic}}
|
{{#isBasicBasic}}
|
||||||
// Basic authentication is added automatically as part of the http_client_config
|
// Basic authentication is added automatically as part of the http_client_config
|
||||||
{{/isBasic}}
|
{{/isBasicBasic}}
|
||||||
{{#isOAuth}}
|
{{#isOAuth}}
|
||||||
// oauth2 authentication is added automatically as part of the http_client_config
|
// oauth2 authentication is added automatically as part of the http_client_config
|
||||||
{{/isOAuth}}
|
{{/isOAuth}}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user