Struct scrypto::resource::resource_manager::ResourceManagerStub
source · pub struct ResourceManagerStub(pub ObjectStubHandle);
Tuple Fields§
§0: ObjectStubHandle
Implementations§
source§impl ResourceManagerStub
impl ResourceManagerStub
pub fn create_empty_vault(&self) -> Vault
pub fn create_empty_bucket(&self) -> Bucket
pub fn resource_type(&self) -> ResourceType
pub fn total_supply(&self) -> Option<Decimal>
pub fn non_fungible_exists(&self, id: &NonFungibleLocalId) -> bool
pub fn burn<B: Into<Bucket>>(&self, bucket: B)
sourcepub fn mint_non_fungible<T: NonFungibleData>(
&self,
id: &NonFungibleLocalId,
data: T
) -> Bucket
pub fn mint_non_fungible<T: NonFungibleData>( &self, id: &NonFungibleLocalId, data: T ) -> Bucket
Mints non-fungible resources
sourcepub fn mint_ruid_non_fungible<T: NonFungibleData>(&self, data: T) -> Bucket
pub fn mint_ruid_non_fungible<T: NonFungibleData>(&self, data: T) -> Bucket
Mints ruid non-fungible resources
sourcepub fn get_non_fungible_data<T: NonFungibleData>(
&self,
id: &NonFungibleLocalId
) -> T
pub fn get_non_fungible_data<T: NonFungibleData>( &self, id: &NonFungibleLocalId ) -> T
Returns the data of a non-fungible unit, both the immutable and mutable parts.
§Panics
Panics if this is not a non-fungible resource or the specified non-fungible is not found.
sourcepub fn update_non_fungible_data<D: ScryptoEncode>(
&self,
id: &NonFungibleLocalId,
field_name: &str,
new_data: D
)
pub fn update_non_fungible_data<D: ScryptoEncode>( &self, id: &NonFungibleLocalId, field_name: &str, new_data: D )
Updates the mutable part of a non-fungible unit.
§Panics
Panics if this is not a non-fungible resource or the specified non-fungible is not found.
pub fn amount_for_withdrawal( &self, request_amount: Decimal, withdraw_strategy: WithdrawStrategy ) -> Decimal
Trait Implementations§
source§impl Clone for ResourceManagerStub
impl Clone for ResourceManagerStub
source§fn clone(&self) -> ResourceManagerStub
fn clone(&self) -> ResourceManagerStub
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 ResourceManagerStub
impl Debug for ResourceManagerStub
source§impl HasStub for ResourceManagerStub
impl HasStub for ResourceManagerStub
type Stub = ResourceManagerStub
source§impl ObjectStub for ResourceManagerStub
impl ObjectStub for ResourceManagerStub
type AddressType = ResourceAddress
fn new(handle: ObjectStubHandle) -> Self
fn handle(&self) -> &ObjectStubHandle
fn call<A: ScryptoEncode, T: ScryptoDecode>(&self, method: &str, args: &A) -> T
fn call_ignore_rtn<A: ScryptoEncode>(&self, method: &str, args: &A)
fn call_raw<T: ScryptoDecode>(&self, method: &str, args: Vec<u8>) -> T
fn instance_of(&self, blueprint_id: &BlueprintId) -> bool
fn blueprint_id(&self) -> BlueprintId
source§impl PartialEq for ResourceManagerStub
impl PartialEq for ResourceManagerStub
source§fn eq(&self, other: &ResourceManagerStub) -> bool
fn eq(&self, other: &ResourceManagerStub) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Copy for ResourceManagerStub
impl Eq for ResourceManagerStub
impl StructuralPartialEq for ResourceManagerStub
Auto Trait Implementations§
impl RefUnwindSafe for ResourceManagerStub
impl Send for ResourceManagerStub
impl Sync for ResourceManagerStub
impl Unpin for ResourceManagerStub
impl UnwindSafe for ResourceManagerStub
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