func (cp *Checkpoint) IncreaseClientSeq(inc uint32) *Checkpoint {
	if inc == 0 {
		return cp
	}
	return New(cp.ServerSeq, cp.ClientSeq+inc)
}
IncreaseClientSeq creates a new instance with increased client sequence.
package checkpoint
import (
	"fmt"
	"math"
)
var Initial = New(0, 0)
var Max = New(math.MaxUint64, math.MaxUint32)
type Checkpoint struct {
	ServerSeq uint64
	ClientSeq uint32
}
func New(serverSeq uint64, clientSeq uint32) *Checkpoint {
	return &Checkpoint{
		ServerSeq: serverSeq,
		ClientSeq: clientSeq,
	}
}
func (cp *Checkpoint) NextClientSeq() *Checkpoint {
	return cp.IncreaseClientSeq(1)
}
func (cp *Checkpoint) NextServerSeq(serverSeq uint64) *Checkpoint {
	if cp.ServerSeq == serverSeq {
		return cp
	}
	return New(serverSeq, cp.ClientSeq)
}