ReadFrom reads from readBuf and put into struct.
(readBuf *codec.Reader)
| 799 | |
| 800 | // ReadFrom reads from readBuf and put into struct. |
| 801 | func (st *ApplyTokenRequest) ReadFrom(readBuf *codec.Reader) error { |
| 802 | var ( |
| 803 | err error |
| 804 | length int32 |
| 805 | have bool |
| 806 | ty byte |
| 807 | ) |
| 808 | st.ResetDefault() |
| 809 | |
| 810 | err = st.SKey.ReadBlock(readBuf, 1, true) |
| 811 | if err != nil { |
| 812 | return err |
| 813 | } |
| 814 | |
| 815 | _ = err |
| 816 | _ = length |
| 817 | _ = have |
| 818 | _ = ty |
| 819 | return nil |
| 820 | } |
| 821 | |
| 822 | // ReadBlock reads struct from the given tag , require or optional. |
| 823 | func (st *ApplyTokenRequest) ReadBlock(readBuf *codec.Reader, tag byte, require bool) error { |
no test coverage detected