diff options
Diffstat (limited to 'src/private/factory.rs')
-rw-r--r-- | src/private/factory.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/private/factory.rs b/src/private/factory.rs index af6df8a..23b4e8f 100644 --- a/src/private/factory.rs +++ b/src/private/factory.rs @@ -4,11 +4,11 @@ use crate::private::cast::CastFrom; use crate::ptr::TransientPtr; /// Interface for a factory. -pub trait IFactory<ReturnInterface, DIContainerT>: - Fn<(Rc<DIContainerT>,), Output = TransientPtr<ReturnInterface>> + CastFrom +pub trait IFactory<ReturnInterface, DIContainerT>: CastFrom where ReturnInterface: 'static + ?Sized, { + fn call(&self, di_container: Rc<DIContainerT>) -> TransientPtr<ReturnInterface>; } /// Interface for a threadsafe factory. |