czmq-ffi-gen 0.7.0 → 0.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGES.md +7 -0
- data/README.md +3 -3
- data/lib/czmq-ffi-gen/czmq/ffi/zarmour.rb +28 -9
- data/lib/czmq-ffi-gen/czmq/ffi/zcert.rb +5 -5
- data/lib/czmq-ffi-gen/czmq/ffi/zcertstore.rb +2 -2
- data/lib/czmq-ffi-gen/czmq/ffi/zdir_patch.rb +9 -2
- data/lib/czmq-ffi-gen/czmq/ffi/zframe.rb +32 -0
- data/lib/czmq-ffi-gen/czmq/ffi/zhashx.rb +6 -6
- data/lib/czmq-ffi-gen/czmq/ffi/zlist.rb +5 -2
- data/lib/czmq-ffi-gen/czmq/ffi/zlistx.rb +49 -0
- data/lib/czmq-ffi-gen/czmq/ffi/zmsg.rb +17 -17
- data/lib/czmq-ffi-gen/czmq/ffi/zsock.rb +120 -0
- data/lib/czmq-ffi-gen/czmq/ffi.rb +121 -85
- data/lib/czmq-ffi-gen/gem_version.rb +1 -1
- data/lib/czmq-ffi-gen/signals.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 40d4556bb0a5a5c7ba0aafa6d6bc34ec4eb4487f
|
4
|
+
data.tar.gz: b58af5fa24fce796084d8657c5fab6ebb1532f3f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2035e8506a6f87e614c2cf97ccf8df9e84ae7645d6df8e1c750130889cc6ff2ee082df24dbb5e635493b3252e09a313a765010e33f6832f7612b02f861ed1b70
|
7
|
+
data.tar.gz: bde5b181e74601897dd2f200c745ce23ce57a1fecda7d31b3c524772de8cca3c87cb34ddb62966781cf4fb175c9ab812fc01d93f6bd2c2b26406164cc1608c13
|
data/CHANGES.md
CHANGED
@@ -1,3 +1,10 @@
|
|
1
|
+
0.8.0 (03/27/2016)
|
2
|
+
-----
|
3
|
+
* upgrade CZMQ low-level binding to
|
4
|
+
- fix function names in warnings
|
5
|
+
- have constants instead of enums
|
6
|
+
- adapt to the new interface of zarmour_encode/decode
|
7
|
+
|
1
8
|
0.7.0 (01/21/2016)
|
2
9
|
-----
|
3
10
|
* add support for current stable release 3.0.2 of CZMQ
|
data/README.md
CHANGED
@@ -44,7 +44,7 @@ for the API documentation **for the released gem**.
|
|
44
44
|
|
45
45
|
## Requirements
|
46
46
|
|
47
|
-
* CZMQ
|
47
|
+
* CZMQ > 3.0 (master)
|
48
48
|
* ZMQ >= 4.0
|
49
49
|
|
50
50
|
For security mechanisms like CURVE, you'll need:
|
@@ -59,8 +59,8 @@ On OSX using homebrew, run:
|
|
59
59
|
If you're running Linux, go check [this page](http://zeromq.org/distro:_start)
|
60
60
|
to get more help. Make sure to install CZMQ, not only ZMQ.
|
61
61
|
|
62
|
-
**Note**: The option `--HEAD` is
|
63
|
-
directly from CZMQ's master branch.
|
62
|
+
**Note**: The option `--HEAD` is required because this binding is generated
|
63
|
+
directly from CZMQ's master branch. The current and older releases aren't supported.
|
64
64
|
|
65
65
|
### Supported Rubies
|
66
66
|
|
@@ -9,6 +9,24 @@ module CZMQ
|
|
9
9
|
# armoured text encoding and decoding
|
10
10
|
# @note This class is 100% generated using zproject.
|
11
11
|
class Zarmour
|
12
|
+
# Standard base 64
|
13
|
+
MODE_BASE64_STD = 0
|
14
|
+
|
15
|
+
# URL and filename friendly base 64
|
16
|
+
MODE_BASE64_URL = 1
|
17
|
+
|
18
|
+
# Standard base 32
|
19
|
+
MODE_BASE32_STD = 2
|
20
|
+
|
21
|
+
# Extended hex base 32
|
22
|
+
MODE_BASE32_HEX = 3
|
23
|
+
|
24
|
+
# Standard base 16
|
25
|
+
MODE_BASE16 = 4
|
26
|
+
|
27
|
+
# Z85 from ZeroMQ RFC 32
|
28
|
+
MODE_Z85 = 5
|
29
|
+
|
12
30
|
# Raised when one tries to use an instance of {Zarmour} after
|
13
31
|
# the internal pointer to the native object has been nullified.
|
14
32
|
class DestroyedError < RuntimeError; end
|
@@ -106,23 +124,23 @@ module CZMQ
|
|
106
124
|
result
|
107
125
|
end
|
108
126
|
|
109
|
-
# Decode an armoured string into a
|
110
|
-
#
|
111
|
-
#
|
127
|
+
# Decode an armoured string into a chunk. The decoded output is
|
128
|
+
# null-terminated, so it may be treated as a string, if that's what
|
129
|
+
# it was prior to encoding.
|
112
130
|
#
|
113
131
|
# @param data [String, #to_s, nil]
|
114
|
-
# @
|
115
|
-
|
116
|
-
def decode(data, decode_size)
|
132
|
+
# @return [Zchunk]
|
133
|
+
def decode(data)
|
117
134
|
raise DestroyedError unless @ptr
|
118
135
|
self_p = @ptr
|
119
|
-
result = ::CZMQ::FFI.zarmour_decode(self_p, data
|
136
|
+
result = ::CZMQ::FFI.zarmour_decode(self_p, data)
|
137
|
+
result = Zchunk.__new result, true
|
120
138
|
result
|
121
139
|
end
|
122
140
|
|
123
141
|
# Get the mode property.
|
124
142
|
#
|
125
|
-
# @return [
|
143
|
+
# @return [Integer]
|
126
144
|
def mode()
|
127
145
|
raise DestroyedError unless @ptr
|
128
146
|
self_p = @ptr
|
@@ -142,11 +160,12 @@ module CZMQ
|
|
142
160
|
|
143
161
|
# Set the mode property.
|
144
162
|
#
|
145
|
-
# @param mode [
|
163
|
+
# @param mode [Integer, #to_int, #to_i]
|
146
164
|
# @return [void]
|
147
165
|
def set_mode(mode)
|
148
166
|
raise DestroyedError unless @ptr
|
149
167
|
self_p = @ptr
|
168
|
+
mode = Integer(mode)
|
150
169
|
result = ::CZMQ::FFI.zarmour_set_mode(self_p, mode)
|
151
170
|
result
|
152
171
|
end
|
@@ -233,12 +233,12 @@ module CZMQ
|
|
233
233
|
# If certificate was loaded from public file, the secret key will be
|
234
234
|
# undefined, and this certificate will not work successfully.
|
235
235
|
#
|
236
|
-
# @param
|
236
|
+
# @param socket [::FFI::Pointer, #to_ptr]
|
237
237
|
# @return [void]
|
238
|
-
def apply(
|
238
|
+
def apply(socket)
|
239
239
|
raise DestroyedError unless @ptr
|
240
240
|
self_p = @ptr
|
241
|
-
result = ::CZMQ::FFI.zcert_apply(self_p,
|
241
|
+
result = ::CZMQ::FFI.zcert_apply(self_p, socket)
|
242
242
|
result
|
243
243
|
end
|
244
244
|
|
@@ -276,8 +276,8 @@ module CZMQ
|
|
276
276
|
result
|
277
277
|
end
|
278
278
|
|
279
|
-
#
|
280
|
-
#
|
279
|
+
# Print certificate contents to open stream. This method is deprecated
|
280
|
+
# and you should use the print method.
|
281
281
|
#
|
282
282
|
# @param file [::FFI::Pointer, #to_ptr]
|
283
283
|
# @return [void]
|
@@ -134,8 +134,8 @@ module CZMQ
|
|
134
134
|
result
|
135
135
|
end
|
136
136
|
|
137
|
-
#
|
138
|
-
#
|
137
|
+
# Print list of certificates in store to open stream. This method is
|
138
|
+
# deprecated, and you should use the print method.
|
139
139
|
#
|
140
140
|
# @param file [::FFI::Pointer, #to_ptr]
|
141
141
|
# @return [void]
|
@@ -9,6 +9,12 @@ module CZMQ
|
|
9
9
|
# work with directory patches
|
10
10
|
# @note This class is 100% generated using zproject.
|
11
11
|
class ZdirPatch
|
12
|
+
# Creates a new file
|
13
|
+
CREATE = 1
|
14
|
+
|
15
|
+
# Delete a file
|
16
|
+
DELETE = 2
|
17
|
+
|
12
18
|
# Raised when one tries to use an instance of {ZdirPatch} after
|
13
19
|
# the internal pointer to the native object has been nullified.
|
14
20
|
class DestroyedError < RuntimeError; end
|
@@ -76,11 +82,12 @@ module CZMQ
|
|
76
82
|
# Create new patch
|
77
83
|
# @param path [String, #to_s, nil]
|
78
84
|
# @param file [Zfile, #__ptr]
|
79
|
-
# @param op [
|
85
|
+
# @param op [Integer, #to_int, #to_i]
|
80
86
|
# @param alias_ [String, #to_s, nil]
|
81
87
|
# @return [CZMQ::ZdirPatch]
|
82
88
|
def self.new(path, file, op, alias_)
|
83
89
|
file = file.__ptr if file
|
90
|
+
op = Integer(op)
|
84
91
|
ptr = ::CZMQ::FFI.zdir_patch_new(path, file, op, alias_)
|
85
92
|
__new ptr
|
86
93
|
end
|
@@ -130,7 +137,7 @@ module CZMQ
|
|
130
137
|
|
131
138
|
# Return operation
|
132
139
|
#
|
133
|
-
# @return [
|
140
|
+
# @return [Integer]
|
134
141
|
def op()
|
135
142
|
raise DestroyedError unless @ptr
|
136
143
|
self_p = @ptr
|
@@ -9,6 +9,15 @@ module CZMQ
|
|
9
9
|
# working with single message frames
|
10
10
|
# @note This class is 100% generated using zproject.
|
11
11
|
class Zframe
|
12
|
+
#
|
13
|
+
MORE = 1
|
14
|
+
|
15
|
+
#
|
16
|
+
REUSE = 2
|
17
|
+
|
18
|
+
#
|
19
|
+
DONTWAIT = 4
|
20
|
+
|
12
21
|
# Raised when one tries to use an instance of {Zframe} after
|
13
22
|
# the internal pointer to the native object has been nullified.
|
14
23
|
class DestroyedError < RuntimeError; end
|
@@ -249,6 +258,29 @@ module CZMQ
|
|
249
258
|
result
|
250
259
|
end
|
251
260
|
|
261
|
+
# Return frame group of radio-dish pattern.
|
262
|
+
#
|
263
|
+
# @return [String]
|
264
|
+
def group()
|
265
|
+
raise DestroyedError unless @ptr
|
266
|
+
self_p = @ptr
|
267
|
+
result = ::CZMQ::FFI.zframe_group(self_p)
|
268
|
+
result
|
269
|
+
end
|
270
|
+
|
271
|
+
# Set group on frame. This is used if/when the frame is sent to a
|
272
|
+
# ZMQ_RADIO socket.
|
273
|
+
# Return -1 on error, 0 on success.
|
274
|
+
#
|
275
|
+
# @param group [String, #to_s, nil]
|
276
|
+
# @return [Integer]
|
277
|
+
def set_group(group)
|
278
|
+
raise DestroyedError unless @ptr
|
279
|
+
self_p = @ptr
|
280
|
+
result = ::CZMQ::FFI.zframe_set_group(self_p, group)
|
281
|
+
result
|
282
|
+
end
|
283
|
+
|
252
284
|
# Return TRUE if two frames have identical size and data
|
253
285
|
# If either frame is NULL, equality is always false.
|
254
286
|
#
|
@@ -156,7 +156,8 @@ module CZMQ
|
|
156
156
|
end
|
157
157
|
|
158
158
|
# Create a new callback of the following type:
|
159
|
-
#
|
159
|
+
# Callback function for zhashx_foreach method.
|
160
|
+
# This callback is deprecated and you should use zhashx_first/_next instead.
|
160
161
|
# typedef int (zhashx_foreach_fn) (
|
161
162
|
# const char *key, void *item, void *argument);
|
162
163
|
#
|
@@ -555,8 +556,8 @@ module CZMQ
|
|
555
556
|
result
|
556
557
|
end
|
557
558
|
|
558
|
-
#
|
559
|
-
#
|
559
|
+
# Set hash for automatic value destruction. This method is deprecated
|
560
|
+
# and you should use set_destructor instead.
|
560
561
|
#
|
561
562
|
# @return [void]
|
562
563
|
def autofree()
|
@@ -566,11 +567,10 @@ module CZMQ
|
|
566
567
|
result
|
567
568
|
end
|
568
569
|
|
569
|
-
# DEPRECATED as clumsy -- use zhashx_first/_next instead
|
570
570
|
# Apply function to each item in the hash table. Items are iterated in no
|
571
571
|
# defined order. Stops if callback function returns non-zero and returns
|
572
|
-
# final return code from callback function (zero = success).
|
573
|
-
#
|
572
|
+
# final return code from callback function (zero = success). This method
|
573
|
+
# is deprecated and you should use zhashx_first/_next instead.
|
574
574
|
#
|
575
575
|
# @param callback [::FFI::Pointer, #to_ptr]
|
576
576
|
# @param argument [::FFI::Pointer, #to_ptr]
|
@@ -281,8 +281,11 @@ module CZMQ
|
|
281
281
|
result
|
282
282
|
end
|
283
283
|
|
284
|
-
# Sort the list
|
285
|
-
#
|
284
|
+
# Sort the list. If the compare function is null, sorts the list by
|
285
|
+
# ascending key value using a straight ASCII comparison. If you specify
|
286
|
+
# a compare function, this decides how items are sorted. The sort is not
|
287
|
+
# stable, so may reorder items with the same keys. The algorithm used is
|
288
|
+
# combsort, a compromise between performance and simplicity.
|
286
289
|
#
|
287
290
|
# @param compare [::FFI::Pointer, #to_ptr]
|
288
291
|
# @return [void]
|
@@ -73,6 +73,55 @@ module CZMQ
|
|
73
73
|
@finalizer = nil
|
74
74
|
end
|
75
75
|
|
76
|
+
# Create a new callback of the following type:
|
77
|
+
# Destroy an item
|
78
|
+
# typedef void (zlistx_destructor_fn) (
|
79
|
+
# void **item);
|
80
|
+
#
|
81
|
+
# @note WARNING: If your Ruby code doesn't retain a reference to the
|
82
|
+
# FFI::Function object after passing it to a C function call,
|
83
|
+
# it may be garbage collected while C still holds the pointer,
|
84
|
+
# potentially resulting in a segmentation fault.
|
85
|
+
def self.destructor_fn
|
86
|
+
::FFI::Function.new :void, [:pointer], blocking: true do |item|
|
87
|
+
result = yield item
|
88
|
+
result
|
89
|
+
end
|
90
|
+
end
|
91
|
+
|
92
|
+
# Create a new callback of the following type:
|
93
|
+
# Duplicate an item
|
94
|
+
# typedef void * (zlistx_duplicator_fn) (
|
95
|
+
# const void *item);
|
96
|
+
#
|
97
|
+
# @note WARNING: If your Ruby code doesn't retain a reference to the
|
98
|
+
# FFI::Function object after passing it to a C function call,
|
99
|
+
# it may be garbage collected while C still holds the pointer,
|
100
|
+
# potentially resulting in a segmentation fault.
|
101
|
+
def self.duplicator_fn
|
102
|
+
::FFI::Function.new :pointer, [:pointer], blocking: true do |item|
|
103
|
+
result = yield item
|
104
|
+
result
|
105
|
+
end
|
106
|
+
end
|
107
|
+
|
108
|
+
# Create a new callback of the following type:
|
109
|
+
# Compare two items, for sorting
|
110
|
+
# typedef int (zlistx_comparator_fn) (
|
111
|
+
# const void *item1, const void *item2);
|
112
|
+
#
|
113
|
+
# @note WARNING: If your Ruby code doesn't retain a reference to the
|
114
|
+
# FFI::Function object after passing it to a C function call,
|
115
|
+
# it may be garbage collected while C still holds the pointer,
|
116
|
+
# potentially resulting in a segmentation fault.
|
117
|
+
def self.comparator_fn
|
118
|
+
::FFI::Function.new :int, [:pointer, :pointer], blocking: true do |item1, item2|
|
119
|
+
result = yield item1, item2
|
120
|
+
result = Integer(result)
|
121
|
+
result
|
122
|
+
end
|
123
|
+
end
|
124
|
+
|
76
125
|
# Create a new, empty list.
|
77
126
|
# @return [CZMQ::Zlistx]
|
78
127
|
def self.new()
|
@@ -100,15 +100,14 @@ module CZMQ
|
|
100
100
|
__new ptr
|
101
101
|
end
|
102
102
|
|
103
|
-
# Decodes a serialized message
|
104
|
-
# a new zmsg_t object. Returns NULL if the
|
105
|
-
# there was insufficient memory to work.
|
106
|
-
# @param
|
107
|
-
# @param buffer_size [Integer, #to_int, #to_i]
|
103
|
+
# Decodes a serialized message frame created by zmsg_encode () and returns
|
104
|
+
# a new zmsg_t object. Returns NULL if the frame was badly formatted or
|
105
|
+
# there was insufficient memory to work.
|
106
|
+
# @param frame [Zframe, #__ptr]
|
108
107
|
# @return [CZMQ::Zmsg]
|
109
|
-
def self.decode(
|
110
|
-
|
111
|
-
ptr = ::CZMQ::FFI.zmsg_decode(
|
108
|
+
def self.decode(frame)
|
109
|
+
frame = frame.__ptr if frame
|
110
|
+
ptr = ::CZMQ::FFI.zmsg_decode(frame)
|
112
111
|
__new ptr
|
113
112
|
end
|
114
113
|
|
@@ -353,7 +352,7 @@ module CZMQ
|
|
353
352
|
end
|
354
353
|
|
355
354
|
# Remove first submessage from message, if any. Returns zmsg_t, or NULL if
|
356
|
-
# decoding was not
|
355
|
+
# decoding was not successful.
|
357
356
|
#
|
358
357
|
# @return [Zmsg]
|
359
358
|
def popmsg()
|
@@ -426,17 +425,18 @@ module CZMQ
|
|
426
425
|
result
|
427
426
|
end
|
428
427
|
|
429
|
-
# Serialize multipart message to a single
|
430
|
-
# structured messages across transports that do not support
|
431
|
-
# Allocates and returns a new
|
432
|
-
# To decode a serialized message
|
428
|
+
# Serialize multipart message to a single message frame. Use this method
|
429
|
+
# to send structured messages across transports that do not support
|
430
|
+
# multipart data. Allocates and returns a new frame containing the
|
431
|
+
# serialized message. To decode a serialized message frame, use
|
432
|
+
# zmsg_decode ().
|
433
433
|
#
|
434
|
-
# @
|
435
|
-
|
436
|
-
def encode(buffer)
|
434
|
+
# @return [Zframe]
|
435
|
+
def encode()
|
437
436
|
raise DestroyedError unless @ptr
|
438
437
|
self_p = @ptr
|
439
|
-
result = ::CZMQ::FFI.zmsg_encode(self_p
|
438
|
+
result = ::CZMQ::FFI.zmsg_encode(self_p)
|
439
|
+
result = Zframe.__new result, true
|
440
440
|
result
|
441
441
|
end
|
442
442
|
|
@@ -201,6 +201,22 @@ module CZMQ
|
|
201
201
|
__new ptr
|
202
202
|
end
|
203
203
|
|
204
|
+
# Create a RADIO socket. Default action is bind.
|
205
|
+
# @param endpoint [String, #to_s, nil]
|
206
|
+
# @return [CZMQ::Zsock]
|
207
|
+
def self.new_radio(endpoint)
|
208
|
+
ptr = ::CZMQ::FFI.zsock_new_radio(endpoint)
|
209
|
+
__new ptr
|
210
|
+
end
|
211
|
+
|
212
|
+
# Create a DISH socket. Default action is connect.
|
213
|
+
# @param endpoint [String, #to_s, nil]
|
214
|
+
# @return [CZMQ::Zsock]
|
215
|
+
def self.new_dish(endpoint)
|
216
|
+
ptr = ::CZMQ::FFI.zsock_new_dish(endpoint)
|
217
|
+
__new ptr
|
218
|
+
end
|
219
|
+
|
204
220
|
# Destroy the socket. You must use this for any socket created via the
|
205
221
|
# zsock_new method.
|
206
222
|
#
|
@@ -794,6 +810,60 @@ module CZMQ
|
|
794
810
|
result
|
795
811
|
end
|
796
812
|
|
813
|
+
# Join a group for the RADIO-DISH pattern. Call only on ZMQ_DISH.
|
814
|
+
# Returns 0 if OK, -1 if failed.
|
815
|
+
#
|
816
|
+
# @param group [String, #to_s, nil]
|
817
|
+
# @return [Integer]
|
818
|
+
def join(group)
|
819
|
+
raise DestroyedError unless @ptr
|
820
|
+
self_p = @ptr
|
821
|
+
result = ::CZMQ::FFI.zsock_join(self_p, group)
|
822
|
+
result
|
823
|
+
end
|
824
|
+
|
825
|
+
# Join a group for the RADIO-DISH pattern. Call only on ZMQ_DISH.
|
826
|
+
# Returns 0 if OK, -1 if failed.
|
827
|
+
#
|
828
|
+
# This is the polymorphic version of #join.
|
829
|
+
#
|
830
|
+
# @param self_p [CZMQ::Zsock, #__ptr, ::FFI::Pointer, nil]
|
831
|
+
# object reference to use this method on
|
832
|
+
# @param group [String, #to_s, nil]
|
833
|
+
# @return [Integer]
|
834
|
+
def self.join(self_p, group)
|
835
|
+
self_p = self_p.__ptr if self_p.respond_to?(:__ptr)
|
836
|
+
result = ::CZMQ::FFI.zsock_join(self_p, group)
|
837
|
+
result
|
838
|
+
end
|
839
|
+
|
840
|
+
# Leave a group for the RADIO-DISH pattern. Call only on ZMQ_DISH.
|
841
|
+
# Returns 0 if OK, -1 if failed.
|
842
|
+
#
|
843
|
+
# @param group [String, #to_s, nil]
|
844
|
+
# @return [Integer]
|
845
|
+
def leave(group)
|
846
|
+
raise DestroyedError unless @ptr
|
847
|
+
self_p = @ptr
|
848
|
+
result = ::CZMQ::FFI.zsock_leave(self_p, group)
|
849
|
+
result
|
850
|
+
end
|
851
|
+
|
852
|
+
# Leave a group for the RADIO-DISH pattern. Call only on ZMQ_DISH.
|
853
|
+
# Returns 0 if OK, -1 if failed.
|
854
|
+
#
|
855
|
+
# This is the polymorphic version of #leave.
|
856
|
+
#
|
857
|
+
# @param self_p [CZMQ::Zsock, #__ptr, ::FFI::Pointer, nil]
|
858
|
+
# object reference to use this method on
|
859
|
+
# @param group [String, #to_s, nil]
|
860
|
+
# @return [Integer]
|
861
|
+
def self.leave(self_p, group)
|
862
|
+
self_p = self_p.__ptr if self_p.respond_to?(:__ptr)
|
863
|
+
result = ::CZMQ::FFI.zsock_leave(self_p, group)
|
864
|
+
result
|
865
|
+
end
|
866
|
+
|
797
867
|
# Probe the supplied object, and report if it looks like a zsock_t.
|
798
868
|
# Takes a polymorphic socket reference.
|
799
869
|
#
|
@@ -966,6 +1036,56 @@ module CZMQ
|
|
966
1036
|
result
|
967
1037
|
end
|
968
1038
|
|
1039
|
+
# Get socket option `use_fd`.
|
1040
|
+
#
|
1041
|
+
# @return [Integer]
|
1042
|
+
def use_fd()
|
1043
|
+
raise DestroyedError unless @ptr
|
1044
|
+
self_p = @ptr
|
1045
|
+
result = ::CZMQ::FFI.zsock_use_fd(self_p)
|
1046
|
+
result
|
1047
|
+
end
|
1048
|
+
|
1049
|
+
# Get socket option `use_fd`.
|
1050
|
+
#
|
1051
|
+
# This is the polymorphic version of #use_fd.
|
1052
|
+
#
|
1053
|
+
# @param self_p [CZMQ::Zsock, #__ptr, ::FFI::Pointer, nil]
|
1054
|
+
# object reference to use this method on
|
1055
|
+
# @return [Integer]
|
1056
|
+
def self.use_fd(self_p)
|
1057
|
+
self_p = self_p.__ptr if self_p.respond_to?(:__ptr)
|
1058
|
+
result = ::CZMQ::FFI.zsock_use_fd(self_p)
|
1059
|
+
result
|
1060
|
+
end
|
1061
|
+
|
1062
|
+
# Set socket option `use_fd`.
|
1063
|
+
#
|
1064
|
+
# @param use_fd [Integer, #to_int, #to_i]
|
1065
|
+
# @return [void]
|
1066
|
+
def set_use_fd(use_fd)
|
1067
|
+
raise DestroyedError unless @ptr
|
1068
|
+
self_p = @ptr
|
1069
|
+
use_fd = Integer(use_fd)
|
1070
|
+
result = ::CZMQ::FFI.zsock_set_use_fd(self_p, use_fd)
|
1071
|
+
result
|
1072
|
+
end
|
1073
|
+
|
1074
|
+
# Set socket option `use_fd`.
|
1075
|
+
#
|
1076
|
+
# This is the polymorphic version of #set_use_fd.
|
1077
|
+
#
|
1078
|
+
# @param self_p [CZMQ::Zsock, #__ptr, ::FFI::Pointer, nil]
|
1079
|
+
# object reference to use this method on
|
1080
|
+
# @param use_fd [Integer, #to_int, #to_i]
|
1081
|
+
# @return [void]
|
1082
|
+
def self.set_use_fd(self_p, use_fd)
|
1083
|
+
self_p = self_p.__ptr if self_p.respond_to?(:__ptr)
|
1084
|
+
use_fd = Integer(use_fd)
|
1085
|
+
result = ::CZMQ::FFI.zsock_set_use_fd(self_p, use_fd)
|
1086
|
+
result
|
1087
|
+
end
|
1088
|
+
|
969
1089
|
# Get socket option `tos`.
|
970
1090
|
#
|
971
1091
|
# @return [Integer]
|
@@ -49,22 +49,13 @@ module CZMQ
|
|
49
49
|
|
50
50
|
require_relative 'ffi/zactor'
|
51
51
|
|
52
|
-
enum :zarmour_mode, [
|
53
|
-
:mode_base64_std, 0,
|
54
|
-
:mode_base64_url, 1,
|
55
|
-
:mode_base32_std, 2,
|
56
|
-
:mode_base32_hex, 3,
|
57
|
-
:mode_base16, 4,
|
58
|
-
:mode_z85, 5,
|
59
|
-
]
|
60
|
-
|
61
52
|
attach_function :zarmour_new, [], :pointer, **opts
|
62
53
|
attach_function :zarmour_destroy, [:pointer], :void, **opts
|
63
54
|
attach_function :zarmour_encode, [:pointer, :pointer, :size_t], :pointer, **opts
|
64
|
-
attach_function :zarmour_decode, [:pointer, :string
|
65
|
-
attach_function :zarmour_mode, [:pointer], :
|
55
|
+
attach_function :zarmour_decode, [:pointer, :string], :pointer, **opts
|
56
|
+
attach_function :zarmour_mode, [:pointer], :int, **opts
|
66
57
|
attach_function :zarmour_mode_str, [:pointer], :string, **opts
|
67
|
-
attach_function :zarmour_set_mode, [:pointer, :
|
58
|
+
attach_function :zarmour_set_mode, [:pointer, :int], :void, **opts
|
68
59
|
attach_function :zarmour_pad, [:pointer], :bool, **opts
|
69
60
|
attach_function :zarmour_set_pad, [:pointer, :bool], :void, **opts
|
70
61
|
attach_function :zarmour_pad_char, [:pointer], :pointer, **opts
|
@@ -91,7 +82,7 @@ module CZMQ
|
|
91
82
|
attach_function :zcert_unset_meta, [:pointer, :string], :void, **opts
|
92
83
|
rescue ::FFI::NotFoundError
|
93
84
|
if $VERBOSE || $DEBUG
|
94
|
-
warn "The function
|
85
|
+
warn "The function zcert_unset_meta() can't be used through " +
|
95
86
|
"this Ruby binding because it's not available."
|
96
87
|
end
|
97
88
|
end
|
@@ -218,17 +209,12 @@ module CZMQ
|
|
218
209
|
|
219
210
|
require_relative 'ffi/zdir'
|
220
211
|
|
221
|
-
|
222
|
-
:create, 1,
|
223
|
-
:delete, 2,
|
224
|
-
]
|
225
|
-
|
226
|
-
attach_function :zdir_patch_new, [:string, :pointer, :zdir_patch_op, :string], :pointer, **opts
|
212
|
+
attach_function :zdir_patch_new, [:string, :pointer, :int, :string], :pointer, **opts
|
227
213
|
attach_function :zdir_patch_destroy, [:pointer], :void, **opts
|
228
214
|
attach_function :zdir_patch_dup, [:pointer], :pointer, **opts
|
229
215
|
attach_function :zdir_patch_path, [:pointer], :string, **opts
|
230
216
|
attach_function :zdir_patch_file, [:pointer], :pointer, **opts
|
231
|
-
attach_function :zdir_patch_op, [:pointer], :
|
217
|
+
attach_function :zdir_patch_op, [:pointer], :int, **opts
|
232
218
|
attach_function :zdir_patch_vpath, [:pointer], :string, **opts
|
233
219
|
attach_function :zdir_patch_digest_set, [:pointer], :void, **opts
|
234
220
|
attach_function :zdir_patch_digest, [:pointer], :string, **opts
|
@@ -281,7 +267,7 @@ module CZMQ
|
|
281
267
|
attach_function :zframe_routing_id, [:pointer], :uint32, **opts
|
282
268
|
rescue ::FFI::NotFoundError
|
283
269
|
if $VERBOSE || $DEBUG
|
284
|
-
warn "The function
|
270
|
+
warn "The function zframe_routing_id() can't be used through " +
|
285
271
|
"this Ruby binding because it's not available."
|
286
272
|
end
|
287
273
|
end
|
@@ -289,7 +275,23 @@ module CZMQ
|
|
289
275
|
attach_function :zframe_set_routing_id, [:pointer, :uint32], :void, **opts
|
290
276
|
rescue ::FFI::NotFoundError
|
291
277
|
if $VERBOSE || $DEBUG
|
292
|
-
warn "The function
|
278
|
+
warn "The function zframe_set_routing_id() can't be used through " +
|
279
|
+
"this Ruby binding because it's not available."
|
280
|
+
end
|
281
|
+
end
|
282
|
+
begin # DRAFT method
|
283
|
+
attach_function :zframe_group, [:pointer], :string, **opts
|
284
|
+
rescue ::FFI::NotFoundError
|
285
|
+
if $VERBOSE || $DEBUG
|
286
|
+
warn "The function zframe_group() can't be used through " +
|
287
|
+
"this Ruby binding because it's not available."
|
288
|
+
end
|
289
|
+
end
|
290
|
+
begin # DRAFT method
|
291
|
+
attach_function :zframe_set_group, [:pointer, :string], :int, **opts
|
292
|
+
rescue ::FFI::NotFoundError
|
293
|
+
if $VERBOSE || $DEBUG
|
294
|
+
warn "The function zframe_set_group() can't be used through " +
|
293
295
|
"this Ruby binding because it's not available."
|
294
296
|
end
|
295
297
|
end
|
@@ -405,22 +407,8 @@ module CZMQ
|
|
405
407
|
attach_function :zlistx_add_start, [:pointer, :pointer], :pointer, **opts
|
406
408
|
attach_function :zlistx_add_end, [:pointer, :pointer], :pointer, **opts
|
407
409
|
attach_function :zlistx_size, [:pointer], :size_t, **opts
|
408
|
-
|
409
|
-
|
410
|
-
rescue ::FFI::NotFoundError
|
411
|
-
if $VERBOSE || $DEBUG
|
412
|
-
warn "The function head() can't be used through " +
|
413
|
-
"this Ruby binding because it's not available."
|
414
|
-
end
|
415
|
-
end
|
416
|
-
begin # DRAFT method
|
417
|
-
attach_function :zlistx_tail, [:pointer], :pointer, **opts
|
418
|
-
rescue ::FFI::NotFoundError
|
419
|
-
if $VERBOSE || $DEBUG
|
420
|
-
warn "The function tail() can't be used through " +
|
421
|
-
"this Ruby binding because it's not available."
|
422
|
-
end
|
423
|
-
end
|
410
|
+
attach_function :zlistx_head, [:pointer], :pointer, **opts
|
411
|
+
attach_function :zlistx_tail, [:pointer], :pointer, **opts
|
424
412
|
attach_function :zlistx_first, [:pointer], :pointer, **opts
|
425
413
|
attach_function :zlistx_next, [:pointer], :pointer, **opts
|
426
414
|
attach_function :zlistx_prev, [:pointer], :pointer, **opts
|
@@ -466,7 +454,7 @@ module CZMQ
|
|
466
454
|
attach_function :zloop_set_nonstop, [:pointer, :bool], :void, **opts
|
467
455
|
rescue ::FFI::NotFoundError
|
468
456
|
if $VERBOSE || $DEBUG
|
469
|
-
warn "The function
|
457
|
+
warn "The function zloop_set_nonstop() can't be used through " +
|
470
458
|
"this Ruby binding because it's not available."
|
471
459
|
end
|
472
460
|
end
|
@@ -478,7 +466,7 @@ module CZMQ
|
|
478
466
|
attach_function :zmsg_new, [], :pointer, **opts
|
479
467
|
attach_function :zmsg_recv, [:pointer], :pointer, **opts
|
480
468
|
attach_function :zmsg_load, [:pointer], :pointer, **opts
|
481
|
-
attach_function :zmsg_decode, [:pointer
|
469
|
+
attach_function :zmsg_decode, [:pointer], :pointer, **opts
|
482
470
|
attach_function :zmsg_new_signal, [:char], :pointer, **opts
|
483
471
|
attach_function :zmsg_destroy, [:pointer], :void, **opts
|
484
472
|
attach_function :zmsg_send, [:pointer, :pointer], :int, **opts
|
@@ -489,7 +477,7 @@ module CZMQ
|
|
489
477
|
attach_function :zmsg_routing_id, [:pointer], :uint32, **opts
|
490
478
|
rescue ::FFI::NotFoundError
|
491
479
|
if $VERBOSE || $DEBUG
|
492
|
-
warn "The function
|
480
|
+
warn "The function zmsg_routing_id() can't be used through " +
|
493
481
|
"this Ruby binding because it's not available."
|
494
482
|
end
|
495
483
|
end
|
@@ -497,7 +485,7 @@ module CZMQ
|
|
497
485
|
attach_function :zmsg_set_routing_id, [:pointer, :uint32], :void, **opts
|
498
486
|
rescue ::FFI::NotFoundError
|
499
487
|
if $VERBOSE || $DEBUG
|
500
|
-
warn "The function
|
488
|
+
warn "The function zmsg_set_routing_id() can't be used through " +
|
501
489
|
"this Ruby binding because it's not available."
|
502
490
|
end
|
503
491
|
end
|
@@ -518,7 +506,7 @@ module CZMQ
|
|
518
506
|
attach_function :zmsg_next, [:pointer], :pointer, **opts
|
519
507
|
attach_function :zmsg_last, [:pointer], :pointer, **opts
|
520
508
|
attach_function :zmsg_save, [:pointer, :pointer], :int, **opts
|
521
|
-
attach_function :zmsg_encode, [:pointer, :pointer
|
509
|
+
attach_function :zmsg_encode, [:pointer], :pointer, **opts
|
522
510
|
attach_function :zmsg_dup, [:pointer], :pointer, **opts
|
523
511
|
attach_function :zmsg_print, [:pointer], :void, **opts
|
524
512
|
attach_function :zmsg_eq, [:pointer, :pointer], :bool, **opts
|
@@ -536,7 +524,7 @@ module CZMQ
|
|
536
524
|
attach_function :zpoller_set_nonstop, [:pointer, :bool], :void, **opts
|
537
525
|
rescue ::FFI::NotFoundError
|
538
526
|
if $VERBOSE || $DEBUG
|
539
|
-
warn "The function
|
527
|
+
warn "The function zpoller_set_nonstop() can't be used through " +
|
540
528
|
"this Ruby binding because it's not available."
|
541
529
|
end
|
542
530
|
end
|
@@ -551,7 +539,7 @@ module CZMQ
|
|
551
539
|
attach_function :zproc_czmq_version, [], :int, **opts
|
552
540
|
rescue ::FFI::NotFoundError
|
553
541
|
if $VERBOSE || $DEBUG
|
554
|
-
warn "The function
|
542
|
+
warn "The function zproc_czmq_version() can't be used through " +
|
555
543
|
"this Ruby binding because it's not available."
|
556
544
|
end
|
557
545
|
end
|
@@ -559,7 +547,7 @@ module CZMQ
|
|
559
547
|
attach_function :zproc_interrupted, [], :bool, **opts
|
560
548
|
rescue ::FFI::NotFoundError
|
561
549
|
if $VERBOSE || $DEBUG
|
562
|
-
warn "The function
|
550
|
+
warn "The function zproc_interrupted() can't be used through " +
|
563
551
|
"this Ruby binding because it's not available."
|
564
552
|
end
|
565
553
|
end
|
@@ -567,7 +555,7 @@ module CZMQ
|
|
567
555
|
attach_function :zproc_has_curve, [], :bool, **opts
|
568
556
|
rescue ::FFI::NotFoundError
|
569
557
|
if $VERBOSE || $DEBUG
|
570
|
-
warn "The function
|
558
|
+
warn "The function zproc_has_curve() can't be used through " +
|
571
559
|
"this Ruby binding because it's not available."
|
572
560
|
end
|
573
561
|
end
|
@@ -575,7 +563,7 @@ module CZMQ
|
|
575
563
|
attach_function :zproc_hostname, [], :pointer, **opts
|
576
564
|
rescue ::FFI::NotFoundError
|
577
565
|
if $VERBOSE || $DEBUG
|
578
|
-
warn "The function
|
566
|
+
warn "The function zproc_hostname() can't be used through " +
|
579
567
|
"this Ruby binding because it's not available."
|
580
568
|
end
|
581
569
|
end
|
@@ -583,7 +571,7 @@ module CZMQ
|
|
583
571
|
attach_function :zproc_daemonize, [:string], :void, **opts
|
584
572
|
rescue ::FFI::NotFoundError
|
585
573
|
if $VERBOSE || $DEBUG
|
586
|
-
warn "The function
|
574
|
+
warn "The function zproc_daemonize() can't be used through " +
|
587
575
|
"this Ruby binding because it's not available."
|
588
576
|
end
|
589
577
|
end
|
@@ -591,7 +579,7 @@ module CZMQ
|
|
591
579
|
attach_function :zproc_run_as, [:string, :string, :string], :void, **opts
|
592
580
|
rescue ::FFI::NotFoundError
|
593
581
|
if $VERBOSE || $DEBUG
|
594
|
-
warn "The function
|
582
|
+
warn "The function zproc_run_as() can't be used through " +
|
595
583
|
"this Ruby binding because it's not available."
|
596
584
|
end
|
597
585
|
end
|
@@ -599,7 +587,7 @@ module CZMQ
|
|
599
587
|
attach_function :zproc_set_io_threads, [:size_t], :void, **opts
|
600
588
|
rescue ::FFI::NotFoundError
|
601
589
|
if $VERBOSE || $DEBUG
|
602
|
-
warn "The function
|
590
|
+
warn "The function zproc_set_io_threads() can't be used through " +
|
603
591
|
"this Ruby binding because it's not available."
|
604
592
|
end
|
605
593
|
end
|
@@ -607,7 +595,7 @@ module CZMQ
|
|
607
595
|
attach_function :zproc_set_max_sockets, [:size_t], :void, **opts
|
608
596
|
rescue ::FFI::NotFoundError
|
609
597
|
if $VERBOSE || $DEBUG
|
610
|
-
warn "The function
|
598
|
+
warn "The function zproc_set_max_sockets() can't be used through " +
|
611
599
|
"this Ruby binding because it's not available."
|
612
600
|
end
|
613
601
|
end
|
@@ -615,7 +603,7 @@ module CZMQ
|
|
615
603
|
attach_function :zproc_set_biface, [:string], :void, **opts
|
616
604
|
rescue ::FFI::NotFoundError
|
617
605
|
if $VERBOSE || $DEBUG
|
618
|
-
warn "The function
|
606
|
+
warn "The function zproc_set_biface() can't be used through " +
|
619
607
|
"this Ruby binding because it's not available."
|
620
608
|
end
|
621
609
|
end
|
@@ -623,7 +611,7 @@ module CZMQ
|
|
623
611
|
attach_function :zproc_biface, [], :string, **opts
|
624
612
|
rescue ::FFI::NotFoundError
|
625
613
|
if $VERBOSE || $DEBUG
|
626
|
-
warn "The function
|
614
|
+
warn "The function zproc_biface() can't be used through " +
|
627
615
|
"this Ruby binding because it's not available."
|
628
616
|
end
|
629
617
|
end
|
@@ -631,7 +619,7 @@ module CZMQ
|
|
631
619
|
attach_function :zproc_set_log_ident, [:string], :void, **opts
|
632
620
|
rescue ::FFI::NotFoundError
|
633
621
|
if $VERBOSE || $DEBUG
|
634
|
-
warn "The function
|
622
|
+
warn "The function zproc_set_log_ident() can't be used through " +
|
635
623
|
"this Ruby binding because it's not available."
|
636
624
|
end
|
637
625
|
end
|
@@ -639,7 +627,7 @@ module CZMQ
|
|
639
627
|
attach_function :zproc_set_log_sender, [:string], :void, **opts
|
640
628
|
rescue ::FFI::NotFoundError
|
641
629
|
if $VERBOSE || $DEBUG
|
642
|
-
warn "The function
|
630
|
+
warn "The function zproc_set_log_sender() can't be used through " +
|
643
631
|
"this Ruby binding because it's not available."
|
644
632
|
end
|
645
633
|
end
|
@@ -647,7 +635,7 @@ module CZMQ
|
|
647
635
|
attach_function :zproc_set_log_system, [:bool], :void, **opts
|
648
636
|
rescue ::FFI::NotFoundError
|
649
637
|
if $VERBOSE || $DEBUG
|
650
|
-
warn "The function
|
638
|
+
warn "The function zproc_set_log_system() can't be used through " +
|
651
639
|
"this Ruby binding because it's not available."
|
652
640
|
end
|
653
641
|
end
|
@@ -655,7 +643,7 @@ module CZMQ
|
|
655
643
|
attach_function :zproc_log_error, [:string, :varargs], :void, **opts
|
656
644
|
rescue ::FFI::NotFoundError
|
657
645
|
if $VERBOSE || $DEBUG
|
658
|
-
warn "The function
|
646
|
+
warn "The function zproc_log_error() can't be used through " +
|
659
647
|
"this Ruby binding because it's not available."
|
660
648
|
end
|
661
649
|
end
|
@@ -663,7 +651,7 @@ module CZMQ
|
|
663
651
|
attach_function :zproc_log_warning, [:string, :varargs], :void, **opts
|
664
652
|
rescue ::FFI::NotFoundError
|
665
653
|
if $VERBOSE || $DEBUG
|
666
|
-
warn "The function
|
654
|
+
warn "The function zproc_log_warning() can't be used through " +
|
667
655
|
"this Ruby binding because it's not available."
|
668
656
|
end
|
669
657
|
end
|
@@ -671,7 +659,7 @@ module CZMQ
|
|
671
659
|
attach_function :zproc_log_notice, [:string, :varargs], :void, **opts
|
672
660
|
rescue ::FFI::NotFoundError
|
673
661
|
if $VERBOSE || $DEBUG
|
674
|
-
warn "The function
|
662
|
+
warn "The function zproc_log_notice() can't be used through " +
|
675
663
|
"this Ruby binding because it's not available."
|
676
664
|
end
|
677
665
|
end
|
@@ -679,7 +667,7 @@ module CZMQ
|
|
679
667
|
attach_function :zproc_log_info, [:string, :varargs], :void, **opts
|
680
668
|
rescue ::FFI::NotFoundError
|
681
669
|
if $VERBOSE || $DEBUG
|
682
|
-
warn "The function
|
670
|
+
warn "The function zproc_log_info() can't be used through " +
|
683
671
|
"this Ruby binding because it's not available."
|
684
672
|
end
|
685
673
|
end
|
@@ -687,7 +675,7 @@ module CZMQ
|
|
687
675
|
attach_function :zproc_log_debug, [:string, :varargs], :void, **opts
|
688
676
|
rescue ::FFI::NotFoundError
|
689
677
|
if $VERBOSE || $DEBUG
|
690
|
-
warn "The function
|
678
|
+
warn "The function zproc_log_debug() can't be used through " +
|
691
679
|
"this Ruby binding because it's not available."
|
692
680
|
end
|
693
681
|
end
|
@@ -695,7 +683,7 @@ module CZMQ
|
|
695
683
|
attach_function :zproc_test, [:bool], :void, **opts
|
696
684
|
rescue ::FFI::NotFoundError
|
697
685
|
if $VERBOSE || $DEBUG
|
698
|
-
warn "The function
|
686
|
+
warn "The function zproc_test() can't be used through " +
|
699
687
|
"this Ruby binding because it's not available."
|
700
688
|
end
|
701
689
|
end
|
@@ -719,7 +707,7 @@ module CZMQ
|
|
719
707
|
attach_function :zsock_new_server, [:string], :pointer, **opts
|
720
708
|
rescue ::FFI::NotFoundError
|
721
709
|
if $VERBOSE || $DEBUG
|
722
|
-
warn "The function
|
710
|
+
warn "The function zsock_new_server() can't be used through " +
|
723
711
|
"this Ruby binding because it's not available."
|
724
712
|
end
|
725
713
|
end
|
@@ -727,7 +715,23 @@ module CZMQ
|
|
727
715
|
attach_function :zsock_new_client, [:string], :pointer, **opts
|
728
716
|
rescue ::FFI::NotFoundError
|
729
717
|
if $VERBOSE || $DEBUG
|
730
|
-
warn "The function
|
718
|
+
warn "The function zsock_new_client() can't be used through " +
|
719
|
+
"this Ruby binding because it's not available."
|
720
|
+
end
|
721
|
+
end
|
722
|
+
begin # DRAFT method
|
723
|
+
attach_function :zsock_new_radio, [:string], :pointer, **opts
|
724
|
+
rescue ::FFI::NotFoundError
|
725
|
+
if $VERBOSE || $DEBUG
|
726
|
+
warn "The function zsock_new_radio() can't be used through " +
|
727
|
+
"this Ruby binding because it's not available."
|
728
|
+
end
|
729
|
+
end
|
730
|
+
begin # DRAFT method
|
731
|
+
attach_function :zsock_new_dish, [:string], :pointer, **opts
|
732
|
+
rescue ::FFI::NotFoundError
|
733
|
+
if $VERBOSE || $DEBUG
|
734
|
+
warn "The function zsock_new_dish() can't be used through " +
|
731
735
|
"this Ruby binding because it's not available."
|
732
736
|
end
|
733
737
|
end
|
@@ -749,7 +753,7 @@ module CZMQ
|
|
749
753
|
attach_function :zsock_routing_id, [:pointer], :uint32, **opts
|
750
754
|
rescue ::FFI::NotFoundError
|
751
755
|
if $VERBOSE || $DEBUG
|
752
|
-
warn "The function
|
756
|
+
warn "The function zsock_routing_id() can't be used through " +
|
753
757
|
"this Ruby binding because it's not available."
|
754
758
|
end
|
755
759
|
end
|
@@ -757,7 +761,7 @@ module CZMQ
|
|
757
761
|
attach_function :zsock_set_routing_id, [:pointer, :uint32], :void, **opts
|
758
762
|
rescue ::FFI::NotFoundError
|
759
763
|
if $VERBOSE || $DEBUG
|
760
|
-
warn "The function
|
764
|
+
warn "The function zsock_set_routing_id() can't be used through " +
|
761
765
|
"this Ruby binding because it's not available."
|
762
766
|
end
|
763
767
|
end
|
@@ -765,13 +769,29 @@ module CZMQ
|
|
765
769
|
attach_function :zsock_signal, [:pointer, :char], :int, **opts
|
766
770
|
attach_function :zsock_wait, [:pointer], :int, **opts
|
767
771
|
attach_function :zsock_flush, [:pointer], :void, **opts
|
772
|
+
begin # DRAFT method
|
773
|
+
attach_function :zsock_join, [:pointer, :string], :int, **opts
|
774
|
+
rescue ::FFI::NotFoundError
|
775
|
+
if $VERBOSE || $DEBUG
|
776
|
+
warn "The function zsock_join() can't be used through " +
|
777
|
+
"this Ruby binding because it's not available."
|
778
|
+
end
|
779
|
+
end
|
780
|
+
begin # DRAFT method
|
781
|
+
attach_function :zsock_leave, [:pointer, :string], :int, **opts
|
782
|
+
rescue ::FFI::NotFoundError
|
783
|
+
if $VERBOSE || $DEBUG
|
784
|
+
warn "The function zsock_leave() can't be used through " +
|
785
|
+
"this Ruby binding because it's not available."
|
786
|
+
end
|
787
|
+
end
|
768
788
|
attach_function :zsock_is, [:pointer], :bool, **opts
|
769
789
|
attach_function :zsock_resolve, [:pointer], :pointer, **opts
|
770
790
|
begin # DRAFT method
|
771
791
|
attach_function :zsock_heartbeat_ivl, [:pointer], :int, **opts
|
772
792
|
rescue ::FFI::NotFoundError
|
773
793
|
if $VERBOSE || $DEBUG
|
774
|
-
warn "The function
|
794
|
+
warn "The function zsock_heartbeat_ivl() can't be used through " +
|
775
795
|
"this Ruby binding because it's not available."
|
776
796
|
end
|
777
797
|
end
|
@@ -779,7 +799,7 @@ module CZMQ
|
|
779
799
|
attach_function :zsock_set_heartbeat_ivl, [:pointer, :int], :void, **opts
|
780
800
|
rescue ::FFI::NotFoundError
|
781
801
|
if $VERBOSE || $DEBUG
|
782
|
-
warn "The function
|
802
|
+
warn "The function zsock_set_heartbeat_ivl() can't be used through " +
|
783
803
|
"this Ruby binding because it's not available."
|
784
804
|
end
|
785
805
|
end
|
@@ -787,7 +807,7 @@ module CZMQ
|
|
787
807
|
attach_function :zsock_heartbeat_ttl, [:pointer], :int, **opts
|
788
808
|
rescue ::FFI::NotFoundError
|
789
809
|
if $VERBOSE || $DEBUG
|
790
|
-
warn "The function
|
810
|
+
warn "The function zsock_heartbeat_ttl() can't be used through " +
|
791
811
|
"this Ruby binding because it's not available."
|
792
812
|
end
|
793
813
|
end
|
@@ -795,7 +815,7 @@ module CZMQ
|
|
795
815
|
attach_function :zsock_set_heartbeat_ttl, [:pointer, :int], :void, **opts
|
796
816
|
rescue ::FFI::NotFoundError
|
797
817
|
if $VERBOSE || $DEBUG
|
798
|
-
warn "The function
|
818
|
+
warn "The function zsock_set_heartbeat_ttl() can't be used through " +
|
799
819
|
"this Ruby binding because it's not available."
|
800
820
|
end
|
801
821
|
end
|
@@ -803,7 +823,7 @@ module CZMQ
|
|
803
823
|
attach_function :zsock_heartbeat_timeout, [:pointer], :int, **opts
|
804
824
|
rescue ::FFI::NotFoundError
|
805
825
|
if $VERBOSE || $DEBUG
|
806
|
-
warn "The function
|
826
|
+
warn "The function zsock_heartbeat_timeout() can't be used through " +
|
807
827
|
"this Ruby binding because it's not available."
|
808
828
|
end
|
809
829
|
end
|
@@ -811,7 +831,23 @@ module CZMQ
|
|
811
831
|
attach_function :zsock_set_heartbeat_timeout, [:pointer, :int], :void, **opts
|
812
832
|
rescue ::FFI::NotFoundError
|
813
833
|
if $VERBOSE || $DEBUG
|
814
|
-
warn "The function
|
834
|
+
warn "The function zsock_set_heartbeat_timeout() can't be used through " +
|
835
|
+
"this Ruby binding because it's not available."
|
836
|
+
end
|
837
|
+
end
|
838
|
+
begin # DRAFT method
|
839
|
+
attach_function :zsock_use_fd, [:pointer], :int, **opts
|
840
|
+
rescue ::FFI::NotFoundError
|
841
|
+
if $VERBOSE || $DEBUG
|
842
|
+
warn "The function zsock_use_fd() can't be used through " +
|
843
|
+
"this Ruby binding because it's not available."
|
844
|
+
end
|
845
|
+
end
|
846
|
+
begin # DRAFT method
|
847
|
+
attach_function :zsock_set_use_fd, [:pointer, :int], :void, **opts
|
848
|
+
rescue ::FFI::NotFoundError
|
849
|
+
if $VERBOSE || $DEBUG
|
850
|
+
warn "The function zsock_set_use_fd() can't be used through " +
|
815
851
|
"this Ruby binding because it's not available."
|
816
852
|
end
|
817
853
|
end
|
@@ -924,7 +960,7 @@ module CZMQ
|
|
924
960
|
attach_function :zstr_str, [:pointer], :pointer, **opts
|
925
961
|
rescue ::FFI::NotFoundError
|
926
962
|
if $VERBOSE || $DEBUG
|
927
|
-
warn "The function
|
963
|
+
warn "The function zstr_str() can't be used through " +
|
928
964
|
"this Ruby binding because it's not available."
|
929
965
|
end
|
930
966
|
end
|
@@ -937,7 +973,7 @@ module CZMQ
|
|
937
973
|
attach_function :ztrie_new, [:pointer], :pointer, **opts
|
938
974
|
rescue ::FFI::NotFoundError
|
939
975
|
if $VERBOSE || $DEBUG
|
940
|
-
warn "The function
|
976
|
+
warn "The function ztrie_new() can't be used through " +
|
941
977
|
"this Ruby binding because it's not available."
|
942
978
|
end
|
943
979
|
end
|
@@ -945,7 +981,7 @@ module CZMQ
|
|
945
981
|
attach_function :ztrie_destroy, [:pointer], :void, **opts
|
946
982
|
rescue ::FFI::NotFoundError
|
947
983
|
if $VERBOSE || $DEBUG
|
948
|
-
warn "The function
|
984
|
+
warn "The function ztrie_destroy() can't be used through " +
|
949
985
|
"this Ruby binding because it's not available."
|
950
986
|
end
|
951
987
|
end
|
@@ -953,7 +989,7 @@ module CZMQ
|
|
953
989
|
attach_function :ztrie_insert_route, [:pointer, :string, :pointer, :pointer], :int, **opts
|
954
990
|
rescue ::FFI::NotFoundError
|
955
991
|
if $VERBOSE || $DEBUG
|
956
|
-
warn "The function
|
992
|
+
warn "The function ztrie_insert_route() can't be used through " +
|
957
993
|
"this Ruby binding because it's not available."
|
958
994
|
end
|
959
995
|
end
|
@@ -961,7 +997,7 @@ module CZMQ
|
|
961
997
|
attach_function :ztrie_remove_route, [:pointer, :string], :int, **opts
|
962
998
|
rescue ::FFI::NotFoundError
|
963
999
|
if $VERBOSE || $DEBUG
|
964
|
-
warn "The function
|
1000
|
+
warn "The function ztrie_remove_route() can't be used through " +
|
965
1001
|
"this Ruby binding because it's not available."
|
966
1002
|
end
|
967
1003
|
end
|
@@ -969,7 +1005,7 @@ module CZMQ
|
|
969
1005
|
attach_function :ztrie_matches, [:pointer, :string], :bool, **opts
|
970
1006
|
rescue ::FFI::NotFoundError
|
971
1007
|
if $VERBOSE || $DEBUG
|
972
|
-
warn "The function
|
1008
|
+
warn "The function ztrie_matches() can't be used through " +
|
973
1009
|
"this Ruby binding because it's not available."
|
974
1010
|
end
|
975
1011
|
end
|
@@ -977,7 +1013,7 @@ module CZMQ
|
|
977
1013
|
attach_function :ztrie_hit_data, [:pointer], :pointer, **opts
|
978
1014
|
rescue ::FFI::NotFoundError
|
979
1015
|
if $VERBOSE || $DEBUG
|
980
|
-
warn "The function
|
1016
|
+
warn "The function ztrie_hit_data() can't be used through " +
|
981
1017
|
"this Ruby binding because it's not available."
|
982
1018
|
end
|
983
1019
|
end
|
@@ -985,7 +1021,7 @@ module CZMQ
|
|
985
1021
|
attach_function :ztrie_hit_parameter_count, [:pointer], :size_t, **opts
|
986
1022
|
rescue ::FFI::NotFoundError
|
987
1023
|
if $VERBOSE || $DEBUG
|
988
|
-
warn "The function
|
1024
|
+
warn "The function ztrie_hit_parameter_count() can't be used through " +
|
989
1025
|
"this Ruby binding because it's not available."
|
990
1026
|
end
|
991
1027
|
end
|
@@ -993,7 +1029,7 @@ module CZMQ
|
|
993
1029
|
attach_function :ztrie_hit_parameters, [:pointer], :pointer, **opts
|
994
1030
|
rescue ::FFI::NotFoundError
|
995
1031
|
if $VERBOSE || $DEBUG
|
996
|
-
warn "The function
|
1032
|
+
warn "The function ztrie_hit_parameters() can't be used through " +
|
997
1033
|
"this Ruby binding because it's not available."
|
998
1034
|
end
|
999
1035
|
end
|
@@ -1001,7 +1037,7 @@ module CZMQ
|
|
1001
1037
|
attach_function :ztrie_hit_asterisk_match, [:pointer], :string, **opts
|
1002
1038
|
rescue ::FFI::NotFoundError
|
1003
1039
|
if $VERBOSE || $DEBUG
|
1004
|
-
warn "The function
|
1040
|
+
warn "The function ztrie_hit_asterisk_match() can't be used through " +
|
1005
1041
|
"this Ruby binding because it's not available."
|
1006
1042
|
end
|
1007
1043
|
end
|
@@ -1009,7 +1045,7 @@ module CZMQ
|
|
1009
1045
|
attach_function :ztrie_print, [:pointer], :void, **opts
|
1010
1046
|
rescue ::FFI::NotFoundError
|
1011
1047
|
if $VERBOSE || $DEBUG
|
1012
|
-
warn "The function
|
1048
|
+
warn "The function ztrie_print() can't be used through " +
|
1013
1049
|
"this Ruby binding because it's not available."
|
1014
1050
|
end
|
1015
1051
|
end
|
@@ -1017,7 +1053,7 @@ module CZMQ
|
|
1017
1053
|
attach_function :ztrie_test, [:bool], :void, **opts
|
1018
1054
|
rescue ::FFI::NotFoundError
|
1019
1055
|
if $VERBOSE || $DEBUG
|
1020
|
-
warn "The function
|
1056
|
+
warn "The function ztrie_test() can't be used through " +
|
1021
1057
|
"this Ruby binding because it's not available."
|
1022
1058
|
end
|
1023
1059
|
end
|
data/lib/czmq-ffi-gen/signals.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: czmq-ffi-gen
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.8.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Patrik Wenger
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-03-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: ffi
|