From d4c2cc962dc4c7b11c2db360fef7a80de3334c11 Mon Sep 17 00:00:00 2001 From: Mikko Rasa Date: Tue, 15 Apr 2014 18:36:36 +0300 Subject: [PATCH] Remove a function that was never used --- source/libr2c2/trainrouter.cpp | 11 ----------- source/libr2c2/trainrouter.h | 1 - 2 files changed, 12 deletions(-) diff --git a/source/libr2c2/trainrouter.cpp b/source/libr2c2/trainrouter.cpp index 44a97f5..c551050 100644 --- a/source/libr2c2/trainrouter.cpp +++ b/source/libr2c2/trainrouter.cpp @@ -385,17 +385,6 @@ void TrainRouter::train_advanced(Block &block) } } -const Route *TrainRouter::get_route_for_block(const Block &block) const -{ - const set &tracks = block.get_tracks(); - for(RouteList::const_iterator i=routes.begin(); i!=routes.end(); ++i) - for(set::const_iterator j=tracks.begin(); j!=tracks.end(); ++j) - if((*i)->has_track(**j)) - return *i; - - return 0; -} - void TrainRouter::create_metrics() { for(vector::iterator i=metrics.begin(); i!=metrics.end(); ++i) diff --git a/source/libr2c2/trainrouter.h b/source/libr2c2/trainrouter.h index 1c523d8..3c23496 100644 --- a/source/libr2c2/trainrouter.h +++ b/source/libr2c2/trainrouter.h @@ -91,7 +91,6 @@ public: private: void block_reserved(Block &, Train *); void train_advanced(Block &); - const Route *get_route_for_block(const Block &) const; void create_metrics(); Route *create_lead_route(Route *, const Route *); -- 2.45.2