1 // Code generated by GoVPP's binapi-generator. DO NOT EDIT.
3 // binapi-generator: v0.4.0-dev
6 // Package rd_cp contains generated bindings for API file rd_cp.api.
14 api "git.fd.io/govpp.git/api"
15 interface_types "git.fd.io/govpp.git/binapi/interface_types"
16 codec "git.fd.io/govpp.git/codec"
19 // This is a compile-time assertion to ensure that this generated file
20 // is compatible with the GoVPP api package it is being compiled against.
21 // A compilation error at this line likely means your copy of the
22 // GoVPP api package needs to be updated.
23 const _ = api.GoVppAPIPackageIsVersion2
28 VersionCrc = 0x2caa616
31 // IP6NdAddressAutoconfig defines message 'ip6_nd_address_autoconfig'.
32 type IP6NdAddressAutoconfig struct {
33 SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
34 Enable bool `binapi:"bool,name=enable" json:"enable,omitempty"`
35 InstallDefaultRoutes bool `binapi:"bool,name=install_default_routes" json:"install_default_routes,omitempty"`
38 func (m *IP6NdAddressAutoconfig) Reset() { *m = IP6NdAddressAutoconfig{} }
39 func (*IP6NdAddressAutoconfig) GetMessageName() string { return "ip6_nd_address_autoconfig" }
40 func (*IP6NdAddressAutoconfig) GetCrcString() string { return "9e14a4a7" }
41 func (*IP6NdAddressAutoconfig) GetMessageType() api.MessageType {
42 return api.RequestMessage
45 func (m *IP6NdAddressAutoconfig) Size() (size int) {
49 size += 4 // m.SwIfIndex
51 size += 1 // m.InstallDefaultRoutes
54 func (m *IP6NdAddressAutoconfig) Marshal(b []byte) ([]byte, error) {
56 b = make([]byte, m.Size())
58 buf := codec.NewBuffer(b)
59 buf.EncodeUint32(uint32(m.SwIfIndex))
60 buf.EncodeBool(m.Enable)
61 buf.EncodeBool(m.InstallDefaultRoutes)
62 return buf.Bytes(), nil
64 func (m *IP6NdAddressAutoconfig) Unmarshal(b []byte) error {
65 buf := codec.NewBuffer(b)
66 m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
67 m.Enable = buf.DecodeBool()
68 m.InstallDefaultRoutes = buf.DecodeBool()
72 // IP6NdAddressAutoconfigReply defines message 'ip6_nd_address_autoconfig_reply'.
73 type IP6NdAddressAutoconfigReply struct {
74 Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
77 func (m *IP6NdAddressAutoconfigReply) Reset() { *m = IP6NdAddressAutoconfigReply{} }
78 func (*IP6NdAddressAutoconfigReply) GetMessageName() string { return "ip6_nd_address_autoconfig_reply" }
79 func (*IP6NdAddressAutoconfigReply) GetCrcString() string { return "e8d4e804" }
80 func (*IP6NdAddressAutoconfigReply) GetMessageType() api.MessageType {
81 return api.ReplyMessage
84 func (m *IP6NdAddressAutoconfigReply) Size() (size int) {
91 func (m *IP6NdAddressAutoconfigReply) Marshal(b []byte) ([]byte, error) {
93 b = make([]byte, m.Size())
95 buf := codec.NewBuffer(b)
96 buf.EncodeInt32(m.Retval)
97 return buf.Bytes(), nil
99 func (m *IP6NdAddressAutoconfigReply) Unmarshal(b []byte) error {
100 buf := codec.NewBuffer(b)
101 m.Retval = buf.DecodeInt32()
105 func init() { file_rd_cp_binapi_init() }
106 func file_rd_cp_binapi_init() {
107 api.RegisterMessage((*IP6NdAddressAutoconfig)(nil), "ip6_nd_address_autoconfig_9e14a4a7")
108 api.RegisterMessage((*IP6NdAddressAutoconfigReply)(nil), "ip6_nd_address_autoconfig_reply_e8d4e804")
111 // Messages returns list of all messages in this module.
112 func AllMessages() []api.Message {
113 return []api.Message{
114 (*IP6NdAddressAutoconfig)(nil),
115 (*IP6NdAddressAutoconfigReply)(nil),