A man wounds four people in a stabbing attack before being stopped by bystanders, who brought him to the ground in a New Zealand neighbourhood, police say.