Пример #1
0
        public List<VersionEntry> GetNewVersions(Uri address, Version appVersion)
        {
            UpdateInfoWrapper wrapper = new UpdateInfoWrapper(signature);

            string content;
            using (var client = new WebClient())
            {
                content = client.DownloadString(address);
            }

            if (wrapper.Load(content))
            {
                var versions = wrapper.Data.Versions
                    .Where(x => x.Version > appVersion)
                    .OrderByDescending(x => x.Version);

                return this.FilterVersions(versions, appVersion);
            }

            return null;
        }
Пример #2
0
        public List <VersionEntry> GetNewVersions(Uri address, Version appVersion)
        {
            UpdateInfoWrapper wrapper = new UpdateInfoWrapper(signature);

            string content;

            using (var client = new WebClient())
            {
                content = client.DownloadString(address);
            }

            if (wrapper.Load(content))
            {
                var versions = wrapper.Data.Versions
                               .Where(x => x.Version > appVersion)
                               .OrderByDescending(x => x.Version);

                return(this.FilterVersions(versions, appVersion));
            }

            return(null);
        }