Examples of countUnstaged()


Examples of org.locationtech.geogig.repository.WorkingTree.countUnstaged()

        File file = new File(filename);
        geogig.command(OSMImportOp.class).setDataSource(file.getAbsolutePath()).call();
        WorkingTree workTree = geogig.getRepository().workingTree();
        long unstaged = workTree.countUnstaged("way").count();
        assertTrue(unstaged > 0);
        unstaged = workTree.countUnstaged("node").count();
        assertTrue(unstaged > 0);
        geogig.command(AddOp.class).call();
        geogig.command(CommitOp.class).setMessage("msg").call();

        // Define mapping
View Full Code Here

Examples of org.locationtech.geogig.repository.WorkingTree.countUnstaged()

        // unmap without having made any changes and check that the canonical folders are not
        // modified
        geogig.command(OSMUnmapOp.class).setPath("busstops").call();
        WorkingTree workTree = geogig.getRepository().workingTree();
        long unstaged = workTree.countUnstaged("way").count();
        assertEquals(0, unstaged);
        unstaged = workTree.countUnstaged("node").count();
        assertEquals(0, unstaged);

        // Modify a node
View Full Code Here

Examples of org.locationtech.geogig.repository.WorkingTree.countUnstaged()

        // modified
        geogig.command(OSMUnmapOp.class).setPath("busstops").call();
        WorkingTree workTree = geogig.getRepository().workingTree();
        long unstaged = workTree.countUnstaged("way").count();
        assertEquals(0, unstaged);
        unstaged = workTree.countUnstaged("node").count();
        assertEquals(0, unstaged);

        // Modify a node
        GeometryFactory gf = new GeometryFactory();
        SimpleFeatureBuilder fb = new SimpleFeatureBuilder((SimpleFeatureType) featureType.get()
View Full Code Here

Examples of org.locationtech.geogig.repository.WorkingTree.countUnstaged()

        assertEquals("newname", values.get(1).get().toString());

        // unmap
        geogig.command(OSMUnmapOp.class).setPath("busstops").call();

        unstaged = workTree.countUnstaged("node").featureCount();
        assertEquals(1, unstaged);

        // check that the unmapped node has the changes we introduced
        Optional<RevFeature> unmapped = geogig.command(RevObjectParse.class)
                .setRefSpec("WORK_HEAD:node/507464799").call(RevFeature.class);
View Full Code Here

Examples of org.locationtech.geogig.repository.WorkingTree.countUnstaged()

        // unmap
        geogig.command(OSMUnmapOp.class).setPath("busstops").call();

        WorkingTree workTree = geogig.getRepository().workingTree();
        long unstaged = workTree.countUnstaged("node").featureCount();
        assertEquals(1, unstaged);

        // check that the unmapped node has the changes we introduced
        Optional<RevFeature> unmapped = geogig.command(RevObjectParse.class)
                .setRefSpec("WORK_HEAD:node/507464799").call(RevFeature.class);
View Full Code Here

Examples of org.locationtech.geogig.repository.WorkingTree.countUnstaged()

        // unmap without having made any changes and check that the canonical folders are not
        // modified
        WorkingTree workTree = geogig.getRepository().workingTree();
        geogig.command(OSMUnmapOp.class)/* .setMapping(mapping) */.setPath("residential").call();
        long unstaged = workTree.countUnstaged("way").count();
        assertEquals(0, unstaged);
        unstaged = workTree.countUnstaged("node").count();
        assertEquals(0, unstaged);

        // modify a mapped feature. We change the value of 'name_alias' tag to "newvalue"
View Full Code Here

Examples of org.locationtech.geogig.repository.WorkingTree.countUnstaged()

        // modified
        WorkingTree workTree = geogig.getRepository().workingTree();
        geogig.command(OSMUnmapOp.class)/* .setMapping(mapping) */.setPath("residential").call();
        long unstaged = workTree.countUnstaged("way").count();
        assertEquals(0, unstaged);
        unstaged = workTree.countUnstaged("node").count();
        assertEquals(0, unstaged);

        // modify a mapped feature. We change the value of 'name_alias' tag to "newvalue"
        ArrayList<Coordinate> coords = Lists.newArrayList(((Geometry) values.get(2).get())
                .getCoordinates());
View Full Code Here

Examples of org.locationtech.geogig.repository.WorkingTree.countUnstaged()

        StagingArea index = index();

        StatusSummary summary = new StatusSummary();

        summary.countStaged = index.countStaged(null).count();
        summary.countUnstaged = workTree.countUnstaged(null).count();
        summary.countConflicted = index.countConflicted(null);

        if (summary.countStaged > 0) {
            summary.staged = command(DiffIndex.class).setReportTrees(true);
        }
View Full Code Here

Examples of org.locationtech.geogig.repository.WorkingTree.countUnstaged()

        WorkingTree workTree = op.setUpdateOnly(updateOnly)
                .setProgressListener(cli.getProgressListener()).call();

        DiffObjectCount staged = geogig.getRepository().index().countStaged(null);
        unstaged = workTree.countUnstaged(null);

        console.println(staged.featureCount() + " features and " + staged.treeCount()
                + " trees staged for commit");
        console.println(unstaged.featureCount() + " features and " + unstaged.treeCount()
                + " trees not staged for commit");
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.