DD.WellWorkover.Cloud/AsbCloudApp/Data/SimpleTimezoneDto.cs
2022-06-02 12:35:51 +05:00

40 lines
1.0 KiB
C#

namespace AsbCloudApp.Data
{
/// <summary>
/// âðåìåííàÿ çîíà
/// </summary>
public class SimpleTimezoneDto
{
/// <summary>
/// ñìåùåíèå â ÷àñàõ îòíîñèòåëüíî UTC
/// </summary>
public double Hours { get; set; }
/// <summary>
/// èäåíòèôèêàòîð ÷àñîâîé çîíû
/// </summary>
public string TimezoneId { get; set; }
/// <summary>
/// çàïðåò íà ïåðåîïðåäåëåíèå
/// </summary>
public bool IsOverride { get; set; }
/// <inheritdoc/>
public override bool Equals(object obj)
{
if (obj is SimpleTimezoneDto tTimeZone
&& tTimeZone.Hours == Hours
&& tTimeZone.TimezoneId == TimezoneId
&& tTimeZone.IsOverride == IsOverride)
return true;
return false;
}
/// <inheritdoc/>
public override int GetHashCode()
=> Hours.GetHashCode()
| TimezoneId.GetHashCode()
| IsOverride.GetHashCode();
}
}