1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
use std::any::Any; use std::fmt::Debug; /// Trait given to the data structure(s) that will be processed by the ETL. pub trait Tea: Send + Debug { /// Helper function that returns Box<dyn Tea> struct as `Any`. /// /// This needs to be defined for the struct inheriting the `Tea` trait due to size not being /// known at compile time. /// /// # Example Method Implementation /// ```ignore /// fn as_any(&self) -> dyn Any { /// self /// } /// ``` fn as_any(&self) -> &dyn Any; }