Parse from a query parameter value. Accepts: - `"all"` → all layers - `"graph,content"` → graph + content - `"semantic,content"` → semantic + content - `"graph"` → graph only - Any comma-separated combination of layer names Unknown layer names are silently ignored. # Examples ```rust use atomic_remote::streaming::{LayerSelection, Layer}; let sel = LayerSelection::from_query_value("graph,conte
(value: &str)
| 129 | /// assert!(sel.includes(Layer::Content)); |
| 130 | /// ``` |
| 131 | pub fn from_query_value(value: &str) -> Self { |
| 132 | let trimmed = value.trim(); |
| 133 | if trimmed.eq_ignore_ascii_case("all") { |
| 134 | return Self::all(); |
| 135 | } |
| 136 | |
| 137 | let layers: HashSet<Layer> = trimmed |
| 138 | .split(',') |
| 139 | .filter_map(|s| Layer::from_str_loose(s.trim())) |
| 140 | .collect(); |
| 141 | |
| 142 | Self { layers } |
| 143 | } |
| 144 | |
| 145 | /// Serialize to a query parameter value. |
| 146 | /// |