()
| 441 | } |
| 442 | |
| 443 | func (s *MysqlGTIDSet) Encode() []byte { |
| 444 | var buf bytes.Buffer |
| 445 | |
| 446 | _ = binary.Write(&buf, binary.LittleEndian, uint64(len(s.Sets))) |
| 447 | |
| 448 | for i := range s.Sets { |
| 449 | s.Sets[i].encode(&buf) |
| 450 | } |
| 451 | |
| 452 | return buf.Bytes() |
| 453 | } |
| 454 | |
| 455 | func (gtid *MysqlGTIDSet) Clone() GTIDSet { |
| 456 | clone := &MysqlGTIDSet{ |