Replacing io with nio.