Thomas Vachuska | 27bee09 | 2015-06-23 19:03:10 -0700 | [diff] [blame] | 1 | /* |
Brian O'Connor | a09fe5b | 2017-08-03 21:12:30 -0700 | [diff] [blame] | 2 | * Copyright 2015-present Open Networking Foundation |
Thomas Vachuska | 27bee09 | 2015-06-23 19:03:10 -0700 | [diff] [blame] | 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 | */ |
| 16 | package org.onosproject.net.packet; |
| 17 | |
| 18 | import org.onosproject.core.ApplicationId; |
alshabib | 19e2cea | 2015-12-07 11:31:49 -0800 | [diff] [blame] | 19 | import org.onosproject.net.DeviceId; |
Thomas Vachuska | 27bee09 | 2015-06-23 19:03:10 -0700 | [diff] [blame] | 20 | import org.onosproject.net.flow.TrafficSelector; |
| 21 | |
Thomas Vachuska | 7f171b2 | 2015-08-21 12:49:08 -0700 | [diff] [blame] | 22 | import java.util.List; |
alshabib | 19e2cea | 2015-12-07 11:31:49 -0800 | [diff] [blame] | 23 | import java.util.Optional; |
Thomas Vachuska | 7f171b2 | 2015-08-21 12:49:08 -0700 | [diff] [blame] | 24 | |
Thomas Vachuska | 27bee09 | 2015-06-23 19:03:10 -0700 | [diff] [blame] | 25 | /** |
| 26 | * Test adapter for packet service. |
| 27 | */ |
| 28 | public class PacketServiceAdapter implements PacketService { |
| 29 | @Override |
| 30 | public void addProcessor(PacketProcessor processor, int priority) { |
| 31 | } |
| 32 | |
| 33 | @Override |
| 34 | public void removeProcessor(PacketProcessor processor) { |
| 35 | } |
| 36 | |
| 37 | @Override |
Thomas Vachuska | 924cda4 | 2015-09-22 12:11:27 -0700 | [diff] [blame] | 38 | public List<PacketProcessorEntry> getProcessors() { |
Thomas Vachuska | 7f171b2 | 2015-08-21 12:49:08 -0700 | [diff] [blame] | 39 | return null; |
| 40 | } |
| 41 | |
| 42 | @Override |
| 43 | public List<PacketRequest> getRequests() { |
| 44 | return null; |
| 45 | } |
| 46 | |
| 47 | @Override |
alshabib | 19e2cea | 2015-12-07 11:31:49 -0800 | [diff] [blame] | 48 | public void requestPackets(TrafficSelector selector, PacketPriority priority, |
| 49 | ApplicationId appId) { |
Thomas Vachuska | 27bee09 | 2015-06-23 19:03:10 -0700 | [diff] [blame] | 50 | } |
| 51 | |
| 52 | @Override |
alshabib | 19e2cea | 2015-12-07 11:31:49 -0800 | [diff] [blame] | 53 | public void requestPackets(TrafficSelector selector, PacketPriority priority, |
| 54 | ApplicationId appId, Optional<DeviceId> deviceId) { |
| 55 | |
| 56 | } |
| 57 | |
| 58 | @Override |
| 59 | public void cancelPackets(TrafficSelector selector, PacketPriority priority, |
| 60 | ApplicationId appId) { |
| 61 | } |
| 62 | |
| 63 | @Override |
| 64 | public void cancelPackets(TrafficSelector selector, PacketPriority priority, |
| 65 | ApplicationId appId, Optional<DeviceId> deviceId) { |
| 66 | |
Thomas Vachuska | 27bee09 | 2015-06-23 19:03:10 -0700 | [diff] [blame] | 67 | } |
| 68 | |
| 69 | @Override |
| 70 | public void emit(OutboundPacket packet) { |
| 71 | } |
| 72 | } |