1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
pub fn artifact<S>(name: S) -> Artifact
where
    S: Into<Box<str>>,
{
    Artifact::new(name.into())
}

pub struct Artifact {
    name: Box<str>,
}

impl Artifact {
    fn new(name: Box<str>) -> Self {
        Self { name }
    }

    pub fn name(&self) -> &str {
        &self.name
    }
}