@Override
    public void addRoadMarker(final String name, final Coordinates from, final Coordinates to, final int mode, final String status) {
        Platform.runLater(new Runnable() {
            @Override
            public void run() {
                try {
                    if (from == null && to == null) {
                        RoadAgentUi ui = roads.get(name);
                        ui.changeStatus(status);
                        return;
                    }
                    if (nodes.containsKey(from) && nodes.containsKey(to)) {
                        if (roads.containsKey(name)) {
                            RoadAgentUi ui = roads.get(name);
                            ui.changeStatus(status);
                        } else {
                            RoadAgentUi ui = new RoadAgentUi(name, from, to, mode);
                            ui.getRoad().setOnMouseClicked(new EventHandler<MouseEvent>() {
                                @Override
                                public void handle(MouseEvent paramT) {
                                    if (paramT.isShiftDown()) {
                                        handler.removeRoad(paramT.getSource());
                                    }
                                }
                            });
                            ui.changeStatus(status);
                            roads.put(name, ui);
                            boolean flag = roadGr.getChildren().add(ui.getRoad());
                            if (flag) {
                                roadsByImage.put(ui.getRoad(), ui);
                            }
                            nodes.get(from).addRoad(name);
                            nodes.get(to).addRoad(name);
                        }
                    } else {
                        throw new Throwable("not existing node");
                    }
                } catch (Throwable t) {
                    ExceptionUtils.handleException(t);
                }
            }
        }

        );
    }