示例#1
0
 def invoke(self, context):
     if context.protocol in ('paste.composit_factory',
                             'paste.composite_factory'):
         return fix_call(context.object,
                         context.loader, context.global_conf,
                         **context.local_conf)
     elif context.protocol == 'paste.app_factory':
         return fix_call(context.object, context.global_conf, **context.local_conf)
     else:
         assert 0, "Protocol %r unknown" % context.protocol
示例#2
0
 def invoke(self, context):
     if context.protocol in ('paste.composit_factory',
                             'paste.composite_factory'):
         return fix_call(context.object,
                         context.loader, context.global_conf,
                         **context.local_conf)
     elif context.protocol == 'paste.app_factory':
         return fix_call(context.object, context.global_conf, **context.local_conf)
     else:
         assert 0, "Protocol %r unknown" % context.protocol
示例#3
0
 def invoke(self, context):
     if context.protocol == 'paste.server_factory':
         return fix_call(context.object,
                         context.global_conf, **context.local_conf)
     elif context.protocol == 'paste.server_runner':
         def server_wrapper(wsgi_app):
             # This should be an object, so it has a nicer __repr__
             return fix_call(context.object,
                             wsgi_app, context.global_conf,
                             **context.local_conf)
         return server_wrapper
     else:
         assert 0, "Protocol %r unknown" % context.protocol
示例#4
0
 def invoke(self, context):
     if context.protocol == 'paste.server_factory':
         return fix_call(context.object,
                         context.global_conf, **context.local_conf)
     elif context.protocol == 'paste.server_runner':
         def server_wrapper(wsgi_app):
             # This should be an object, so it has a nicer __repr__
             return fix_call(context.object,
                             wsgi_app, context.global_conf,
                             **context.local_conf)
         return server_wrapper
     else:
         assert 0, "Protocol %r unknown" % context.protocol
示例#5
0
 def server_wrapper(wsgi_app):
     # This should be an object, so it has a nicer __repr__
     return fix_call(context.object,
                     wsgi_app, context.global_conf,
                     **context.local_conf)
示例#6
0
 def invoke(self, context):
     assert context.protocol in _flatten(self.egg_protocols)
     return fix_call(context.object,
                     context.global_conf, **context.local_conf)
示例#7
0
 def server_wrapper(wsgi_app):
     # This should be an object, so it has a nicer __repr__
     return fix_call(context.object,
                     wsgi_app, context.global_conf,
                     **context.local_conf)
示例#8
0
 def invoke(self, context):
     assert context.protocol in _flatten(self.egg_protocols)
     return fix_call(context.object,
                     context.global_conf, **context.local_conf)