diff options
Diffstat (limited to 'src/interfaces/factory.rs')
-rw-r--r-- | src/interfaces/factory.rs | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/src/interfaces/factory.rs b/src/interfaces/factory.rs deleted file mode 100644 index c67abd6..0000000 --- a/src/interfaces/factory.rs +++ /dev/null @@ -1,23 +0,0 @@ -use std::marker::Tuple; - -use crate::libs::intertrait::CastFrom; -use crate::ptr::TransientPtr; - -/// Interface for a factory. -pub trait IFactory<Args, ReturnInterface>: - Fn<Args, Output = TransientPtr<ReturnInterface>> + CastFrom -where - Args: Tuple, - ReturnInterface: 'static + ?Sized, -{ -} - -/// Interface for a threadsafe factory. -#[cfg(feature = "async")] -pub trait IThreadsafeFactory<Args, ReturnInterface>: - Fn<Args, Output = TransientPtr<ReturnInterface>> + crate::libs::intertrait::CastFromSync -where - Args: Tuple, - ReturnInterface: 'static + ?Sized, -{ -} |