envelope class work in progress