Beispiel #1
0
        public String GetFirstElementColumnFullName()
        {
            if (isEmpty())
            {
                String msg = "This order-by clause is empty: " + ToString();
                throw new IllegalStateException(msg);
            }
            OrderByElement element = (OrderByElement)_orderByList.get(0);

            return(element.getColumnFullName());
        }
Beispiel #2
0
        public bool isSameOrderByColumn(String columnFullName)
        {
            String[] columnFullNameArray = columnFullName.Split('/');
            if (_orderByList.size() != columnFullNameArray.Length)
            {
                return(false);
            }
            int count = 0;

            foreach (String columnFullNameElement in columnFullNameArray)
            {
                OrderByElement element = (OrderByElement)_orderByList.get(count);
                if (!element.getColumnFullName().ToLower().Equals(columnFullNameElement.ToLower()))
                {
                    return(false);
                }
                count++;
            }
            return(true);
        }