From 6184b8b59e28df8611d36be060ba33c505765380 Mon Sep 17 00:00:00 2001 From: Hong Ooi Date: Wed, 5 May 2021 13:05:58 +1000 Subject: [PATCH] add print method for request object --- R/batch.R | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/R/batch.R b/R/batch.R index 4ed37e0..75d8279 100644 --- a/R/batch.R +++ b/R/batch.R @@ -85,6 +85,16 @@ public=list( if(!is_empty(self$body)) req$body <- self$body req + }, + + print=function(...) + { + path <- httr::parse_url(self$op) + path$query <- self$options + path <- sub("^://", "", httr::build_url(path)) + cat("\n") + cat(" path:", self$method, path, "\n") + invisible(self) } ))