Skip to content

Commit

Permalink
feat(const-oid): add Identified trait
Browse files Browse the repository at this point in the history
Signed-off-by: Nathaniel McCallum <nathaniel@profian.com>
  • Loading branch information
npmccallum committed Mar 7, 2022
1 parent 4ca4b07 commit 6602d00
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions const-oid/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,12 @@ pub use crate::{
use crate::encoder::Encoder;
use core::{fmt, str::FromStr};

/// Identifies a type with a given OID.
pub trait Identified {
/// The OID associated with this type.
const OID: ObjectIdentifier;
}

/// Object identifier (OID).
///
/// OIDs are hierarchical structures consisting of "arcs", i.e. integer
Expand Down

0 comments on commit 6602d00

Please sign in to comment.