// Code generated by GoVPP's binapi-generator. DO NOT EDIT. // versions: // binapi-generator: v0.5.0-dev // VPP: 20.01 // source: .vppapi/core/l2.api.json // Package l2 contains generated bindings for API file l2.api. // // Contents: // 7 aliases // 12 enums // 9 structs // 1 union // 54 messages // package l2 import ( "fmt" "net" "strconv" "strings" api "git.fd.io/govpp.git/api" codec "git.fd.io/govpp.git/codec" ) // This is a compile-time assertion to ensure that this generated file // is compatible with the GoVPP api package it is being compiled against. // A compilation error at this line likely means your copy of the // GoVPP api package needs to be updated. const _ = api.GoVppAPIPackageIsVersion2 const ( APIFile = "l2" APIVersion = "2.2.2" VersionCrc = 0x2e148df3 ) // AddressFamily defines enum 'address_family'. type AddressFamily uint32 const ( ADDRESS_IP4 AddressFamily = 0 ADDRESS_IP6 AddressFamily = 1 ) var ( AddressFamily_name = map[uint32]string{ 0: "ADDRESS_IP4", 1: "ADDRESS_IP6", } AddressFamily_value = map[string]uint32{ "ADDRESS_IP4": 0, "ADDRESS_IP6": 1, } ) func (x AddressFamily) String() string { s, ok := AddressFamily_name[uint32(x)] if ok { return s } return "AddressFamily(" + strconv.Itoa(int(x)) + ")" } // BdFlags defines enum 'bd_flags'. type BdFlags uint32 const ( BRIDGE_API_FLAG_NONE BdFlags = 0 BRIDGE_API_FLAG_LEARN BdFlags = 1 BRIDGE_API_FLAG_FWD BdFlags = 2 BRIDGE_API_FLAG_FLOOD BdFlags = 4 BRIDGE_API_FLAG_UU_FLOOD BdFlags = 8 BRIDGE_API_FLAG_ARP_TERM BdFlags = 16 BRIDGE_API_FLAG_ARP_UFWD BdFlags = 32 ) var ( BdFlags_name = map[uint32]string{ 0: "BRIDGE_API_FLAG_NONE", 1: "BRIDGE_API_FLAG_LEARN", 2: "BRIDGE_API_FLAG_FWD", 4: "BRIDGE_API_FLAG_FLOOD", 8: "BRIDGE_API_FLAG_UU_FLOOD", 16: "BRIDGE_API_FLAG_ARP_TERM", 32: "BRIDGE_API_FLAG_ARP_UFWD", } BdFlags_value = map[string]uint32{ "BRIDGE_API_FLAG_NONE": 0, "BRIDGE_API_FLAG_LEARN": 1, "BRIDGE_API_FLAG_FWD": 2, "BRIDGE_API_FLAG_FLOOD": 4, "BRIDGE_API_FLAG_UU_FLOOD": 8, "BRIDGE_API_FLAG_ARP_TERM": 16, "BRIDGE_API_FLAG_ARP_UFWD": 32, } ) func (x BdFlags) String() string { s, ok := BdFlags_name[uint32(x)] if ok { return s } str := func(n uint32) string { s, ok := BdFlags_name[uint32(n)] if ok { return s } return "BdFlags(" + strconv.Itoa(int(n)) + ")" } for i := uint32(0); i <= 32; i++ { val := uint32(x) if val&(1<