Commit 744cff7e authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent 116d5481
...@@ -151,7 +151,7 @@ cdef nogil: ...@@ -151,7 +151,7 @@ cdef nogil:
# XXX wconn is maintained and kept in sync with zconn. # XXX wconn is maintained and kept in sync with zconn.
# XXX simultaneous call? # XXX simultaneous call?
# XXX move -> .py ? # XXX move -> .py ?
cdef pywconnOf(zconn): cdef wcfs.PyConn pywconnOf(zconn):
assert isinstance(zconn, ZConnection) assert isinstance(zconn, ZConnection)
assert zconn.opened # XXX needed assert zconn.opened # XXX needed
......
...@@ -99,3 +99,21 @@ cdef extern from "wcfs/internal/wcfs.h" namespace "wcfs" nogil: ...@@ -99,3 +99,21 @@ cdef extern from "wcfs/internal/wcfs.h" namespace "wcfs" nogil:
# FileH.X = FileH->X in C++ # FileH.X = FileH->X in C++
# XXX add mmap? # XXX add mmap?
pass pass
# ---- python bits ----
cdef class PyWCFS:
cdef WCFS wc
cdef class PyConn:
cdef Conn wconn
cdef class PyFileH:
cdef FileH wfileh
cdef class PyWatchLink:
cdef WatchLink wlink
cdef class PyPinReq:
cdef PinReq pinreq
...@@ -36,10 +36,9 @@ cdef extern from *: ...@@ -36,10 +36,9 @@ cdef extern from *:
from ZODB.utils import p64, u64 from ZODB.utils import p64, u64
# XXX hack, why it is needed? (likely top-level wendelin.* redirector # XXX hack, why it is needed? (likely top-level wendelin.* redirector
from wcfs.internal._wcfs cimport * #from wcfs.internal._wcfs cimport *
cdef class PyWCFS: cdef class PyWCFS:
cdef WCFS wc
property mountpoint: property mountpoint:
def __get__(PyWCFS pywc): def __get__(PyWCFS pywc):
...@@ -63,7 +62,6 @@ cdef class PyWCFS: ...@@ -63,7 +62,6 @@ cdef class PyWCFS:
cdef class PyConn: cdef class PyConn:
cdef Conn wconn
def __dealloc__(PyConn pywconn): def __dealloc__(PyConn pywconn):
pywconn.wconn = nil pywconn.wconn = nil
...@@ -90,7 +88,6 @@ cdef class PyConn: ...@@ -90,7 +88,6 @@ cdef class PyConn:
# XXX resync # XXX resync
cdef class PyFileH: cdef class PyFileH:
cdef FileH wfileh
def __dealloc__(PyFileH pywfileh): def __dealloc__(PyFileH pywfileh):
pywfileh.wfileh = nil pywfileh.wfileh = nil
...@@ -98,7 +95,6 @@ cdef class PyFileH: ...@@ -98,7 +95,6 @@ cdef class PyFileH:
# ---------------------------------------- # ----------------------------------------
cdef class PyWatchLink: cdef class PyWatchLink:
cdef WatchLink wlink
def __init__(PyWatchLink pywlink, PyWCFS pywc): def __init__(PyWatchLink pywlink, PyWCFS pywc):
with nogil: with nogil:
...@@ -169,7 +165,6 @@ cdef class PyWatchLink: ...@@ -169,7 +165,6 @@ cdef class PyWatchLink:
cdef class PyPinReq: cdef class PyPinReq:
cdef PinReq pinreq
property foid: property foid:
def __get__(PyPinReq pypin): def __get__(PyPinReq pypin):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment