pub struct Address(/* private fields */);
Expand description
40-bit node ID derived from VerifyingKey
.
Address is derived by taking last five bytes of memory-hard hash. Address is valid unless:
- first byte of memory-hard hash is greater than
0x10
- first byte of address is
0xFF
- every byte of address is
0x00
Trait Implementations§
Source§impl TryFrom<&[u8]> for Address
Tries to construct an address from a slice of bytes. Fails if len(bytes) != 5
.
impl TryFrom<&[u8]> for Address
Tries to construct an address from a slice of bytes. Fails if len(bytes) != 5
.
Source§impl TryFrom<&VerifyingKey> for Address
Tries to derive address from VerifyingKey
. Throws
InternalError
for invalid addresses.
impl TryFrom<&VerifyingKey> for Address
Tries to derive address from VerifyingKey
. Throws
InternalError
for invalid addresses.
impl StructuralPartialEq for Address
Auto Trait Implementations§
impl Freeze for Address
impl RefUnwindSafe for Address
impl Send for Address
impl Sync for Address
impl Unpin for Address
impl UnwindSafe for Address
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