This commit introduces a visitor for router functions (RouterFunctions.Visitor), allowing to iterate over all the components that make up a router function. This commit also introduces a ToStringVisitor, which creates a nicely formatted string for use with toString(). Issue: SPR-15711, SPR-15711