public ReactiveScriptEngine(string path, PluginLocator locator, Action<string> dispatch) { _keyPath = path; _dispatch = dispatch; _pausedScripts = new List<string>(); _reader = new ReactiveScriptReader( _keyPath, () => { return locator; }, (m) => _dispatch(m)); _touchHandler = new ScriptTouchHandler(_reader.GetPaths()); _scripts = _reader.Read(); }
public ReactiveScriptEngine(string path, PluginLocator locator, Action<string,string> outputDispatcher, Action<string> dispatch) { _keyPath = path; _outputDispatcher = outputDispatcher; _dispatch = dispatch; _pausedScripts = new List<string>(); _reader = new ReactiveScriptReader( _keyPath, () => { return locator; }, _outputDispatcher, (m) => _dispatch(m)); _touchHandler = new ScriptTouchHandler(_reader.GetPaths()); _scripts = _reader.Read(); foreach (var script in _scripts) { if (script.IsService) script.StartService(); } }
public ReactiveScriptEngine(string path, PluginLocator locator, Action <string, string> outputDispatcher, Action <string> dispatch) { _keyPath = path; _outputDispatcher = outputDispatcher; _dispatch = dispatch; _pausedScripts = new List <string>(); _reader = new ReactiveScriptReader( _keyPath, () => { return(locator); }, _outputDispatcher, (m) => _dispatch(m)); _touchHandler = new ScriptTouchHandler(_reader.GetPaths()); _scripts = _reader.Read(); foreach (var script in _scripts) { if (script.IsService) { script.StartService(); } } }