blob: 116c7dcd164ac4c5061d7c4555be2f56378eccc1 [file] [log] [blame]
khenaidooab1f7bd2019-11-14 14:00:27 -05001/*
2 * Copyright 2019-present Open Networking Foundation
3
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7
8 * http://www.apache.org/licenses/LICENSE-2.0
9
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
npujar1d86a522019-11-14 17:11:16 +053016
khenaidooab1f7bd2019-11-14 14:00:27 -050017package mocks
18
19import (
20 "context"
npujar1d86a522019-11-14 17:11:16 +053021
serkant.uluderya2ae470f2020-01-21 11:13:09 -080022 "github.com/opencord/voltha-protos/v3/go/voltha"
khenaidooab1f7bd2019-11-14 14:00:27 -050023)
24
npujar1d86a522019-11-14 17:11:16 +053025// DeviceManager -
khenaidooab1f7bd2019-11-14 14:00:27 -050026type DeviceManager struct {
27}
28
npujar1d86a522019-11-14 17:11:16 +053029// GetDevice -
npujar467fe752020-01-16 20:17:45 +053030func (dm *DeviceManager) GetDevice(ctx context.Context, deviceID string) (*voltha.Device, error) {
khenaidooab1f7bd2019-11-14 14:00:27 -050031 return nil, nil
32}
npujar1d86a522019-11-14 17:11:16 +053033
34// IsRootDevice -
35func (dm *DeviceManager) IsRootDevice(deviceID string) (bool, error) {
khenaidooab1f7bd2019-11-14 14:00:27 -050036 return false, nil
37}
38
npujar1d86a522019-11-14 17:11:16 +053039// NotifyInvalidTransition -
npujar467fe752020-01-16 20:17:45 +053040func (dm *DeviceManager) NotifyInvalidTransition(ctx context.Context, pcDevice *voltha.Device) error {
khenaidooab1f7bd2019-11-14 14:00:27 -050041 return nil
42}
43
npujar1d86a522019-11-14 17:11:16 +053044// SetAdminStateToEnable -
npujar467fe752020-01-16 20:17:45 +053045func (dm *DeviceManager) SetAdminStateToEnable(ctx context.Context, cDevice *voltha.Device) error {
khenaidooab1f7bd2019-11-14 14:00:27 -050046 return nil
47}
48
npujar1d86a522019-11-14 17:11:16 +053049// CreateLogicalDevice -
npujar467fe752020-01-16 20:17:45 +053050func (dm *DeviceManager) CreateLogicalDevice(ctx context.Context, cDevice *voltha.Device) error {
khenaidooab1f7bd2019-11-14 14:00:27 -050051 return nil
52}
53
npujar1d86a522019-11-14 17:11:16 +053054// SetupUNILogicalPorts -
npujar467fe752020-01-16 20:17:45 +053055func (dm *DeviceManager) SetupUNILogicalPorts(ctx context.Context, cDevice *voltha.Device) error {
khenaidooab1f7bd2019-11-14 14:00:27 -050056 return nil
57}
58
npujar1d86a522019-11-14 17:11:16 +053059// DisableAllChildDevices -
npujar467fe752020-01-16 20:17:45 +053060func (dm *DeviceManager) DisableAllChildDevices(ctx context.Context, cDevice *voltha.Device) error {
khenaidooab1f7bd2019-11-14 14:00:27 -050061 return nil
62}
63
npujar1d86a522019-11-14 17:11:16 +053064// DeleteLogicalDevice -
npujar467fe752020-01-16 20:17:45 +053065func (dm *DeviceManager) DeleteLogicalDevice(ctx context.Context, cDevice *voltha.Device) error {
khenaidooab1f7bd2019-11-14 14:00:27 -050066 return nil
67}
68
npujar1d86a522019-11-14 17:11:16 +053069// DeleteLogicalPorts -
npujar467fe752020-01-16 20:17:45 +053070func (dm *DeviceManager) DeleteLogicalPorts(ctx context.Context, cDevice *voltha.Device) error {
khenaidooab1f7bd2019-11-14 14:00:27 -050071 return nil
72}
73
npujar1d86a522019-11-14 17:11:16 +053074// DeleteAllChildDevices -
npujar467fe752020-01-16 20:17:45 +053075func (dm *DeviceManager) DeleteAllChildDevices(ctx context.Context, cDevice *voltha.Device) error {
khenaidooab1f7bd2019-11-14 14:00:27 -050076 return nil
77}
78
npujar1d86a522019-11-14 17:11:16 +053079// RunPostDeviceDelete -
npujar467fe752020-01-16 20:17:45 +053080func (dm *DeviceManager) RunPostDeviceDelete(ctx context.Context, cDevice *voltha.Device) error {
khenaidooab1f7bd2019-11-14 14:00:27 -050081 return nil
82}
83
npujar1d86a522019-11-14 17:11:16 +053084// ListDevices -
khenaidooab1f7bd2019-11-14 14:00:27 -050085func (dm *DeviceManager) ListDevices() (*voltha.Devices, error) {
86 return nil, nil
87}
88
npujar1d86a522019-11-14 17:11:16 +053089// ListDeviceIds -
khenaidooab1f7bd2019-11-14 14:00:27 -050090func (dm *DeviceManager) ListDeviceIds() (*voltha.IDs, error) {
91 return nil, nil
92}
93
npujar1d86a522019-11-14 17:11:16 +053094// ReconcileDevices -
khenaidooab1f7bd2019-11-14 14:00:27 -050095func (dm *DeviceManager) ReconcileDevices(ctx context.Context, ids *voltha.IDs, ch chan interface{}) {
96}
97
npujar1d86a522019-11-14 17:11:16 +053098// CreateDevice -
khenaidooab1f7bd2019-11-14 14:00:27 -050099func (dm *DeviceManager) CreateDevice(ctx context.Context, device *voltha.Device, ch chan interface{}) {
100}
101
npujar1d86a522019-11-14 17:11:16 +0530102// EnableDevice -
khenaidooab1f7bd2019-11-14 14:00:27 -0500103func (dm *DeviceManager) EnableDevice(ctx context.Context, id *voltha.ID, ch chan interface{}) {
104}
105
npujar1d86a522019-11-14 17:11:16 +0530106// DisableDevice -
khenaidooab1f7bd2019-11-14 14:00:27 -0500107func (dm *DeviceManager) DisableDevice(ctx context.Context, id *voltha.ID, ch chan interface{}) {
108}
109
npujar1d86a522019-11-14 17:11:16 +0530110// RebootDevice -
khenaidooab1f7bd2019-11-14 14:00:27 -0500111func (dm *DeviceManager) RebootDevice(ctx context.Context, id *voltha.ID, ch chan interface{}) {
112}
113
npujar1d86a522019-11-14 17:11:16 +0530114// DeleteDevice -
khenaidooab1f7bd2019-11-14 14:00:27 -0500115func (dm *DeviceManager) DeleteDevice(ctx context.Context, id *voltha.ID, ch chan interface{}) {
116}
117
npujar1d86a522019-11-14 17:11:16 +0530118// StopManagingDevice -
khenaidooab1f7bd2019-11-14 14:00:27 -0500119func (dm *DeviceManager) StopManagingDevice(id string) {
120}
121
npujar1d86a522019-11-14 17:11:16 +0530122// DownloadImage -
khenaidooab1f7bd2019-11-14 14:00:27 -0500123func (dm *DeviceManager) DownloadImage(ctx context.Context, img *voltha.ImageDownload, ch chan interface{}) {
124}
125
npujar1d86a522019-11-14 17:11:16 +0530126// CancelImageDownload -
khenaidooab1f7bd2019-11-14 14:00:27 -0500127func (dm *DeviceManager) CancelImageDownload(ctx context.Context, img *voltha.ImageDownload, ch chan interface{}) {
128}
129
npujar1d86a522019-11-14 17:11:16 +0530130// ActivateImage -
khenaidooab1f7bd2019-11-14 14:00:27 -0500131func (dm *DeviceManager) ActivateImage(ctx context.Context, img *voltha.ImageDownload, ch chan interface{}) {
132}
133
npujar1d86a522019-11-14 17:11:16 +0530134// RevertImage -
khenaidooab1f7bd2019-11-14 14:00:27 -0500135func (dm *DeviceManager) RevertImage(ctx context.Context, img *voltha.ImageDownload, ch chan interface{}) {
136}
137
npujar1d86a522019-11-14 17:11:16 +0530138// GetImageDownloadStatus -
khenaidooab1f7bd2019-11-14 14:00:27 -0500139func (dm *DeviceManager) GetImageDownloadStatus(ctx context.Context, img *voltha.ImageDownload, ch chan interface{}) {
140}
141
npujar1d86a522019-11-14 17:11:16 +0530142// UpdateImageDownload -
143func (dm *DeviceManager) UpdateImageDownload(deviceID string, img *voltha.ImageDownload) error {
khenaidooab1f7bd2019-11-14 14:00:27 -0500144 return nil
145}
146
npujar1d86a522019-11-14 17:11:16 +0530147// SimulateAlarm -
khenaidooab1f7bd2019-11-14 14:00:27 -0500148func (dm *DeviceManager) SimulateAlarm(ctx context.Context, simulatereq *voltha.SimulateAlarmRequest, ch chan interface{}) {
149}
150
npujar1d86a522019-11-14 17:11:16 +0530151// GetImageDownload -
khenaidooab1f7bd2019-11-14 14:00:27 -0500152func (dm *DeviceManager) GetImageDownload(ctx context.Context, img *voltha.ImageDownload) (*voltha.ImageDownload, error) {
153 return nil, nil
154}
155
npujar1d86a522019-11-14 17:11:16 +0530156// ListImageDownloads -
157func (dm *DeviceManager) ListImageDownloads(ctx context.Context, deviceID string) (*voltha.ImageDownloads, error) {
khenaidooab1f7bd2019-11-14 14:00:27 -0500158 return nil, nil
159}
160
npujar1d86a522019-11-14 17:11:16 +0530161// UpdatePmConfigs -
khenaidooab1f7bd2019-11-14 14:00:27 -0500162func (dm *DeviceManager) UpdatePmConfigs(ctx context.Context, pmConfigs *voltha.PmConfigs, ch chan interface{}) {
163}
164
npujar1d86a522019-11-14 17:11:16 +0530165// ListPmConfigs -
166func (dm *DeviceManager) ListPmConfigs(ctx context.Context, deviceID string) (*voltha.PmConfigs, error) {
khenaidooab1f7bd2019-11-14 14:00:27 -0500167 return nil, nil
168}
169
npujar1d86a522019-11-14 17:11:16 +0530170// DeletePeerPorts -
171func (dm *DeviceManager) DeletePeerPorts(fromDeviceID string, deviceID string) error {
khenaidooab1f7bd2019-11-14 14:00:27 -0500172 return nil
173}
174
npujar1d86a522019-11-14 17:11:16 +0530175// ProcessTransition -
khenaidooab1f7bd2019-11-14 14:00:27 -0500176func (dm *DeviceManager) ProcessTransition(previous *voltha.Device, current *voltha.Device) error {
177 return nil
178}