public static string PortParityTypeToUIStr(EPortParityType type) { switch (type) { case EPortParityType.ENone: return(CS_PortParityType_None_UIStr); case EPortParityType.EOdd: return(CS_PortParityType_Odd_UIStr); case EPortParityType.EEven: return(CS_PortParityType_Even_UIStr); } throw new Exception("PortParityTypeToUIStr Error"); }
public static char PortParityTypeToDBChar(EPortParityType type) { switch (type) { case EPortParityType.ENone: return(CS_PortParityType_None_DBChar); case EPortParityType.EOdd: return(CS_PortParityType_Odd_DBChar); case EPortParityType.EEven: return(CS_PortParityType_Even_DBChar); } throw new Exception("PortParityTypeToDBChar Error"); }