% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/helpers.R
\name{execute.awk.stream}
\alias{execute.awk.stream}
\title{Execute AWK Script over Batches of Files (Internal Engine)}
\usage{
execute.awk.stream(
  awk.script.content,
  the.files,
  value.code,
  header.names,
  include.filename,
  num.batches,
  num.files.per.batch,
  path.to.awk,
  total.files,
  show.warnings,
  nrows,
  file.header,
  return.as
)
}
\arguments{
\item{awk.script.content}{A character string containing the raw body of the AWK script logic.}

\item{the.files}{A character vector of normalized paths to the target files.}

\item{value.code}{A character string indicating the identifier for code-only return mode.}

\item{header.names}{A character vector of column names to assign to the resulting dataset.}

\item{include.filename}{A logical value indicating whether to append the source filename tracking column.}

\item{num.batches}{An integer specifying the total number of batches to chunk files into.}

\item{num.files.per.batch}{An integer specifying the maximum number of files processed per AWK execution window.}

\item{path.to.awk}{A character string designating the system path or command name for the AWK binary.}

\item{total.files}{An integer tracking the total count of valid files to process.}

\item{show.warnings}{A logical value. If \code{FALSE}, wraps the internal engine reading in \code{suppressWarnings}.}

\item{nrows}{A numeric value restricting the maximum number of rows to read per batch chunk.}

\item{file.header}{A character string establishing the column header name for file origin logging.}

\item{return.as}{A character string controlling the return type format (\code{"result"}, \code{"code"}, or \code{"all"}).}
}
\value{
A named list containing two elements:
\item{list.data}{A list of data tables containing parsed chunk outputs.}
\item{expanded.statements}{A character vector containing the raw shell strings passed to the system command pipeline.}
}
\description{
An internal helper function that splits file processing into batches, constructs
systemic shell commands to invoke AWK, and streams the processed text strings
back into R via \code{data.table::fread}.
}
\keyword{internal}
