csv

package
v3.0.0-...-ad58db6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 5, 2024 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultCSVSeparator = ','
View Source
const DefaultOutputTimeFormat = "2006-01-02"

Variables

This section is empty.

Functions

func CSVDatabase

func CSVDatabase(dbStream io.Reader, cdc CSVDatabaseConfig) error

CSVDatabase generates CSV export of the database

func CSVDatabaseResolved

func CSVDatabaseResolved(dbStream io.Reader, cdc CSVDatabaseResolvedConfig) error

CSVDatabaseResolved generates CSV export of the resolved database

func CSVLog

func CSVLog(logStream io.Reader, c CSVLogConfig) error

CSVLog generates CSV export of the log

func Command

func Command() *cli.Command

func NewCSVCommand

func NewCSVCommand(cu utils.CmdUtils) *cli.Command

func NewCSVDatabaseCommand

func NewCSVDatabaseCommand(cu utils.CmdUtils, csvDatabase CSVDatabaseCmd) *cli.Command

func NewCSVDatabaseResolvedCommand

func NewCSVDatabaseResolvedCommand(cu utils.CmdUtils, csvDatabaseResolved CSVDatabaseResolvedCmd) *cli.Command

func NewCSVLogCommand

func NewCSVLogCommand(cu utils.CmdUtils, csvLog CSVLogCmd) *cli.Command

Types

type CSVConfig

type CSVConfig struct {
	reporter.CommonConfig
	CSVSeparator     rune
	OutputTimeFormat string
}

func NewCSVConfig

func NewCSVConfig(c reporter.CommonConfig) CSVConfig

type CSVDatabaseCmd

type CSVDatabaseCmd func(dbStream io.Reader, cdc CSVDatabaseConfig) error

type CSVDatabaseConfig

type CSVDatabaseConfig struct {
	ParserConfig   parser.Config
	ReporterConfig reporter.Config
}

type CSVDatabaseReporter

type CSVDatabaseReporter struct {
	// contains filtered or unexported fields
}

CSVReporter outputs report for single food

func NewCSVDatabaseReporter

func NewCSVDatabaseReporter(config reporter.Config) CSVDatabaseReporter

NewCSVReporter creates new CSV reporter

func (CSVDatabaseReporter) Flush

func (r CSVDatabaseReporter) Flush() error

Flush flushes the buffer

func (CSVDatabaseReporter) Process

func (r CSVDatabaseReporter) Process(n *shared.DBNode) error

Process writes single node

type CSVDatabaseResolvedCmd

type CSVDatabaseResolvedCmd func(dbStream io.Reader, cdrc CSVDatabaseResolvedConfig) error

type CSVDatabaseResolvedConfig

type CSVDatabaseResolvedConfig struct {
	ParserConfig   parser.Config
	ReporterConfig reporter.Config
	ResolverConfig resolver.Config
}

type CSVLogCmd

type CSVLogCmd func(logStream io.Reader, c CSVLogConfig) error

type CSVLogConfig

type CSVLogConfig struct {
	DateFormat     string
	ParserConfig   parser.Config
	FilterConfig   filter.Config
	ReporterConfig CSVConfig
}

type CSVReporter

type CSVReporter struct {
	// contains filtered or unexported fields
}

CSVReporter outputs report for single food

func NewCSVReporter

func NewCSVReporter(config CSVConfig) CSVReporter

NewCSVReporter creates new CSV reporter

func (CSVReporter) Flush

func (r CSVReporter) Flush() error

Flush flushes the buffer

func (CSVReporter) Process

func (r CSVReporter) Process(ln *shared.LogNode) error

Process writes single node

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL