怎么进行自动匹配
我有一个枚举类型
public enum Operator
{
// 摘要:
// 类似(LIKE '%value%')
Like = 0,
//
// 摘要:
// 左类似(LIKE 'value%')
LLike = 1,
//
// 摘要:
// 右类似(LIKE '%value')
RLike = 2,
//
// 摘要:
// 不类似(NOT LIKE '%value%')
NLike = 3,
//
// 摘要:
// 左不类似(NOT LIKE 'value%')
NLLike = 4,
//
// 摘要:
// 右不类似(NOT LIKE '%value')
NRLike = 5,
//
// 摘要:
// 等于
EQ = 6,
//
// 摘要:
// 不等于
NE = 7,
//
// 摘要:
// 大于
GT = 8,
//
// 摘要:
// 大于等于
GE = 9,
//
// 摘要:
// 小于
LT = 10,
//
// 摘要:
// 小于等于
LE = 11,
Entity.opreator=6
Entity.opreator=Operator.(str)
Entity.opreator= (Operator)Enum.Parse(typeof(Operator),"EQ");
int i = (int)(Operator)Enum.Parse(typeof(Operator), "EQ");