1#![cfg_attr(feature = "fail-on-warnings", deny(warnings))]
23#![cfg_attr(feature = "fail-on-warnings", deny(clippy::all))]
24#![forbid(unsafe_code)]
25
26pub mod clock;
27pub mod context;
28pub mod error;
29pub mod events;
30pub mod idempotent;
31mod macros;
32pub mod nested;
33pub mod one_time_executor;
34pub mod operation;
35pub mod pagination;
36pub mod query;
37pub mod traits;
38
39pub mod prelude {
40 pub use chrono;
43 pub use serde;
44 pub use serde_json;
45 pub use sqlx;
46 pub use uuid;
47
48 #[cfg(feature = "json-schema")]
49 pub use schemars;
50}
51
52#[doc(inline)]
53pub use context::*;
54#[doc(inline)]
55pub use error::*;
56pub use es_entity_macros::EsEntity;
57pub use es_entity_macros::EsEvent;
58pub use es_entity_macros::EsRepo;
59pub use es_entity_macros::es_event_context;
60pub use es_entity_macros::expand_es_query;
61pub use es_entity_macros::retry_on_concurrent_modification;
62#[doc(inline)]
63pub use events::*;
64#[doc(inline)]
65pub use idempotent::*;
66#[doc(inline)]
67pub use nested::*;
68#[doc(inline)]
69pub use one_time_executor::*;
70#[doc(inline)]
71pub use operation::*;
72#[doc(inline)]
73pub use pagination::*;
74#[doc(inline)]
75pub use query::*;
76#[doc(inline)]
77pub use traits::*;
78
79#[cfg(feature = "graphql")]
80pub mod graphql {
81 pub use async_graphql;
82 pub use base64;
83
84 #[derive(Debug, serde::Serialize, serde::Deserialize, Clone, Copy)]
85 #[serde(transparent)]
86 pub struct UUID(crate::prelude::uuid::Uuid);
87 async_graphql::scalar!(UUID);
88 impl<T: Into<crate::prelude::uuid::Uuid>> From<T> for UUID {
89 fn from(id: T) -> Self {
90 let uuid = id.into();
91 Self(uuid)
92 }
93 }
94 impl From<&UUID> for crate::prelude::uuid::Uuid {
95 fn from(id: &UUID) -> Self {
96 id.0
97 }
98 }
99}