Change to multiple hooks for vertex visitor, rearrange dfs routines.