Documentation
¶
Overview ¶
Package example. Just data types for testing in here.
Index ¶
- func PerfcheckDecode(p *Perfcheck, src []byte) (err error)
- func PerfcheckEncode(dst []byte, p *Perfcheck) []byte
- func PerfcheckLen(p *Perfcheck) int
- func StructDecode(s *Struct, src []byte) (err error)
- func StructEncode(dst []byte, s *Struct) []byte
- func StructLen(s *Struct) int
- func TypeRecorderDispatch(disp Source, rec []byte) error
- type EncDec
- type Index
- type Perfcheck
- type Source
- type SourceMock
- type SourceMockRecorder
- type Struct
- type StructInternal
- type TypeRecorder
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func PerfcheckDecode ¶ added in v0.8.4
PerfcheckEncode decodes content of Perfcheck.
func PerfcheckEncode ¶ added in v0.8.4
func PerfcheckLen ¶ added in v0.8.4
func StructDecode ¶
StructEncode decodes content of Struct.
func StructEncode ¶
func TypeRecorderDispatch ¶
TypeRecorderDispatch dispatches encoded data made with TypeRecorder
Types ¶
type EncDec ¶
type EncDec bool
EncDec auto-apply type.
type Source ¶
type Source interface {
Fixeds(a bool, b int32, c uint16, d float64, e [12]byte) error
Vars(a string, b []byte, c intypes.VI16, d intypes.VU32, e EncDec, id Index) error
}
Source interface to generate testing stuff.
type SourceMock ¶
type SourceMock struct {
// contains filtered or unexported fields
}
SourceMock interface github.com/sirkon/fenneg/example/internal/example.Source mock
func NewSourceMock ¶
func NewSourceMock(ctrl *gomock.Controller) *SourceMock
NewSourceMock creates SourceMock instance
func (*SourceMock) EXPECT ¶
func (m *SourceMock) EXPECT() *SourceMockRecorder
EXPECT returns expected calls recorder
type SourceMockRecorder ¶
type SourceMockRecorder struct {
// contains filtered or unexported fields
}
SourceMockRecorder records expected calls of github.com/sirkon/fenneg/example/internal/example.Source
func (*SourceMockRecorder) Fixeds ¶
func (mr *SourceMockRecorder) Fixeds(a, b, c, d, e any) *gomock.Call
Fixeds register expected call of method github.com/sirkon/fenneg/example/internal/example.Source.Fixeds
func (*SourceMockRecorder) FixedsWhatever ¶
func (mr *SourceMockRecorder) FixedsWhatever() *gomock.Call
FixedsWhatever records a call with arbitrary arguments.
func (*SourceMockRecorder) Vars ¶
func (mr *SourceMockRecorder) Vars(a, b, c, d, e, id any) *gomock.Call
Vars register expected call of method github.com/sirkon/fenneg/example/internal/example.Source.Vars
func (*SourceMockRecorder) VarsWhatever ¶
func (mr *SourceMockRecorder) VarsWhatever() *gomock.Call
VarsWhatever records a call with arbitrary arguments.
type Struct ¶
type Struct struct {
ID Index
ChangeID Index
Repeat uint32
Theme uint32
Data []byte
Pi float32
E float64
Field string
Int int
Uint uint
VarInt intypes.VI
VarUint intypes.VU
BoolSlice []bool
StringSlice []string
BoolSliceSlice [][]bool
StringSliceSlice [][]string
MapKFVF map[uint32]uint32
MapKFVV map[uint32]string
MapKVVF map[string]uint32
Struct StructInternal
StructSlice []StructInternal
StructMapInt map[int]StructInternal
StructMapStruct map[StructInternal]StructInternal
}
type StructInternal ¶ added in v0.7.0
type TypeRecorder ¶
type TypeRecorder struct {
// contains filtered or unexported fields
}
TypeRecorder implement