Package org.apache.syncope.common.search

Examples of org.apache.syncope.common.search.OrderByClauseBuilder


     * Returns a new instance of <tt>OrderByClauseBuilder</tt>, for assisted building of <tt>orderby</tt> clauses.
     *
     * @return default instance of <tt>OrderByClauseBuilder</tt>
     */
    public static OrderByClauseBuilder getOrderByClauseBuilder() {
        return new OrderByClauseBuilder();
    }
View Full Code Here


    protected <T> void resetClient(final Class<T> serviceClass) {
        SyncopeSession.get().resetClient(serviceClass);
    }

    protected String toOrderBy(final SortParam<String> sort) {
        OrderByClauseBuilder builder = SyncopeClient.getOrderByClauseBuilder();

        String property = sort.getProperty();
        if (property.indexOf('#') != -1) {
            property = property.substring(property.indexOf('#') + 1);
        }

        if (sort.isAscending()) {
            builder.asc(property);
        } else {
            builder.desc(property);
        }

        return builder.build();
    }
View Full Code Here

TOP

Related Classes of org.apache.syncope.common.search.OrderByClauseBuilder

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.