pub struct UnresolvedAddress(pub [u8; 24]);Expand description
まだ解決していないアドレス。アドレスそのものか、アドレスに紐づけたネームスペースのどちらか。 先頭の1バイトの最下位ビットが1ならネームスペースで、どちらも24バイトで書く。
Tuple Fields§
§0: [u8; 24]Implementations§
Source§impl UnresolvedAddress
impl UnresolvedAddress
Sourcepub fn from_namespace_id(
namespace_id: NamespaceId,
network: NetworkIdentifier,
) -> Self
pub fn from_namespace_id( namespace_id: NamespaceId, network: NetworkIdentifier, ) -> Self
ネームスペースを指すアドレスにする。公式の SDK の Address.from_namespace_id と同じく、
ネットワークの識別子の最下位ビットを立てた1バイト、ID の8バイト、残りの0を並べる。
catapult が読むのは、先頭の最下位ビットと ID だけ。
Sourcepub fn namespace_id(&self) -> Option<NamespaceId>
pub fn namespace_id(&self) -> Option<NamespaceId>
ネームスペースを指していれば、その ID。catapult の addAddressResolver と同じく、先頭の最下位ビットで見分ける。
Trait Implementations§
Source§impl Clone for UnresolvedAddress
impl Clone for UnresolvedAddress
Source§fn clone(&self) -> UnresolvedAddress
fn clone(&self) -> UnresolvedAddress
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for UnresolvedAddress
Source§impl Debug for UnresolvedAddress
impl Debug for UnresolvedAddress
impl Eq for UnresolvedAddress
Source§impl From<Address> for UnresolvedAddress
impl From<Address> for UnresolvedAddress
Source§impl Hash for UnresolvedAddress
impl Hash for UnresolvedAddress
Source§impl PartialEq for UnresolvedAddress
impl PartialEq for UnresolvedAddress
impl StructuralPartialEq for UnresolvedAddress
Auto Trait Implementations§
impl Freeze for UnresolvedAddress
impl RefUnwindSafe for UnresolvedAddress
impl Send for UnresolvedAddress
impl Sync for UnresolvedAddress
impl Unpin for UnresolvedAddress
impl UnsafeUnpin for UnresolvedAddress
impl UnwindSafe for UnresolvedAddress
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