promotionwindow.cs
来自「NHibernate NET开发者所需的」· CS 代码 · 共 35 行
CS
35 行
using System;
using System.Collections;
namespace NHibernate.Test.NHSpecificTest.NH464
{
public class PromotionWindow
{
private IList dates;
public PromotionWindow()
{
this.dates = new ArrayList();
}
public IList Dates
{
get { return dates; }
set { dates = value; }
}
public bool IsActive()
{
bool isActive = false;
DateTime today = DateTime.Today;
foreach (DateRange dateRange in dates)
{
isActive = dateRange.Contains(today);
if (isActive)
break;
}
return isActive;
}
}
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?