Get a human-readable description.
(&self)
| 94 | impl DelegationPermission { |
| 95 | /// Get a human-readable description. |
| 96 | pub fn description(&self) -> &'static str { |
| 97 | match self { |
| 98 | DelegationPermission::Read => "Read repository content", |
| 99 | DelegationPermission::Record => "Record (commit) changes", |
| 100 | DelegationPermission::Push => "Push changes to remotes", |
| 101 | DelegationPermission::Pull => "Pull changes from remotes", |
| 102 | DelegationPermission::ManageStacks => "Create and delete stacks", |
| 103 | DelegationPermission::ManageTags => "Create and delete tags", |
| 104 | DelegationPermission::Admin => "Manage repository settings", |
| 105 | DelegationPermission::Full => "Full access (all permissions)", |
| 106 | } |
| 107 | } |
| 108 | |
| 109 | /// Check if this permission implies another permission. |
| 110 | pub fn implies(&self, other: &DelegationPermission) -> bool { |
no outgoing calls