Marc Kupietz | c616098 | 2025-06-24 15:57:51 +0200 | [diff] [blame] | 1 | % Generated by roxygen2: do not edit by hand |
| 2 | % Please edit documentation in R/KorAPQuery.R |
| 3 | \name{fetchAll,KorAPQuery-method} |
| 4 | \alias{fetchAll,KorAPQuery-method} |
| 5 | \alias{fetchAll} |
| 6 | \title{Fetch all results of a KorAP query.} |
| 7 | \usage{ |
| 8 | \S4method{fetchAll}{KorAPQuery}(kqo, verbose = kqo@korapConnection@verbose, ...) |
| 9 | } |
Marc Kupietz | dc880ac | 2025-06-24 20:34:43 +0200 | [diff] [blame] | 10 | \arguments{ |
| 11 | \item{kqo}{object obtained from \code{\link[=corpusQuery]{corpusQuery()}}} |
| 12 | |
| 13 | \item{verbose}{print progress information if true} |
| 14 | |
| 15 | \item{...}{further arguments passed to \code{\link[=fetchNext]{fetchNext()}}} |
| 16 | } |
| 17 | \value{ |
| 18 | The updated \code{kqo} object with all results in \verb{@collectedMatches} |
| 19 | } |
Marc Kupietz | c616098 | 2025-06-24 15:57:51 +0200 | [diff] [blame] | 20 | \description{ |
| 21 | \strong{\code{fetchAll}} fetches all results of a KorAP query. |
| 22 | } |
| 23 | \examples{ |
| 24 | \dontrun{ |
| 25 | # Fetch all metadata of every query hit for "Ameisenplage" and show a summary |
| 26 | q <- KorAPConnection() |> |
| 27 | corpusQuery("Ameisenplage") |> |
| 28 | fetchAll() |
| 29 | q@collectedMatches |
| 30 | |
| 31 | # Fetch also all KWICs |
| 32 | q <- KorAPConnection() |> auth() |> |
| 33 | corpusQuery("Ameisenplage", metadataOnly = FALSE) |> |
| 34 | fetchAll() |
| 35 | q@collectedMatches |
| 36 | |
| 37 | # Retrieve title and text sigle metadata of all texts published on 1958-03-12 |
| 38 | q <- KorAPConnection() |> |
| 39 | corpusQuery("<base/s=t>", # this matches each text once |
| 40 | vc = "pubDate in 1958-03-12", |
| 41 | fields = c("textSigle", "title"), |
| 42 | ) |> |
| 43 | fetchAll() |
| 44 | q@collectedMatches |
| 45 | } |
| 46 | |
| 47 | } |
| 48 | \seealso{ |
| 49 | Other corpus search functions: |
| 50 | \code{\link{corpusQuery,KorAPConnection-method}}, |
| 51 | \code{\link{fetchNext,KorAPQuery-method}} |
| 52 | } |
| 53 | \concept{corpus search functions} |