53 | | A Python library for creating declarative structure definitions. Each instance |
54 | | of the `Construct` class has a name, and knows how to read from a stream, write |
55 | | to a stream, and determine its length. Some predefined `Construct` subclasses |
56 | | use an arbitrary Python function evaluated at runtime, or behave differently |
57 | | depending on whether sub‐`Construct`s throw exceptions. `Const` uses a |
58 | | sub‐`Construct` and makes sure the value is correct. Also has lazy |
59 | | `Construct`s. |
| 53 | [http://construct.wikispaces.com/ Construct] is a Python library for creating |
| 54 | declarative structure definitions. Each instance of the `Construct` class has a |
| 55 | name, and knows how to read from a stream, write to a stream, and determine its |
| 56 | length. Some predefined `Construct` subclasses use an arbitrary Python function |
| 57 | evaluated at runtime, or behave differently depending on whether |
| 58 | sub‐`Construct`s throw exceptions. `Const` uses a sub‐`Construct` and makes |
| 59 | sure the value is correct. Also has lazy `Construct`s. |