source:
trunk/essentials/dev-lang/python/Lib/xdrlib.py@
3226
| Last change on this file since 3226 was 3225, checked in by , 19 years ago | |
|---|---|
| File size: 7.2 KB | |
| Line | |
|---|---|
| 1 | """Implements (a subset of) Sun XDR -- eXternal Data Representation. |
| 2 | |
| 3 | See: RFC 1014 |
| 4 | |
| 5 | """ |
| 6 | |
| 7 | import struct |
| 8 | try: |
| 9 | from cStringIO import StringIO as _StringIO |
| 10 | except ImportError: |
| 11 | from StringIO import StringIO as _StringIO |
| 12 | |
| 13 | __all__ = ["Error", "Packer", "Unpacker", "ConversionError"] |
| 14 | |
| 15 | # exceptions |
| 16 | class Error(Exception): |
| 17 | """Exception class for this module. Use: |
| 18 | |
| 19 | except xdrlib.Error, var: |
| 20 | # var has the Error instance for the exception |
| 21 | |
