Package org.opentripplanner.updater

Examples of org.opentripplanner.updater.GraphWriterRunnable


    }

    @Override
    public void setup() throws InterruptedException, ExecutionException {
        // Create a realtime data snapshot source and wait for runnable to be executed
        updaterManager.executeBlocking(new GraphWriterRunnable() {
            @Override
            public void run(Graph graph) {
                // Only create a realtime data snapshot source if none exists already
                if (graph.timetableSnapshotSource == null) {
                    TimetableSnapshotSource snapshotSource = new TimetableSnapshotSource(graph);
View Full Code Here


    }

    @Override
    public void setup() throws InterruptedException, ExecutionException {
        // Create a realtime data snapshot source and wait for runnable to be executed
        updaterManager.executeBlocking(new GraphWriterRunnable() {
            @Override
            public void run(Graph graph) {
                // Only create a realtime data snapshot source if none exists already
                TimetableSnapshotSource snapshotSource = graph.timetableSnapshotSource;
                if (snapshotSource == null) {
View Full Code Here

        // Creation of network linker library will not modify the graph
        networkLinkerLibrary = new NetworkLinkerLibrary(graph,
                Collections.<Class<?>, Object> emptyMap());

        // Adding a bike rental station service needs a graph writer runnable
        updaterManager.executeBlocking(new GraphWriterRunnable() {
            @Override
            public void run(Graph graph) {
                service = graph.getService(BikeRentalStationService.class, true);
            }
        });
View Full Code Here

    public void setup() {
        LOG.info("Setup example updater");
       
        // Execute anonymous graph writer runnable and wait for its termination
        try {
            updaterManager.executeBlocking(new GraphWriterRunnable() {
                @Override
                public void run(Graph graph) {
                    LOG.info("Anonymous graph writer {} runnable is run on the "
                            + "graph writer scheduler.", this.hashCode());
                    // Do some writing to the graph here
View Full Code Here

                LOG.info("Ignoring feed with an old timestamp.");
                return;
            }

            // Handle update in graph writer runnable
            updaterManager.execute(new GraphWriterRunnable() {
                @Override
                public void run(Graph graph) {
                    updateHandler.update(feed);
                }
            });
View Full Code Here

        // Creation of network linker library will not modify the graph
        networkLinkerLibrary = new NetworkLinkerLibrary(graph,
                Collections.<Class<?>, Object> emptyMap());

        // Adding a bike park station service needs a graph writer runnable
        updaterManager.executeBlocking(new GraphWriterRunnable() {
            @Override
            public void run(Graph graph) {
                bikeService = graph.getService(BikeRentalStationService.class, true);
            }
        });
View Full Code Here

TOP

Related Classes of org.opentripplanner.updater.GraphWriterRunnable

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.