(ctx context.Context)
| 261 | } |
| 262 | |
| 263 | func (p *TJSONProtocol) ReadFieldBegin(ctx context.Context) (string, TType, int16, error) { |
| 264 | b, _ := p.reader.Peek(1) |
| 265 | if len(b) < 1 || b[0] == JSON_RBRACE[0] || b[0] == JSON_RBRACKET[0] { |
| 266 | return "", STOP, -1, nil |
| 267 | } |
| 268 | fieldId, err := p.ReadI16(ctx) |
| 269 | if err != nil { |
| 270 | return "", STOP, fieldId, err |
| 271 | } |
| 272 | if _, err = p.ParseObjectStart(); err != nil { |
| 273 | return "", STOP, fieldId, err |
| 274 | } |
| 275 | sType, err := p.ReadString(ctx) |
| 276 | if err != nil { |
| 277 | return "", STOP, fieldId, err |
| 278 | } |
| 279 | fType, err := p.StringToTypeId(sType) |
| 280 | return "", fType, fieldId, err |
| 281 | } |
| 282 | |
| 283 | func (p *TJSONProtocol) ReadFieldEnd(ctx context.Context) error { |
| 284 | return p.ParseObjectEnd() |
nothing calls this directly
no test coverage detected