def hypermedia_out():
 request = cherrypy.serving.request
 request._hypermedia_inner_handler = request.handler
 request.handler = hypermedia_handler

def hypermedia_out ( ) : request = cherrypy . serving . request request . _hypermedia_inner_handler = request . handler request . handler = hypermedia_handler
determine the best handler for the requested content type wrap the normal handler and transform the output from that handler into the requested content type .