Modified legacy one to visit pattern.