6a93afd0436ecf00da91101746a2619c5fd5c429
[govpp.git] / binapi / vpe_types / vpe_types.ba.go
1 // Code generated by GoVPP's binapi-generator. DO NOT EDIT.
2 // versions:
3 //  binapi-generator: v0.4.0-dev
4 //  VPP:              20.05-release
5
6 // Package vpe_types contains generated bindings for API file vpe_types.api.
7 //
8 // Contents:
9 //   2 aliases
10 //   1 enum
11 //   1 struct
12 //
13 package vpe_types
14
15 import (
16         "strconv"
17
18         api "git.fd.io/govpp.git/api"
19 )
20
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
26
27 // LogLevel defines enum 'log_level'.
28 type LogLevel uint32
29
30 const (
31         VPE_API_LOG_LEVEL_EMERG    LogLevel = 0
32         VPE_API_LOG_LEVEL_ALERT    LogLevel = 1
33         VPE_API_LOG_LEVEL_CRIT     LogLevel = 2
34         VPE_API_LOG_LEVEL_ERR      LogLevel = 3
35         VPE_API_LOG_LEVEL_WARNING  LogLevel = 4
36         VPE_API_LOG_LEVEL_NOTICE   LogLevel = 5
37         VPE_API_LOG_LEVEL_INFO     LogLevel = 6
38         VPE_API_LOG_LEVEL_DEBUG    LogLevel = 7
39         VPE_API_LOG_LEVEL_DISABLED LogLevel = 8
40 )
41
42 var (
43         LogLevel_name = map[uint32]string{
44                 0: "VPE_API_LOG_LEVEL_EMERG",
45                 1: "VPE_API_LOG_LEVEL_ALERT",
46                 2: "VPE_API_LOG_LEVEL_CRIT",
47                 3: "VPE_API_LOG_LEVEL_ERR",
48                 4: "VPE_API_LOG_LEVEL_WARNING",
49                 5: "VPE_API_LOG_LEVEL_NOTICE",
50                 6: "VPE_API_LOG_LEVEL_INFO",
51                 7: "VPE_API_LOG_LEVEL_DEBUG",
52                 8: "VPE_API_LOG_LEVEL_DISABLED",
53         }
54         LogLevel_value = map[string]uint32{
55                 "VPE_API_LOG_LEVEL_EMERG":    0,
56                 "VPE_API_LOG_LEVEL_ALERT":    1,
57                 "VPE_API_LOG_LEVEL_CRIT":     2,
58                 "VPE_API_LOG_LEVEL_ERR":      3,
59                 "VPE_API_LOG_LEVEL_WARNING":  4,
60                 "VPE_API_LOG_LEVEL_NOTICE":   5,
61                 "VPE_API_LOG_LEVEL_INFO":     6,
62                 "VPE_API_LOG_LEVEL_DEBUG":    7,
63                 "VPE_API_LOG_LEVEL_DISABLED": 8,
64         }
65 )
66
67 func (x LogLevel) String() string {
68         s, ok := LogLevel_name[uint32(x)]
69         if ok {
70                 return s
71         }
72         return "LogLevel(" + strconv.Itoa(int(x)) + ")"
73 }
74
75 // Timedelta defines alias 'timedelta'.
76 type Timedelta float64
77
78 // Timestamp defines alias 'timestamp'.
79 type Timestamp float64
80
81 // Version defines type 'version'.
82 type Version struct {
83         Major         uint32 `binapi:"u32,name=major" json:"major,omitempty"`
84         Minor         uint32 `binapi:"u32,name=minor" json:"minor,omitempty"`
85         Patch         uint32 `binapi:"u32,name=patch" json:"patch,omitempty"`
86         PreRelease    []byte `binapi:"u8[17],name=pre_release" json:"pre_release,omitempty"`
87         BuildMetadata []byte `binapi:"u8[17],name=build_metadata" json:"build_metadata,omitempty"`
88 }