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
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
extern crate aho_corasick;
#[macro_use]
extern crate bitflags;
#[macro_use]
extern crate lazy_static;
#[macro_use]
mod macros;
mod agpl3;
mod apache2;
mod cc01;
mod gpl3;
mod kind;
mod lgpl3;
mod license;
mod mit;
mod mpl2;
mod unknown;
mod unlicense;
pub use agpl3::Agpl3;
pub use apache2::Apache2;
pub use cc01::Cc01;
pub use gpl3::Gpl3;
pub use kind::Kind;
pub use lgpl3::Lgpl3;
pub use license::License;
pub use mit::Mit;
pub use mpl2::Mpl2;
pub use unknown::Unknown;
pub use unlicense::Unlicense;
pub mod permissions {
bitflags! {
pub struct Permissions: u8 {
const COMMERCIAL_USE = 0b_0000_0001;
const DISTRIBUTION = 0b_0000_0010;
const MODIFICATION = 0b_0000_0100;
const PATENT_RIGHTS = 0b_0000_1000;
const PRIVATE_USE = 0b_0001_0000;
}
}
}
pub mod conditions {
bitflags! {
pub struct Conditions: u8 {
const DISCLOSE_SOURCES = 0b_0000_0001;
const DOCUMENT_CHANGES = 0b_0000_0010;
const LICENSE_AND_COPYRIGHT_NOTICE = 0b_0000_0100;
const NETWORK_USE_IS_DISTRIBUTION = 0b_0000_1000;
const SAME_LICENSE = 0b_0001_0000;
}
}
}
pub mod limitations {
bitflags! {
pub struct Limitations: u8 {
const NO_LIABILITY = 0b_0000_0001;
const NO_TRADEMARK_RIGHTS = 0b_0000_0010;
const NO_WARRANTY = 0b_0000_0100;
const NO_PATENT_RIGHTS = 0b_0000_1000;
}
}
}