implement rest of the functionality and tests.