rustpub 0.1.4

An implementation of the Activitypub types
Documentation
use std::collections::HashMap;

use serde::{Deserialize, Serialize};
use rustpub_macro::{activitypub_property, activitypub_property_hashmap};

use crate::core::*;

pub trait ActivitypubProperty {
    fn is_none(&self) -> bool;
}

activitypub_property!{pub Attachment, false, Object, Link}
activitypub_property!{pub AttributedTo, false, Object, Link}
activitypub_property!{pub Audience, false, Object, Link}
activitypub_property_hashmap!{pub Content, false, String}
activitypub_property!{pub Context, false, Object, Link}
activitypub_property!{pub Generator, false, Object, Link}
activitypub_property!{pub InReplyTo, false, Object, Link}
activitypub_property_hashmap!{pub Name, false, String}
activitypub_property_hashmap!{pub Summary, false, String}
activitypub_property!{pub Tag, false, Object, Link}
activitypub_property!{pub Url, false, String, Link}

pub type Kind = String;
pub type Id = String;
pub type MediaType = String;
pub type Inbox = String;
pub type Outbox = String;
pub type Href = String;