blob: a9459508613e27d7553c920d10400c0a9bd0a8d7 [file] [log] [blame]
Jian Li152b8852015-12-07 14:47:25 -08001/*
Brian O'Connor5ab426f2016-04-09 01:19:45 -07002 * Copyright 2015-present Open Networking Laboratory
Jian Li152b8852015-12-07 14:47:25 -08003 *
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 */
16package org.onosproject.openflow.controller.driver;
17
18import org.projectfloodlight.openflow.protocol.OFPacketOut;
19import org.projectfloodlight.openflow.protocol.OFType;
20import org.projectfloodlight.openflow.protocol.action.OFAction;
21import org.projectfloodlight.openflow.types.OFBufferId;
22import org.projectfloodlight.openflow.types.OFPort;
23
24import java.util.List;
25
26/**
27 * Mock of the Open Flow packet out message.
28 */
29public class MockOfPacketOut extends OfMessageAdapter implements OFPacketOut {
30
31 public MockOfPacketOut() {
32 super(OFType.PACKET_OUT);
33 }
34
35 @Override
36 public OFBufferId getBufferId() {
37 return null;
38 }
39
40 @Override
41 public OFPort getInPort() {
42 return null;
43 }
44
45 @Override
46 public List<OFAction> getActions() {
47 return null;
48 }
49
50 @Override
51 public byte[] getData() {
52 return new byte[0];
53 }
54
55 @Override
56 public OFPacketOut.Builder createBuilder() {
57 return null;
58 }
59}