return "MoveRoutes";
}
public void run() throws IOException {
for (int i = 0; i < routes.size(); i++) {
RouteModel route = routes.get(i);
CategoryTreeNode parent = parents.get(i);
CategoryTreeNode category = route.getCategory();
if (category.isLocal() && parent.isRemote())
throw new IOException("cannot move local route " + route.getName() + " to remote parent " + parent.getName());
if (category.isRemote() && parent.isLocal())
throw new IOException("cannot move remote route " + route.getName() + " to local parent " + parent.getName());
route.getRoute().update(parent.getCategory(), route.getDescription() != null ? route.getDescription() : route.getName());
}
invokeLater(new Runnable() {
public void run() {
for (CategoryTreeNode parent : parents) {