The goal of the overhaul is to move nearly every one of the state’s 4.7 million recipients of the government healthcare program to managed care in three years, ending the use of hospital emergency rooms that drive up costs.