kubizone_common/ident.rs
1use std::hash::Hash;
2
3use crate::{FullyQualifiedDomainName, Type};
4
5/// A uniquely identified Record identity.
6///
7/// Encompasses the tuple of (fqdn, type, rdata), which should uniquely identify
8/// it within a zone, since zones cannot contain records which are not unique
9/// across these parameters.
10///
11/// Can be used to store records in HashMaps/HashSets
12#[derive(Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
13pub struct RecordIdent {
14 pub fqdn: FullyQualifiedDomainName,
15 pub r#type: Type,
16 pub rdata: String,
17}