Package com.vividsolutions.jts.util

Examples of com.vividsolutions.jts.util.Stopwatch.stop()


                        largerPoints = Math.max(largerPoints, shape.getNumOfPoints());
                    }
                }
                row = query.fetch();
            }
            sw.stop();
        } finally {
            query.close();
        }
        log("\t- " + featureCount + " features iterated in " + sw.getTimeString());
        log("\t\t- total poinst: " + totalPoints + ", larger geometry: " + largerPoints + " points"
View Full Code Here


                        value = row.getObject(i);
                    }
                }
                row = query.fetch();
            }
            sw.stop();
        } finally {
            query.close();
        }
        log("\t- " + featureCount + " features iterated in " + sw.getTimeString());
        log("\t\t- total poinst: " + totalPoints + ", larger geometry: " + largerPoints
View Full Code Here

                defaultGeometry = (Geometry) feature.getDefaultGeometry();
                npoints = defaultGeometry == null ? 0 : defaultGeometry.getNumPoints();
                totalPoints += npoints;
                largerPoints = Math.max(largerPoints, npoints);
            }
            sw.stop();
        } finally {
            iterator.close();
        }
        log("\t- " + featureCount + " features iterated in " + sw.getTimeString());
        log("\t\t- total poinst: " + totalPoints + ", larger geometry: " + largerPoints
View Full Code Here

        Stopwatch sw = new Stopwatch();
        long totalTime = 0;
        for (int i = 0; i < numRuns; i++) {
            sw.start();
            renderer.paint(graphics, paintArea, mapArea);
            sw.stop();
            totalTime += sw.getTime();
            log("Layer rendered in " + sw.getTimeString());
            sw.reset();
            File output = new File("testRender.png");
            log("writing rendered image to " + output.getAbsolutePath());
View Full Code Here

    @BeforeClass
    public static void setUpBeforeClass() throws Exception {
        Stopwatch sw = new Stopwatch();
        sw.start();
        loadDataAccesses();
        sw.stop();
        System.out.println("Set up time: " + sw.getTimeString());
    }

    /**
     * Test that chaining works
View Full Code Here

    @BeforeClass
    public static void setUpBeforeClass() throws Exception {
        Stopwatch sw = new Stopwatch();
        sw.start();
        loadDataAccesses();
        sw.stop();
        System.out.println("Set up time: " + sw.getTimeString());
    }

    /**
     * Basic test to make sure everything got loaded correctly
View Full Code Here

        final GridCoverage2D coverage = readCoverage(reader, reqWidth, reqHeight, reqEnvelope);
        assertNotNull("read coverage returned null", coverage);

        RenderedImage image = coverage.getRenderedImage();
        writeToDisk(image, "testRead_" + tableName);
        sw.stop();
        return sw.getTime();
    }

    @Test
    public void testIMG_USGSQUAD_SGBASE2() throws Exception {
View Full Code Here

                            // RenderedImage image =
                            // coverage.view(ViewType.NATIVE).getRenderedImage();
                            Stopwatch sw = new Stopwatch();
                            sw.start();
                            writeToDisk(image, "testRead_" + tableName);
                            sw.stop();
                            long memMB = (Runtime.getRuntime().totalMemory() - Runtime.getRuntime()
                                    .freeMemory()) / 1024 / 1024;
                            System.err.println("wrote #" + writeCount.incrementAndGet() + " in "
                                    + sw.getTimeString() + ": Mem: " + memMB + "M. Thread: "
                                    + Thread.currentThread().getName() + ", iteration #" + i);
View Full Code Here

        threadPool.shutdown();
        while (!threadPool.isTerminated()) {
            Thread.sleep(100);
        }
        sw.stop();
        System.err.println("____ Finished in " + sw.getTimeString() + ". Min: " + stats[0]
                + ", Max: " + stats[1] + ", total execution time: " + stats[2] + ", Avg: "
                + (stats[2] / (threads * count)) + ". Max mem: " + stats[3] + "MB");
        System.err.println("__________________\n  SNAPSHOT!!!!!!!!");
        // Thread.sleep(5000);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.