blob: d50980da1350c95daa135cb9a159d7e4e324aeea [file] [log] [blame]
Naveen Sampath04696f72022-06-13 15:19:14 +05301/*
2* Copyright 2022-present Open Networking Foundation
3* Licensed under the Apache License, Version 2.0 (the "License");
4* you may not use this file except in compliance with the License.
5* You may obtain a copy of the License at
6*
7* http://www.apache.org/licenses/LICENSE-2.0
8*
9* Unless required by applicable law or agreed to in writing, software
10* distributed under the License is distributed on an "AS IS" BASIS,
11* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12* See the License for the specific language governing permissions and
13* limitations under the License.
14 */
15
Naveen Sampath04696f72022-06-13 15:19:14 +053016package common
vinokuma926cb3e2023-03-29 11:41:06 +053017
Naveen Sampath04696f72022-06-13 15:19:14 +053018import (
19 "errors"
20)
21
vinokuma926cb3e2023-03-29 11:41:06 +053022// AdminState represents Status of an VLAN:ENABLE/DISABLE
Naveen Sampath04696f72022-06-13 15:19:14 +053023type AdminState string
24
25var (
26 // ErrEntryNotFound is the error when the key doesn't exist in the KVStore
27 ErrEntryNotFound = errors.New("Entry not found")
28)
vinokuma926cb3e2023-03-29 11:41:06 +053029
Naveen Sampath04696f72022-06-13 15:19:14 +053030// DeviceState refers to the state of device
31type DeviceState string
32
33// Device State constants
34const (
35 DeviceStateDOWN DeviceState = "DOWN"
36 DeviceStateUP DeviceState = "UP"
37)
38
39// Status represents the status of the request sent to the device manager.
40type Status string
41
vinokuma926cb3e2023-03-29 11:41:06 +053042// LogLevel represents the type of the OLT's LOG
Naveen Sampath04696f72022-06-13 15:19:14 +053043type LogLevel int
44
45const (
vinokuma926cb3e2023-03-29 11:41:06 +053046 // CRITICAL represents log level type of the OLT.
47 CRITICAL LogLevel = iota
48 // ERROR represents log level type of the OLT.
49 ERROR
50 // WARNING represents log level type of the OLT.
51 WARNING
52 // INFO represents log level type of the OLT.
53 INFO
54 // DEBUG represents log level type of the OLT.
55 DEBUG
Naveen Sampath04696f72022-06-13 15:19:14 +053056)