added conversion

This commit is contained in:
Monica Moniot
2023-10-31 10:57:34 -04:00
parent b0788b62d9
commit 548d5f4f20
+7
View File
@@ -398,6 +398,13 @@ impl<'de> Deserialize<'de> for ShortAddress {
}
}
impl From<ShortAddress> for std::net::Ipv6Addr {
fn from(value: ShortAddress) -> Self {
std::net::Ipv6Addr::from(*value.as_bytes())
}
}
impl crate::Address for Address {
const SIZE: usize = 48;
}