Add Builder and Reader ABCs for each struct type

This has zero overhead if not used.  I decided that it was simpler
to use ABCs instead of real classes, given that using real classes
offers little benefit.

This also implements == and != for StructSchema objects.
This commit is contained in:
Andy Lutomirski
2013-09-03 11:01:12 -07:00
parent 47ee1a87a3
commit b3264a7292
2 changed files with 32 additions and 0 deletions

View File

@@ -60,6 +60,8 @@ cdef extern from "capnp/schema.h" namespace " ::capnp":
Field getFieldByName(char * name)
int operator == (StructSchema)
cdef cppclass EnumSchema:
cppclass Enumerant:
EnumNode.Enumerant.Reader getProto()