# Binance Public Spot API
#
# OpenAPI Specifications for the Binance Public Spot API API documents: - [https://github.com/binance/binance-spot-api-docs](https://github.com/binance/binance-spot-api-docs) - [https://binance-docs.github.io/apidocs/spot/en](https://binance-docs.github.io/apidocs/spot/en)
#
# The version of the OpenAPI document: 1.0
#
# Generated by: https://openapi-generator.tech
#' @docType class
#' @title InlineResponse20011
#'
#' @description InlineResponse20011 Class
#'
#' @format An \code{R6Class} generator object
#'
#' @field rows list( \link{InlineResponse20011Rows} )
#'
#' @field total integer
#'
#' @importFrom R6 R6Class
#' @importFrom jsonlite fromJSON toJSON
#' @export
InlineResponse20011 <- R6::R6Class(
'InlineResponse20011',
public = list(
`rows` = NULL,
`total` = NULL,
initialize = function(
`rows`, `total`, ...
) {
local.optional.var <- list(...)
if (!missing(`rows`)) {
stopifnot(is.vector(`rows`), length(`rows`) != 0)
sapply(`rows`, function(x) stopifnot(R6::is.R6(x)))
self$`rows` <- `rows`
}
if (!missing(`total`)) {
stopifnot(is.numeric(`total`), length(`total`) == 1)
self$`total` <- `total`
}
},
toJSON = function() {
InlineResponse20011Object <- list()
if (!is.null(self$`rows`)) {
InlineResponse20011Object[['rows']] <-
lapply(self$`rows`, function(x) x$toJSON())
}
if (!is.null(self$`total`)) {
InlineResponse20011Object[['total']] <-
self$`total`
}
InlineResponse20011Object
},
fromJSON = function(InlineResponse20011Json) {
InlineResponse20011Object <- jsonlite::fromJSON(InlineResponse20011Json)
if (!is.null(InlineResponse20011Object$`rows`)) {
self$`rows` <- ApiClient$new()$deserializeObj(InlineResponse20011Object$`rows`, "array[InlineResponse20011Rows]", loadNamespace("binanceRapi"))
}
if (!is.null(InlineResponse20011Object$`total`)) {
self$`total` <- InlineResponse20011Object$`total`
}
self
},
toJSONString = function() {
jsoncontent <- c(
if (!is.null(self$`rows`)) {
sprintf(
'"rows":
[%s]
',
paste(sapply(self$`rows`, function(x) jsonlite::toJSON(x$toJSON(), auto_unbox=TRUE, digits = NA)), collapse=",")
)},
if (!is.null(self$`total`)) {
sprintf(
'"total":
%d
',
self$`total`
)}
)
jsoncontent <- paste(jsoncontent, collapse = ",")
paste('{', jsoncontent, '}', sep = "")
},
fromJSONString = function(InlineResponse20011Json) {
InlineResponse20011Object <- jsonlite::fromJSON(InlineResponse20011Json)
self$`rows` <- ApiClient$new()$deserializeObj(InlineResponse20011Object$`rows`, "array[InlineResponse20011Rows]", loadNamespace("binanceRapi"))
self$`total` <- InlineResponse20011Object$`total`
self
}
)
)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.