frostfs-api-go/query/types.proto
2020-01-30 16:35:30 +03:00

32 lines
903 B
Protocol Buffer

syntax = "proto3";
package query;
option go_package = "github.com/nspcc-dev/neofs-api/query";
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
option (gogoproto.stable_marshaler_all) = true;
message Filter {
option (gogoproto.goproto_stringer) = false;
enum Type {
// Exact sets when value of filter should be equal to the header value
Exact = 0;
// Regex sets when value of filter should match the header value by the regular expression
Regex = 1;
}
// Type of filter
Type type = 1 [(gogoproto.customname) = "Type"];
// Name of field that should be filtered
string Name = 2;
// Value that should be used for filter
string Value = 3;
}
message Query {
option (gogoproto.goproto_stringer) = false;
// Filters is set of filters, should not be empty
repeated Filter Filters = 1 [(gogoproto.nullable) = false];
}