Пример #1
0
 /// <summary>
 /// 添加参数,如果参数已存在则替换
 /// </summary>
 /// <param name="name">参数名</param>
 /// <param name="value">参数值</param>
 /// <param name="operator">运算符</param>
 public void Add(string name, object value, Operator? @operator = null)
 {
     if (string.IsNullOrWhiteSpace(name))
     {
         return;
     }
     name = _dialect.GetParamName(name);
     if (_params.ContainsKey(name))
     {
         _params.Remove(name);
     }
     _params.Add(name, GetValue(value, @operator));
 }