1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
/*
 * Copyright (C) 2023  Aravinth Manivannan <realaravinth@batsense.net>
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU Affero General Public License as
 * published by the Free Software Foundation, either version 3 of the
 * License, or (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU Affero General Public License for more details.
 *
 * You should have received a copy of the GNU Affero General Public License
 * along with this program.  If not, see <https://www.gnu.org/licenses/>.
 */
//! # Welcome to F3 Documentation!
//!
//! Please refer to the [main documentation](https://f3.forgefriends.org/) for a complete overview.
//! This is an incomplete Rust port of the F3 library created by the ForgeFriends project.
use serde::{Deserialize, Serialize};

pub mod comment;
pub mod identities;
pub mod issue;
pub mod label;
pub mod milestone;
pub mod project;
pub mod pullrequest;
pub mod reaction;
pub mod release;
pub mod repository;
pub mod review;
pub mod topic;
pub mod user;

pub use comment::Comment;
pub use identities::Identities;
pub use issue::Issue;
pub use label::Label;
pub use milestone::Milestone;
pub use project::Project;
pub use pullrequest::PullRequest;
pub use reaction::Reaction;
pub use release::{Release, ReleaseAsset};
pub use repository::Repository;
pub use review::{Review, ReviewComment, ReviewState};
pub use topic::Topic;
pub use user::User;

#[derive(Clone, Debug, Serialize, Deserialize, Eq, PartialEq)]
#[serde(rename_all = "lowercase")]
/// states of issue, milestone, etc with only "open" and "closed" states and "closed" states and
/// "closed" states and "closed" states
pub enum OpenCloseState {
    /// A 'closed' issue will not see any activity in the future
    Closed,
    /// An 'open' issue will see activity in the future
    Open,
}

impl Default for OpenCloseState {
    fn default() -> Self {
        Self::Open
    }
}