added the setFunctionsAdapter method