1 // Code generated by GoVPP's binapi-generator. DO NOT EDIT.
3 // binapi-generator: v0.4.0-dev
5 // source: /usr/share/vpp/api/core/rd_cp.api.json
7 // Package rd_cp contains generated bindings for API file rd_cp.api.
15 api "git.fd.io/govpp.git/api"
16 interface_types "git.fd.io/govpp.git/binapi/interface_types"
17 codec "git.fd.io/govpp.git/codec"
20 // This is a compile-time assertion to ensure that this generated file
21 // is compatible with the GoVPP api package it is being compiled against.
22 // A compilation error at this line likely means your copy of the
23 // GoVPP api package needs to be updated.
24 const _ = api.GoVppAPIPackageIsVersion2
29 VersionCrc = 0x2caa616
32 // IP6NdAddressAutoconfig defines message 'ip6_nd_address_autoconfig'.
33 type IP6NdAddressAutoconfig struct {
34 SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
35 Enable bool `binapi:"bool,name=enable" json:"enable,omitempty"`
36 InstallDefaultRoutes bool `binapi:"bool,name=install_default_routes" json:"install_default_routes,omitempty"`
39 func (m *IP6NdAddressAutoconfig) Reset() { *m = IP6NdAddressAutoconfig{} }
40 func (*IP6NdAddressAutoconfig) GetMessageName() string { return "ip6_nd_address_autoconfig" }
41 func (*IP6NdAddressAutoconfig) GetCrcString() string { return "9e14a4a7" }
42 func (*IP6NdAddressAutoconfig) GetMessageType() api.MessageType {
43 return api.RequestMessage
46 func (m *IP6NdAddressAutoconfig) Size() int {
51 size += 4 // m.SwIfIndex
53 size += 1 // m.InstallDefaultRoutes
56 func (m *IP6NdAddressAutoconfig) Marshal(b []byte) ([]byte, error) {
59 buf = codec.NewBuffer(make([]byte, m.Size()))
61 buf = codec.NewBuffer(b)
63 buf.EncodeUint32(uint32(m.SwIfIndex))
64 buf.EncodeBool(m.Enable)
65 buf.EncodeBool(m.InstallDefaultRoutes)
66 return buf.Bytes(), nil
68 func (m *IP6NdAddressAutoconfig) Unmarshal(b []byte) error {
69 buf := codec.NewBuffer(b)
70 m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
71 m.Enable = buf.DecodeBool()
72 m.InstallDefaultRoutes = buf.DecodeBool()
76 // IP6NdAddressAutoconfigReply defines message 'ip6_nd_address_autoconfig_reply'.
77 type IP6NdAddressAutoconfigReply struct {
78 Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
81 func (m *IP6NdAddressAutoconfigReply) Reset() { *m = IP6NdAddressAutoconfigReply{} }
82 func (*IP6NdAddressAutoconfigReply) GetMessageName() string { return "ip6_nd_address_autoconfig_reply" }
83 func (*IP6NdAddressAutoconfigReply) GetCrcString() string { return "e8d4e804" }
84 func (*IP6NdAddressAutoconfigReply) GetMessageType() api.MessageType {
85 return api.ReplyMessage
88 func (m *IP6NdAddressAutoconfigReply) Size() int {
96 func (m *IP6NdAddressAutoconfigReply) Marshal(b []byte) ([]byte, error) {
99 buf = codec.NewBuffer(make([]byte, m.Size()))
101 buf = codec.NewBuffer(b)
103 buf.EncodeUint32(uint32(m.Retval))
104 return buf.Bytes(), nil
106 func (m *IP6NdAddressAutoconfigReply) Unmarshal(b []byte) error {
107 buf := codec.NewBuffer(b)
108 m.Retval = int32(buf.DecodeUint32())
112 func init() { file_rd_cp_binapi_init() }
113 func file_rd_cp_binapi_init() {
114 api.RegisterMessage((*IP6NdAddressAutoconfig)(nil), "ip6_nd_address_autoconfig_9e14a4a7")
115 api.RegisterMessage((*IP6NdAddressAutoconfigReply)(nil), "ip6_nd_address_autoconfig_reply_e8d4e804")
118 // Messages returns list of all messages in this module.
119 func AllMessages() []api.Message {
120 return []api.Message{
121 (*IP6NdAddressAutoconfig)(nil),
122 (*IP6NdAddressAutoconfigReply)(nil),