use ruma_macros::IdZst;
use super::{IdParseError, KeyName};
#[repr(transparent)]
#[derive(PartialEq, Eq, PartialOrd, Ord, Hash, IdZst)]
#[ruma_id(
validate = ruma_identifiers_validation::server_signing_key_version::validate,
)]
pub struct ServerSigningKeyVersion(str);
impl KeyName for ServerSigningKeyVersion {
fn validate(s: &str) -> Result<(), IdParseError> {
ruma_identifiers_validation::server_signing_key_version::validate(s)
}
}
impl KeyName for OwnedServerSigningKeyVersion {
fn validate(s: &str) -> Result<(), IdParseError> {
ruma_identifiers_validation::server_signing_key_version::validate(s)
}
}