public override int GetHashCode() { int hash = 1; if (VersionInfo.Length != 0) { hash ^= VersionInfo.GetHashCode(); } if (node_ != null) { hash ^= Node.GetHashCode(); } hash ^= resourceNames_.GetHashCode(); if (TypeUrl.Length != 0) { hash ^= TypeUrl.GetHashCode(); } if (ResponseNonce.Length != 0) { hash ^= ResponseNonce.GetHashCode(); } if (errorDetail_ != null) { hash ^= ErrorDetail.GetHashCode(); } if (_unknownFields != null) { hash ^= _unknownFields.GetHashCode(); } return(hash); }
async public Task <ResponseAuthCookie> GenrateAuthCookie() { //get nonce ResponseNonce retNonce = await CallService <ResponseNonce, RequestNonce> (Settings.GetNonceAuthCookieUrl, HttpMethod.Get, new RequestNonce()); if (retNonce != null) { Settings.WP_AUTH_COOKIE_NONCE = retNonce.Nonce; Debug.WriteLine("done gen aut cookie " + Settings.WP_AUTH_COOKIE_NONCE); //generate auth cookie ResponseAuthCookie retAuthCookie = await CallService <ResponseAuthCookie, RequestAuthCookie> (Settings.GenerateAuthCookieUrl, HttpMethod.Post, new RequestAuthCookie()); Settings.WP_AuthCookie = retAuthCookie; Debug.WriteLine("WP Auth Cookie: {0} - {1} - {2}", retAuthCookie.User.Username, retAuthCookie.User.Displayname, retAuthCookie.Cookie); return(Settings.WP_AuthCookie); } else { return(null); } }