# HG changeset patch # User paulb # Date 1203276117 0 # Node ID 0c70a001d6e83ae5b928a3b046b91821501dd3d9 # Parent ab998f8b472a9fa1eaec0495953587f59349ce02 [project @ 2008-02-17 19:21:08 by paulb] Added missing example. diff -r ab998f8b472a -r 0c70a001d6e8 examples/BaseHTTPRequestHandler/RecursiveApp.py --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/examples/BaseHTTPRequestHandler/RecursiveApp.py Sun Feb 17 19:21:57 2008 +0000 @@ -0,0 +1,15 @@ +#!/usr/bin/env python + +from WebStack.Adapters.BaseHTTPRequestHandler import deploy +import Recursive + +# Get a simple Web site. + +resource = Recursive.get_site() + +# Special magic incantation. + +print "Serving..." +deploy(resource, handle_errors=0) + +# vim: tabstop=4 expandtab shiftwidth=4 diff -r ab998f8b472a -r 0c70a001d6e8 examples/CGI/RecursiveApp.py --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/examples/CGI/RecursiveApp.py Sun Feb 17 19:21:57 2008 +0000 @@ -0,0 +1,22 @@ +#!/usr/bin/env python + +# NOTE: Path manipulation requires manual customisation. + +import sys +#sys.path.append("/home/paulb/Software/Python/WebStack") +#sys.path.append("/home/paulb/Software/Python/XSLTools") +#sys.path.append("/home/paulb/Software/Python/XSLTools/examples/Common") +#sys.path.append("/home/paulb/Software/Python/libxml2dom") + +from WebStack.Adapters.CGI import deploy +import Recursive + +# Get a simple Web site. + +resource = Recursive.get_site() + +# Special magic incantation. + +deploy(resource, handle_errors=0) + +# vim: tabstop=4 expandtab shiftwidth=4 diff -r ab998f8b472a -r 0c70a001d6e8 examples/ModPython/RecursiveApp/RecursiveHandler.py --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/examples/ModPython/RecursiveApp/RecursiveHandler.py Sun Feb 17 19:21:57 2008 +0000 @@ -0,0 +1,24 @@ +#!/usr/bin/env python + +# NOTE: Path manipulation requires manual customisation. + +import sys +#sys.path.append("/home/paulb/Software/Python/WebStack") +#sys.path.append("/home/paulb/Software/Python/XSLTools") +#sys.path.append("/home/paulb/Software/Python/XSLTools/examples/Common") +#sys.path.append("/home/paulb/Software/Python/libxml2dom") + +from WebStack.Adapters import ModPython +import Recursive + +# Get a simple Web site. + +resource = Recursive.get_site() + +# NOTE: Not sure if the resource should be maintained in a resource pool. + +def handler(req): + global resource + return ModPython.respond(req, resource, handle_errors=0) + +# vim: tabstop=4 expandtab shiftwidth=4 diff -r ab998f8b472a -r 0c70a001d6e8 examples/Twisted/RecursiveApp.py --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/examples/Twisted/RecursiveApp.py Sun Feb 17 19:21:57 2008 +0000 @@ -0,0 +1,15 @@ +#!/usr/bin/env python + +from WebStack.Adapters.Twisted import deploy +import Recursive + +# Get a simple Web site. + +resource = Recursive.get_site() + +# Special magic incantation. + +print "Serving..." +deploy(resource, handle_errors=0) + +# vim: tabstop=4 expandtab shiftwidth=4