Added a FunctionPointer interface to aid passing functions around using
annonymous inner classes.