Skip to main content

gateway_internal/
query_parameter.rs

1/// Represents a filter for query parameters, preventing them from being mapped if they are
2/// already handled by path parameters or the body.
3#[derive(Debug, Clone, PartialEq)]
4pub struct QueryParamFilter {
5    /// Encoding of the field paths.
6    /// In Go implementation, this uses a DoubleArray trie structure for efficiency.
7    /// Here we represent it as a set of field paths for simplicity in the domain model phase.
8    pub field_paths: Vec<String>,
9}
10
11/// A mapping from a query parameter key to a protobuf field path.
12#[derive(Debug, Clone, PartialEq)]
13pub struct QueryParameter {
14    /// The key in the query string (e.g., "page_size").
15    pub key: String,
16
17    /// The target field path in the protobuf message (e.g., "page_size").
18    pub field_path: Vec<String>,
19}