aboutsummaryrefslogtreecommitdiff
path: root/src/modules/blog/post.rs
blob: 3422b85bd44af7d30c545d8037ae4b7ce1b1ffeb (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
pub struct Post {
  title: String,
  link:  String,
}

impl Post {
  pub const fn new(title: String, link: String) -> Self { Self { title, link } }

  pub const fn title(&self) -> &String { &self.title }

  pub const fn link(&self) -> &String { &self.link }
}