public override bool Equals(object obj) { if (this == obj) { return(true); } CacheKey cacheKey = obj as CacheKey; if (cacheKey == null) { return(false); } return(AWSSDKUtils.AreEqual(new object[4] { ImmutableCredentials, RegionEndpoint, ServiceUrl, CacheType }, new object[4] { cacheKey.ImmutableCredentials, cacheKey.RegionEndpoint, cacheKey.ServiceUrl, cacheKey.CacheType })); }
public override bool Equals(object obj) { if (object.ReferenceEquals(this, obj)) { return(true); } var po = obj as CredentialProfileOptions; if (po == null) { return(false); } #if !BCL35 && !NETSTANDARD13 return(AWSSDKUtils.AreEqual( new object[] { AccessKey, EndpointName, ExternalID, MfaSerial, RoleArn, RoleSessionName, SecretKey, SourceProfile, Token, UserIdentity, CredentialProcess, WebIdentityTokenFile, SsoAccountId, SsoRegion, SsoRoleName, SsoStartUrl }, new object[] { po.AccessKey, po.EndpointName, po.ExternalID, po.MfaSerial, po.RoleArn, po.RoleSessionName, po.SecretKey, po.SourceProfile, po.Token, po.UserIdentity, po.CredentialProcess, po.WebIdentityTokenFile, SsoAccountId, SsoRegion, SsoRoleName, SsoStartUrl })); #elif BCL35 return(AWSSDKUtils.AreEqual( new object[] { AccessKey, EndpointName, ExternalID, MfaSerial, RoleArn, RoleSessionName, SecretKey, SourceProfile, Token, UserIdentity, CredentialProcess, WebIdentityTokenFile }, new object[] { po.AccessKey, po.EndpointName, po.ExternalID, po.MfaSerial, po.RoleArn, po.RoleSessionName, po.SecretKey, po.SourceProfile, po.Token, po.UserIdentity, po.CredentialProcess, po.WebIdentityTokenFile })); #else return(AWSSDKUtils.AreEqual( new object[] { AccessKey, ExternalID, MfaSerial, RoleArn, RoleSessionName, SecretKey, SourceProfile, Token, CredentialProcess, WebIdentityTokenFile }, new object[] { po.AccessKey, po.ExternalID, po.MfaSerial, po.RoleArn, po.RoleSessionName, po.SecretKey, po.SourceProfile, po.Token, po.CredentialProcess, po.WebIdentityTokenFile })); #endif }
public static void Clear(object cacheType) { lock (cacheLock) { foreach (CacheKey key in cache.Keys) { if (AWSSDKUtils.AreEqual(key.CacheType, cacheType)) { cache.GetValue(key, null).Clear(); } } } }
public override bool Equals(object obj) { if (object.ReferenceEquals(this, obj)) { return(true); } var bac = obj as BasicAWSCredentials; if (bac == null) { return(false); } return(AWSSDKUtils.AreEqual( new object[] { _credentials }, new object[] { bac._credentials })); }
public override bool Equals(object obj) { if (object.ReferenceEquals(this, obj)) { return(true); } AssumeRoleImmutableCredentials aric = obj as AssumeRoleImmutableCredentials; if (aric == null) { return(false); } return(AWSSDKUtils.AreEqual( new object[] { AccessKey, SecretKey, Token, Expiration }, new object[] { aric.AccessKey, aric.SecretKey, aric.Token, Expiration })); }
public override bool Equals(object obj) { if (object.ReferenceEquals(this, obj)) { return(true); } ImmutableCredentials ic = obj as ImmutableCredentials; if (ic == null) { return(false); } return(AWSSDKUtils.AreEqual( new object[] { AccessKey, SecretKey, Token }, new object[] { ic.AccessKey, ic.SecretKey, ic.Token })); }
public override bool Equals(object obj) { if (object.ReferenceEquals(this, obj)) { return(true); } var sac = obj as SessionAWSCredentials; if (sac == null) { return(false); } return(AWSSDKUtils.AreEqual( new object[] { _lastCredentials }, new object[] { sac._lastCredentials })); }
public override bool Equals(object obj) { if (object.ReferenceEquals(this, obj)) { return(true); } SSOImmutableCredentials ssoImmutableCredentials = obj as SSOImmutableCredentials; if (ssoImmutableCredentials == null) { return(false); } return(AWSSDKUtils.AreEqual( new object[] { AccessKey, SecretKey, Token, Expiration }, new object[] { ssoImmutableCredentials.AccessKey, ssoImmutableCredentials.SecretKey, ssoImmutableCredentials.Token, Expiration })); }
public override bool Equals(object obj) { if (object.ReferenceEquals(this, obj)) { return(true); } var p = obj as CredentialProfile; if (p == null) { return(false); } return(AWSSDKUtils.AreEqual( new object[] { Name, Options, Region, ProfileType, CanCreateAWSCredentials, UniqueKey }, new object[] { p.Name, p.Options, p.Region, p.ProfileType, p.CanCreateAWSCredentials, p.UniqueKey }) && AWSSDKUtils.DictionariesAreEqual(Properties, p.Properties)); }
public override bool Equals(object obj) { if (object.ReferenceEquals(this, obj)) { return(true); } CacheKey ck = obj as CacheKey; if (ck == null) { return(false); } var allEqual = AWSSDKUtils.AreEqual( new object[] { this.ImmutableCredentials, this.RegionEndpoint, this.ServiceUrl, this.CacheType }, new object[] { ck.ImmutableCredentials, ck.RegionEndpoint, ck.ServiceUrl, ck.CacheType }); return(allEqual); }
public override bool Equals(object obj) { if (object.ReferenceEquals(this, obj)) { return(true); } var po = obj as CredentialProfileOptions; if (po == null) { return(false); } #if BCL return(AWSSDKUtils.AreEqual( new object[] { AccessKey, EndpointName, ExternalID, MfaSerial, RoleArn, SecretKey, SourceProfile, Token, UserIdentity }, new object[] { po.AccessKey, po.EndpointName, po.ExternalID, po.MfaSerial, po.RoleArn, po.SecretKey, po.SourceProfile, po.Token, po.UserIdentity })); #else return(AWSSDKUtils.AreEqual( new object[] { AccessKey, ExternalID, MfaSerial, RoleArn, SecretKey, SourceProfile, Token }, new object[] { po.AccessKey, po.ExternalID, po.MfaSerial, po.RoleArn, po.SecretKey, po.SourceProfile, po.Token })); #endif }
public override bool Equals(object obj) { if (this == obj) { return(true); } ImmutableCredentials immutableCredentials = obj as ImmutableCredentials; if (immutableCredentials == null) { return(false); } return(AWSSDKUtils.AreEqual(new object[3] { AccessKey, SecretKey, Token }, new object[3] { immutableCredentials.AccessKey, immutableCredentials.SecretKey, immutableCredentials.Token })); }