aboutsummaryrefslogtreecommitdiff
path: root/src/interfaces
diff options
context:
space:
mode:
authorHampusM <hampus@hampusmat.com>2022-07-27 15:17:33 +0200
committerHampusM <hampus@hampusmat.com>2022-07-31 12:15:18 +0200
commit3fbf26181f1b4b9e594debb103fd347bd93240ea (patch)
tree63cf13edb5ea21a6cbbcfcf474611820382a5048 /src/interfaces
parent224e59112e65ce6cbafe5a87dba031dd11e936a8 (diff)
refactor!: rename InterfacePtr to TransientPtr
BREAKING CHANGE: InterfacePtr has been renamed to TransientPtr
Diffstat (limited to 'src/interfaces')
-rw-r--r--src/interfaces/factory.rs4
-rw-r--r--src/interfaces/injectable.rs4
2 files changed, 4 insertions, 4 deletions
diff --git a/src/interfaces/factory.rs b/src/interfaces/factory.rs
index c97fc09..6f8e7c7 100644
--- a/src/interfaces/factory.rs
+++ b/src/interfaces/factory.rs
@@ -1,9 +1,9 @@
#![allow(clippy::module_name_repetitions)]
use crate::libs::intertrait::CastFrom;
-use crate::ptr::InterfacePtr;
+use crate::ptr::TransientPtr;
pub trait IFactory<Args, ReturnInterface>:
- Fn<Args, Output = InterfacePtr<ReturnInterface>> + CastFrom
+ Fn<Args, Output = TransientPtr<ReturnInterface>> + CastFrom
where
ReturnInterface: 'static + ?Sized,
{
diff --git a/src/interfaces/injectable.rs b/src/interfaces/injectable.rs
index 24032a6..0af1217 100644
--- a/src/interfaces/injectable.rs
+++ b/src/interfaces/injectable.rs
@@ -1,6 +1,6 @@
use crate::errors::injectable::ResolveError;
use crate::libs::intertrait::CastFrom;
-use crate::ptr::InterfacePtr;
+use crate::ptr::TransientPtr;
use crate::DIContainer;
pub trait Injectable: CastFrom
@@ -11,7 +11,7 @@ pub trait Injectable: CastFrom
/// Will return `Err` if resolving the dependencies fails.
fn resolve(
di_container: &DIContainer,
- ) -> error_stack::Result<InterfacePtr<Self>, ResolveError>
+ ) -> error_stack::Result<TransientPtr<Self>, ResolveError>
where
Self: Sized;
}