Exemplo n.º 1
0
        internal static AsyncHTTPClient BuildPackage(AssetStoreAsset asset, AssetStoreResultBase <BuildPackageResult> .Callback callback)
        {
            string             url = AssetStoreClient.APIUrl("/content/download/" + asset.packageID.ToString());
            BuildPackageResult r   = new BuildPackageResult(asset, callback);

            return(AssetStoreClient.CreateJSONRequest(url, delegate(AssetStoreResponse ar)
            {
                r.Parse(ar);
            }));
        }
Exemplo n.º 2
0
        internal static AsyncHTTPClient BuildPackage(AssetStoreAsset asset, AssetStoreResultBase <BuildPackageResult> .Callback callback)
        {
            // ISSUE: object of a compiler-generated type is created
            // ISSUE: variable of a compiler-generated type
            AssetStoreClient.\u003CBuildPackage\u003Ec__AnonStorey57 packageCAnonStorey57 = new AssetStoreClient.\u003CBuildPackage\u003Ec__AnonStorey57();
            string url = AssetStoreClient.APIUrl("/content/download/" + asset.packageID.ToString());

            // ISSUE: reference to a compiler-generated field
            packageCAnonStorey57.r = new BuildPackageResult(asset, callback);
            // ISSUE: reference to a compiler-generated method
            return(AssetStoreClient.CreateJSONRequest(url, new AssetStoreClient.DoneCallback(packageCAnonStorey57.\u003C\u003Em__95)));
        }
Exemplo n.º 3
0
        internal static AsyncHTTPClient DirectPurchase(int packageID, string password, AssetStoreResultBase <PurchaseResult> .Callback callback)
        {
            string         url = AssetStoreClient.APIUrl(string.Format("/purchase/direct/{0}", packageID.ToString()));
            PurchaseResult r   = new PurchaseResult(callback);
            Dictionary <string, string> dictionary = new Dictionary <string, string>();

            dictionary["password"] = password;
            return(AssetStoreClient.CreateJSONRequestPost(url, dictionary, delegate(AssetStoreResponse ar)
            {
                r.Parse(ar);
            }));
        }
Exemplo n.º 4
0
        internal static AsyncHTTPClient DirectPurchase(int packageID, string password, AssetStoreResultBase <PurchaseResult> .Callback callback)
        {
            // ISSUE: object of a compiler-generated type is created
            // ISSUE: variable of a compiler-generated type
            AssetStoreClient.\u003CDirectPurchase\u003Ec__AnonStorey56 purchaseCAnonStorey56 = new AssetStoreClient.\u003CDirectPurchase\u003Ec__AnonStorey56();
            string url = AssetStoreClient.APIUrl(string.Format("/purchase/direct/{0}", (object)packageID.ToString()));

            // ISSUE: reference to a compiler-generated field
            purchaseCAnonStorey56.r = new PurchaseResult(callback);
            Dictionary <string, string> dictionary = new Dictionary <string, string>();

            dictionary["password"] = password;
            // ISSUE: reference to a compiler-generated method
            return(AssetStoreClient.CreateJSONRequestPost(url, dictionary, new AssetStoreClient.DoneCallback(purchaseCAnonStorey56.\u003C\u003Em__94)));
        }
Exemplo n.º 5
0
        internal static AsyncHTTPClient AssetsInfo(List <AssetStoreAsset> assets, AssetStoreResultBase <AssetStoreAssetsInfo> .Callback callback)
        {
            string text = AssetStoreClient.APIUrl("/assets/list");

            foreach (AssetStoreAsset current in assets)
            {
                text = text + "&id=" + current.id.ToString();
            }
            AssetStoreAssetsInfo r = new AssetStoreAssetsInfo(callback, assets);

            return(AssetStoreClient.CreateJSONRequest(text, delegate(AssetStoreResponse ar)
            {
                r.Parse(ar);
            }));
        }
Exemplo n.º 6
0
        internal static AsyncHTTPClient AssetsInfo(List <AssetStoreAsset> assets, AssetStoreResultBase <AssetStoreAssetsInfo> .Callback callback)
        {
            // ISSUE: object of a compiler-generated type is created
            // ISSUE: variable of a compiler-generated type
            AssetStoreClient.\u003CAssetsInfo\u003Ec__AnonStorey55 infoCAnonStorey55 = new AssetStoreClient.\u003CAssetsInfo\u003Ec__AnonStorey55();
            string url = AssetStoreClient.APIUrl("/assets/list");

            using (List <AssetStoreAsset> .Enumerator enumerator = assets.GetEnumerator())
            {
                while (enumerator.MoveNext())
                {
                    AssetStoreAsset current = enumerator.Current;
                    url = url + "&id=" + current.id.ToString();
                }
            }
            // ISSUE: reference to a compiler-generated field
            infoCAnonStorey55.r = new AssetStoreAssetsInfo(callback, assets);
            // ISSUE: reference to a compiler-generated method
            return(AssetStoreClient.CreateJSONRequest(url, new AssetStoreClient.DoneCallback(infoCAnonStorey55.\u003C\u003Em__93)));
        }