[][src]Struct casperlabs_contract_ffi::uref::URef

pub struct URef(_, _);

Represents an unforgeable reference

Methods

impl URef[src]

pub fn new(id: [u8; 32], access_rights: AccessRights) -> Self[src]

Creates a URef from an id and access rights.

pub fn addr(&self) -> [u8; 32][src]

Returns the address of this URef.

pub fn access_rights(&self) -> Option<AccessRights>[src]

Returns the access rights of this URef.

pub fn with_access_rights(self, access_rights: AccessRights) -> Self[src]

Returns a new URef with updated access rights.

pub fn remove_access_rights(self) -> Self[src]

Removes the access rights from this URef.

pub fn is_readable(self) -> bool[src]

pub fn into_read(self) -> URef[src]

pub fn into_read_add_write(self) -> URef[src]

pub fn is_writeable(self) -> bool[src]

pub fn is_addable(self) -> bool[src]

pub fn as_string(&self) -> String[src]

Formats address and its access rights in an unique way that could be used as a name when storing given uref in a global state.

Trait Implementations

impl CLTyped for URef[src]

impl Clone for URef[src]

impl Copy for URef[src]

impl Debug for URef[src]

impl Display for URef[src]

impl Eq for URef[src]

impl From<PurseId> for URef[src]

impl<T: CLTyped> From<TURef<T>> for URef[src]

impl From<URef> for Key[src]

impl FromBytes for URef[src]

impl Hash for URef[src]

impl Ord for URef[src]

impl PartialEq<URef> for URef[src]

impl PartialOrd<URef> for URef[src]

impl StructuralEq for URef[src]

impl StructuralPartialEq for URef[src]

impl ToBytes for URef[src]

Auto Trait Implementations

impl Send for URef

impl Sync for URef

impl Unpin for URef

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.