need feedback on matching-algorithm for upcomming TMC-import

I need some feedback on the algorithm I sketched out using pseudocode on
http://wiki.openstreetmap.org/wiki/TMC/TMC_Import_Germany#automatic_import

What would be the best aproach if a segment/area/road is not a present in OSM
by a matching type=route -relation of it the combined members of such a relation
do not match?

Marcus