public StateStore(StatePlugin system, string path) { if (singleton != null) { throw new InvalidOperationException(nameof(StateStore)); } this.system = system; this.store = StatePlugin.System.LoadStore(path); singleton = this; StatePlugin.System.ActorSystem.EventStream.Subscribe(Self, typeof(Blockchain.RelayResult)); UpdateCurrentSnapshot(); }
public static Props Props(StatePlugin system, string path) { return(Akka.Actor.Props.Create(() => new StateStore(system, path))); }