Alex Yashchuk | 4caa8e8 | 2017-12-08 17:40:05 +0200 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 2017 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 | */ |
| 16 | |
| 17 | package org.onosproject.driver.pipeline; |
| 18 | |
| 19 | import org.onosproject.net.behaviour.PipelinerContext; |
| 20 | import org.onosproject.net.flow.FlowRule; |
| 21 | import org.onosproject.net.flowobjective.ForwardingObjective; |
| 22 | import org.onosproject.driver.pipeline.ofdpa.Ofdpa3Pipeline; |
| 23 | import java.util.Collection; |
| 24 | |
| 25 | public class XpliantPipeline extends Ofdpa3Pipeline { |
| 26 | |
| 27 | @Override |
| 28 | protected void initDriverId() { |
| 29 | driverId = coreService.registerApplication( |
| 30 | "org.onosproject.driver.XpliantPipeline"); |
| 31 | } |
| 32 | |
| 33 | @Override |
| 34 | protected void initGroupHander(PipelinerContext context) { |
| 35 | groupHandler = new XpliantGroupHandler(); |
| 36 | groupHandler.init(deviceId, context); |
| 37 | } |
| 38 | |
| 39 | @Override |
| 40 | protected Collection<FlowRule> processEthTypeSpecific(ForwardingObjective fwd) { |
| 41 | return processEthTypeSpecificInternal(fwd, true, ACL_TABLE); |
| 42 | } |
| 43 | |
| 44 | @Override |
| 45 | public boolean requireMplsPop() { |
| 46 | return false; |
| 47 | } |
| 48 | |
| 49 | @Override |
| 50 | public boolean requireMplsBosMatch() { |
| 51 | return false; |
| 52 | } |
| 53 | |
| 54 | @Override |
| 55 | public boolean requireMplsTtlModification() { |
| 56 | return false; |
| 57 | } |
| 58 | } |