summaryrefslogtreecommitdiffstats
path: root/cython/imobiledevice.pxd
diff options
context:
space:
mode:
authorGravatar Bryan Forbes2010-04-09 16:52:30 -0500
committerGravatar Martin Szulecki2012-03-20 23:25:55 +0100
commitbea5efe442daeab05d5d7a2e9d9e7b934ba6e684 (patch)
tree0346eebd799517c0976e640db7241d0c72cf7d95 /cython/imobiledevice.pxd
parentacac4f819ccafa6f6bb945626f2e21ec2b75074b (diff)
downloadlibimobiledevice-bea5efe442daeab05d5d7a2e9d9e7b934ba6e684.tar.gz
libimobiledevice-bea5efe442daeab05d5d7a2e9d9e7b934ba6e684.tar.bz2
Implemented hierarchy suggested by Martin S.
Implemented new BaseService constructors. Moved LockdownClient to lockdown.pxi. Implemented more of the afc interface.
Diffstat (limited to 'cython/imobiledevice.pxd')
-rw-r--r--cython/imobiledevice.pxd39
1 files changed, 36 insertions, 3 deletions
diff --git a/cython/imobiledevice.pxd b/cython/imobiledevice.pxd
index 6bf75af..a699138 100644
--- a/cython/imobiledevice.pxd
+++ b/cython/imobiledevice.pxd
@@ -45,14 +45,47 @@ cdef class iDevice(Base):
45 45
46 cpdef iDeviceConnection connect(self, uint16_t port) 46 cpdef iDeviceConnection connect(self, uint16_t port)
47 47
48cdef class LockdownError(BaseError): pass 48cdef class BaseService(Base):
49 pass
50
51cdef class PropertyListService(BaseService):
52 cpdef send(self, plist.Node node)
53 cpdef object receive(self)
54 cdef inline int16_t _send(self, plist.plist_t node)
55 cdef inline int16_t _receive(self, plist.plist_t* c_node)
49 56
50cdef extern from "libimobiledevice/lockdown.h": 57cdef extern from "libimobiledevice/lockdown.h":
51 cdef struct lockdownd_client_private: 58 cdef struct lockdownd_client_private:
52 pass 59 pass
53 ctypedef lockdownd_client_private *lockdownd_client_t 60 ctypedef lockdownd_client_private *lockdownd_client_t
61 cdef struct lockdownd_pair_record:
62 char *device_certificate
63 char *host_certificate
64 char *host_id
65 char *root_certificate
66 ctypedef lockdownd_pair_record *lockdownd_pair_record_t
67
68cdef class LockdownError(BaseError): pass
69
70cdef class LockdownPairRecord:
71 cdef lockdownd_pair_record_t _c_record
54 72
55cdef class LockdownClient(Base): 73cdef class LockdownClient(PropertyListService):
56 cdef lockdownd_client_t _c_client 74 cdef lockdownd_client_t _c_client
57 cpdef int start_service(self, bytes service) 75 cdef readonly iDevice device
76
77 cpdef bytes query_type(self)
78 cpdef plist.Node get_value(self, bytes domain=*, bytes key=*)
79 cpdef set_value(self, bytes domain, bytes key, object value)
80 cpdef remove_value(self, bytes domain, bytes key)
81 cpdef uint16_t start_service(self, object service)
82 cpdef object get_service_client(self, object service_class)
83 cpdef tuple start_session(self, bytes host_id)
84 cpdef stop_session(self, bytes session_id)
85 cpdef pair(self, object pair_record=*)
86 cpdef validate_pair(self, object pair_record=*)
87 cpdef unpair(self, object pair_record=*)
88 cpdef activate(self, plist.Node activation_record)
89 cpdef deactivate(self)
90 cpdef enter_recovery(self)
58 cpdef goodbye(self) 91 cpdef goodbye(self)