func (wr *watchRequest) toPB() *pb.WatchRequest {
	req := &pb.WatchCreateRequest{
		StartRevision:  wr.rev,
		Key:            []byte(wr.key),
		RangeEnd:       []byte(wr.end),
		ProgressNotify: wr.progressNotify,
		Filters:        wr.filters,
		PrevKv:         wr.prevKV,
		Fragment:       wr.fragment,
	}
	cr := &pb.WatchRequest_CreateRequest{CreateRequest: req}
	return &pb.WatchRequest{RequestUnion: cr}
}
func (wr *watchRequest) toPB() *pb.WatchRequest {
	req := &pb.WatchCreateRequest{
		StartRevision:  wr.rev,
		Key:            []byte(wr.key),
		RangeEnd:       []byte(wr.end),
		ProgressNotify: wr.progressNotify,
		Filters:        wr.filters,
		PrevKv:         wr.prevKV,
		Fragment:       wr.fragment,
	}
	cr := &pb.WatchRequest_CreateRequest{CreateRequest: req}
	return &pb.WatchRequest{RequestUnion: cr}
}
func ( wr * watchRequest ) toPB ( ) * pb . WatchRequest { req := & pb . WatchCreateRequest { StartRevision : wr . rev , Key : [ ] byte ( wr . key ) , RangeEnd : [ ] byte ( wr . end ) , ProgressNotify : wr . progressNotify , Filters : wr . filters , PrevKv : wr . prevKV , Fragment : wr . fragment , } cr := & pb . WatchRequest_CreateRequest { CreateRequest : req } return & pb . WatchRequest { RequestUnion : cr } }
// toPB converts an internal watch request structure to its protobuf WatchRequest structure.
toPB converts an internal watch request structure to its protobuf WatchRequest structure .