public int ToInt() { switch (Type.GetTypeCode(m_value.GetType())) { case TypeCode.UInt32: return (int)((uint)m_value); case TypeCode.Int32: return (int)m_value; } return Convert.ToInt32(m_value); }