MCPcopy Create free account
hub / github.com/apache/fory / WriteData

Method WriteData

go/fory/field_serializer.go:120–127  ·  view source on GitHub ↗
(ctx *WriteContext, value reflect.Value)

Source from the content-addressed store, hash-verified

118}
119
120func (s encodedInt32Serializer) WriteData(ctx *WriteContext, value reflect.Value) {
121 switch s.typeID {
122 case INT32:
123 ctx.buffer.WriteInt32(int32(value.Int()))
124 default:
125 ctx.buffer.WriteVarint32(int32(value.Int()))
126 }
127}
128
129func (s encodedInt32Serializer) Write(ctx *WriteContext, refMode RefMode, writeType bool, hasGenerics bool, value reflect.Value) {
130 _ = hasGenerics

Callers 1

WriteMethod · 0.95

Calls 3

int32Function · 0.50
WriteInt32Method · 0.45
WriteVarint32Method · 0.45

Tested by

no test coverage detected