public bool Assign(string str) { int l = str.Length; if (l == 0) { str = "0"; } if (strIsValue(str, l)) { vtype = QuestTCPVType.vtExt; vd.Clear(); if (!double.TryParse(str.Replace(',', '.'), out vf)) { vf = 0; } return(true); } if ((l > 1) && (str[0] == '[') && (str[l - 1] == ']')) { char[] chs = { 'h', ';', '[', ']', '-' }; for (int i = 0; i < l; i++) { char c = str[i]; if (((c >= '0') && (c <= '9')) || chs.Contains(c)) { continue; } return(false); } vtype = QuestTCPVType.vtRange; vd.Assign(str); vf = 0; return(true); } return(false); }
public void CopyDataFrom(QuestTCPVariant source) { vd.CopyDataFrom(source.vd); vf = source.vf; vtype = source.vtype; }
public void Clear() { vf = 0; vd.Clear(); vtype = QuestTCPVType.vtExt; }