noodles_vcf/header/record/value/map/
other.rs

1//! Inner VCF header other map value.
2
3pub(crate) mod tag;
4
5pub use self::tag::Tag;
6
7use super::{builder, Inner, Map};
8
9/// An inner VCF header other map value.
10#[derive(Clone, Debug, Eq, PartialEq)]
11pub struct Other {
12    pub(crate) id_tag: Tag,
13}
14
15impl Inner for Other {
16    type StandardTag = tag::Standard;
17    type Builder = builder::Identity;
18}
19
20impl Default for Other {
21    fn default() -> Self {
22        Self { id_tag: tag::ID }
23    }
24}
25
26impl Map<Other> {
27    /// Creates a nonstandard VCF header map value.
28    ///
29    /// # Examples
30    ///
31    /// ```
32    /// use noodles_vcf::header::record::value::{map::Other, Map};
33    /// let map = Map::<Other>::new();
34    /// ```
35    pub fn new() -> Self {
36        Self::default()
37    }
38
39    pub(crate) fn id_tag(&self) -> &Tag {
40        &self.inner.id_tag
41    }
42}