SteamKit2.CDNClient.DownloadDepotManifest C# (CSharp) Method

DownloadDepotManifest() public method

Downloads the depot manifest for the given depot and manifest.
public DownloadDepotManifest ( int depotid, ulong manifestid ) : DepotManifest
depotid int The depotid.
manifestid ulong The manifestid.
return DepotManifest
        public DepotManifest DownloadDepotManifest(int depotid, ulong manifestid)
        {
            Uri manifestURI = new Uri(BuildCommand(endPoint, "depot"), String.Format("{0}/manifest/{1}", depotid, manifestid));

            PrepareAuthHeader(ref webClient, manifestURI);

            byte[] compressedManifest;
            byte[] manifest;
            try
            {
                compressedManifest = webClient.DownloadData(manifestURI);
            }
            catch (WebException)
            {
                return null;
            }

            try
            {
                manifest = ZipUtil.Decompress(compressedManifest);
            }
            catch (Exception)
            {
                return null;
            }

            return new DepotManifest( manifest );
        }