csv

package
v1.8.8 Latest Latest
Warning

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

Go to latest
Published: Mar 27, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ProcessorCSVDecoder

type ProcessorCSVDecoder struct {
	SourceKey        string   `comment:"The source key containing the CSV record"`
	NoKeyError       bool     `comment:"Optional. Whether to report error if no key in the log mathes the SourceKey, default to false"`
	SplitKeys        []string `comment:"The keys matching the decoded CSV fields"`
	SplitSep         string   `comment:"Optional. The Separator, default to ,"`
	TrimLeadingSpace bool     `comment:"Optional. Whether to ignore the leading space in each CSV field, default to false"`
	PreserveOthers   bool     `comment:"Optional. Whether to preserve the remaining record if #splitKeys < #CSV fields, default to false"`
	ExpandOthers     bool     `comment:"Optional. Whether to decode the remaining record if #splitKeys < #CSV fields, default to false"`
	ExpandKeyPrefix  string   `comment:"Required when ExpandOthers=true. The prefix of the keys for storing the remaining record fields"`
	KeepSource       bool     `comment:"Optional. Whether to keep the source log content given successful decoding, default to false"`
	// contains filtered or unexported fields
}

func (*ProcessorCSVDecoder) Description

func (*ProcessorCSVDecoder) Description() string

func (*ProcessorCSVDecoder) Init

func (p *ProcessorCSVDecoder) Init(context pipeline.Context) error

func (*ProcessorCSVDecoder) ProcessLogs

func (p *ProcessorCSVDecoder) ProcessLogs(logArray []*protocol.Log) []*protocol.Log

Jump to

Keyboard shortcuts

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