/// <exclude />
        public static DataFieldTreeOrderingProfile FromString(string str)
        {
            var parts = str.Split(',');
            int priority;
            bool order;

            DataFieldTreeOrderingProfile treeOrderingProfile = new DataFieldTreeOrderingProfile();

            if (int.TryParse(parts[0], out priority))
                treeOrderingProfile.OrderPriority = priority;

            if (parts.Length > 1 && bool.TryParse(parts[1], out order))
                treeOrderingProfile.OrderDescending = order;

            return treeOrderingProfile;
        }
예제 #2
0
        /// <exclude />
        public static DataFieldTreeOrderingProfile FromString(string str)
        {
            var  parts = str.Split(',');
            int  priority;
            bool order;

            DataFieldTreeOrderingProfile treeOrderingProfile = new DataFieldTreeOrderingProfile();

            if (int.TryParse(parts[0], out priority))
            {
                treeOrderingProfile.OrderPriority = priority;
            }

            if (parts.Length > 1 && bool.TryParse(parts[1], out order))
            {
                treeOrderingProfile.OrderDescending = order;
            }

            return(treeOrderingProfile);
        }