Struct dyer::engine::App [−][src]
An abstraction and collection of data flow of Dyer
,
Fields
task: Arc<Mutex<Vec<Task<T>>>>
task_tmp: Arc<Mutex<Vec<Task<T>>>>
profile: Arc<Mutex<Vec<Profile<P>>>>
req: Arc<Mutex<Vec<Request<T, P>>>>
req_tmp: Arc<Mutex<Vec<Request<T, P>>>>
res: Arc<Mutex<Vec<Response<T, P>>>>
result: Arc<Mutex<Vec<Entity>>>
yield_err: Arc<Mutex<Vec<String>>>
fut_res: Arc<Mutex<Vec<(u64, JoinHandle<()>)>>>
fut_profile: Arc<Mutex<Vec<(u64, JoinHandle<()>)>>>
rt_args: Arc<Mutex<AppArg>>
Implementations
impl<'a, Entity, T, P> App<Entity, T, P> where
T: 'static + Serialize + for<'de> Deserialize<'de> + Debug + Clone + Sync + Send,
P: 'static + Serialize + for<'de> Deserialize<'de> + Debug + Clone + Sync + Send,
Entity: Serialize + Debug + Clone + Send + Sync,
[src]
T: 'static + Serialize + for<'de> Deserialize<'de> + Debug + Clone + Sync + Send,
P: 'static + Serialize + for<'de> Deserialize<'de> + Debug + Clone + Sync + Send,
Entity: Serialize + Debug + Clone + Send + Sync,
pub fn new() -> Self
[src]
pub fn info(&mut self)
[src]
get the overview of App
pub fn enough_profile(&self) -> bool
[src]
to see whether to generate Profile
pub async fn plineout<C>(&mut self, pipeline: &PipeLine<'a, Entity, C>) where
C: Send + 'a,
[src]
C: Send + 'a,
drive and consume extracted Entity into PipeLine
pub async fn update_req(&mut self, middleware: &MiddleWare<'a, Entity, T, P>)
[src]
load and balance Request
pub async fn spawn_task(&mut self)
[src]
spawn polling Request
as tokio::task
and executing asynchronously,
pub fn buf_task(&self, path: &str) -> Vec<usize>
[src]
load cached Task
from caced directory
pub async fn close<'b, C>(
&'a mut self,
spd: &'static dyn Spider<Entity, T, P>,
middleware: &'a MiddleWare<'b, Entity, T, P>,
pipeline: &'a PipeLine<'b, Entity, C>
) where
C: Send + 'b,
[src]
&'a mut self,
spd: &'static dyn Spider<Entity, T, P>,
middleware: &'a MiddleWare<'b, Entity, T, P>,
pipeline: &'a PipeLine<'b, Entity, C>
) where
C: Send + 'b,
preparation before closing Dyer
pub async fn run<'b, C>(
&'a mut self,
spd: &'static dyn Spider<Entity, T, P>,
middleware: &'a MiddleWare<'b, Entity, T, P>,
pipeline: PipeLine<'b, Entity, C>
) -> Result<(), Box<dyn Error + Send + Sync>> where
C: Send + 'a,
[src]
&'a mut self,
spd: &'static dyn Spider<Entity, T, P>,
middleware: &'a MiddleWare<'b, Entity, T, P>,
pipeline: PipeLine<'b, Entity, C>
) -> Result<(), Box<dyn Error + Send + Sync>> where
C: Send + 'a,
drive Dyer
into running.
Auto Trait Implementations
impl<Entity, T, P> RefUnwindSafe for App<Entity, T, P>
impl<Entity, T, P> Send for App<Entity, T, P> where
Entity: Send,
T: Send,
Entity: Send,
T: Send,
impl<Entity, T, P> Sync for App<Entity, T, P> where
Entity: Send,
T: Send,
Entity: Send,
T: Send,
impl<Entity, T, P> Unpin for App<Entity, T, P>
impl<Entity, T, P> UnwindSafe for App<Entity, T, P>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T> Instrument for T
[src]
pub fn instrument(self, span: Span) -> Instrumented<Self>
[src]
pub fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T> Instrument for T
[src]
pub fn instrument(self, span: Span) -> Instrumented<Self>
[src]
pub fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,