public static DateTimeOffset GetSelfExcusionEndDate(SelfExclusion selfEclusionType, DateTimeOffset startDate) { switch (selfEclusionType) { case SelfExclusion.Permanent: return(DateTimeOffset.MaxValue); case SelfExclusion._6months: return(startDate.AddMonths(6)); case SelfExclusion._1Year: return(startDate.AddYears(1)); case SelfExclusion._5Years: return(startDate.AddYears(5)); default: return(DateTimeOffset.MinValue); } }
public PlayerSelfExcluded(Guid playerId, SelfExclusion selfExclusion, DateTimeOffset selfExclusionEndDate) { PlayerId = playerId; SelfExclusionType = selfExclusion.ToString(); SelfExclusionEndDate = selfExclusionEndDate; }
public DateTimeOffset GetSelfExclusionEndDate(SelfExclusion exclusionType, DateTimeOffset startDate) { return(ExclusionDateHelper.GetSelfExcusionEndDate(exclusionType, startDate)); }