Example #1
0
 public override int GetHashCode()
 {
     unchecked
     {
         var hashCode = (Category != null ? Category.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (CateringCode != null ? CateringCode.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (ConnectionIndicator != null ? ConnectionIndicator.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (CourseIndicator != null ? CourseIndicator.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (HeadCode != null ? HeadCode.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (OperatingCharacteristics != null ? OperatingCharacteristics.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (PortionId != null ? PortionId.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (PowerType != null ? PowerType.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (int)RecordIdentity;
         hashCode = (hashCode * 397) ^ (int)Reservations;
         hashCode = (hashCode * 397) ^ (Rsid != null ? Rsid.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (int)SeatingClass;
         hashCode = (hashCode * 397) ^ (ServiceBranding != null ? ServiceBranding.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (ServiceCode != null ? ServiceCode.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (int)Sleepers;
         hashCode = (hashCode * 397) ^ Speed;
         hashCode = (hashCode * 397) ^ (TimingLoad != null ? TimingLoad.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (Tiploc != null ? Tiploc.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (TiplocSuffix != null ? TiplocSuffix.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (TrainIdentity != null ? TrainIdentity.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (UicCode != null ? UicCode.GetHashCode() : 0);
         return(hashCode);
     }
 }
Example #2
0
 public override int GetHashCode()
 {
     unchecked
     {
         var hashCode = (AtocCode != null ? AtocCode.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (AtsCode != null ? AtsCode.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (int)BankHolidayRunning;
         hashCode = (hashCode * 397) ^ (int)CateringCode;
         hashCode = (hashCode * 397) ^ (ConnectionIndicator != null ? ConnectionIndicator.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (CourseIndicator != null ? CourseIndicator.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (DataSource != null ? DataSource.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ DateRunsFrom.GetHashCode();
         hashCode = (hashCode * 397) ^ DateRunsTo.GetHashCode();
         hashCode = (hashCode * 397) ^ (HeadCode != null ? HeadCode.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (int)OperatingCharacteristics;
         hashCode = (hashCode * 397) ^ (OperatingCharacteristicsString != null ? OperatingCharacteristicsString.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (PortionId != null ? PortionId.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (int)PowerType;
         hashCode = (hashCode * 397) ^ (int)RecordIdentity;
         hashCode = (hashCode * 397) ^ (int)Reservations;
         hashCode = (hashCode * 397) ^ (Rsid != null ? Rsid.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (int)RunningDays;
         hashCode = (hashCode * 397) ^ (ScheduleLocations != null ? ScheduleLocations.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (int)SeatingClass;
         hashCode = (hashCode * 397) ^ (int)ServiceBranding;
         hashCode = (hashCode * 397) ^ (int)ServiceTypeFlags;
         hashCode = (hashCode * 397) ^ (int)Sleepers;
         hashCode = (hashCode * 397) ^ Speed;
         hashCode = (hashCode * 397) ^ (int)StpIndicator;
         hashCode = (hashCode * 397) ^ (TimingLoad != null ? TimingLoad.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (TrainCategory != null ? TrainCategory.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (TrainIdentity != null ? TrainIdentity.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (TrainServiceCode != null ? TrainServiceCode.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (TrainStatus != null ? TrainStatus.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (TrainUid != null ? TrainUid.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (UicCode != null ? UicCode.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (UniqueId != null ? UniqueId.GetHashCode() : 0);
         return(hashCode);
     }
 }