generalized read and edit