Example #1
0
func (m *initMessage) read(r *typed.ReadBuffer) error {
	m.Version = r.ReadUint16()

	m.initParams = initParams{}
	np := r.ReadUint16()
	for i := 0; i < int(np); i++ {
		k := r.ReadLen16String()
		v := r.ReadLen16String()
		m.initParams[k] = v
	}

	return r.Err()
}
Example #2
0
func (m *errorMessage) read(r *typed.ReadBuffer) error {
	m.errCode = SystemErrCode(r.ReadByte())
	m.id = r.ReadUint32()
	m.message = r.ReadLen16String()
	return r.Err()
}
Example #3
0
func (m *errorMessage) read(r *typed.ReadBuffer) error {
	m.errCode = SystemErrCode(r.ReadSingleByte())
	m.tracing.read(r)
	m.message = r.ReadLen16String()
	return r.Err()
}