diff --git a/Cargo.toml b/Cargo.toml index 13ea3de..74af75e 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,9 +1,8 @@ [package] name = "locator" -version = "2.0.0" +version = "2.0.1" edition = "2021" - [dependencies] alphanumeric-sort = "1.5.3" getset = "0.1.2" diff --git a/src/lib.rs b/src/lib.rs index 9ca1f33..3420425 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -154,6 +154,30 @@ pub enum Fetcher { #[derive(Copy, Clone, Eq, PartialEq, Ord, PartialOrd, Hash)] pub struct OrgId(usize); +impl From for u64 { + fn from(value: OrgId) -> Self { + value.0 as u64 + } +} + +impl From for usize { + fn from(value: OrgId) -> Self { + value.0 + } +} + +impl From for i64 { + fn from(value: OrgId) -> Self { + value.0 as i64 + } +} + +impl From for isize { + fn from(value: OrgId) -> Self { + value.0 as isize + } +} + impl TryFrom<&str> for OrgId { type Error = ::Err;