aboutsummaryrefslogtreecommitdiff
path: root/src/interfaces/factory.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/interfaces/factory.rs')
-rw-r--r--src/interfaces/factory.rs10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/interfaces/factory.rs b/src/interfaces/factory.rs
new file mode 100644
index 0000000..c97fc09
--- /dev/null
+++ b/src/interfaces/factory.rs
@@ -0,0 +1,10 @@
+#![allow(clippy::module_name_repetitions)]
+use crate::libs::intertrait::CastFrom;
+use crate::ptr::InterfacePtr;
+
+pub trait IFactory<Args, ReturnInterface>:
+ Fn<Args, Output = InterfacePtr<ReturnInterface>> + CastFrom
+where
+ ReturnInterface: 'static + ?Sized,
+{
+}