class encapsulation started, see issue #4