move accessor into class methods