using System;
namespace Implab.Components {
public interface IRunnable {
///
/// Starts this instance.
///
IPromise Start();
///
/// Stops this instance. After the instance is stopped it can't be started again, stopping should be treated as gracefull and async dispose.
///
IPromise Stop();
ExecutionState State { get; }
event EventHandler StateChanged;
Exception LastError { get; }
}
}