Implement a dummy sources message in the thread actor

This commit is contained in:
Anthony Ramine 2016-03-24 15:26:40 +01:00
parent ef265b1c0b
commit 9a2955d4da

View file

@ -39,6 +39,15 @@ struct ReconfigureReply {
from: String
}
#[derive(Serialize)]
struct SourcesReply {
from: String,
sources: Vec<Source>,
}
#[derive(Serialize)]
enum Source {}
pub struct ThreadActor {
name: String,
}
@ -88,6 +97,15 @@ impl Actor for ThreadActor {
ActorMessageStatus::Processed
}
"sources" => {
let msg = SourcesReply {
from: self.name(),
sources: vec![],
};
stream.write_json_packet(&msg);
ActorMessageStatus::Processed
}
_ => ActorMessageStatus::Ignored,
})
}