1 // Code generated by GoVPP's binapi-generator. DO NOT EDIT.
3 // binapi-generator: v0.3.5-56-gc0da1f2-dirty
5 // source: /usr/share/vpp/api/core/vpe.api.json
7 // Package vpe contains generated bindings for API file vpe.api.
16 api "git.fd.io/govpp.git/api"
17 vpe_types "git.fd.io/govpp.git/binapi/vpe_types"
18 codec "git.fd.io/govpp.git/codec"
21 // This is a compile-time assertion to ensure that this generated file
22 // is compatible with the GoVPP api package it is being compiled against.
23 // A compilation error at this line likely means your copy of the
24 // GoVPP api package needs to be updated.
25 const _ = api.GoVppAPIPackageIsVersion2
30 VersionCrc = 0x40364e00
33 // ThreadData defines type 'thread_data'.
34 type ThreadData struct {
35 ID uint32 `binapi:"u32,name=id" json:"id,omitempty"`
36 Name string `binapi:"string[64],name=name" json:"name,omitempty"`
37 Type string `binapi:"string[64],name=type" json:"type,omitempty"`
38 PID uint32 `binapi:"u32,name=pid" json:"pid,omitempty"`
39 CPUID uint32 `binapi:"u32,name=cpu_id" json:"cpu_id,omitempty"`
40 Core uint32 `binapi:"u32,name=core" json:"core,omitempty"`
41 CPUSocket uint32 `binapi:"u32,name=cpu_socket" json:"cpu_socket,omitempty"`
44 // AddNodeNext defines message 'add_node_next'.
45 type AddNodeNext struct {
46 NodeName string `binapi:"string[64],name=node_name" json:"node_name,omitempty"`
47 NextName string `binapi:"string[64],name=next_name" json:"next_name,omitempty"`
50 func (m *AddNodeNext) Reset() { *m = AddNodeNext{} }
51 func (*AddNodeNext) GetMessageName() string { return "add_node_next" }
52 func (*AddNodeNext) GetCrcString() string { return "2457116d" }
53 func (*AddNodeNext) GetMessageType() api.MessageType {
54 return api.RequestMessage
57 func (m *AddNodeNext) Size() (size int) {
61 size += 64 // m.NodeName
62 size += 64 // m.NextName
65 func (m *AddNodeNext) Marshal(b []byte) ([]byte, error) {
67 b = make([]byte, m.Size())
69 buf := codec.NewBuffer(b)
70 buf.EncodeString(m.NodeName, 64)
71 buf.EncodeString(m.NextName, 64)
72 return buf.Bytes(), nil
74 func (m *AddNodeNext) Unmarshal(b []byte) error {
75 buf := codec.NewBuffer(b)
76 m.NodeName = buf.DecodeString(64)
77 m.NextName = buf.DecodeString(64)
81 // AddNodeNextReply defines message 'add_node_next_reply'.
82 type AddNodeNextReply struct {
83 Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
84 NextIndex uint32 `binapi:"u32,name=next_index" json:"next_index,omitempty"`
87 func (m *AddNodeNextReply) Reset() { *m = AddNodeNextReply{} }
88 func (*AddNodeNextReply) GetMessageName() string { return "add_node_next_reply" }
89 func (*AddNodeNextReply) GetCrcString() string { return "2ed75f32" }
90 func (*AddNodeNextReply) GetMessageType() api.MessageType {
91 return api.ReplyMessage
94 func (m *AddNodeNextReply) Size() (size int) {
99 size += 4 // m.NextIndex
102 func (m *AddNodeNextReply) Marshal(b []byte) ([]byte, error) {
104 b = make([]byte, m.Size())
106 buf := codec.NewBuffer(b)
107 buf.EncodeInt32(m.Retval)
108 buf.EncodeUint32(m.NextIndex)
109 return buf.Bytes(), nil
111 func (m *AddNodeNextReply) Unmarshal(b []byte) error {
112 buf := codec.NewBuffer(b)
113 m.Retval = buf.DecodeInt32()
114 m.NextIndex = buf.DecodeUint32()
118 // Cli defines message 'cli'.
120 CmdInShmem uint64 `binapi:"u64,name=cmd_in_shmem" json:"cmd_in_shmem,omitempty"`
123 func (m *Cli) Reset() { *m = Cli{} }
124 func (*Cli) GetMessageName() string { return "cli" }
125 func (*Cli) GetCrcString() string { return "23bfbfff" }
126 func (*Cli) GetMessageType() api.MessageType {
127 return api.RequestMessage
130 func (m *Cli) Size() (size int) {
134 size += 8 // m.CmdInShmem
137 func (m *Cli) Marshal(b []byte) ([]byte, error) {
139 b = make([]byte, m.Size())
141 buf := codec.NewBuffer(b)
142 buf.EncodeUint64(m.CmdInShmem)
143 return buf.Bytes(), nil
145 func (m *Cli) Unmarshal(b []byte) error {
146 buf := codec.NewBuffer(b)
147 m.CmdInShmem = buf.DecodeUint64()
151 // CliInband defines message 'cli_inband'.
152 type CliInband struct {
153 Cmd string `binapi:"string[],name=cmd" json:"cmd,omitempty"`
156 func (m *CliInband) Reset() { *m = CliInband{} }
157 func (*CliInband) GetMessageName() string { return "cli_inband" }
158 func (*CliInband) GetCrcString() string { return "f8377302" }
159 func (*CliInband) GetMessageType() api.MessageType {
160 return api.RequestMessage
163 func (m *CliInband) Size() (size int) {
167 size += 4 + len(m.Cmd) // m.Cmd
170 func (m *CliInband) Marshal(b []byte) ([]byte, error) {
172 b = make([]byte, m.Size())
174 buf := codec.NewBuffer(b)
175 buf.EncodeString(m.Cmd, 0)
176 return buf.Bytes(), nil
178 func (m *CliInband) Unmarshal(b []byte) error {
179 buf := codec.NewBuffer(b)
180 m.Cmd = buf.DecodeString(0)
184 // CliInbandReply defines message 'cli_inband_reply'.
185 type CliInbandReply struct {
186 Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
187 Reply string `binapi:"string[],name=reply" json:"reply,omitempty"`
190 func (m *CliInbandReply) Reset() { *m = CliInbandReply{} }
191 func (*CliInbandReply) GetMessageName() string { return "cli_inband_reply" }
192 func (*CliInbandReply) GetCrcString() string { return "05879051" }
193 func (*CliInbandReply) GetMessageType() api.MessageType {
194 return api.ReplyMessage
197 func (m *CliInbandReply) Size() (size int) {
201 size += 4 // m.Retval
202 size += 4 + len(m.Reply) // m.Reply
205 func (m *CliInbandReply) Marshal(b []byte) ([]byte, error) {
207 b = make([]byte, m.Size())
209 buf := codec.NewBuffer(b)
210 buf.EncodeInt32(m.Retval)
211 buf.EncodeString(m.Reply, 0)
212 return buf.Bytes(), nil
214 func (m *CliInbandReply) Unmarshal(b []byte) error {
215 buf := codec.NewBuffer(b)
216 m.Retval = buf.DecodeInt32()
217 m.Reply = buf.DecodeString(0)
221 // CliReply defines message 'cli_reply'.
222 type CliReply struct {
223 Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
224 ReplyInShmem uint64 `binapi:"u64,name=reply_in_shmem" json:"reply_in_shmem,omitempty"`
227 func (m *CliReply) Reset() { *m = CliReply{} }
228 func (*CliReply) GetMessageName() string { return "cli_reply" }
229 func (*CliReply) GetCrcString() string { return "06d68297" }
230 func (*CliReply) GetMessageType() api.MessageType {
231 return api.ReplyMessage
234 func (m *CliReply) Size() (size int) {
238 size += 4 // m.Retval
239 size += 8 // m.ReplyInShmem
242 func (m *CliReply) Marshal(b []byte) ([]byte, error) {
244 b = make([]byte, m.Size())
246 buf := codec.NewBuffer(b)
247 buf.EncodeInt32(m.Retval)
248 buf.EncodeUint64(m.ReplyInShmem)
249 return buf.Bytes(), nil
251 func (m *CliReply) Unmarshal(b []byte) error {
252 buf := codec.NewBuffer(b)
253 m.Retval = buf.DecodeInt32()
254 m.ReplyInShmem = buf.DecodeUint64()
258 // ControlPing defines message 'control_ping'.
259 type ControlPing struct{}
261 func (m *ControlPing) Reset() { *m = ControlPing{} }
262 func (*ControlPing) GetMessageName() string { return "control_ping" }
263 func (*ControlPing) GetCrcString() string { return "51077d14" }
264 func (*ControlPing) GetMessageType() api.MessageType {
265 return api.RequestMessage
268 func (m *ControlPing) Size() (size int) {
274 func (m *ControlPing) Marshal(b []byte) ([]byte, error) {
276 b = make([]byte, m.Size())
278 buf := codec.NewBuffer(b)
279 return buf.Bytes(), nil
281 func (m *ControlPing) Unmarshal(b []byte) error {
285 // ControlPingReply defines message 'control_ping_reply'.
286 type ControlPingReply struct {
287 Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
288 ClientIndex uint32 `binapi:"u32,name=client_index" json:"client_index,omitempty"`
289 VpePID uint32 `binapi:"u32,name=vpe_pid" json:"vpe_pid,omitempty"`
292 func (m *ControlPingReply) Reset() { *m = ControlPingReply{} }
293 func (*ControlPingReply) GetMessageName() string { return "control_ping_reply" }
294 func (*ControlPingReply) GetCrcString() string { return "f6b0b8ca" }
295 func (*ControlPingReply) GetMessageType() api.MessageType {
296 return api.ReplyMessage
299 func (m *ControlPingReply) Size() (size int) {
303 size += 4 // m.Retval
304 size += 4 // m.ClientIndex
305 size += 4 // m.VpePID
308 func (m *ControlPingReply) Marshal(b []byte) ([]byte, error) {
310 b = make([]byte, m.Size())
312 buf := codec.NewBuffer(b)
313 buf.EncodeInt32(m.Retval)
314 buf.EncodeUint32(m.ClientIndex)
315 buf.EncodeUint32(m.VpePID)
316 return buf.Bytes(), nil
318 func (m *ControlPingReply) Unmarshal(b []byte) error {
319 buf := codec.NewBuffer(b)
320 m.Retval = buf.DecodeInt32()
321 m.ClientIndex = buf.DecodeUint32()
322 m.VpePID = buf.DecodeUint32()
326 // GetF64EndianValue defines message 'get_f64_endian_value'.
327 type GetF64EndianValue struct {
328 F64One float64 `binapi:"f64,name=f64_one,default=1" json:"f64_one,omitempty"`
331 func (m *GetF64EndianValue) Reset() { *m = GetF64EndianValue{} }
332 func (*GetF64EndianValue) GetMessageName() string { return "get_f64_endian_value" }
333 func (*GetF64EndianValue) GetCrcString() string { return "809fcd44" }
334 func (*GetF64EndianValue) GetMessageType() api.MessageType {
335 return api.RequestMessage
338 func (m *GetF64EndianValue) Size() (size int) {
342 size += 8 // m.F64One
345 func (m *GetF64EndianValue) Marshal(b []byte) ([]byte, error) {
347 b = make([]byte, m.Size())
349 buf := codec.NewBuffer(b)
350 buf.EncodeFloat64(m.F64One)
351 return buf.Bytes(), nil
353 func (m *GetF64EndianValue) Unmarshal(b []byte) error {
354 buf := codec.NewBuffer(b)
355 m.F64One = buf.DecodeFloat64()
359 // GetF64EndianValueReply defines message 'get_f64_endian_value_reply'.
360 type GetF64EndianValueReply struct {
361 Retval uint32 `binapi:"u32,name=retval" json:"retval,omitempty"`
362 F64OneResult float64 `binapi:"f64,name=f64_one_result" json:"f64_one_result,omitempty"`
365 func (m *GetF64EndianValueReply) Reset() { *m = GetF64EndianValueReply{} }
366 func (*GetF64EndianValueReply) GetMessageName() string { return "get_f64_endian_value_reply" }
367 func (*GetF64EndianValueReply) GetCrcString() string { return "7e02e404" }
368 func (*GetF64EndianValueReply) GetMessageType() api.MessageType {
369 return api.ReplyMessage
372 func (m *GetF64EndianValueReply) Size() (size int) {
376 size += 4 // m.Retval
377 size += 8 // m.F64OneResult
380 func (m *GetF64EndianValueReply) Marshal(b []byte) ([]byte, error) {
382 b = make([]byte, m.Size())
384 buf := codec.NewBuffer(b)
385 buf.EncodeUint32(m.Retval)
386 buf.EncodeFloat64(m.F64OneResult)
387 return buf.Bytes(), nil
389 func (m *GetF64EndianValueReply) Unmarshal(b []byte) error {
390 buf := codec.NewBuffer(b)
391 m.Retval = buf.DecodeUint32()
392 m.F64OneResult = buf.DecodeFloat64()
396 // GetF64IncrementByOne defines message 'get_f64_increment_by_one'.
397 type GetF64IncrementByOne struct {
398 F64Value float64 `binapi:"f64,name=f64_value,default=1" json:"f64_value,omitempty"`
401 func (m *GetF64IncrementByOne) Reset() { *m = GetF64IncrementByOne{} }
402 func (*GetF64IncrementByOne) GetMessageName() string { return "get_f64_increment_by_one" }
403 func (*GetF64IncrementByOne) GetCrcString() string { return "b64f027e" }
404 func (*GetF64IncrementByOne) GetMessageType() api.MessageType {
405 return api.RequestMessage
408 func (m *GetF64IncrementByOne) Size() (size int) {
412 size += 8 // m.F64Value
415 func (m *GetF64IncrementByOne) Marshal(b []byte) ([]byte, error) {
417 b = make([]byte, m.Size())
419 buf := codec.NewBuffer(b)
420 buf.EncodeFloat64(m.F64Value)
421 return buf.Bytes(), nil
423 func (m *GetF64IncrementByOne) Unmarshal(b []byte) error {
424 buf := codec.NewBuffer(b)
425 m.F64Value = buf.DecodeFloat64()
429 // GetF64IncrementByOneReply defines message 'get_f64_increment_by_one_reply'.
430 type GetF64IncrementByOneReply struct {
431 Retval uint32 `binapi:"u32,name=retval" json:"retval,omitempty"`
432 F64Value float64 `binapi:"f64,name=f64_value" json:"f64_value,omitempty"`
435 func (m *GetF64IncrementByOneReply) Reset() { *m = GetF64IncrementByOneReply{} }
436 func (*GetF64IncrementByOneReply) GetMessageName() string { return "get_f64_increment_by_one_reply" }
437 func (*GetF64IncrementByOneReply) GetCrcString() string { return "d25dbaa3" }
438 func (*GetF64IncrementByOneReply) GetMessageType() api.MessageType {
439 return api.ReplyMessage
442 func (m *GetF64IncrementByOneReply) Size() (size int) {
446 size += 4 // m.Retval
447 size += 8 // m.F64Value
450 func (m *GetF64IncrementByOneReply) Marshal(b []byte) ([]byte, error) {
452 b = make([]byte, m.Size())
454 buf := codec.NewBuffer(b)
455 buf.EncodeUint32(m.Retval)
456 buf.EncodeFloat64(m.F64Value)
457 return buf.Bytes(), nil
459 func (m *GetF64IncrementByOneReply) Unmarshal(b []byte) error {
460 buf := codec.NewBuffer(b)
461 m.Retval = buf.DecodeUint32()
462 m.F64Value = buf.DecodeFloat64()
466 // GetNextIndex defines message 'get_next_index'.
467 type GetNextIndex struct {
468 NodeName string `binapi:"string[64],name=node_name" json:"node_name,omitempty"`
469 NextName string `binapi:"string[64],name=next_name" json:"next_name,omitempty"`
472 func (m *GetNextIndex) Reset() { *m = GetNextIndex{} }
473 func (*GetNextIndex) GetMessageName() string { return "get_next_index" }
474 func (*GetNextIndex) GetCrcString() string { return "2457116d" }
475 func (*GetNextIndex) GetMessageType() api.MessageType {
476 return api.RequestMessage
479 func (m *GetNextIndex) Size() (size int) {
483 size += 64 // m.NodeName
484 size += 64 // m.NextName
487 func (m *GetNextIndex) Marshal(b []byte) ([]byte, error) {
489 b = make([]byte, m.Size())
491 buf := codec.NewBuffer(b)
492 buf.EncodeString(m.NodeName, 64)
493 buf.EncodeString(m.NextName, 64)
494 return buf.Bytes(), nil
496 func (m *GetNextIndex) Unmarshal(b []byte) error {
497 buf := codec.NewBuffer(b)
498 m.NodeName = buf.DecodeString(64)
499 m.NextName = buf.DecodeString(64)
503 // GetNextIndexReply defines message 'get_next_index_reply'.
504 type GetNextIndexReply struct {
505 Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
506 NextIndex uint32 `binapi:"u32,name=next_index" json:"next_index,omitempty"`
509 func (m *GetNextIndexReply) Reset() { *m = GetNextIndexReply{} }
510 func (*GetNextIndexReply) GetMessageName() string { return "get_next_index_reply" }
511 func (*GetNextIndexReply) GetCrcString() string { return "2ed75f32" }
512 func (*GetNextIndexReply) GetMessageType() api.MessageType {
513 return api.ReplyMessage
516 func (m *GetNextIndexReply) Size() (size int) {
520 size += 4 // m.Retval
521 size += 4 // m.NextIndex
524 func (m *GetNextIndexReply) Marshal(b []byte) ([]byte, error) {
526 b = make([]byte, m.Size())
528 buf := codec.NewBuffer(b)
529 buf.EncodeInt32(m.Retval)
530 buf.EncodeUint32(m.NextIndex)
531 return buf.Bytes(), nil
533 func (m *GetNextIndexReply) Unmarshal(b []byte) error {
534 buf := codec.NewBuffer(b)
535 m.Retval = buf.DecodeInt32()
536 m.NextIndex = buf.DecodeUint32()
540 // GetNodeGraph defines message 'get_node_graph'.
541 type GetNodeGraph struct{}
543 func (m *GetNodeGraph) Reset() { *m = GetNodeGraph{} }
544 func (*GetNodeGraph) GetMessageName() string { return "get_node_graph" }
545 func (*GetNodeGraph) GetCrcString() string { return "51077d14" }
546 func (*GetNodeGraph) GetMessageType() api.MessageType {
547 return api.RequestMessage
550 func (m *GetNodeGraph) Size() (size int) {
556 func (m *GetNodeGraph) Marshal(b []byte) ([]byte, error) {
558 b = make([]byte, m.Size())
560 buf := codec.NewBuffer(b)
561 return buf.Bytes(), nil
563 func (m *GetNodeGraph) Unmarshal(b []byte) error {
567 // GetNodeGraphReply defines message 'get_node_graph_reply'.
568 type GetNodeGraphReply struct {
569 Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
570 ReplyInShmem uint64 `binapi:"u64,name=reply_in_shmem" json:"reply_in_shmem,omitempty"`
573 func (m *GetNodeGraphReply) Reset() { *m = GetNodeGraphReply{} }
574 func (*GetNodeGraphReply) GetMessageName() string { return "get_node_graph_reply" }
575 func (*GetNodeGraphReply) GetCrcString() string { return "06d68297" }
576 func (*GetNodeGraphReply) GetMessageType() api.MessageType {
577 return api.ReplyMessage
580 func (m *GetNodeGraphReply) Size() (size int) {
584 size += 4 // m.Retval
585 size += 8 // m.ReplyInShmem
588 func (m *GetNodeGraphReply) Marshal(b []byte) ([]byte, error) {
590 b = make([]byte, m.Size())
592 buf := codec.NewBuffer(b)
593 buf.EncodeInt32(m.Retval)
594 buf.EncodeUint64(m.ReplyInShmem)
595 return buf.Bytes(), nil
597 func (m *GetNodeGraphReply) Unmarshal(b []byte) error {
598 buf := codec.NewBuffer(b)
599 m.Retval = buf.DecodeInt32()
600 m.ReplyInShmem = buf.DecodeUint64()
604 // GetNodeIndex defines message 'get_node_index'.
605 type GetNodeIndex struct {
606 NodeName string `binapi:"string[64],name=node_name" json:"node_name,omitempty"`
609 func (m *GetNodeIndex) Reset() { *m = GetNodeIndex{} }
610 func (*GetNodeIndex) GetMessageName() string { return "get_node_index" }
611 func (*GetNodeIndex) GetCrcString() string { return "f1984c64" }
612 func (*GetNodeIndex) GetMessageType() api.MessageType {
613 return api.RequestMessage
616 func (m *GetNodeIndex) Size() (size int) {
620 size += 64 // m.NodeName
623 func (m *GetNodeIndex) Marshal(b []byte) ([]byte, error) {
625 b = make([]byte, m.Size())
627 buf := codec.NewBuffer(b)
628 buf.EncodeString(m.NodeName, 64)
629 return buf.Bytes(), nil
631 func (m *GetNodeIndex) Unmarshal(b []byte) error {
632 buf := codec.NewBuffer(b)
633 m.NodeName = buf.DecodeString(64)
637 // GetNodeIndexReply defines message 'get_node_index_reply'.
638 type GetNodeIndexReply struct {
639 Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
640 NodeIndex uint32 `binapi:"u32,name=node_index" json:"node_index,omitempty"`
643 func (m *GetNodeIndexReply) Reset() { *m = GetNodeIndexReply{} }
644 func (*GetNodeIndexReply) GetMessageName() string { return "get_node_index_reply" }
645 func (*GetNodeIndexReply) GetCrcString() string { return "a8600b89" }
646 func (*GetNodeIndexReply) GetMessageType() api.MessageType {
647 return api.ReplyMessage
650 func (m *GetNodeIndexReply) Size() (size int) {
654 size += 4 // m.Retval
655 size += 4 // m.NodeIndex
658 func (m *GetNodeIndexReply) Marshal(b []byte) ([]byte, error) {
660 b = make([]byte, m.Size())
662 buf := codec.NewBuffer(b)
663 buf.EncodeInt32(m.Retval)
664 buf.EncodeUint32(m.NodeIndex)
665 return buf.Bytes(), nil
667 func (m *GetNodeIndexReply) Unmarshal(b []byte) error {
668 buf := codec.NewBuffer(b)
669 m.Retval = buf.DecodeInt32()
670 m.NodeIndex = buf.DecodeUint32()
674 // LogDetails defines message 'log_details'.
675 type LogDetails struct {
676 Timestamp vpe_types.Timestamp `binapi:"timestamp,name=timestamp" json:"timestamp,omitempty"`
677 Level vpe_types.LogLevel `binapi:"log_level,name=level" json:"level,omitempty"`
678 MsgClass string `binapi:"string[32],name=msg_class" json:"msg_class,omitempty"`
679 Message string `binapi:"string[256],name=message" json:"message,omitempty"`
682 func (m *LogDetails) Reset() { *m = LogDetails{} }
683 func (*LogDetails) GetMessageName() string { return "log_details" }
684 func (*LogDetails) GetCrcString() string { return "03d61cc0" }
685 func (*LogDetails) GetMessageType() api.MessageType {
686 return api.ReplyMessage
689 func (m *LogDetails) Size() (size int) {
693 size += 8 // m.Timestamp
695 size += 32 // m.MsgClass
696 size += 256 // m.Message
699 func (m *LogDetails) Marshal(b []byte) ([]byte, error) {
701 b = make([]byte, m.Size())
703 buf := codec.NewBuffer(b)
704 buf.EncodeFloat64(float64(m.Timestamp))
705 buf.EncodeUint32(uint32(m.Level))
706 buf.EncodeString(m.MsgClass, 32)
707 buf.EncodeString(m.Message, 256)
708 return buf.Bytes(), nil
710 func (m *LogDetails) Unmarshal(b []byte) error {
711 buf := codec.NewBuffer(b)
712 m.Timestamp = vpe_types.Timestamp(buf.DecodeFloat64())
713 m.Level = vpe_types.LogLevel(buf.DecodeUint32())
714 m.MsgClass = buf.DecodeString(32)
715 m.Message = buf.DecodeString(256)
719 // LogDump defines message 'log_dump'.
720 type LogDump struct {
721 StartTimestamp vpe_types.Timestamp `binapi:"timestamp,name=start_timestamp" json:"start_timestamp,omitempty"`
724 func (m *LogDump) Reset() { *m = LogDump{} }
725 func (*LogDump) GetMessageName() string { return "log_dump" }
726 func (*LogDump) GetCrcString() string { return "6ab31753" }
727 func (*LogDump) GetMessageType() api.MessageType {
728 return api.RequestMessage
731 func (m *LogDump) Size() (size int) {
735 size += 8 // m.StartTimestamp
738 func (m *LogDump) Marshal(b []byte) ([]byte, error) {
740 b = make([]byte, m.Size())
742 buf := codec.NewBuffer(b)
743 buf.EncodeFloat64(float64(m.StartTimestamp))
744 return buf.Bytes(), nil
746 func (m *LogDump) Unmarshal(b []byte) error {
747 buf := codec.NewBuffer(b)
748 m.StartTimestamp = vpe_types.Timestamp(buf.DecodeFloat64())
752 // ShowThreads defines message 'show_threads'.
753 type ShowThreads struct{}
755 func (m *ShowThreads) Reset() { *m = ShowThreads{} }
756 func (*ShowThreads) GetMessageName() string { return "show_threads" }
757 func (*ShowThreads) GetCrcString() string { return "51077d14" }
758 func (*ShowThreads) GetMessageType() api.MessageType {
759 return api.RequestMessage
762 func (m *ShowThreads) Size() (size int) {
768 func (m *ShowThreads) Marshal(b []byte) ([]byte, error) {
770 b = make([]byte, m.Size())
772 buf := codec.NewBuffer(b)
773 return buf.Bytes(), nil
775 func (m *ShowThreads) Unmarshal(b []byte) error {
779 // ShowThreadsReply defines message 'show_threads_reply'.
780 type ShowThreadsReply struct {
781 Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
782 Count uint32 `binapi:"u32,name=count" json:"-"`
783 ThreadData []ThreadData `binapi:"thread_data[count],name=thread_data" json:"thread_data,omitempty"`
786 func (m *ShowThreadsReply) Reset() { *m = ShowThreadsReply{} }
787 func (*ShowThreadsReply) GetMessageName() string { return "show_threads_reply" }
788 func (*ShowThreadsReply) GetCrcString() string { return "efd78e83" }
789 func (*ShowThreadsReply) GetMessageType() api.MessageType {
790 return api.ReplyMessage
793 func (m *ShowThreadsReply) Size() (size int) {
797 size += 4 // m.Retval
799 for j1 := 0; j1 < len(m.ThreadData); j1++ {
802 if j1 < len(m.ThreadData) {
803 s1 = m.ThreadData[j1]
806 size += 64 // s1.Name
807 size += 64 // s1.Type
809 size += 4 // s1.CPUID
811 size += 4 // s1.CPUSocket
815 func (m *ShowThreadsReply) Marshal(b []byte) ([]byte, error) {
817 b = make([]byte, m.Size())
819 buf := codec.NewBuffer(b)
820 buf.EncodeInt32(m.Retval)
821 buf.EncodeUint32(uint32(len(m.ThreadData)))
822 for j0 := 0; j0 < len(m.ThreadData); j0++ {
823 var v0 ThreadData // ThreadData
824 if j0 < len(m.ThreadData) {
825 v0 = m.ThreadData[j0]
827 buf.EncodeUint32(v0.ID)
828 buf.EncodeString(v0.Name, 64)
829 buf.EncodeString(v0.Type, 64)
830 buf.EncodeUint32(v0.PID)
831 buf.EncodeUint32(v0.CPUID)
832 buf.EncodeUint32(v0.Core)
833 buf.EncodeUint32(v0.CPUSocket)
835 return buf.Bytes(), nil
837 func (m *ShowThreadsReply) Unmarshal(b []byte) error {
838 buf := codec.NewBuffer(b)
839 m.Retval = buf.DecodeInt32()
840 m.Count = buf.DecodeUint32()
841 m.ThreadData = make([]ThreadData, m.Count)
842 for j0 := 0; j0 < len(m.ThreadData); j0++ {
843 m.ThreadData[j0].ID = buf.DecodeUint32()
844 m.ThreadData[j0].Name = buf.DecodeString(64)
845 m.ThreadData[j0].Type = buf.DecodeString(64)
846 m.ThreadData[j0].PID = buf.DecodeUint32()
847 m.ThreadData[j0].CPUID = buf.DecodeUint32()
848 m.ThreadData[j0].Core = buf.DecodeUint32()
849 m.ThreadData[j0].CPUSocket = buf.DecodeUint32()
854 // ShowVersion defines message 'show_version'.
855 type ShowVersion struct{}
857 func (m *ShowVersion) Reset() { *m = ShowVersion{} }
858 func (*ShowVersion) GetMessageName() string { return "show_version" }
859 func (*ShowVersion) GetCrcString() string { return "51077d14" }
860 func (*ShowVersion) GetMessageType() api.MessageType {
861 return api.RequestMessage
864 func (m *ShowVersion) Size() (size int) {
870 func (m *ShowVersion) Marshal(b []byte) ([]byte, error) {
872 b = make([]byte, m.Size())
874 buf := codec.NewBuffer(b)
875 return buf.Bytes(), nil
877 func (m *ShowVersion) Unmarshal(b []byte) error {
881 // ShowVersionReply defines message 'show_version_reply'.
882 type ShowVersionReply struct {
883 Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
884 Program string `binapi:"string[32],name=program" json:"program,omitempty"`
885 Version string `binapi:"string[32],name=version" json:"version,omitempty"`
886 BuildDate string `binapi:"string[32],name=build_date" json:"build_date,omitempty"`
887 BuildDirectory string `binapi:"string[256],name=build_directory" json:"build_directory,omitempty"`
890 func (m *ShowVersionReply) Reset() { *m = ShowVersionReply{} }
891 func (*ShowVersionReply) GetMessageName() string { return "show_version_reply" }
892 func (*ShowVersionReply) GetCrcString() string { return "c919bde1" }
893 func (*ShowVersionReply) GetMessageType() api.MessageType {
894 return api.ReplyMessage
897 func (m *ShowVersionReply) Size() (size int) {
901 size += 4 // m.Retval
902 size += 32 // m.Program
903 size += 32 // m.Version
904 size += 32 // m.BuildDate
905 size += 256 // m.BuildDirectory
908 func (m *ShowVersionReply) Marshal(b []byte) ([]byte, error) {
910 b = make([]byte, m.Size())
912 buf := codec.NewBuffer(b)
913 buf.EncodeInt32(m.Retval)
914 buf.EncodeString(m.Program, 32)
915 buf.EncodeString(m.Version, 32)
916 buf.EncodeString(m.BuildDate, 32)
917 buf.EncodeString(m.BuildDirectory, 256)
918 return buf.Bytes(), nil
920 func (m *ShowVersionReply) Unmarshal(b []byte) error {
921 buf := codec.NewBuffer(b)
922 m.Retval = buf.DecodeInt32()
923 m.Program = buf.DecodeString(32)
924 m.Version = buf.DecodeString(32)
925 m.BuildDate = buf.DecodeString(32)
926 m.BuildDirectory = buf.DecodeString(256)
930 // ShowVpeSystemTime defines message 'show_vpe_system_time'.
931 type ShowVpeSystemTime struct{}
933 func (m *ShowVpeSystemTime) Reset() { *m = ShowVpeSystemTime{} }
934 func (*ShowVpeSystemTime) GetMessageName() string { return "show_vpe_system_time" }
935 func (*ShowVpeSystemTime) GetCrcString() string { return "51077d14" }
936 func (*ShowVpeSystemTime) GetMessageType() api.MessageType {
937 return api.RequestMessage
940 func (m *ShowVpeSystemTime) Size() (size int) {
946 func (m *ShowVpeSystemTime) Marshal(b []byte) ([]byte, error) {
948 b = make([]byte, m.Size())
950 buf := codec.NewBuffer(b)
951 return buf.Bytes(), nil
953 func (m *ShowVpeSystemTime) Unmarshal(b []byte) error {
957 // ShowVpeSystemTimeReply defines message 'show_vpe_system_time_reply'.
958 type ShowVpeSystemTimeReply struct {
959 Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
960 VpeSystemTime vpe_types.Timestamp `binapi:"timestamp,name=vpe_system_time" json:"vpe_system_time,omitempty"`
963 func (m *ShowVpeSystemTimeReply) Reset() { *m = ShowVpeSystemTimeReply{} }
964 func (*ShowVpeSystemTimeReply) GetMessageName() string { return "show_vpe_system_time_reply" }
965 func (*ShowVpeSystemTimeReply) GetCrcString() string { return "7ffd8193" }
966 func (*ShowVpeSystemTimeReply) GetMessageType() api.MessageType {
967 return api.ReplyMessage
970 func (m *ShowVpeSystemTimeReply) Size() (size int) {
974 size += 4 // m.Retval
975 size += 8 // m.VpeSystemTime
978 func (m *ShowVpeSystemTimeReply) Marshal(b []byte) ([]byte, error) {
980 b = make([]byte, m.Size())
982 buf := codec.NewBuffer(b)
983 buf.EncodeInt32(m.Retval)
984 buf.EncodeFloat64(float64(m.VpeSystemTime))
985 return buf.Bytes(), nil
987 func (m *ShowVpeSystemTimeReply) Unmarshal(b []byte) error {
988 buf := codec.NewBuffer(b)
989 m.Retval = buf.DecodeInt32()
990 m.VpeSystemTime = vpe_types.Timestamp(buf.DecodeFloat64())
994 func init() { file_vpe_binapi_init() }
995 func file_vpe_binapi_init() {
996 api.RegisterMessage((*AddNodeNext)(nil), "add_node_next_2457116d")
997 api.RegisterMessage((*AddNodeNextReply)(nil), "add_node_next_reply_2ed75f32")
998 api.RegisterMessage((*Cli)(nil), "cli_23bfbfff")
999 api.RegisterMessage((*CliInband)(nil), "cli_inband_f8377302")
1000 api.RegisterMessage((*CliInbandReply)(nil), "cli_inband_reply_05879051")
1001 api.RegisterMessage((*CliReply)(nil), "cli_reply_06d68297")
1002 api.RegisterMessage((*ControlPing)(nil), "control_ping_51077d14")
1003 api.RegisterMessage((*ControlPingReply)(nil), "control_ping_reply_f6b0b8ca")
1004 api.RegisterMessage((*GetF64EndianValue)(nil), "get_f64_endian_value_809fcd44")
1005 api.RegisterMessage((*GetF64EndianValueReply)(nil), "get_f64_endian_value_reply_7e02e404")
1006 api.RegisterMessage((*GetF64IncrementByOne)(nil), "get_f64_increment_by_one_b64f027e")
1007 api.RegisterMessage((*GetF64IncrementByOneReply)(nil), "get_f64_increment_by_one_reply_d25dbaa3")
1008 api.RegisterMessage((*GetNextIndex)(nil), "get_next_index_2457116d")
1009 api.RegisterMessage((*GetNextIndexReply)(nil), "get_next_index_reply_2ed75f32")
1010 api.RegisterMessage((*GetNodeGraph)(nil), "get_node_graph_51077d14")
1011 api.RegisterMessage((*GetNodeGraphReply)(nil), "get_node_graph_reply_06d68297")
1012 api.RegisterMessage((*GetNodeIndex)(nil), "get_node_index_f1984c64")
1013 api.RegisterMessage((*GetNodeIndexReply)(nil), "get_node_index_reply_a8600b89")
1014 api.RegisterMessage((*LogDetails)(nil), "log_details_03d61cc0")
1015 api.RegisterMessage((*LogDump)(nil), "log_dump_6ab31753")
1016 api.RegisterMessage((*ShowThreads)(nil), "show_threads_51077d14")
1017 api.RegisterMessage((*ShowThreadsReply)(nil), "show_threads_reply_efd78e83")
1018 api.RegisterMessage((*ShowVersion)(nil), "show_version_51077d14")
1019 api.RegisterMessage((*ShowVersionReply)(nil), "show_version_reply_c919bde1")
1020 api.RegisterMessage((*ShowVpeSystemTime)(nil), "show_vpe_system_time_51077d14")
1021 api.RegisterMessage((*ShowVpeSystemTimeReply)(nil), "show_vpe_system_time_reply_7ffd8193")
1024 // Messages returns list of all messages in this module.
1025 func AllMessages() []api.Message {
1026 return []api.Message{
1027 (*AddNodeNext)(nil),
1028 (*AddNodeNextReply)(nil),
1031 (*CliInbandReply)(nil),
1033 (*ControlPing)(nil),
1034 (*ControlPingReply)(nil),
1035 (*GetF64EndianValue)(nil),
1036 (*GetF64EndianValueReply)(nil),
1037 (*GetF64IncrementByOne)(nil),
1038 (*GetF64IncrementByOneReply)(nil),
1039 (*GetNextIndex)(nil),
1040 (*GetNextIndexReply)(nil),
1041 (*GetNodeGraph)(nil),
1042 (*GetNodeGraphReply)(nil),
1043 (*GetNodeIndex)(nil),
1044 (*GetNodeIndexReply)(nil),
1047 (*ShowThreads)(nil),
1048 (*ShowThreadsReply)(nil),
1049 (*ShowVersion)(nil),
1050 (*ShowVersionReply)(nil),
1051 (*ShowVpeSystemTime)(nil),
1052 (*ShowVpeSystemTimeReply)(nil),