added visitor functionality