etcdserver/api/v3rpc/watch.go
func FiltersFromRequest(creq *pb.WatchCreateRequest) []mvcc.FilterFunc {
	filters := make([]mvcc.FilterFunc, 0, len(creq.Filters))
	for _, ft := range creq.Filters {
		switch ft {
		case pb.WatchCreateRequest_NOPUT:
			filters = append(filters, filterNoPut)
		case pb.WatchCreateRequest_NODELETE:
			filters = append(filters, filterNoDelete)
		default:
		}
	}
	return filters
}
func FiltersFromRequest(creq *pb.WatchCreateRequest) []mvcc.FilterFunc {
	filters := make([]mvcc.FilterFunc, 0, len(creq.Filters))
	for _, ft := range creq.Filters {
		switch ft {
		case pb.WatchCreateRequest_NOPUT:
			filters = append(filters, filterNoPut)
		case pb.WatchCreateRequest_NODELETE:
			filters = append(filters, filterNoDelete)
		default:
		}
	}
	return filters
}
func FiltersFromRequest ( creq * pb . WatchCreateRequest ) [ ] mvcc . FilterFunc { filters := make ( [ ] mvcc . FilterFunc , 0 , len ( creq . Filters ) ) for _ , ft := range creq . Filters { switch ft { case pb . WatchCreateRequest_NOPUT : filters = append ( filters , filterNoPut ) case pb . WatchCreateRequest_NODELETE : filters = append ( filters , filterNoDelete ) default : } } return filters }
// FiltersFromRequest returns "mvcc.FilterFunc" from a given watch create request.
FiltersFromRequest returns mvcc . FilterFunc from a given watch create request .