Example #1
0
        public bool Equals(DestinyMilestoneActivityPhase input)
        {
            if (input == null)
            {
                return(false);
            }

            return
                ((
                     Complete == input.Complete ||
                     (Complete != null && Complete.Equals(input.Complete))
                     ) &&
                 (
                     PhaseHash == input.PhaseHash ||
                     (PhaseHash.Equals(input.PhaseHash))
                 ));
        }
Example #2
0
        /// <summary>
        ///     Returns true if MarketDefinition instances are equal
        /// </summary>
        /// <param name="other">Instance of MarketDefinition to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(MarketDefinition other)
        {
            // credit: http://stackoverflow.com/a/10454552/677735
            if (other == null)
            {
                return(false);
            }

            return((Venue == other.Venue || Venue != null && Venue.Equals(other.Venue)) &&
                   (SettledTime == other.SettledTime || SettledTime != null && SettledTime.Equals(other.SettledTime)) &&
                   (Timezone == other.Timezone || Timezone != null && Timezone.Equals(other.Timezone)) &&
                   (EachWayDivisor == other.EachWayDivisor || EachWayDivisor != null && EachWayDivisor.Equals(other.EachWayDivisor)) &&
                   (Regulators == other.Regulators || Regulators != null && Regulators.SequenceEqual(other.Regulators)) &&
                   (MarketType == other.MarketType || MarketType != null && MarketType.Equals(other.MarketType)) &&
                   (MarketBaseRate == other.MarketBaseRate || MarketBaseRate != null && MarketBaseRate.Equals(other.MarketBaseRate)) &&
                   (NumberOfWinners == other.NumberOfWinners || NumberOfWinners != null && NumberOfWinners.Equals(other.NumberOfWinners)) &&
                   (CountryCode == other.CountryCode || CountryCode != null && CountryCode.Equals(other.CountryCode)) &&
                   (InPlay == other.InPlay || InPlay != null && InPlay.Equals(other.InPlay)) &&
                   (BetDelay == other.BetDelay || BetDelay != null && BetDelay.Equals(other.BetDelay)) &&
                   (BspMarket == other.BspMarket || BspMarket != null && BspMarket.Equals(other.BspMarket)) &&
                   (BettingType == other.BettingType || BettingType != null && BettingType.Equals(other.BettingType)) &&
                   (NumberOfActiveRunners == other.NumberOfActiveRunners || NumberOfActiveRunners != null && NumberOfActiveRunners.Equals(other.NumberOfActiveRunners)) &&
                   (EventId == other.EventId || EventId != null && EventId.Equals(other.EventId)) &&
                   (CrossMatching == other.CrossMatching || CrossMatching != null && CrossMatching.Equals(other.CrossMatching)) &&
                   (RunnersVoidable == other.RunnersVoidable || RunnersVoidable != null && RunnersVoidable.Equals(other.RunnersVoidable)) &&
                   (TurnInPlayEnabled == other.TurnInPlayEnabled || TurnInPlayEnabled != null && TurnInPlayEnabled.Equals(other.TurnInPlayEnabled)) &&
                   (SuspendTime == other.SuspendTime || SuspendTime != null && SuspendTime.Equals(other.SuspendTime)) &&
                   (DiscountAllowed == other.DiscountAllowed || DiscountAllowed != null && DiscountAllowed.Equals(other.DiscountAllowed)) &&
                   (PersistenceEnabled == other.PersistenceEnabled || PersistenceEnabled != null && PersistenceEnabled.Equals(other.PersistenceEnabled)) &&
                   (Runners == other.Runners || Runners != null && Runners.SequenceEqual(other.Runners)) &&
                   (Version == other.Version || Version != null && Version.Equals(other.Version)) &&
                   (EventTypeId == other.EventTypeId || EventTypeId != null && EventTypeId.Equals(other.EventTypeId)) &&
                   (Complete == other.Complete || Complete != null && Complete.Equals(other.Complete)) &&
                   (OpenDate == other.OpenDate || OpenDate != null && OpenDate.Equals(other.OpenDate)) &&
                   (MarketTime == other.MarketTime || MarketTime != null && MarketTime.Equals(other.MarketTime)) &&
                   (BspReconciled == other.BspReconciled || BspReconciled != null && BspReconciled.Equals(other.BspReconciled)) &&
                   (Status == other.Status || Status != null && Status.Equals(other.Status)));
        }
Example #3
0
        public bool Equals(DestinyObjectiveProgress input)
        {
            if (input == null)
            {
                return(false);
            }

            return
                ((
                     ObjectiveHash == input.ObjectiveHash ||
                     (ObjectiveHash.Equals(input.ObjectiveHash))
                     ) &&
                 (
                     DestinationHash == input.DestinationHash ||
                     (DestinationHash.Equals(input.DestinationHash))
                 ) &&
                 (
                     ActivityHash == input.ActivityHash ||
                     (ActivityHash.Equals(input.ActivityHash))
                 ) &&
                 (
                     Progress == input.Progress ||
                     (Progress.Equals(input.Progress))
                 ) &&
                 (
                     CompletionValue == input.CompletionValue ||
                     (CompletionValue.Equals(input.CompletionValue))
                 ) &&
                 (
                     Complete == input.Complete ||
                     (Complete != null && Complete.Equals(input.Complete))
                 ) &&
                 (
                     Visible == input.Visible ||
                     (Visible != null && Visible.Equals(input.Visible))
                 ));
        }