pub struct Builder { /* private fields */ }Expand description
Augments a SIWE message with encoded capability delegations.
Implementations
sourceimpl Builder
impl Builder
sourcepub fn default_actions(&self, namespace: &Namespace) -> Option<&Set<String>>
pub fn default_actions(&self, namespace: &Namespace) -> Option<&Set<String>>
Inspect the default actions for a namespace.
sourcepub fn actions(
&self,
namespace: &Namespace
) -> Option<&BTreeMap<String, Set<String>>>
pub fn actions(
&self,
namespace: &Namespace
) -> Option<&BTreeMap<String, Set<String>>>
Inspect the targeted actions for a namespace.
sourcepub fn extra_fields(
&self,
namespace: &Namespace
) -> Option<&HashMap<String, Value>>
pub fn extra_fields(
&self,
namespace: &Namespace
) -> Option<&HashMap<String, Value>>
Inspect the extra fields for a namespace.
sourcepub fn with_default_action<S>(self, namespace: &Namespace, action: S) -> Self where
S: Into<String>,
pub fn with_default_action<S>(self, namespace: &Namespace, action: S) -> Self where
S: Into<String>,
Extend the set of default actions for a namespace.
sourcepub fn with_default_actions<I, S>(self, namespace: &Namespace, actions: I) -> Self where
S: Into<String>,
I: IntoIterator<Item = S>,
pub fn with_default_actions<I, S>(self, namespace: &Namespace, actions: I) -> Self where
S: Into<String>,
I: IntoIterator<Item = S>,
Extend the set of default actions for a namespace.
sourcepub fn with_action<T, S>(self, namespace: &Namespace, target: T, action: S) -> Self where
T: Into<String>,
S: Into<String>,
pub fn with_action<T, S>(self, namespace: &Namespace, target: T, action: S) -> Self where
T: Into<String>,
S: Into<String>,
Extend the set of actions for a target in a namespace.
sourcepub fn with_actions<I, S, T>(
self,
namespace: &Namespace,
target: T,
actions: I
) -> Self where
T: Into<String>,
S: Into<String>,
I: IntoIterator<Item = S>,
pub fn with_actions<I, S, T>(
self,
namespace: &Namespace,
target: T,
actions: I
) -> Self where
T: Into<String>,
S: Into<String>,
I: IntoIterator<Item = S>,
Extend the set of actions for a target in a namespace.
sourcepub fn with_extra_fields(
self,
namespace: &Namespace,
fields: HashMap<String, Value>
) -> Self
pub fn with_extra_fields(
self,
namespace: &Namespace,
fields: HashMap<String, Value>
) -> Self
Extend the extra fields for a namespace.
This function performs a simple HashMap::extend, so does not merge serde_json::Values.
Any existing fields with a key matching the incoming fields will be overwritten.
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Builder
impl Send for Builder
impl Sync for Builder
impl Unpin for Builder
impl UnwindSafe for Builder
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more