added implementation of some member functions