Package org.geotools.data

Examples of org.geotools.data.QueryCapabilities


            SimpleFeatureSource featureSource = (SimpleFeatureSource) resource.getFeatureSource(
                    null, null);
            Query query = buildQuery(request, featureSource.getSchema());
           
            // couple sanity checks
            final QueryCapabilities queryCapabilities = featureSource.getQueryCapabilities();
            if(!queryCapabilities.isOffsetSupported() && (query.getStartIndex() != null && query.getStartIndex() > 1)) {
                throw new RestletException("Offset is not supported on this data source", Status.SERVER_ERROR_INTERNAL);
            }
           
            SimpleFeatureCollection features = featureSource.getFeatures(query);
View Full Code Here


              }

                // check for startIndex + offset
                final Integer startIndex = request.getStartIndex();
                if (startIndex != null) {
                    QueryCapabilities queryCapabilities = source.getQueryCapabilities();
                    if (queryCapabilities.isOffsetSupported()) {
                        // fsource is required to support
                        // SortBy.NATURAL_ORDER so we don't bother checking
                        definitionQuery.setStartIndex(startIndex);
                    } else {
                        // source = new PagingFeatureSource(source,
View Full Code Here

TOP

Related Classes of org.geotools.data.QueryCapabilities

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.