Back to index

moin  1.9.0~rc2
Classes | Functions | Variables
MoinMoin.support.werkzeug.contrib.profiler Namespace Reference

Classes

class  MergeStream
class  ProfilerMiddleware

Functions

def make_action

Variables

 available = True

Function Documentation

def MoinMoin.support.werkzeug.contrib.profiler.make_action (   app_factory,
  hostname = 'localhost',
  port = 5000,
  threaded = False,
  processes = 1,
  stream = None,
  sort_by = ('time', 'calls',
  restrictions = () 
)
Return a new callback for :mod:`werkzeug.script` that starts a local
server with the profiler enabled::

    from werkzeug.contrib import profiler
    action_profile = profiler.make_action(make_app)

Definition at line 103 of file profiler.py.

00103 
00104                 sort_by=('time', 'calls'), restrictions=()):
00105     """Return a new callback for :mod:`werkzeug.script` that starts a local
00106     server with the profiler enabled::
00107 
00108         from werkzeug.contrib import profiler
00109         action_profile = profiler.make_action(make_app)
00110     """
00111     def action(hostname=('h', hostname), port=('p', port),
00112                threaded=threaded, processes=processes):
00113         """Start a new development server."""
00114         from werkzeug.serving import run_simple
00115         app = ProfilerMiddleware(app_factory(), stream, sort_by, restrictions)
00116         run_simple(hostname, port, app, False, None, threaded, processes)
00117     return action

Here is the call graph for this function:

Here is the caller graph for this function:


Variable Documentation

Definition at line 26 of file profiler.py.