Example #1
0
 JsFile CreateExternalJsFile(string filename)
 {
     var unit = new JsUnit { Statements = new List<JsStatement>() };
     var st = new JsCodeStatement
     {
         Code = File.ReadAllText(filename)
     };
     var file = new JsFile { Filename = filename, Units = new List<JsUnit> { unit } };
     unit.Statements.Add(st);
     return file;
 }
        public static SkJsFile getNewSkJsFile(JsFile newFile)
        {
            SkJsFile result = null;

            if (newFile != null)
            {
                result = new SkJsFile();
                result.JsFile = newFile;
            }

            return result;
        }
        public static JsFile getNewJsFile(string fileName)
        {
            JsFile result = null;

            if (fileName != null)
            {
                result = new JsFile();
                result.Filename = fileName;
            }

            return result;
        }