A reusable library for graph traversals where the 'visiting' operation is injected as argument