Package org.apache.solr.client.solrj.SolrQuery

Examples of org.apache.solr.client.solrj.SolrQuery.ORDER


            SortOrder sortOrder = sort.getSortOrder();

            if (sortByResolved != null && sortOrder != null)
            {
                ORDER solrSortOrder = null;
                switch (sortOrder)
                {
                case ASCENDING:
                    solrSortOrder = ORDER.asc;
                    break;
View Full Code Here


            for (String sortField : sortFields) {
                String field = sortField.split(" ")[0];
                if (solrFieldKeyMap.containsKey(field)) {
                    field = solrFieldKeyMap.get(field);
                }
                ORDER order = "desc".equals(sortField.split(" ")[1]) ? ORDER.desc : ORDER.asc;

                if (field != null) {
                    query.addSortField(field, order);
                }
            }
View Full Code Here

            if (q.getMaxFeatures() > 0) {
                query.setRows(q.getMaxFeatures());
            }

            // Sort
            ORDER naturalSortOrder = ORDER.asc;
            if (q.getSortBy() != null) {
                for (SortBy sort : q.getSortBy()) {
                    if (sort.getPropertyName() != null) {
                        query.addSort(sort.getPropertyName().getPropertyName(), sort.getSortOrder()
                                .equals(SortOrder.ASCENDING) ? ORDER.asc : ORDER.desc);
View Full Code Here

TOP

Related Classes of org.apache.solr.client.solrj.SolrQuery.ORDER

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.