Ñò
MhEc
@ s d d k Z d d k Z d d k Z d d k i Z d d k i Z d d k i i
Z
d d k Td d k Z d d k
Z
d d k Z d „ Z d d „ Z d e
i
f d „ ƒ YZ d e
i f d „ ƒ YZ d e
i f d
„ ƒ YZ d e
i f d „ ƒ YZ d
e
i f d „ ƒ YZ d S( iÿÿÿÿN( t *c O s t i t | | Ž S( N( t HTTPHandlert handle_httpt
CGIHandler( t argst params( ( s: /usr/lib/python2.6/site-packages/myghty/http/CGIHandler.pyt handle s c K s t i t d | | S( Nt interpreter_name( R t get_handlerR ( R R ( ( s: /usr/lib/python2.6/site-packages/myghty/http/CGIHandler.pyR s R c B sS e Z d „ Z d „ Z d „ Z d „ Z d „ Z d „ Z d d d d d „ Z RS( c K s t i i | d t i | d S( N( R t __init__t Nonet syst stderr( t selfR ( ( s: /usr/lib/python2.6/site-packages/myghty/http/CGIHandler.pyR s c K s | S( N( ( R
t httpreqR ( ( s: /usr/lib/python2.6/site-packages/myghty/http/CGIHandler.pyt do_get_init_params s c K s
t | S( N( t CGIResolver( R
R ( ( s: /usr/lib/python2.6/site-packages/myghty/http/CGIHandler.pyt do_get_resolver" s c K s
t | | S( N( t CGIRequestImpl( R
R R ( ( s: /usr/lib/python2.6/site-packages/myghty/http/CGIHandler.pyt do_make_request_impl% s c K s | i S( N( t path_info( R
R R ( ( s: /usr/lib/python2.6/site-packages/myghty/http/CGIHandler.pyt do_get_component( s c C sI | i ƒ | t i j o+ t i i d | | p d | i f ƒ n d S( Ns¼
Response code %d (%s)
Page: "%s"
s
no message( t send_http_headerR t HTTP_OKR t stdoutt writeR ( R
R t status_codet reason( ( s: /usr/lib/python2.6/site-packages/myghty/http/CGIHandler.pyt do_handle_result+ s
c K s= | d j o
t ƒ } n t i i | | | | | | d S( N( R
t CGIHTTPRequestR R ( R
R t interpt request_implt componentR ( ( s: /usr/lib/python2.6/site-packages/myghty/http/CGIHandler.pyR 8 s
N(
t __name__t
__module__R R R R R R R
R ( ( ( s: /usr/lib/python2.6/site-packages/myghty/http/CGIHandler.pyR s
R c B s e Z d Z d „ Z d „ Z RS( s| simulates a mod_python request for use in non-mod-python applications.
only a minimal featureset is here currently.
c C sÕ t i i | ƒ t i d t ƒ | _ t i } xG | i ƒ D]9 } | d d !d j o | i
i | d | | ƒ q; q; Wd | _ | d | _
| d | _ | i d d ƒ | _ | i d
d ƒ | _ t i | _ d S( Nt keep_blank_valuesi i t HTTPi s text/htmlt REQUEST_METHODt PATH_TRANSLATEDt QUERY_STRINGt PATH_INFOt /( R t HTTPRequestR t cgit FieldStoraget Truet fieldstoraget ost environt keyst
headers_int addt content_typet methodt filenamet getR
R R R R t
out_buffer( R
t envt key( ( s: /usr/lib/python2.6/site-packages/myghty/http/CGIHandler.pyR B s
#
c C s0 | i ƒ } | i | i ƒ | i i d ƒ d S( Ns
( t get_response_headerst
get_outputR8 R ( R
t headers( ( s: /usr/lib/python2.6/site-packages/myghty/http/CGIHandler.pyt do_send_headersS s ( R! R" t __doc__R R> ( ( ( s: /usr/lib/python2.6/site-packages/myghty/http/CGIHandler.pyR > s R c B s e Z RS( ( R! R" ( ( ( s: /usr/lib/python2.6/site-packages/myghty/http/CGIHandler.pyR Z s t CGIWriterc B s e Z RS( ( R! R" ( ( ( s: /usr/lib/python2.6/site-packages/myghty/http/CGIHandler.pyR@ \ s R c B s&