cedar_policy/proto.rs
1/*
2 * Copyright Cedar Contributors
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * https://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17/// Protobuf structures for types in `cedar_policy_core` and `cedar_policy_validator`
18pub mod models {
19 mod cedar_policy_core {
20 #![allow(
21 missing_docs,
22 clippy::doc_markdown,
23 clippy::derive_partial_eq_without_eq
24 )]
25 include!(concat!(env!("OUT_DIR"), "/cedar_policy_core.rs"));
26 }
27 mod cedar_policy_validator {
28 #![allow(
29 missing_docs,
30 clippy::doc_markdown,
31 clippy::derive_partial_eq_without_eq
32 )]
33 include!(concat!(env!("OUT_DIR"), "/cedar_policy_validator.rs"));
34 }
35 pub use cedar_policy_core::*;
36 pub use cedar_policy_validator::*;
37}
38
39/// Conversions between proto types and `cedar_policy_core::ast` types (other than policy/policyset types)
40mod ast;
41
42/// Conversions between proto types and `cedar_policy_core::ast` policy/policyset types
43mod policy;
44
45/// Conversions between proto types and `cedar_policy_core::entities` types
46mod entities;
47
48/// Conversions between proto types and `cedar_policy_validator` types
49mod validator;
50
51/// Conversions between proto types and `cedar_policy::api` types
52mod api;
53
54/// `Protobuf` trait and associated utilities
55pub mod traits;