Implemented basic functions.