public int GetHashCode(ITransactionSourceKey obj) { if (obj is UtxoConfidentialSourceKey utxoConfidentialSourceKey) { return(utxoConfidentialSourceKey.KeyImage.GetHashCode()); } return(0); }
public bool Equals(ITransactionSourceKey other) { if (other is UtxoConfidentialSourceKey utxoConfidentialSourceKey) { return(KeyImage.Equals(utxoConfidentialSourceKey.KeyImage)); } return(false); }
public int GetHashCode(ITransactionSourceKey obj) { if (obj is AccountSourceKey accountSourceKey) { return(accountSourceKey.Signer.GetHashCode() ^ accountSourceKey.Height.GetHashCode()); } return(0); }
public bool Equals(ITransactionSourceKey other) { if (other is AccountSourceKey accountSourceKey) { return(Signer.Equals(accountSourceKey.Signer) && Height == accountSourceKey.Height); } return(false); }
public bool Equals(ITransactionSourceKey x, ITransactionSourceKey y) { if (x == null && y == null) { return(true); } if (x is UtxoConfidentialSourceKey utxoConfidentialSourceKey1 && y is UtxoConfidentialSourceKey utxoConfidentialSourceKey2) { return(utxoConfidentialSourceKey1.KeyImage.Equals(utxoConfidentialSourceKey2.KeyImage)); } return(false); }
public bool Equals(ITransactionSourceKey x, ITransactionSourceKey y) { if (x == null && y == null) { return(true); } if (x is AccountSourceKey accountSourceKey1 && y is AccountSourceKey accountSourceKey2) { return(accountSourceKey1.Signer.Equals(accountSourceKey2.Signer) && accountSourceKey1.Height == accountSourceKey2.Height); } return(false); }