Broken code into several internal features.