added basic member functions for stack functionality