Struct scrypto::modules::RoleAssignment
source · pub struct RoleAssignment(pub ModuleHandle);
Tuple Fields§
§0: ModuleHandle
Implementations§
source§impl RoleAssignment
impl RoleAssignment
pub fn new<R: Into<OwnerRoleEntry>>( owner_role: R, roles: IndexMap<ModuleId, RoleAssignmentInit> ) -> Self
pub fn set_owner_role<A: Into<AccessRule>>(&self, rule: A)
pub fn lock_owner_role(&self)
fn internal_set_role<A: Into<AccessRule>>( &self, module: ModuleId, name: &str, rule: A )
fn internal_get_role(&self, module: ModuleId, name: &str) -> Option<AccessRule>
pub fn set_role<A: Into<AccessRule>>(&self, name: &str, rule: A)
pub fn get_role(&self, name: &str) -> Option<AccessRule>
pub fn set_metadata_role<A: Into<AccessRule>>(&self, name: &str, rule: A)
pub fn get_metadata_role(&self, name: &str) -> Option<AccessRule>
pub fn set_component_royalties_role<A: Into<AccessRule>>( &self, name: &str, rule: A )
pub fn get_component_royalties_role(&self, name: &str) -> Option<AccessRule>
pub fn set_role_assignment_role<A: Into<AccessRule>>(&self, name: &str, rule: A)
pub fn get_role_assignment_role(&self, name: &str) -> Option<AccessRule>
Trait Implementations§
source§impl Attachable for RoleAssignment
impl Attachable for RoleAssignment
const MODULE_ID: AttachedModuleId = AttachedModuleId::RoleAssignment
fn new(handle: ModuleHandle) -> Self
fn handle(&self) -> &ModuleHandle
fn attached(address: GlobalAddress) -> Self
fn self_attached() -> Self
fn call<A: ScryptoEncode, T: ScryptoDecode>(&self, method: &str, args: &A) -> T
fn call_raw(&self, method: &str, args: Vec<u8>) -> Vec<u8> ⓘ
fn call_ignore_rtn<A: ScryptoEncode>(&self, method: &str, args: &A)
source§impl Clone for RoleAssignment
impl Clone for RoleAssignment
source§fn clone(&self) -> RoleAssignment
fn clone(&self) -> RoleAssignment
Returns a copy 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 RoleAssignment
impl Debug for RoleAssignment
source§impl Hash for RoleAssignment
impl Hash for RoleAssignment
source§impl PartialEq for RoleAssignment
impl PartialEq for RoleAssignment
source§fn eq(&self, other: &RoleAssignment) -> bool
fn eq(&self, other: &RoleAssignment) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Eq for RoleAssignment
impl StructuralPartialEq for RoleAssignment
Auto Trait Implementations§
impl RefUnwindSafe for RoleAssignment
impl Send for RoleAssignment
impl Sync for RoleAssignment
impl Unpin for RoleAssignment
impl UnwindSafe for RoleAssignment
Blanket Implementations§
§impl<U> As for U
impl<U> As for U
§fn as_<T>(self) -> Twhere
T: CastFrom<U>,
fn as_<T>(self) -> Twhere
T: CastFrom<U>,
Casts
self
to type T
. The semantics of numeric casting with the as
operator are followed, so <T as As>::as_::<U>
can be used in the same way as T as U
for numeric conversions. Read moresource§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
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more