(&self)
| 58 | } |
| 59 | |
| 60 | pub fn list(&self) -> Vec<&PermissionInfo> { |
| 61 | let mut result: Vec<&PermissionInfo> = Vec::new(); |
| 62 | for items in self.pending.values() { |
| 63 | for item in items.values() { |
| 64 | result.push(&item.info); |
| 65 | } |
| 66 | } |
| 67 | result.sort_by(|a, b| a.id.cmp(&b.id)); |
| 68 | result |
| 69 | } |
| 70 | |
| 71 | fn to_keys(pattern: Option<&Pattern>, permission_type: &str) -> Vec<String> { |
| 72 | match pattern { |