Exemple #1
0
        public static async Task <RemoteAssetBundle> UploadAssetBundle(string url, AssetBundleInfo info, string appName = null, string jwtName = null)
        {
            HttpResponseMessage response = await UploadAssetBundleAsync(url, info, appName, jwtName);

            string content = await response.Content.ReadAsStringAsync();

            return(RemoteAssetBundle.Deserialize(content));
        }
Exemple #2
0
        ///<summary>Simplified version of <see cref="VerifyAssetBundleAsync"/>
        ///<para>This is enforced by default as an extra set of checks and balances when calling <see cref="GetAssetBundleManifestAsync"/> with verified = true</para>
        ///<param name="url">The absolute URL to the PUT endpoint</param>
        ///<param name="bundle">The RemoteAssetBundle struct</param>
        ///<param name="jwtName">Optional name of a JSON Web Token (placed somewhere in Assets) that can be used for authentication</param>
        ///<returns>Returns a Task which returns a deserialized RemoteAssetBundle</returns>
        ///</summary>
        public static async Task <RemoteAssetBundle> VerifyAssetBundle(string url, RemoteAssetBundle bundle, bool verifiedVal, string jwtName = null)
        {
            HttpResponseMessage response = await VerifyAssetBundleAsync(url, bundle, verifiedVal, jwtName);

            string content = await response.Content.ReadAsStringAsync();

            return(RemoteAssetBundle.Deserialize(content));
        }