You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "paleolimbot (via GitHub)" <gi...@apache.org> on 2023/06/08 18:57:22 UTC

[GitHub] [arrow] paleolimbot commented on a diff in pull request #35055: GH-34436: [R] Bindings for JSON Dataset

paleolimbot commented on code in PR #35055:
URL: https://github.com/apache/arrow/pull/35055#discussion_r1223433937


##########
r/R/dataset-format.R:
##########
@@ -532,6 +575,22 @@ ParquetFragmentScanOptions$create <- function(use_buffered_stream = FALSE,
   dataset___ParquetFragmentScanOptions__Make(use_buffered_stream, buffer_size, pre_buffer)
 }
 
+#' @usage NULL
+#' @format NULL
+#' @rdname FragmentScanOptions
+#' @export
+JsonFragmentScanOptions <- R6Class("JsonFragmentScanOptions", inherit = FragmentScanOptions)
+JsonFragmentScanOptions$create <- function(...) {
+  dots <- list2(...)
+  parse_opt_choices <- dots[names(dots) %in% names(formals(JsonParseOptions$create))]
+  read_opt_choices <- dots[names(dots) %in% names(formals(JsonReadOptions$create))]
+
+  parse_options <- do.call(JsonParseOptions$create, parse_opt_choices)
+  read_options <- do.call(JsonReadOptions$create, read_opt_choices)
+

Review Comment:
   Should there be an error for elements of `dots` that are unaccounted for?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org