namespace Gatedge.K3Cloud.Utils.Common
{
///
/// 过滤条件项
///
public class FilterItem
{
//{"Left":"(","FieldName":"Field1","Compare":"67","Value":"111","Right":")","Logic":"0"}
///
/// 左连接符
///
public string Left { get; set; }
///
/// 字段名
///
public string FieldName { get; set; }
///
/// 比较符
///
public string Compare { get; set; }
///
/// 值
///
public string Value { get; set; }
///
/// 右连接符
///
public string Right { get; set; }
///
/// 逻辑控制符
///
public string Logic { get; set; }
///
/// 构造函数
///
public FilterItem()
{
Left = "";
Right = "";
Logic = "0";
FieldName = "";
Compare = "";
Value = "";
}
///
/// 生成并且的条件
///
///
///
///
public FilterItem(string fieldName, string compare, string value)
{
Left = "";
Right = "";
Logic = "0";
FieldName = fieldName;
Compare = compare;
Value = value;
}
///
/// 构造无左右连接符的过滤条件
///
///
///
///
///
public FilterItem(string fieldName, string compare, string value, string logic)
{
Left = "";
Right = "";
FieldName = fieldName;
Compare = compare;
Value = value;
Logic = logic;
}
///
/// 构造全属性过滤条件
///
public FilterItem(string left, string fieldName, string compare, string value, string right, string logic)
{
Left = left;
FieldName = fieldName;
Compare = compare;
Value = value;
Right = right;
Logic = logic;
}
}
}