Extract code from the initializer into methods