예제 #1
0
        public bool Equals(AssetPair other, bool eitherDirection)
        {
            if (!eitherDirection)
            {
                return(Equals(other));
            }

            return(Equals(other) || (Asset1.Equals(other.Asset2) && Asset2.Equals(other.Asset1)));
        }
예제 #2
0
 public Asset Other(Asset asset)
 {
     return(Asset1.Equals(asset) ? Asset2 : Asset1);
 }
예제 #3
0
 public bool Has(Asset asset)
 {
     return(Asset1.Equals(asset) || Asset2.Equals(asset));
 }
예제 #4
0
 public bool Equals(AssetPair other)
 {
     return(Asset1.Equals(other.Asset1) && Asset2.Equals(other.Asset2));
 }