Package org.geowebcache.seed

Examples of org.geowebcache.seed.SeedRequest


        }

        TYPE type = GWCTask.TYPE.valueOf(form.getFirst("type").getValue().toUpperCase());

        final String layerName = tl.getName();
        SeedRequest sr = new SeedRequest(layerName, bounds, gridSetId, threadCount, zoomStart,
                zoomStop, format, type, fullParameters);

        TileRange tr = TileBreeder.createTileRange(sr, tl);

        GWCTask[] tasks;
        try {
            tasks = seeder.createTasks(tr, tl, sr.getType(), sr.getThreadCount(),
                    sr.getFilterUpdate());
        } catch (GeoWebCacheException e) {
            throw new RestletException(e.getMessage(), Status.SERVER_ERROR_INTERNAL);
        }

        seeder.dispatchTasks(tasks);
View Full Code Here


     */
    public void doPost(Request req, Response resp)
    throws RestletException, IOException {       
        String formatExtension = (String) req.getAttributes().get("extension");
       
        SeedRequest sr = null;
       
        XStream xs = xmlConfig.getConfiguredXStream(new XStream(new DomDriver()));
       
        if(formatExtension.equalsIgnoreCase("xml")) {
            sr = (SeedRequest) xs.fromXML(req.getEntity().getStream());
View Full Code Here

        int zoomStart;
        int zoomStop;
        zoomStart = gridSubset.getZoomStart();
        zoomStop = gridSubset.getZoomStop();
        final TYPE taskType = TRUNCATE;
        SeedRequest req = new SeedRequest(layer.getName(), bounds, gridSubset.getName(),
                threadCount, zoomStart, zoomStop, formatName, taskType, parameters);

        GWCTask[] tasks;
        try {
            TileRange tr = TileBreeder.createTileRange(req, layer);
View Full Code Here

        }

        TYPE type = GWCTask.TYPE.valueOf(form.getFirst("type").getValue().toUpperCase());

        final String layerName = tl.getName();
        SeedRequest sr = new SeedRequest(layerName, bounds, gridSetId, threadCount, zoomStart,
                zoomStop, format, type, fullParameters);

        TileRange tr = TileBreeder.createTileRange(sr, tl);

        GWCTask[] tasks;
        try {
            tasks = seeder.createTasks(tr, tl, sr.getType(), sr.getThreadCount(),
                    sr.getFilterUpdate());
        } catch (GeoWebCacheException e) {
            throw new RestletException(e.getMessage(), Status.SERVER_ERROR_INTERNAL);
        }

        seeder.dispatchTasks(tasks);
View Full Code Here

        resp.setEntity(rep);
    }

    protected void handleRequest(Request req, Response resp, Object obj) {
        final SeedRequest sr = (SeedRequest) obj;
        String layerName = null;
        try {
            layerName = URLDecoder.decode((String) req.getAttributes().get("layer"), "UTF-8");
        } catch (UnsupportedEncodingException uee) {
        }
View Full Code Here

            int zoomStop) {
        String gridSet = tl.getGridSubsets().iterator().next();
        BoundingBox bounds = null;
        int threadCount = 1;
        String format = tl.getMimeTypes().get(0).getFormat();
        SeedRequest req = new SeedRequest(tl.getName(), bounds, gridSet, threadCount, zoomStart,
                zoomStop, format, type, null);
        return req;

    }
View Full Code Here

    public void testMinMaxCacheSeedTile() throws Exception {
        WMSLayer tl = createWMSLayer("image/png", 5, 6);
       
        MockTileSupport mock = new MockTileSupport(tl);

        SeedRequest req = createRequest(tl, GWCTask.TYPE.SEED, 4, 7);
        TileRange tr = TileBreeder.createTileRange(req, tl);
       
        seedTiles(mock.storageBroker, tr, tl);
       
        // zero transient cache attempts
View Full Code Here

        WMSLayer tl = createWMSLayer("image/png", 5, 6);

        MockTileSupport mock = new MockTileSupport(tl);

        // we're not really seeding, just using the range
        SeedRequest req = createRequest(tl, GWCTask.TYPE.SEED, 4, 7);
        TileRange tr = TileBreeder.createTileRange(req, tl);

        List<ConveyorTile> tiles = getTiles(mock.storageBroker, tr, tl);

        // this number is determined by our tileRange minus those out of bounds
View Full Code Here

TOP

Related Classes of org.geowebcache.seed.SeedRequest

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.