| Server IP : 61.19.30.66 / Your IP : 216.73.216.15 Web Server : Apache/2.2.22 (Ubuntu) System : Linux klw 3.11.0-15-generic #25~precise1-Ubuntu SMP Thu Jan 30 17:39:31 UTC 2014 x86_64 User : www-data ( 33) PHP Version : 5.3.10-1ubuntu3.48 Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority, MySQL : ON | cURL : OFF | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : OFF Directory : /usr/lib/python2.7/dist-packages/twisted/python/ |
Upload File : |
ó
[³XMc @ s d e f d „ ƒ YZ d S( t
MonkeyPatcherc B sD e Z d Z d „ Z d „ Z d „ Z d „ Z d „ Z d „ Z RS( sn
Cover up attributes with new objects. Neat for monkey-patching things for
unit-testing purposes.
c G s4 g | _ g | _ x | D] } | j | Œ q Wd S( N( t _patchesToApplyt
_originalst addPatch( t selft patchest patch( ( s9 /usr/lib/python2.7/dist-packages/twisted/python/monkey.pyt __init__
s
c C s | j j | | | f ƒ d S( sæ
Add a patch so that the attribute C{name} on C{obj} will be assigned to
C{value} when C{patch} is called or during C{runWithPatches}.
You can restore the original values with a call to restore().
N( R t append( R t objt namet value( ( s9 /usr/lib/python2.7/dist-packages/twisted/python/monkey.pyR s c C s= x6 | j D]+ \ } } } | | f | | f k r
t Sq
Wt S( sc
Has the C{name} attribute of C{obj} already been patched by this
patcher?
( R t Truet False( R R R
t ot nt v( ( s9 /usr/lib/python2.7/dist-packages/twisted/python/monkey.pyt _alreadyPatched! s c C sh xa | j D]V \ } } } | j | | ƒ sP | j j | | t | | ƒ f ƒ n t | | | ƒ q
Wd S( s†
Apply all of the patches that have been specified with L{addPatch}.
Reverse this operation using L{restore}.
N( R R R R t getattrt setattr( R R R
R ( ( s9 /usr/lib/python2.7/dist-packages/twisted/python/monkey.pyR , s %c C s<