digest

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: Feb 8, 2024 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const (
	UnknownValueType = ValueType(iota)
	NumberValueType
	StringValueType
	BooleanValueType
	ObjValueType
	ArrayValueType
	NilValueType
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Digest

type Digest interface {
	AddSampleData(*data.Data) error
	JSON() ([]byte, error)
	Reset()
	String() string
	SampleType() control.SampleType
}

type Digester

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

func NewDigester

func NewDigester(settings Settings) *Digester

func (*Digester) Close

func (d *Digester) Close() error

func (*Digester) ProcessSample

func (d *Digester) ProcessSample(streams []control.SamplerStreamUID, sampleData *data.Data) bool

func (*Digester) SetDigestsConfig

func (d *Digester) SetDigestsConfig(digestCfgs map[control.SamplerDigestUID]control.Digest)

type Settings

type Settings struct {
	ResourceName   string
	SamplerName    string
	EnabledDigests []control.DigestType

	NotifyErr func(error)
	Exporter  exporter.Exporter
}

type St

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

func NewStDigest

func NewStDigest(maxProcessedFields int, notifyErr func(error)) *St

func (*St) AddSampleData

func (s *St) AddSampleData(sampleData *data.Data) error

AddSample is not thread safe

func (*St) JSON

func (s *St) JSON() ([]byte, error)

func (*St) Reset

func (s *St) Reset()

func (*St) SampleType

func (s *St) SampleType() control.SampleType

func (*St) String

func (s *St) String() string

type Value

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

func NewValue

func NewValue(maxProcessedFields int) *Value

func (*Value) AddSampleData

func (v *Value) AddSampleData(sampleData *data.Data) error

AddSample is not thread safe

func (*Value) JSON

func (v *Value) JSON() ([]byte, error)

func (*Value) Reset

func (v *Value) Reset()

func (*Value) SampleType

func (v *Value) SampleType() control.SampleType

func (*Value) String

func (v *Value) String() string

type ValueType

type ValueType int8

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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