예제 #1
0
        public T ActivateScript <T> (string scriptName)
            where T : IScript
        {
            var path = FileNamer.GetScriptPath(scriptName);

            return((T)ActivateScriptFromFile(path));
        }
예제 #2
0
        public IScript ActivateScriptAt(string scriptName, string workingDirectory)
        {
            var scriptPath = FileNamer.GetScriptPath(scriptName, workingDirectory);

            var script = ActivateScriptFromFile(scriptPath);

            script.Relocate(workingDirectory);

            return(script);
        }
예제 #3
0
        public IScript ActivateScript(string scriptName)
        {
            var path = FileNamer.GetScriptPath(scriptName);

            if (String.IsNullOrEmpty(path))
            {
                throw new ScriptNotFoundException(scriptName);
            }

            return(ActivateScriptFromFile(path));
        }