You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
yuurei/src/post.rs

18 lines
416 B

4 years ago
use super::*;
4 years ago
use cryptohelpers::sha256::Sha256Hash;
4 years ago
4 years ago
id_type!(PostID; "A unique post ID");
/// A single completed post
#[derive(Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
4 years ago
pub struct Post
{
4 years ago
id: PostID,
name: Option<String>,
email: Option<String>,
4 years ago
4 years ago
body: hard_format::formats::PEMFormattedString,
signature: Option<hard_format::formats::PEMFormattedString>,
hash: Sha256Hash,
4 years ago
}