nl-linux 0.2.0 → 0.2.1

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.
@@ -0,0 +1,605 @@
1
+ # SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause)
2
+ #--
3
+ # frozen_string_literal: true
4
+ # rbs_inline: enabled
5
+ # This code is generated by Ynl::Generator. DO NOT EDIT.
6
+ require 'nl'
7
+ # Multipath TCP.
8
+ class Nl::Linux::MptcpPm < ::Nl::Family
9
+ NAME = "mptcp_pm"
10
+ PROTOCOL = Ractor.make_shareable(::Nl::Protocols::Genl.new("mptcp_pm"))
11
+ module Structs
12
+ end
13
+ module AttributeSets
14
+ class Address < ::Nl::Protocols::Genl::AttributeSet
15
+ # Abstract class
16
+ class Attribute < ::Nl::Protocols::Genl::AttributeSet::Attribute
17
+ end
18
+ class Family < Attribute
19
+ TYPE = 1
20
+ NAME = :"family"
21
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U16, check: nil)
22
+ end
23
+ class Id < Attribute
24
+ TYPE = 2
25
+ NAME = :"id"
26
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U8, check: nil)
27
+ end
28
+ class Addr4 < Attribute
29
+ TYPE = 3
30
+ NAME = :"addr4"
31
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Big::U32, check: nil)
32
+ end
33
+ class Addr6 < Attribute
34
+ TYPE = 4
35
+ NAME = :"addr6"
36
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Binary.new(check: -> { raise ArgumentError, "Value #{it.inspect} is not equal to length 16" unless it.bytesize == 16 })
37
+ end
38
+ class Port < Attribute
39
+ TYPE = 5
40
+ NAME = :"port"
41
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U16, check: nil)
42
+ end
43
+ class Flags < Attribute
44
+ TYPE = 6
45
+ NAME = :"flags"
46
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U32, check: nil)
47
+ end
48
+ class IfIdx < Attribute
49
+ TYPE = 7
50
+ NAME = :"if_idx"
51
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::S32, check: nil)
52
+ end
53
+ # :nodoc:
54
+ BY_NAME = Ractor.make_shareable({:"family" => Family, :"id" => Id, :"addr4" => Addr4, :"addr6" => Addr6, :"port" => Port, :"flags" => Flags, :"if_idx" => IfIdx}) #: Hash[::Symbol, Attribute]
55
+ # :nodoc:
56
+ BY_TYPE = Ractor.make_shareable({1 => Family, 2 => Id, 3 => Addr4, 4 => Addr6, 5 => Port, 6 => Flags, 7 => IfIdx}) #: Hash[::Integer, Attribute]
57
+ class << self
58
+ # Looks up Attribute class by name.
59
+ #--
60
+ # @rbs name: Symbol
61
+ # @rbs return: Attribute
62
+ def by_name(name); BY_NAME.fetch(name); end
63
+ # Looks up Attribute class by type value.
64
+ #--
65
+ # @rbs type: Integer
66
+ # @rbs return: Attribute
67
+ def by_type(type); BY_TYPE.fetch(type); end
68
+ end
69
+ end
70
+ class SubflowAttribute < ::Nl::Protocols::Genl::AttributeSet
71
+ # Abstract class
72
+ class Attribute < ::Nl::Protocols::Genl::AttributeSet::Attribute
73
+ end
74
+ class TokenRem < Attribute
75
+ TYPE = 1
76
+ NAME = :"token_rem"
77
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U32, check: nil)
78
+ end
79
+ class TokenLoc < Attribute
80
+ TYPE = 2
81
+ NAME = :"token_loc"
82
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U32, check: nil)
83
+ end
84
+ class RelwriteSeq < Attribute
85
+ TYPE = 3
86
+ NAME = :"relwrite_seq"
87
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U32, check: nil)
88
+ end
89
+ class MapSeq < Attribute
90
+ TYPE = 4
91
+ NAME = :"map_seq"
92
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U64, check: nil)
93
+ end
94
+ class MapSfseq < Attribute
95
+ TYPE = 5
96
+ NAME = :"map_sfseq"
97
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U32, check: nil)
98
+ end
99
+ class SsnOffset < Attribute
100
+ TYPE = 6
101
+ NAME = :"ssn_offset"
102
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U32, check: nil)
103
+ end
104
+ class MapDatalen < Attribute
105
+ TYPE = 7
106
+ NAME = :"map_datalen"
107
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U16, check: nil)
108
+ end
109
+ class Flags < Attribute
110
+ TYPE = 8
111
+ NAME = :"flags"
112
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U32, check: nil)
113
+ end
114
+ class IdRem < Attribute
115
+ TYPE = 9
116
+ NAME = :"id_rem"
117
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U8, check: nil)
118
+ end
119
+ class IdLoc < Attribute
120
+ TYPE = 10
121
+ NAME = :"id_loc"
122
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U8, check: nil)
123
+ end
124
+ class Pad < Attribute
125
+ TYPE = 11
126
+ NAME = :"pad"
127
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Pad.new()
128
+ end
129
+ # :nodoc:
130
+ BY_NAME = Ractor.make_shareable({:"token_rem" => TokenRem, :"token_loc" => TokenLoc, :"relwrite_seq" => RelwriteSeq, :"map_seq" => MapSeq, :"map_sfseq" => MapSfseq, :"ssn_offset" => SsnOffset, :"map_datalen" => MapDatalen, :"flags" => Flags, :"id_rem" => IdRem, :"id_loc" => IdLoc, :"pad" => Pad}) #: Hash[::Symbol, Attribute]
131
+ # :nodoc:
132
+ BY_TYPE = Ractor.make_shareable({1 => TokenRem, 2 => TokenLoc, 3 => RelwriteSeq, 4 => MapSeq, 5 => MapSfseq, 6 => SsnOffset, 7 => MapDatalen, 8 => Flags, 9 => IdRem, 10 => IdLoc, 11 => Pad}) #: Hash[::Integer, Attribute]
133
+ class << self
134
+ # Looks up Attribute class by name.
135
+ #--
136
+ # @rbs name: Symbol
137
+ # @rbs return: Attribute
138
+ def by_name(name); BY_NAME.fetch(name); end
139
+ # Looks up Attribute class by type value.
140
+ #--
141
+ # @rbs type: Integer
142
+ # @rbs return: Attribute
143
+ def by_type(type); BY_TYPE.fetch(type); end
144
+ end
145
+ end
146
+ class Endpoint < ::Nl::Protocols::Genl::AttributeSet
147
+ # Abstract class
148
+ class Attribute < ::Nl::Protocols::Genl::AttributeSet::Attribute
149
+ end
150
+ class Addr < Attribute
151
+ TYPE = 1
152
+ NAME = :"addr"
153
+ end
154
+ # :nodoc:
155
+ BY_NAME = Ractor.make_shareable({:"addr" => Addr}) #: Hash[::Symbol, Attribute]
156
+ # :nodoc:
157
+ BY_TYPE = Ractor.make_shareable({1 => Addr}) #: Hash[::Integer, Attribute]
158
+ class << self
159
+ # Looks up Attribute class by name.
160
+ #--
161
+ # @rbs name: Symbol
162
+ # @rbs return: Attribute
163
+ def by_name(name); BY_NAME.fetch(name); end
164
+ # Looks up Attribute class by type value.
165
+ #--
166
+ # @rbs type: Integer
167
+ # @rbs return: Attribute
168
+ def by_type(type); BY_TYPE.fetch(type); end
169
+ end
170
+ end
171
+ class Attr < ::Nl::Protocols::Genl::AttributeSet
172
+ # Abstract class
173
+ class Attribute < ::Nl::Protocols::Genl::AttributeSet::Attribute
174
+ end
175
+ class Addr < Attribute
176
+ TYPE = 1
177
+ NAME = :"addr"
178
+ end
179
+ class RcvAddAddrs < Attribute
180
+ TYPE = 2
181
+ NAME = :"rcv_add_addrs"
182
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U32, check: nil)
183
+ end
184
+ class Subflows < Attribute
185
+ TYPE = 3
186
+ NAME = :"subflows"
187
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U32, check: nil)
188
+ end
189
+ class Token < Attribute
190
+ TYPE = 4
191
+ NAME = :"token"
192
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U32, check: nil)
193
+ end
194
+ class LocId < Attribute
195
+ TYPE = 5
196
+ NAME = :"loc_id"
197
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U8, check: nil)
198
+ end
199
+ class AddrRemote < Attribute
200
+ TYPE = 6
201
+ NAME = :"addr_remote"
202
+ end
203
+ # :nodoc:
204
+ BY_NAME = Ractor.make_shareable({:"addr" => Addr, :"rcv_add_addrs" => RcvAddAddrs, :"subflows" => Subflows, :"token" => Token, :"loc_id" => LocId, :"addr_remote" => AddrRemote}) #: Hash[::Symbol, Attribute]
205
+ # :nodoc:
206
+ BY_TYPE = Ractor.make_shareable({1 => Addr, 2 => RcvAddAddrs, 3 => Subflows, 4 => Token, 5 => LocId, 6 => AddrRemote}) #: Hash[::Integer, Attribute]
207
+ class << self
208
+ # Looks up Attribute class by name.
209
+ #--
210
+ # @rbs name: Symbol
211
+ # @rbs return: Attribute
212
+ def by_name(name); BY_NAME.fetch(name); end
213
+ # Looks up Attribute class by type value.
214
+ #--
215
+ # @rbs type: Integer
216
+ # @rbs return: Attribute
217
+ def by_type(type); BY_TYPE.fetch(type); end
218
+ end
219
+ end
220
+ class EventAttr < ::Nl::Protocols::Genl::AttributeSet
221
+ # Abstract class
222
+ class Attribute < ::Nl::Protocols::Genl::AttributeSet::Attribute
223
+ end
224
+ class Token < Attribute
225
+ TYPE = 1
226
+ NAME = :"token"
227
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U32, check: nil)
228
+ end
229
+ class Family < Attribute
230
+ TYPE = 2
231
+ NAME = :"family"
232
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U16, check: nil)
233
+ end
234
+ class LocId < Attribute
235
+ TYPE = 3
236
+ NAME = :"loc_id"
237
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U8, check: nil)
238
+ end
239
+ class RemId < Attribute
240
+ TYPE = 4
241
+ NAME = :"rem_id"
242
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U8, check: nil)
243
+ end
244
+ class Saddr4 < Attribute
245
+ TYPE = 5
246
+ NAME = :"saddr4"
247
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Big::U32, check: nil)
248
+ end
249
+ class Saddr6 < Attribute
250
+ TYPE = 6
251
+ NAME = :"saddr6"
252
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Binary.new(check: -> { raise ArgumentError, "Value #{it.inspect} is shorter than minimum length 16" unless it.bytesize >= 16 })
253
+ end
254
+ class Daddr4 < Attribute
255
+ TYPE = 7
256
+ NAME = :"daddr4"
257
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Big::U32, check: nil)
258
+ end
259
+ class Daddr6 < Attribute
260
+ TYPE = 8
261
+ NAME = :"daddr6"
262
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Binary.new(check: -> { raise ArgumentError, "Value #{it.inspect} is shorter than minimum length 16" unless it.bytesize >= 16 })
263
+ end
264
+ class Sport < Attribute
265
+ TYPE = 9
266
+ NAME = :"sport"
267
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Big::U16, check: nil)
268
+ end
269
+ class Dport < Attribute
270
+ TYPE = 10
271
+ NAME = :"dport"
272
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Big::U16, check: nil)
273
+ end
274
+ class Backup < Attribute
275
+ TYPE = 11
276
+ NAME = :"backup"
277
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U8, check: nil)
278
+ end
279
+ class Error < Attribute
280
+ TYPE = 12
281
+ NAME = :"error"
282
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U8, check: nil)
283
+ end
284
+ class Flags < Attribute
285
+ TYPE = 13
286
+ NAME = :"flags"
287
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U16, check: nil)
288
+ end
289
+ class Timeout < Attribute
290
+ TYPE = 14
291
+ NAME = :"timeout"
292
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U32, check: nil)
293
+ end
294
+ class IfIdx < Attribute
295
+ TYPE = 15
296
+ NAME = :"if_idx"
297
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::S32, check: nil)
298
+ end
299
+ class ResetReason < Attribute
300
+ TYPE = 16
301
+ NAME = :"reset_reason"
302
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U32, check: nil)
303
+ end
304
+ class ResetFlags < Attribute
305
+ TYPE = 17
306
+ NAME = :"reset_flags"
307
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U32, check: nil)
308
+ end
309
+ class ServerSide < Attribute
310
+ TYPE = 18
311
+ NAME = :"server_side"
312
+ DATATYPE = ::Nl::Protocols::Genl::DataTypes::Scalar.new(::Nl::Endian::Host::U8, check: nil)
313
+ end
314
+ # :nodoc:
315
+ BY_NAME = Ractor.make_shareable({:"token" => Token, :"family" => Family, :"loc_id" => LocId, :"rem_id" => RemId, :"saddr4" => Saddr4, :"saddr6" => Saddr6, :"daddr4" => Daddr4, :"daddr6" => Daddr6, :"sport" => Sport, :"dport" => Dport, :"backup" => Backup, :"error" => Error, :"flags" => Flags, :"timeout" => Timeout, :"if_idx" => IfIdx, :"reset_reason" => ResetReason, :"reset_flags" => ResetFlags, :"server_side" => ServerSide}) #: Hash[::Symbol, Attribute]
316
+ # :nodoc:
317
+ BY_TYPE = Ractor.make_shareable({1 => Token, 2 => Family, 3 => LocId, 4 => RemId, 5 => Saddr4, 6 => Saddr6, 7 => Daddr4, 8 => Daddr6, 9 => Sport, 10 => Dport, 11 => Backup, 12 => Error, 13 => Flags, 14 => Timeout, 15 => IfIdx, 16 => ResetReason, 17 => ResetFlags, 18 => ServerSide}) #: Hash[::Integer, Attribute]
318
+ class << self
319
+ # Looks up Attribute class by name.
320
+ #--
321
+ # @rbs name: Symbol
322
+ # @rbs return: Attribute
323
+ def by_name(name); BY_NAME.fetch(name); end
324
+ # Looks up Attribute class by type value.
325
+ #--
326
+ # @rbs type: Integer
327
+ # @rbs return: Attribute
328
+ def by_type(type); BY_TYPE.fetch(type); end
329
+ end
330
+ end
331
+ Endpoint::Addr::DATATYPE = ::Nl::Protocols::Genl::DataTypes::NestedAttributes.new(Address)
332
+ Attr::Addr::DATATYPE = ::Nl::Protocols::Genl::DataTypes::NestedAttributes.new(Address)
333
+ Attr::AddrRemote::DATATYPE = ::Nl::Protocols::Genl::DataTypes::NestedAttributes.new(Address)
334
+ end
335
+ module Messages
336
+ # Add endpoint
337
+ class DoAddAddrRequest < ::Nl::Protocols::Genl::Message
338
+ TYPE = 1
339
+ FIXED_HEADER = nil
340
+ ATTRIBUTE_SET = AttributeSets::Endpoint
341
+ ATTRIBUTES = Ractor.make_shareable(%i[addr])
342
+ # Gets the value of `addr` attribute in the message.
343
+ #--
344
+ # @rbs return: AttributeSets::Address
345
+ def addr; attributes[:"addr"]&.value; end
346
+ end
347
+ # Delete endpoint
348
+ class DoDelAddrRequest < ::Nl::Protocols::Genl::Message
349
+ TYPE = 2
350
+ FIXED_HEADER = nil
351
+ ATTRIBUTE_SET = AttributeSets::Endpoint
352
+ ATTRIBUTES = Ractor.make_shareable(%i[addr])
353
+ # Gets the value of `addr` attribute in the message.
354
+ #--
355
+ # @rbs return: AttributeSets::Address
356
+ def addr; attributes[:"addr"]&.value; end
357
+ end
358
+ # Get endpoint information
359
+ class DoGetAddrRequest < ::Nl::Protocols::Genl::Message
360
+ TYPE = 3
361
+ FIXED_HEADER = nil
362
+ ATTRIBUTE_SET = AttributeSets::Attr
363
+ ATTRIBUTES = Ractor.make_shareable(%i[addr token])
364
+ # Gets the value of `addr` attribute in the message.
365
+ #--
366
+ # @rbs return: AttributeSets::Address
367
+ def addr; attributes[:"addr"]&.value; end
368
+ # Gets the value of `token` attribute in the message.
369
+ #--
370
+ # @rbs return: ::Integer
371
+ def token; attributes[:"token"]&.value; end
372
+ end
373
+ # Get endpoint information
374
+ class DoGetAddrReply < ::Nl::Protocols::Genl::Message
375
+ TYPE = 3
376
+ FIXED_HEADER = nil
377
+ ATTRIBUTE_SET = AttributeSets::Attr
378
+ ATTRIBUTES = Ractor.make_shareable(%i[addr])
379
+ # Gets the value of `addr` attribute in the message.
380
+ #--
381
+ # @rbs return: AttributeSets::Address
382
+ def addr; attributes[:"addr"]&.value; end
383
+ end
384
+ # Get endpoint information
385
+ class DumpGetAddrReply < ::Nl::Protocols::Genl::Message
386
+ TYPE = 3
387
+ FIXED_HEADER = nil
388
+ ATTRIBUTE_SET = AttributeSets::Attr
389
+ ATTRIBUTES = Ractor.make_shareable(%i[addr])
390
+ # Gets the value of `addr` attribute in the message.
391
+ #--
392
+ # @rbs return: AttributeSets::Address
393
+ def addr; attributes[:"addr"]&.value; end
394
+ end
395
+ # Flush addresses
396
+ class DoFlushAddrsRequest < ::Nl::Protocols::Genl::Message
397
+ TYPE = 4
398
+ FIXED_HEADER = nil
399
+ ATTRIBUTE_SET = AttributeSets::Endpoint
400
+ ATTRIBUTES = Ractor.make_shareable(%i[addr])
401
+ # Gets the value of `addr` attribute in the message.
402
+ #--
403
+ # @rbs return: AttributeSets::Address
404
+ def addr; attributes[:"addr"]&.value; end
405
+ end
406
+ # Set protocol limits
407
+ class DoSetLimitsRequest < ::Nl::Protocols::Genl::Message
408
+ TYPE = 5
409
+ FIXED_HEADER = nil
410
+ ATTRIBUTE_SET = AttributeSets::Attr
411
+ ATTRIBUTES = Ractor.make_shareable(%i[rcv_add_addrs subflows])
412
+ # Gets the value of `rcv-add-addrs` attribute in the message.
413
+ #--
414
+ # @rbs return: ::Integer
415
+ def rcv_add_addrs; attributes[:"rcv_add_addrs"]&.value; end
416
+ # Gets the value of `subflows` attribute in the message.
417
+ #--
418
+ # @rbs return: ::Integer
419
+ def subflows; attributes[:"subflows"]&.value; end
420
+ end
421
+ # Get protocol limits
422
+ class DoGetLimitsRequest < ::Nl::Protocols::Genl::Message
423
+ TYPE = 6
424
+ FIXED_HEADER = nil
425
+ ATTRIBUTE_SET = AttributeSets::Attr
426
+ ATTRIBUTES = Ractor.make_shareable(%i[rcv_add_addrs subflows])
427
+ # Gets the value of `rcv-add-addrs` attribute in the message.
428
+ #--
429
+ # @rbs return: ::Integer
430
+ def rcv_add_addrs; attributes[:"rcv_add_addrs"]&.value; end
431
+ # Gets the value of `subflows` attribute in the message.
432
+ #--
433
+ # @rbs return: ::Integer
434
+ def subflows; attributes[:"subflows"]&.value; end
435
+ end
436
+ # Get protocol limits
437
+ class DoGetLimitsReply < ::Nl::Protocols::Genl::Message
438
+ TYPE = 6
439
+ FIXED_HEADER = nil
440
+ ATTRIBUTE_SET = AttributeSets::Attr
441
+ ATTRIBUTES = Ractor.make_shareable(%i[rcv_add_addrs subflows])
442
+ # Gets the value of `rcv-add-addrs` attribute in the message.
443
+ #--
444
+ # @rbs return: ::Integer
445
+ def rcv_add_addrs; attributes[:"rcv_add_addrs"]&.value; end
446
+ # Gets the value of `subflows` attribute in the message.
447
+ #--
448
+ # @rbs return: ::Integer
449
+ def subflows; attributes[:"subflows"]&.value; end
450
+ end
451
+ # Change endpoint flags
452
+ class DoSetFlagsRequest < ::Nl::Protocols::Genl::Message
453
+ TYPE = 7
454
+ FIXED_HEADER = nil
455
+ ATTRIBUTE_SET = AttributeSets::Attr
456
+ ATTRIBUTES = Ractor.make_shareable(%i[addr token addr_remote])
457
+ # Gets the value of `addr` attribute in the message.
458
+ #--
459
+ # @rbs return: AttributeSets::Address
460
+ def addr; attributes[:"addr"]&.value; end
461
+ # Gets the value of `token` attribute in the message.
462
+ #--
463
+ # @rbs return: ::Integer
464
+ def token; attributes[:"token"]&.value; end
465
+ # Gets the value of `addr-remote` attribute in the message.
466
+ #--
467
+ # @rbs return: AttributeSets::Address
468
+ def addr_remote; attributes[:"addr_remote"]&.value; end
469
+ end
470
+ # Announce new address
471
+ class DoAnnounceRequest < ::Nl::Protocols::Genl::Message
472
+ TYPE = 8
473
+ FIXED_HEADER = nil
474
+ ATTRIBUTE_SET = AttributeSets::Attr
475
+ ATTRIBUTES = Ractor.make_shareable(%i[addr token])
476
+ # Gets the value of `addr` attribute in the message.
477
+ #--
478
+ # @rbs return: AttributeSets::Address
479
+ def addr; attributes[:"addr"]&.value; end
480
+ # Gets the value of `token` attribute in the message.
481
+ #--
482
+ # @rbs return: ::Integer
483
+ def token; attributes[:"token"]&.value; end
484
+ end
485
+ # Announce removal
486
+ class DoRemoveRequest < ::Nl::Protocols::Genl::Message
487
+ TYPE = 9
488
+ FIXED_HEADER = nil
489
+ ATTRIBUTE_SET = AttributeSets::Attr
490
+ ATTRIBUTES = Ractor.make_shareable(%i[token loc_id])
491
+ # Gets the value of `token` attribute in the message.
492
+ #--
493
+ # @rbs return: ::Integer
494
+ def token; attributes[:"token"]&.value; end
495
+ # Gets the value of `loc-id` attribute in the message.
496
+ #--
497
+ # @rbs return: ::Integer
498
+ def loc_id; attributes[:"loc_id"]&.value; end
499
+ end
500
+ # Create subflow
501
+ class DoSubflowCreateRequest < ::Nl::Protocols::Genl::Message
502
+ TYPE = 10
503
+ FIXED_HEADER = nil
504
+ ATTRIBUTE_SET = AttributeSets::Attr
505
+ ATTRIBUTES = Ractor.make_shareable(%i[addr token addr_remote])
506
+ # Gets the value of `addr` attribute in the message.
507
+ #--
508
+ # @rbs return: AttributeSets::Address
509
+ def addr; attributes[:"addr"]&.value; end
510
+ # Gets the value of `token` attribute in the message.
511
+ #--
512
+ # @rbs return: ::Integer
513
+ def token; attributes[:"token"]&.value; end
514
+ # Gets the value of `addr-remote` attribute in the message.
515
+ #--
516
+ # @rbs return: AttributeSets::Address
517
+ def addr_remote; attributes[:"addr_remote"]&.value; end
518
+ end
519
+ # Destroy subflow
520
+ class DoSubflowDestroyRequest < ::Nl::Protocols::Genl::Message
521
+ TYPE = 11
522
+ FIXED_HEADER = nil
523
+ ATTRIBUTE_SET = AttributeSets::Attr
524
+ ATTRIBUTES = Ractor.make_shareable(%i[addr token addr_remote])
525
+ # Gets the value of `addr` attribute in the message.
526
+ #--
527
+ # @rbs return: AttributeSets::Address
528
+ def addr; attributes[:"addr"]&.value; end
529
+ # Gets the value of `token` attribute in the message.
530
+ #--
531
+ # @rbs return: ::Integer
532
+ def token; attributes[:"token"]&.value; end
533
+ # Gets the value of `addr-remote` attribute in the message.
534
+ #--
535
+ # @rbs return: AttributeSets::Address
536
+ def addr_remote; attributes[:"addr_remote"]&.value; end
537
+ end
538
+ end
539
+ # Add endpoint
540
+ #--
541
+ # @rbs (?addr: AttributeSets::Address) -> void
542
+ def do_add_addr(**args)
543
+ exchange_message(:"do", Messages::DoAddAddrRequest, nil, args)
544
+ end
545
+ # Delete endpoint
546
+ #--
547
+ # @rbs (?addr: AttributeSets::Address) -> void
548
+ def do_del_addr(**args)
549
+ exchange_message(:"do", Messages::DoDelAddrRequest, nil, args)
550
+ end
551
+ # Get endpoint information
552
+ #--
553
+ # @rbs (?addr: AttributeSets::Address, ?token: ::Integer) -> Messages::DoGetAddrReply
554
+ def do_get_addr(**args)
555
+ exchange_message(:"do", Messages::DoGetAddrRequest, Messages::DoGetAddrReply, args)
556
+ end
557
+ # Flush addresses
558
+ #--
559
+ # @rbs (?addr: AttributeSets::Address) -> void
560
+ def do_flush_addrs(**args)
561
+ exchange_message(:"do", Messages::DoFlushAddrsRequest, nil, args)
562
+ end
563
+ # Set protocol limits
564
+ #--
565
+ # @rbs (?rcv_add_addrs: ::Integer, ?subflows: ::Integer) -> void
566
+ def do_set_limits(**args)
567
+ exchange_message(:"do", Messages::DoSetLimitsRequest, nil, args)
568
+ end
569
+ # Get protocol limits
570
+ #--
571
+ # @rbs (?rcv_add_addrs: ::Integer, ?subflows: ::Integer) -> Messages::DoGetLimitsReply
572
+ def do_get_limits(**args)
573
+ exchange_message(:"do", Messages::DoGetLimitsRequest, Messages::DoGetLimitsReply, args)
574
+ end
575
+ # Change endpoint flags
576
+ #--
577
+ # @rbs (?addr: AttributeSets::Address, ?token: ::Integer, ?addr_remote: AttributeSets::Address) -> void
578
+ def do_set_flags(**args)
579
+ exchange_message(:"do", Messages::DoSetFlagsRequest, nil, args)
580
+ end
581
+ # Announce new address
582
+ #--
583
+ # @rbs (?addr: AttributeSets::Address, ?token: ::Integer) -> void
584
+ def do_announce(**args)
585
+ exchange_message(:"do", Messages::DoAnnounceRequest, nil, args)
586
+ end
587
+ # Announce removal
588
+ #--
589
+ # @rbs (?token: ::Integer, ?loc_id: ::Integer) -> void
590
+ def do_remove(**args)
591
+ exchange_message(:"do", Messages::DoRemoveRequest, nil, args)
592
+ end
593
+ # Create subflow
594
+ #--
595
+ # @rbs (?addr: AttributeSets::Address, ?token: ::Integer, ?addr_remote: AttributeSets::Address) -> void
596
+ def do_subflow_create(**args)
597
+ exchange_message(:"do", Messages::DoSubflowCreateRequest, nil, args)
598
+ end
599
+ # Destroy subflow
600
+ #--
601
+ # @rbs (?addr: AttributeSets::Address, ?token: ::Integer, ?addr_remote: AttributeSets::Address) -> void
602
+ def do_subflow_destroy(**args)
603
+ exchange_message(:"do", Messages::DoSubflowDestroyRequest, nil, args)
604
+ end
605
+ end