home *** CD-ROM | disk | FTP | other *** search
- # Source Generated with Decompyle++
- # File: in.pyc (Python 2.6)
-
- import IPython.ipapi as IPython
- from IPython.genutils import Term
- from IPython.ipapi import IPyAutocall
-
- class Macro(IPyAutocall):
-
- def __init__(self, data):
- self.value = ''.join(data).rstrip() + '\n'
-
-
- def __str__(self):
- return self.value
-
-
- def __repr__(self):
- return 'IPython.macro.Macro(%s)' % repr(self.value)
-
-
- def __call__(self, *args):
- Term.cout.flush()
- self._ip.user_ns['_margv'] = args
- self._ip.runlines(self.value)
-
-
- def __getstate__(self):
- return {
- 'value': self.value }
-
-
-