Exemplo n.º 1
0
        public static InstallConfigJson Load(string filePath)
        {
            InstallConfigJson installConfigJson = new InstallConfigJson(filePath);

            installConfigJson.LoadJson();
            return(installConfigJson);
        }
Exemplo n.º 2
0
        /// <summary>
        /// Create project using InstallConfiguration,
        /// used only by Updater
        /// </summary>
        /// <param name="installConfigJson">InstallConfigJson Object</param>
        /// <returns>Project object</returns>
        public static Project ByInstallConfig(InstallConfigJson installConfigJson)
        {
            var project = new Project
            {
                FolderId =
                    DriveUtils.GetProjectFolderId(installConfigJson.SoftwareName, installConfigJson.RootFolderId),
                SoftwareName = installConfigJson.SoftwareName
            };

            project.Versions = DriveUtils.GetVersions(project.FolderId);

            return(project);
        }