protoscanner

package
v0.0.0-rc1 Latest Latest
Warning

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

Go to latest
Published: Sep 16, 2024 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ScannerTypeLineSplitter = ProtoScannerType("lineSplitter")
	ScannerTypeRepeated     = ProtoScannerType("repeated")
)

Variables

This section is empty.

Functions

This section is empty.

Types

type ProtoScanner

type ProtoScanner interface {
	Scan() bool
	Message() (protoreflect.Message, error)
	RawData() []byte
	// Approximate raw data len
	ApxDataLen() int
	Err() error
}

func NewProtoScanner

func NewProtoScanner(scannerType ProtoScannerType, lineSplitter abstract.LfLineSplitter, data []byte, msgDesc protoreflect.MessageDescriptor) (ProtoScanner, error)

type ProtoScannerType

type ProtoScannerType string

type RepeatedScanner

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

func NewRepeatedScanner

func NewRepeatedScanner(data []byte, wrapperDesc protoreflect.MessageDescriptor) (*RepeatedScanner, error)

func (*RepeatedScanner) ApxDataLen

func (s *RepeatedScanner) ApxDataLen() int

func (*RepeatedScanner) Err

func (s *RepeatedScanner) Err() error

func (*RepeatedScanner) Message

func (s *RepeatedScanner) Message() (protoreflect.Message, error)

func (*RepeatedScanner) RawData

func (s *RepeatedScanner) RawData() []byte

func (*RepeatedScanner) Scan

func (s *RepeatedScanner) Scan() (res bool)

type SplitterScanner

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

func NewSplitterScanner

func NewSplitterScanner(lineSplitter abstract.LfLineSplitter, data []byte, msgDesc protoreflect.MessageDescriptor) (*SplitterScanner, error)

func (*SplitterScanner) ApxDataLen

func (s *SplitterScanner) ApxDataLen() int

func (*SplitterScanner) Err

func (s *SplitterScanner) Err() error

func (*SplitterScanner) Message

func (s *SplitterScanner) Message() (protoreflect.Message, error)

func (*SplitterScanner) RawData

func (s *SplitterScanner) RawData() []byte

func (*SplitterScanner) Scan

func (s *SplitterScanner) Scan() bool

Jump to

Keyboard shortcuts

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