forked from loafle/openapi-generator-original
[R] fix assignment, better doc (#12979)
* better code format * fix doc comment, remove blank line * ignore .lintr in rbuildignore
This commit is contained in:
parent
0ce606c7c5
commit
e4b268613c
@ -11,6 +11,7 @@
|
||||
^\.gitignore$
|
||||
^\.openapi-generator-ignore$
|
||||
^\.travis\.yml$
|
||||
^\.lintr$
|
||||
^\.github$
|
||||
^\.openapi-generator$
|
||||
^docs$
|
||||
|
@ -12,7 +12,7 @@
|
||||
{{#operation}}
|
||||
#' \strong{ {{operationId}} } \emph{ {{summary}} }
|
||||
{{#notes}}
|
||||
#' {{notes}}
|
||||
#' {{{.}}}
|
||||
{{/notes}}
|
||||
#'
|
||||
#' \itemize{
|
||||
@ -182,7 +182,7 @@
|
||||
#' @param {{{paramName}}} {{{description}}}
|
||||
{{/requiredParams}}
|
||||
{{#optionalParams}}
|
||||
#' @param {{{paramName}}} (optional){{{description}}} {{#defaultValue}} (default value: {{{.}}}){{/defaultValue}}
|
||||
#' @param {{{paramName}}} (optional) {{{description}}}{{^description}}No description{{/description}}{{#defaultValue}} (default value: {{{.}}}){{/defaultValue}}
|
||||
{{/optionalParams}}
|
||||
{{#vendorExtensions.x-streaming}}
|
||||
#' @param stream_callback (optional) callback function to process the data stream
|
||||
@ -221,7 +221,7 @@
|
||||
#' @param {{{paramName}}} {{{description}}}
|
||||
{{/requiredParams}}
|
||||
{{#optionalParams}}
|
||||
#' @param {{{paramName}}} (optional) {{{description}}}{{#defaultValue}} (default value: {{{.}}}){{/defaultValue}}
|
||||
#' @param {{{paramName}}} (optional) {{{description}}}{{^description}}No description{{/description}}{{#defaultValue}} (default value: {{{.}}}){{/defaultValue}}
|
||||
{{/optionalParams}}
|
||||
{{#vendorExtensions.x-streaming}}
|
||||
#' @param stream_callback (optional) callback function to process the data stream
|
||||
@ -276,7 +276,9 @@
|
||||
{{#bodyParams}}
|
||||
if (!missing(`{{paramName}}`)) {
|
||||
{{#isArray}}
|
||||
body.items = paste(unlist(lapply({{paramName}}, function(param) {param$toJSONString()})), collapse = ",")
|
||||
body.items <- paste(unlist(lapply({{paramName}}, function(param) {
|
||||
param$toJSONString()
|
||||
})), collapse = ",")
|
||||
body <- paste0("[", body.items, "]")
|
||||
{{/isArray}}
|
||||
{{^isArray}}
|
||||
|
@ -1,5 +1,3 @@
|
||||
{{#models}}
|
||||
{{#model}}
|
||||
#' @docType class
|
||||
#' @title {{classname}}
|
||||
#' @description {{classname}} Class
|
||||
@ -9,10 +7,6 @@
|
||||
{{/vars}}
|
||||
#' @importFrom R6 R6Class
|
||||
#' @importFrom jsonlite fromJSON toJSON
|
||||
{{#isEnum}}
|
||||
{{>modelEnum}}
|
||||
{{/isEnum}}
|
||||
{{^isEnum}}
|
||||
#' @export
|
||||
{{classname}} <- R6::R6Class(
|
||||
"{{classname}}",
|
||||
@ -363,6 +357,3 @@
|
||||
}
|
||||
)
|
||||
)
|
||||
{{/isEnum}}
|
||||
{{/model}}
|
||||
{{/models}}
|
||||
|
@ -11,6 +11,7 @@
|
||||
^\.gitignore$
|
||||
^\.openapi-generator-ignore$
|
||||
^\.travis\.yml$
|
||||
^\.lintr$
|
||||
^\.github$
|
||||
^\.openapi-generator$
|
||||
^docs$
|
||||
|
@ -213,4 +213,3 @@ AllofTagApiResponse <- R6::R6Class(
|
||||
}
|
||||
)
|
||||
)
|
||||
|
||||
|
@ -150,4 +150,3 @@ Animal <- R6::R6Class(
|
||||
}
|
||||
)
|
||||
)
|
||||
|
||||
|
@ -155,4 +155,3 @@ AnyOfPig <- R6::R6Class(
|
||||
}
|
||||
)
|
||||
)
|
||||
|
||||
|
@ -156,4 +156,3 @@ BasquePig <- R6::R6Class(
|
||||
}
|
||||
)
|
||||
)
|
||||
|
||||
|
@ -174,4 +174,3 @@ Cat <- R6::R6Class(
|
||||
}
|
||||
)
|
||||
)
|
||||
|
||||
|
@ -121,4 +121,3 @@ CatAllOf <- R6::R6Class(
|
||||
}
|
||||
)
|
||||
)
|
||||
|
||||
|
@ -144,4 +144,3 @@ Category <- R6::R6Class(
|
||||
}
|
||||
)
|
||||
)
|
||||
|
||||
|
@ -156,4 +156,3 @@ DanishPig <- R6::R6Class(
|
||||
}
|
||||
)
|
||||
)
|
||||
|
||||
|
@ -174,4 +174,3 @@ Dog <- R6::R6Class(
|
||||
}
|
||||
)
|
||||
)
|
||||
|
||||
|
@ -121,4 +121,3 @@ DogAllOf <- R6::R6Class(
|
||||
}
|
||||
)
|
||||
)
|
||||
|
||||
|
@ -167,4 +167,3 @@ ModelApiResponse <- R6::R6Class(
|
||||
}
|
||||
)
|
||||
)
|
||||
|
||||
|
@ -146,4 +146,3 @@ NestedOneOf <- R6::R6Class(
|
||||
}
|
||||
)
|
||||
)
|
||||
|
||||
|
@ -236,4 +236,3 @@ Order <- R6::R6Class(
|
||||
}
|
||||
)
|
||||
)
|
||||
|
||||
|
@ -253,4 +253,3 @@ Pet <- R6::R6Class(
|
||||
}
|
||||
)
|
||||
)
|
||||
|
||||
|
@ -642,7 +642,7 @@ PetApi <- R6::R6Class(
|
||||
#' Deletes a pet
|
||||
#'
|
||||
#' @param pet_id Pet id to delete
|
||||
#' @param api_key (optional)
|
||||
#' @param api_key (optional) No description
|
||||
#' @param ... Other optional arguments
|
||||
#' @return void
|
||||
#' @export
|
||||
@ -665,7 +665,7 @@ PetApi <- R6::R6Class(
|
||||
#' Deletes a pet
|
||||
#'
|
||||
#' @param pet_id Pet id to delete
|
||||
#' @param api_key (optional)
|
||||
#' @param api_key (optional) No description
|
||||
#' @param ... Other optional arguments
|
||||
#' @return API response (void) with additional information such as HTTP status code, headers
|
||||
#' @export
|
||||
|
@ -171,4 +171,3 @@ Pig <- R6::R6Class(
|
||||
}
|
||||
)
|
||||
)
|
||||
|
||||
|
@ -236,4 +236,3 @@ Special <- R6::R6Class(
|
||||
}
|
||||
)
|
||||
)
|
||||
|
||||
|
@ -15,7 +15,7 @@
|
||||
#' @section Methods:
|
||||
#' \describe{
|
||||
#' \strong{ DeleteOrder } \emph{ Delete purchase order by ID }
|
||||
#' For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors
|
||||
#' For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors
|
||||
#'
|
||||
#' \itemize{
|
||||
#' \item \emph{ @param } order_id character
|
||||
@ -55,7 +55,7 @@
|
||||
#' }
|
||||
#'
|
||||
#' \strong{ GetOrderById } \emph{ Find purchase order by ID }
|
||||
#' For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions
|
||||
#' For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions
|
||||
#'
|
||||
#' \itemize{
|
||||
#' \item \emph{ @param } order_id integer
|
||||
|
@ -144,4 +144,3 @@ Tag <- R6::R6Class(
|
||||
}
|
||||
)
|
||||
)
|
||||
|
||||
|
@ -145,4 +145,3 @@ UpdatePetRequest <- R6::R6Class(
|
||||
}
|
||||
)
|
||||
)
|
||||
|
||||
|
@ -282,4 +282,3 @@ User <- R6::R6Class(
|
||||
}
|
||||
)
|
||||
)
|
||||
|
||||
|
@ -559,7 +559,9 @@ UserApi <- R6::R6Class(
|
||||
}
|
||||
|
||||
if (!missing(`user`)) {
|
||||
body.items = paste(unlist(lapply(user, function(param) {param$toJSONString()})), collapse = ",")
|
||||
body.items <- paste(unlist(lapply(user, function(param) {
|
||||
param$toJSONString()
|
||||
})), collapse = ",")
|
||||
body <- paste0("[", body.items, "]")
|
||||
} else {
|
||||
body <- NULL
|
||||
@ -650,7 +652,9 @@ UserApi <- R6::R6Class(
|
||||
}
|
||||
|
||||
if (!missing(`user`)) {
|
||||
body.items = paste(unlist(lapply(user, function(param) {param$toJSONString()})), collapse = ",")
|
||||
body.items <- paste(unlist(lapply(user, function(param) {
|
||||
param$toJSONString()
|
||||
})), collapse = ",")
|
||||
body <- paste0("[", body.items, "]")
|
||||
} else {
|
||||
body <- NULL
|
||||
|
Loading…
x
Reference in New Issue
Block a user