pub struct Delegations { /* private fields */ }Expand description
Wrapper to described a collections of delegations.
Implementations§
Source§impl Delegations
impl Delegations
Sourcepub fn builder() -> DelegationsBuilder
pub fn builder() -> DelegationsBuilder
Return a DelegationsBuilder.
Sourcepub fn new(
keys: HashMap<KeyId, PublicKey>,
roles: Vec<Delegation>,
) -> Result<Self>
pub fn new( keys: HashMap<KeyId, PublicKey>, roles: Vec<Delegation>, ) -> Result<Self>
Create a new Delegations wrapper from the given set of trusted keys and roles.
Sourcepub fn keys(&self) -> &HashMap<KeyId, PublicKey>
pub fn keys(&self) -> &HashMap<KeyId, PublicKey>
An immutable reference to the keys used for this set of delegations.
Sourcepub fn roles(&self) -> &Vec<Delegation>
pub fn roles(&self) -> &Vec<Delegation>
An immutable reference to the delegated roles.
Trait Implementations§
Source§impl Clone for Delegations
impl Clone for Delegations
Source§fn clone(&self) -> Delegations
fn clone(&self) -> Delegations
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for Delegations
impl Debug for Delegations
Source§impl Default for Delegations
impl Default for Delegations
Source§fn default() -> Delegations
fn default() -> Delegations
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for Delegations
impl<'de> Deserialize<'de> for Delegations
Source§fn deserialize<D: Deserializer<'de>>(de: D) -> Result<Self, D::Error>
fn deserialize<D: Deserializer<'de>>(de: D) -> Result<Self, D::Error>
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for Delegations
impl PartialEq for Delegations
Source§impl Serialize for Delegations
impl Serialize for Delegations
impl Eq for Delegations
impl StructuralPartialEq for Delegations
Auto Trait Implementations§
impl Freeze for Delegations
impl RefUnwindSafe for Delegations
impl Send for Delegations
impl Sync for Delegations
impl Unpin for Delegations
impl UnsafeUnpin for Delegations
impl UnwindSafe for Delegations
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more