Documentation
¶
Index ¶
- func Execute(args []string, version string)
- func InputFormat(path string) string
- func ParseRows(path string, opts Options, onRow func(Row) error) error
- func ParseTSV(r io.Reader, opts Options, onRow func(Row) error) error
- func ParseTSVChan(ctx context.Context, r io.Reader, opts Options) (<-chan Row, <-chan error)
- func RowCount(path string) (int64, error)
- type Options
- type Row
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InputFormat ¶ added in v0.5.0
func ParseTSV ¶
ParseTSV streams a TSV from r, invoking onRow for each line. It keeps memory bounded by reusing chunk buffers; row data is only valid inside onRow.
func ParseTSVChan ¶
ParseTSVChan exposes rows over a channel. Rows are copied to keep the channel consumer safe from buffer reuse. Errors are sent on errCh after the rows channel closes.
Types ¶
type Options ¶
type Options struct {
BufferSize int // Size of the bufio.Reader buffer
ChunkSize int // Bytes to read per chunk before splitting into lines
BatchLines int // How many lines to hand to a worker at once
Workers int // Number of parsing workers
StrictColumns bool // Enforce a fixed column count (first row if ExpectedColumns == 0)
ExpectedColumns int // Expected column count when StrictColumns is true (0 to infer from first row)
PreserveOrder bool // Deliver rows in file order
AllowCRLF bool // Trim trailing \r when present
Progress *progress
SkipProgressFirstRow bool
Timeout time.Duration
}
Options controls TSV parsing performance characteristics.
func DefaultOptions ¶
func DefaultOptions() Options
DefaultOptions returns a tuned baseline for large TSVs.
func (Options) WithAllowCRLF ¶
WithAllowCRLF toggles CRLF stripping (default: enabled).
func (Options) WithPreserveOrder ¶
WithPreserveOrder overrides the default ordering behavior.
Source Files
¶
- classify.go
- extract.go
- extract_curation.go
- extract_protocol_bioscan5m.go
- extract_protocol_bioscan5m_engine.go
- extract_protocol_bioscan5m_report.go
- fasta.go
- format.go
- list.go
- markers.go
- package.go
- pipeline.go
- progress.go
- qc.go
- rdp_taxonomy.go
- reader.go
- reader_parquet.go
- reader_tsv.go
- root.go
- split.go
- taxdump.go
- tsv_parser.go
- util.go
Click to show internal directories.
Click to hide internal directories.