From 803ae7731ba54c81ca70d3c4119fbda3c83f5090 Mon Sep 17 00:00:00 2001
From: Dorchies David <david.dorchies@inrae.fr>
Date: Thu, 5 Aug 2021 12:18:00 +0200
Subject: [PATCH] refactor(doc): process parameter `params` as common parameter
 for all functions

---
 R/doApiQuery.R                              | 1 -
 R/get_indicateurs_services_communes.R       | 1 -
 R/get_indicateurs_services_indicateurs.R    | 1 -
 R/get_prelevements_chroniques.R             | 1 -
 R/get_prelevements_points_prelevement.R     | 1 -
 man-roxygen/param_get_common.R              | 1 +
 man/doApiQuery.Rd                           | 2 +-
 man/get_indicateurs_services_communes.Rd    | 2 +-
 man/get_indicateurs_services_indicateurs.Rd | 2 +-
 man/get_prelevements_chroniques.Rd          | 2 +-
 man/get_prelevements_points_prelevement.Rd  | 2 +-
 11 files changed, 6 insertions(+), 10 deletions(-)

diff --git a/R/doApiQuery.R b/R/doApiQuery.R
index 1b691b6..63eae68 100644
--- a/R/doApiQuery.R
+++ b/R/doApiQuery.R
@@ -9,7 +9,6 @@
 #'
 #' @param api a [character] name of the API (e.g.: "indicateurs_services", "prelevements"...), see example for available APIs
 #' @param operation a [character] name of the operation, see example for available operations in an API
-#' @param params a [list] the list of parameters of the queries and their values in the format `list(ParamName = "Param value", ...)`, use the function `get_available_params` for a list of the available parameters for a given operation in an API
 #' @template param_get_common
 #'
 #' @return A [list] with the concatenated results returned by the API.
diff --git a/R/get_indicateurs_services_communes.R b/R/get_indicateurs_services_communes.R
index 7a857ac..eb744a2 100644
--- a/R/get_indicateurs_services_communes.R
+++ b/R/get_indicateurs_services_communes.R
@@ -2,7 +2,6 @@
 #'
 #' See the API documentation for available filter parameters: \url{https://hubeau.eaufrance.fr/page/api-indicateurs-services}
 #'
-#' @param params [list] where the keys are the names of the filtered parameters and the values are the values of the filters. See the API documentation for the complete list of available filter parameters
 #' @template param_get_common
 #'
 #' @return a [tibble::tibble] with one row by commune, by service and by year and the following columns:
diff --git a/R/get_indicateurs_services_indicateurs.R b/R/get_indicateurs_services_indicateurs.R
index 35a54f6..b8497a0 100644
--- a/R/get_indicateurs_services_indicateurs.R
+++ b/R/get_indicateurs_services_indicateurs.R
@@ -2,7 +2,6 @@
 #'
 #' See the API documentation for available filter parameters: \url{https://hubeau.eaufrance.fr/page/api-indicateurs-services}
 #'
-#' @param params [list] where the keys are the names of the filtered parameters and the values are the values of the filters. See the API documentation for the complete list of available filter parameters
 #' @template param_get_common
 #'
 #' @return a [tibble::tibble] with one row by commune, by service and by year and the following columns:
diff --git a/R/get_prelevements_chroniques.R b/R/get_prelevements_chroniques.R
index 227a4d0..69929d6 100644
--- a/R/get_prelevements_chroniques.R
+++ b/R/get_prelevements_chroniques.R
@@ -2,7 +2,6 @@
 #'
 #' See the API documentation for available filter parameters: \url{https://hubeau.eaufrance.fr/page/api-prelevements-eau#/prelevements/chronique}
 #'
-#' @param params [list] where the keys are the names of the filtered parameters and the values are the values of the filters. See the API documentation for the complete list of available filter parameters
 #' @template param_get_common
 #'
 #' @return a [tibble::tibble] with all available parameters in columns and one row by device, year and usage.
diff --git a/R/get_prelevements_points_prelevement.R b/R/get_prelevements_points_prelevement.R
index 6948850..de077c7 100644
--- a/R/get_prelevements_points_prelevement.R
+++ b/R/get_prelevements_points_prelevement.R
@@ -2,7 +2,6 @@
 #'
 #' See the API documentation for available filter parameters: \url{https://hubeau.eaufrance.fr/page/api-prelevements-eau#/prelevements/prelevement}
 #'
-#' @param params [list] where the keys are the names of the filtered parameters and the values are the values of the filters. See the API documentation for the complete list of available filter parameters
 #' @template param_get_common
 #'
 #' @return a [tibble::tibble] with all available parameters in columns and one row by device.
diff --git a/man-roxygen/param_get_common.R b/man-roxygen/param_get_common.R
index ecf1313..1142159 100644
--- a/man-roxygen/param_get_common.R
+++ b/man-roxygen/param_get_common.R
@@ -1,2 +1,3 @@
+#' @param params a [list] the list of parameters of the queries and their values in the format `list(ParamName = "Param value", ...)`, use the function [get_available_params] for a list of the available parameters for a given operation in an API and see the API documentation for the complete list of available filter parameters
 #' @param cfg a [config] object Configuration of the communication. Use by default the internal package
 #'        configuration
diff --git a/man/doApiQuery.Rd b/man/doApiQuery.Rd
index ee6c9e9..261a27f 100644
--- a/man/doApiQuery.Rd
+++ b/man/doApiQuery.Rd
@@ -23,7 +23,7 @@ get_available_params(
 
 \item{operation}{a \link{character} name of the operation, see example for available operations in an API}
 
-\item{params}{a \link{list} the list of parameters of the queries and their values in the format \code{list(ParamName = "Param value", ...)}, use the function \code{get_available_params} for a list of the available parameters for a given operation in an API}
+\item{params}{a \link{list} the list of parameters of the queries and their values in the format \code{list(ParamName = "Param value", ...)}, use the function \link{get_available_params} for a list of the available parameters for a given operation in an API and see the API documentation for the complete list of available filter parameters}
 
 \item{cfg}{a \link{config} object Configuration of the communication. Use by default the internal package
 configuration}
diff --git a/man/get_indicateurs_services_communes.Rd b/man/get_indicateurs_services_communes.Rd
index d5d1002..6f2e463 100644
--- a/man/get_indicateurs_services_communes.Rd
+++ b/man/get_indicateurs_services_communes.Rd
@@ -10,7 +10,7 @@ get_indicateurs_services_communes(
 )
 }
 \arguments{
-\item{params}{\link{list} where the keys are the names of the filtered parameters and the values are the values of the filters. See the API documentation for the complete list of available filter parameters}
+\item{params}{a \link{list} the list of parameters of the queries and their values in the format \code{list(ParamName = "Param value", ...)}, use the function \link{get_available_params} for a list of the available parameters for a given operation in an API and see the API documentation for the complete list of available filter parameters}
 
 \item{cfg}{a \link{config} object Configuration of the communication. Use by default the internal package
 configuration}
diff --git a/man/get_indicateurs_services_indicateurs.Rd b/man/get_indicateurs_services_indicateurs.Rd
index a3157ee..1c03ef9 100644
--- a/man/get_indicateurs_services_indicateurs.Rd
+++ b/man/get_indicateurs_services_indicateurs.Rd
@@ -10,7 +10,7 @@ get_indicateurs_services_indicateurs(
 )
 }
 \arguments{
-\item{params}{\link{list} where the keys are the names of the filtered parameters and the values are the values of the filters. See the API documentation for the complete list of available filter parameters}
+\item{params}{a \link{list} the list of parameters of the queries and their values in the format \code{list(ParamName = "Param value", ...)}, use the function \link{get_available_params} for a list of the available parameters for a given operation in an API and see the API documentation for the complete list of available filter parameters}
 
 \item{cfg}{a \link{config} object Configuration of the communication. Use by default the internal package
 configuration}
diff --git a/man/get_prelevements_chroniques.Rd b/man/get_prelevements_chroniques.Rd
index 6a1071d..9d76894 100644
--- a/man/get_prelevements_chroniques.Rd
+++ b/man/get_prelevements_chroniques.Rd
@@ -10,7 +10,7 @@ get_prelevements_chroniques(
 )
 }
 \arguments{
-\item{params}{\link{list} where the keys are the names of the filtered parameters and the values are the values of the filters. See the API documentation for the complete list of available filter parameters}
+\item{params}{a \link{list} the list of parameters of the queries and their values in the format \code{list(ParamName = "Param value", ...)}, use the function \link{get_available_params} for a list of the available parameters for a given operation in an API and see the API documentation for the complete list of available filter parameters}
 
 \item{cfg}{a \link{config} object Configuration of the communication. Use by default the internal package
 configuration}
diff --git a/man/get_prelevements_points_prelevement.Rd b/man/get_prelevements_points_prelevement.Rd
index e158909..fbb2846 100644
--- a/man/get_prelevements_points_prelevement.Rd
+++ b/man/get_prelevements_points_prelevement.Rd
@@ -10,7 +10,7 @@ get_prelevements_points_prelevement(
 )
 }
 \arguments{
-\item{params}{\link{list} where the keys are the names of the filtered parameters and the values are the values of the filters. See the API documentation for the complete list of available filter parameters}
+\item{params}{a \link{list} the list of parameters of the queries and their values in the format \code{list(ParamName = "Param value", ...)}, use the function \link{get_available_params} for a list of the available parameters for a given operation in an API and see the API documentation for the complete list of available filter parameters}
 
 \item{cfg}{a \link{config} object Configuration of the communication. Use by default the internal package
 configuration}
-- 
GitLab