Fix the API. make some class members private