Time distribution across script event categories.

This commit is contained in:
benshu 2015-08-23 21:02:40 +02:00
parent 71b277d567
commit 1e6a2f08fc
11 changed files with 184 additions and 50 deletions

View file

@ -186,20 +186,20 @@ impl Runnable for WorkerMessageHandler {
}
}
pub struct WorkerEventHandler {
pub struct SimpleWorkerErrorHandler {
addr: TrustedWorkerAddress,
}
impl WorkerEventHandler {
pub fn new(addr: TrustedWorkerAddress) -> WorkerEventHandler {
WorkerEventHandler {
impl SimpleWorkerErrorHandler {
pub fn new(addr: TrustedWorkerAddress) -> SimpleWorkerErrorHandler {
SimpleWorkerErrorHandler {
addr: addr
}
}
}
impl Runnable for WorkerEventHandler {
fn handler(self: Box<WorkerEventHandler>) {
impl Runnable for SimpleWorkerErrorHandler {
fn handler(self: Box<SimpleWorkerErrorHandler>) {
let this = *self;
Worker::dispatch_simple_error(this.addr);
}