/// <summary> /// /// </summary> /// <returns></returns> public override string ToString() { return (string.Format(CultureInfo.InvariantCulture, "Authority:{0}, Scope:{1}, ClientId:{2}, UniqueId:{3}, DisplayableId:{4}, HomeObjectId:{5}, Policy:{6}", this.Authority, MsalStringHelper.AsSingleString(this.Scope.ToArray()), this.ClientId, this.UniqueId, this.DisplayableId, this.HomeObjectId, this.Policy)); }
/// <summary> /// Returns the hash code for this TokenCacheKey. /// </summary> /// <returns> /// A 32-bit signed integer hash code. /// </returns> public override int GetHashCode() { const string Delimiter = ":::"; return((this.Authority + Delimiter + MsalStringHelper.AsSingleString(this.Scope) + Delimiter + this.ClientId.ToLower() + Delimiter + this.UniqueId + Delimiter + this.HomeObjectId + Delimiter + ((this.DisplayableId != null) ? this.DisplayableId.ToLower() : null) + Delimiter + ((this.Policy != null) ? this.Policy.ToLower() : null)).GetHashCode()); }