CPPFunctionHandler like CPPMethodHandler, and refactored some stuff into
standalone_base.py