Update README.md
This commit is contained in:
@@ -25,11 +25,9 @@ You also need a working version of the latest [Cython](http://cython.org/) insta
|
||||
At the moment, there is no documenation, but the library is almost a 1:1 clone of the [Capnproto C++ Library](http://kentonv.github.io/capnproto/cxx.html)
|
||||
|
||||
The examples has one example that shows off the capabilities quite nicely. Here it is, reproduced:
|
||||
|
||||
import os
|
||||
```python
|
||||
import capnp
|
||||
this_dir = os.path.dirname(__file__)
|
||||
addressbook = capnp.load(os.path.join(this_dir, 'addressbook.capnp'))
|
||||
addressbook = capnp.load('addressbook.capnp')
|
||||
|
||||
def writeAddressBook(fd):
|
||||
message = capnp.MallocMessageBuilder()
|
||||
@@ -85,3 +83,4 @@ The examples has one example that shows off the capabilities quite nicely. Here
|
||||
|
||||
f = open('example', 'r')
|
||||
printAddressBook(f.fileno())
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user