-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
NamSor SAS
committed
Nov 24, 2019
1 parent
e5d2887
commit 01ca5d5
Showing
85 changed files
with
553 additions
and
330 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
Package: namsor | ||
Title: R Package Client for NamSor API v2 | ||
Version: 1.0.1 | ||
Version: 1.0.0 | ||
Authors@R: person("OpenAPI Generator community", email = "[email protected]", role = c("aut", "cre")) | ||
Description: NamSor API v2 : enpoints to process personal names (gender, cultural origin or ethnicity) in all alphabets or languages. Use GET methods for small tests, but prefer POST methods for higher throughput (batch processing of up to 100 names at a time). Need something you can't find here? We have many more features coming soon. Let us know, we'll do our best to add it! | ||
Depends: R (>= 3.3.3) | ||
Encoding: UTF-8 | ||
License: Unlicense | ||
LazyData: true | ||
Suggests: testthat | ||
Imports: jsonlite, httr, R6, caTools | ||
Imports: jsonlite, httr, R6 | ||
RoxygenNote: 6.0.1.9000 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ | |
# | ||
# NamSor API v2 : enpoints to process personal names (gender, cultural origin or ethnicity) in all alphabets or languages. Use GET methods for small tests, but prefer POST methods for higher throughput (batch processing of up to 100 names at a time). Need something you can't find here? We have many more features coming soon. Let us know, we'll do our best to add it! | ||
# | ||
# OpenAPI spec version: 2.0.6 | ||
# OpenAPI spec version: 2.0.7 | ||
# Contact: [email protected] | ||
# Generated by: https://openapi-generator.tech | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,110 @@ | ||
# NamSor API v2 | ||
# | ||
# NamSor API v2 : enpoints to process personal names (gender, cultural origin or ethnicity) in all alphabets or languages. Use GET methods for small tests, but prefer POST methods for higher throughput (batch processing of up to 100 names at a time). Need something you can't find here? We have many more features coming soon. Let us know, we'll do our best to add it! | ||
# | ||
# OpenAPI spec version: 2.0.7 | ||
# Contact: [email protected] | ||
# Generated by: https://openapi-generator.tech | ||
|
||
|
||
#' APIClassifierOut Class | ||
#' | ||
#' @field classifierName | ||
#' @field serving | ||
#' @field learning | ||
#' @field shuttingDown | ||
#' @field probabilityCalibrated | ||
#' | ||
#' @importFrom R6 R6Class | ||
#' @importFrom jsonlite fromJSON toJSON | ||
#' @export | ||
APIClassifierOut <- R6::R6Class( | ||
'APIClassifierOut', | ||
public = list( | ||
`classifierName` = NULL, | ||
`serving` = NULL, | ||
`learning` = NULL, | ||
`shuttingDown` = NULL, | ||
`probabilityCalibrated` = NULL, | ||
initialize = function(`classifierName`, `serving`, `learning`, `shuttingDown`, `probabilityCalibrated`){ | ||
if (!missing(`classifierName`)) { | ||
stopifnot(is.character(`classifierName`), length(`classifierName`) == 1) | ||
self$`classifierName` <- `classifierName` | ||
} | ||
if (!missing(`serving`)) { | ||
self$`serving` <- `serving` | ||
} | ||
if (!missing(`learning`)) { | ||
self$`learning` <- `learning` | ||
} | ||
if (!missing(`shuttingDown`)) { | ||
self$`shuttingDown` <- `shuttingDown` | ||
} | ||
if (!missing(`probabilityCalibrated`)) { | ||
self$`probabilityCalibrated` <- `probabilityCalibrated` | ||
} | ||
}, | ||
toJSON = function() { | ||
APIClassifierOutObject <- list() | ||
if (!is.null(self$`classifierName`)) { | ||
APIClassifierOutObject[['classifierName']] <- self$`classifierName` | ||
} | ||
if (!is.null(self$`serving`)) { | ||
APIClassifierOutObject[['serving']] <- self$`serving` | ||
} | ||
if (!is.null(self$`learning`)) { | ||
APIClassifierOutObject[['learning']] <- self$`learning` | ||
} | ||
if (!is.null(self$`shuttingDown`)) { | ||
APIClassifierOutObject[['shuttingDown']] <- self$`shuttingDown` | ||
} | ||
if (!is.null(self$`probabilityCalibrated`)) { | ||
APIClassifierOutObject[['probabilityCalibrated']] <- self$`probabilityCalibrated` | ||
} | ||
|
||
APIClassifierOutObject | ||
}, | ||
fromJSON = function(APIClassifierOutJson) { | ||
APIClassifierOutObject <- jsonlite::fromJSON(APIClassifierOutJson) | ||
if (!is.null(APIClassifierOutObject$`classifierName`)) { | ||
self$`classifierName` <- APIClassifierOutObject$`classifierName` | ||
} | ||
if (!is.null(APIClassifierOutObject$`serving`)) { | ||
self$`serving` <- APIClassifierOutObject$`serving` | ||
} | ||
if (!is.null(APIClassifierOutObject$`learning`)) { | ||
self$`learning` <- APIClassifierOutObject$`learning` | ||
} | ||
if (!is.null(APIClassifierOutObject$`shuttingDown`)) { | ||
self$`shuttingDown` <- APIClassifierOutObject$`shuttingDown` | ||
} | ||
if (!is.null(APIClassifierOutObject$`probabilityCalibrated`)) { | ||
self$`probabilityCalibrated` <- APIClassifierOutObject$`probabilityCalibrated` | ||
} | ||
}, | ||
toJSONString = function() { | ||
sprintf( | ||
'{ | ||
"classifierName": %s, | ||
"serving": %s, | ||
"learning": %s, | ||
"shuttingDown": %s, | ||
"probabilityCalibrated": %s | ||
}', | ||
self$`classifierName`, | ||
self$`serving`, | ||
self$`learning`, | ||
self$`shuttingDown`, | ||
self$`probabilityCalibrated` | ||
) | ||
}, | ||
fromJSONString = function(APIClassifierOutJson) { | ||
APIClassifierOutObject <- jsonlite::fromJSON(APIClassifierOutJson) | ||
self$`classifierName` <- APIClassifierOutObject$`classifierName` | ||
self$`serving` <- APIClassifierOutObject$`serving` | ||
self$`learning` <- APIClassifierOutObject$`learning` | ||
self$`shuttingDown` <- APIClassifierOutObject$`shuttingDown` | ||
self$`probabilityCalibrated` <- APIClassifierOutObject$`probabilityCalibrated` | ||
} | ||
) | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
# NamSor API v2 | ||
# | ||
# NamSor API v2 : enpoints to process personal names (gender, cultural origin or ethnicity) in all alphabets or languages. Use GET methods for small tests, but prefer POST methods for higher throughput (batch processing of up to 100 names at a time). Need something you can't find here? We have many more features coming soon. Let us know, we'll do our best to add it! | ||
# | ||
# OpenAPI spec version: 2.0.7 | ||
# Contact: [email protected] | ||
# Generated by: https://openapi-generator.tech | ||
|
||
|
||
#' APIClassifierTaxonomyOut Class | ||
#' | ||
#' @field classifierName | ||
#' @field taxonomyClasses | ||
#' | ||
#' @importFrom R6 R6Class | ||
#' @importFrom jsonlite fromJSON toJSON | ||
#' @export | ||
APIClassifierTaxonomyOut <- R6::R6Class( | ||
'APIClassifierTaxonomyOut', | ||
public = list( | ||
`classifierName` = NULL, | ||
`taxonomyClasses` = NULL, | ||
initialize = function(`classifierName`, `taxonomyClasses`){ | ||
if (!missing(`classifierName`)) { | ||
stopifnot(is.character(`classifierName`), length(`classifierName`) == 1) | ||
self$`classifierName` <- `classifierName` | ||
} | ||
if (!missing(`taxonomyClasses`)) { | ||
stopifnot(is.list(`taxonomyClasses`), length(`taxonomyClasses`) != 0) | ||
lapply(`taxonomyClasses`, function(x) stopifnot(is.character(x))) | ||
self$`taxonomyClasses` <- `taxonomyClasses` | ||
} | ||
}, | ||
toJSON = function() { | ||
APIClassifierTaxonomyOutObject <- list() | ||
if (!is.null(self$`classifierName`)) { | ||
APIClassifierTaxonomyOutObject[['classifierName']] <- self$`classifierName` | ||
} | ||
if (!is.null(self$`taxonomyClasses`)) { | ||
APIClassifierTaxonomyOutObject[['taxonomyClasses']] <- self$`taxonomyClasses` | ||
} | ||
|
||
APIClassifierTaxonomyOutObject | ||
}, | ||
fromJSON = function(APIClassifierTaxonomyOutJson) { | ||
APIClassifierTaxonomyOutObject <- jsonlite::fromJSON(APIClassifierTaxonomyOutJson) | ||
if (!is.null(APIClassifierTaxonomyOutObject$`classifierName`)) { | ||
self$`classifierName` <- APIClassifierTaxonomyOutObject$`classifierName` | ||
} | ||
if (!is.null(APIClassifierTaxonomyOutObject$`taxonomyClasses`)) { | ||
self$`taxonomyClasses` <- APIClassifierTaxonomyOutObject$`taxonomyClasses` | ||
} | ||
}, | ||
toJSONString = function() { | ||
sprintf( | ||
'{ | ||
"classifierName": %s, | ||
"taxonomyClasses": [%s] | ||
}', | ||
self$`classifierName`, | ||
lapply(self$`taxonomyClasses`, function(x) paste(paste0('"', x, '"'), sep=",")) | ||
) | ||
}, | ||
fromJSONString = function(APIClassifierTaxonomyOutJson) { | ||
APIClassifierTaxonomyOutObject <- jsonlite::fromJSON(APIClassifierTaxonomyOutJson) | ||
self$`classifierName` <- APIClassifierTaxonomyOutObject$`classifierName` | ||
self$`taxonomyClasses` <- APIClassifierTaxonomyOutObject$`taxonomyClasses` | ||
} | ||
) | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
# NamSor API v2 | ||
# | ||
# NamSor API v2 : enpoints to process personal names (gender, cultural origin or ethnicity) in all alphabets or languages. Use GET methods for small tests, but prefer POST methods for higher throughput (batch processing of up to 100 names at a time). Need something you can't find here? We have many more features coming soon. Let us know, we'll do our best to add it! | ||
# | ||
# OpenAPI spec version: 2.0.7 | ||
# Contact: [email protected] | ||
# Generated by: https://openapi-generator.tech | ||
|
||
|
||
#' APIClassifiersStatusOut Class | ||
#' | ||
#' @field softwareVersion | ||
#' @field classifiers | ||
#' | ||
#' @importFrom R6 R6Class | ||
#' @importFrom jsonlite fromJSON toJSON | ||
#' @export | ||
APIClassifiersStatusOut <- R6::R6Class( | ||
'APIClassifiersStatusOut', | ||
public = list( | ||
`softwareVersion` = NULL, | ||
`classifiers` = NULL, | ||
initialize = function(`softwareVersion`, `classifiers`){ | ||
if (!missing(`softwareVersion`)) { | ||
stopifnot(R6::is.R6(`softwareVersion`)) | ||
self$`softwareVersion` <- `softwareVersion` | ||
} | ||
if (!missing(`classifiers`)) { | ||
stopifnot(is.list(`classifiers`), length(`classifiers`) != 0) | ||
lapply(`classifiers`, function(x) stopifnot(R6::is.R6(x))) | ||
self$`classifiers` <- `classifiers` | ||
} | ||
}, | ||
toJSON = function() { | ||
APIClassifiersStatusOutObject <- list() | ||
if (!is.null(self$`softwareVersion`)) { | ||
APIClassifiersStatusOutObject[['softwareVersion']] <- self$`softwareVersion`$toJSON() | ||
} | ||
if (!is.null(self$`classifiers`)) { | ||
APIClassifiersStatusOutObject[['classifiers']] <- lapply(self$`classifiers`, function(x) x$toJSON()) | ||
} | ||
|
||
APIClassifiersStatusOutObject | ||
}, | ||
fromJSON = function(APIClassifiersStatusOutJson) { | ||
APIClassifiersStatusOutObject <- jsonlite::fromJSON(APIClassifiersStatusOutJson) | ||
if (!is.null(APIClassifiersStatusOutObject$`softwareVersion`)) { | ||
softwareVersionObject <- SoftwareVersionOut$new() | ||
softwareVersionObject$fromJSON(jsonlite::toJSON(APIClassifiersStatusOutObject$softwareVersion, auto_unbox = TRUE)) | ||
self$`softwareVersion` <- softwareVersionObject | ||
} | ||
if (!is.null(APIClassifiersStatusOutObject$`classifiers`)) { | ||
self$`classifiers` <- lapply(APIClassifiersStatusOutObject$`classifiers`, function(x) { | ||
classifiersObject <- APIClassifierOut$new() | ||
classifiersObject$fromJSON(jsonlite::toJSON(x, auto_unbox = TRUE)) | ||
classifiersObject | ||
}) | ||
} | ||
}, | ||
toJSONString = function() { | ||
sprintf( | ||
'{ | ||
"softwareVersion": %s, | ||
"classifiers": [%s] | ||
}', | ||
self$`softwareVersion`$toJSON(), | ||
lapply(self$`classifiers`, function(x) paste(x$toJSON(), sep=",")) | ||
) | ||
}, | ||
fromJSONString = function(APIClassifiersStatusOutJson) { | ||
APIClassifiersStatusOutObject <- jsonlite::fromJSON(APIClassifiersStatusOutJson) | ||
SoftwareVersionOutObject <- SoftwareVersionOut$new() | ||
self$`softwareVersion` <- SoftwareVersionOutObject$fromJSON(jsonlite::toJSON(APIClassifiersStatusOutObject$softwareVersion, auto_unbox = TRUE)) | ||
self$`classifiers` <- lapply(APIClassifiersStatusOutObject$`classifiers`, function(x) APIClassifierOut$new()$fromJSON(jsonlite::toJSON(x, auto_unbox = TRUE))) | ||
} | ||
) | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ | |
# | ||
# NamSor API v2 : enpoints to process personal names (gender, cultural origin or ethnicity) in all alphabets or languages. Use GET methods for small tests, but prefer POST methods for higher throughput (batch processing of up to 100 names at a time). Need something you can't find here? We have many more features coming soon. Let us know, we'll do our best to add it! | ||
# | ||
# OpenAPI spec version: 2.0.6 | ||
# OpenAPI spec version: 2.0.7 | ||
# Contact: [email protected] | ||
# Generated by: https://openapi-generator.tech | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ | |
# | ||
# NamSor API v2 : enpoints to process personal names (gender, cultural origin or ethnicity) in all alphabets or languages. Use GET methods for small tests, but prefer POST methods for higher throughput (batch processing of up to 100 names at a time). Need something you can't find here? We have many more features coming soon. Let us know, we'll do our best to add it! | ||
# | ||
# OpenAPI spec version: 2.0.6 | ||
# OpenAPI spec version: 2.0.7 | ||
# Contact: [email protected] | ||
# Generated by: https://openapi-generator.tech | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ | |
# | ||
# NamSor API v2 : enpoints to process personal names (gender, cultural origin or ethnicity) in all alphabets or languages. Use GET methods for small tests, but prefer POST methods for higher throughput (batch processing of up to 100 names at a time). Need something you can't find here? We have many more features coming soon. Let us know, we'll do our best to add it! | ||
# | ||
# OpenAPI spec version: 2.0.6 | ||
# OpenAPI spec version: 2.0.7 | ||
# Contact: [email protected] | ||
# Generated by: https://openapi-generator.tech | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ | |
# | ||
# NamSor API v2 : enpoints to process personal names (gender, cultural origin or ethnicity) in all alphabets or languages. Use GET methods for small tests, but prefer POST methods for higher throughput (batch processing of up to 100 names at a time). Need something you can't find here? We have many more features coming soon. Let us know, we'll do our best to add it! | ||
# | ||
# OpenAPI spec version: 2.0.6 | ||
# OpenAPI spec version: 2.0.7 | ||
# Contact: [email protected] | ||
# Generated by: https://openapi-generator.tech | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ | |
# | ||
# NamSor API v2 : enpoints to process personal names (gender, cultural origin or ethnicity) in all alphabets or languages. Use GET methods for small tests, but prefer POST methods for higher throughput (batch processing of up to 100 names at a time). Need something you can't find here? We have many more features coming soon. Let us know, we'll do our best to add it! | ||
# | ||
# OpenAPI spec version: 2.0.6 | ||
# OpenAPI spec version: 2.0.7 | ||
# Contact: [email protected] | ||
# Generated by: https://openapi-generator.tech | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ | |
# | ||
# NamSor API v2 : enpoints to process personal names (gender, cultural origin or ethnicity) in all alphabets or languages. Use GET methods for small tests, but prefer POST methods for higher throughput (batch processing of up to 100 names at a time). Need something you can't find here? We have many more features coming soon. Let us know, we'll do our best to add it! | ||
# | ||
# OpenAPI spec version: 2.0.6 | ||
# OpenAPI spec version: 2.0.7 | ||
# Contact: [email protected] | ||
# Generated by: https://openapi-generator.tech | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ | |
# | ||
# NamSor API v2 : enpoints to process personal names (gender, cultural origin or ethnicity) in all alphabets or languages. Use GET methods for small tests, but prefer POST methods for higher throughput (batch processing of up to 100 names at a time). Need something you can't find here? We have many more features coming soon. Let us know, we'll do our best to add it! | ||
# | ||
# OpenAPI spec version: 2.0.6 | ||
# OpenAPI spec version: 2.0.7 | ||
# Contact: [email protected] | ||
# Generated by: https://openapi-generator.tech | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ | |
# | ||
# NamSor API v2 : enpoints to process personal names (gender, cultural origin or ethnicity) in all alphabets or languages. Use GET methods for small tests, but prefer POST methods for higher throughput (batch processing of up to 100 names at a time). Need something you can't find here? We have many more features coming soon. Let us know, we'll do our best to add it! | ||
# | ||
# OpenAPI spec version: 2.0.6 | ||
# OpenAPI spec version: 2.0.7 | ||
# Contact: [email protected] | ||
# Generated by: https://openapi-generator.tech | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ | |
# | ||
# NamSor API v2 : enpoints to process personal names (gender, cultural origin or ethnicity) in all alphabets or languages. Use GET methods for small tests, but prefer POST methods for higher throughput (batch processing of up to 100 names at a time). Need something you can't find here? We have many more features coming soon. Let us know, we'll do our best to add it! | ||
# | ||
# OpenAPI spec version: 2.0.6 | ||
# OpenAPI spec version: 2.0.7 | ||
# Contact: [email protected] | ||
# Generated by: https://openapi-generator.tech | ||
|
||
|
Oops, something went wrong.