def METHOD_NAME (func):
    """CherryPy expose JSON decorator"""
    @expose
    def wrapper (self, *args, **kwds):
        """Decorator wrapper"""
        encoder = JSONEncoder()
        data = func (self, *args, **kwds)
        cherrypy.response.headers['Content-Type'] = "text/json"
        try:
            jsondata = encoder.encode(data)
            return jsondata
        except Exception as exp:
            Exception("Fail to JSONtify obj '%s' type '%s', %s" \
                % (data, type(data), exp))
    return wrapper