Beispiel #1
0
 /// <summary>
 /// 添加规则
 /// </summary>
 /// <param name="criterion"></param>
 public void Add(Criterion criterion)
 {
     _criteria.Add(criterion);
 }
Beispiel #2
0
 /// <summary>
 /// 添加规范
 /// </summary>
 /// <param name="criterion"></param>
 public void Add(Criterion criterion)
 {
     if (!IsNamedQuery())
     {
         _criteria.Add(criterion);
     }
     else
         throw new ApplicationException(
             "You cannot add additionalcriteria to named queries");
 }