diff --git a/src/billing/adapters/types.rs b/src/billing/adapters/types.rs new file mode 100644 index 0000000..316a085 --- /dev/null +++ b/src/billing/adapters/types.rs @@ -0,0 +1,45 @@ +// SPDX-FileCopyrightText: 2024 Aravinth Manivannan +// +// SPDX-License-Identifier: AGPL-3.0-or-later + +// SPDX-FileCopyrightText: 2024 Aravinth Manivannan +// +// SPDX-License-Identifier: AGPL-3.0-or-later +#![allow(dead_code)] + +use std::sync::Arc; + +use actix_web::web::Data; +use cqrs_es::persist::ViewRepository; +use postgres_es::PostgresCqrs; + +use crate::billing::{ + adapters::{ + input::web::RoutesRepository, + output::db::postgres::{ + bill_view::BillView, line_item_view::LineItemView, store_view::StoreView, + BillingDBPostgresAdapter, + }, + }, + application::services::BillingServicesObj, + domain::{bill_aggregate::Bill, line_item_aggregate::LineItem, store_aggregate::Store}, +}; + +pub type WebBillingRoutesRepository = Data>; + +pub type WebBillingServiceObj = Data; + +pub type BillingBillCqrsExec = Arc>; +pub type WebBillingBillCqrsExec = Data; +pub type BillingBillCqrsView = Arc>; +pub type WebBillingBillCqrsView = Data; + +pub type BillingLineItemCqrsExec = Arc>; +pub type WebBillingLineItemCqrsExec = Data; +pub type BillingLineItemCqrsView = Arc>; +pub type WebBillingLineItemCqrsView = Data; + +pub type BillingStoreCqrsExec = Arc>; +pub type WebBillingStoreCqrsExec = Data; +pub type BillingStoreCqrsView = Arc>; +pub type WebBillingStoreCqrsView = Data;