Carmelo Cascone | b5324e7 | 2018-11-25 02:26:32 -0800 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 2018-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 | */ |
| 16 | |
Carmelo Cascone | 356ab8b | 2019-09-25 01:02:53 -0700 | [diff] [blame] | 17 | package org.onosproject.pipelines.fabric.impl.behaviour.pipeliner; |
Carmelo Cascone | b5324e7 | 2018-11-25 02:26:32 -0800 | [diff] [blame] | 18 | |
| 19 | import org.onlab.packet.EthType; |
| 20 | import org.onlab.packet.MacAddress; |
| 21 | import org.onosproject.net.flow.criteria.Criteria; |
| 22 | import org.onosproject.net.flow.criteria.Criterion; |
| 23 | |
| 24 | /** |
| 25 | * Constants common to ForwardingFunctionType operations. |
| 26 | */ |
Carmelo Cascone | 356ab8b | 2019-09-25 01:02:53 -0700 | [diff] [blame] | 27 | final class Commons { |
Carmelo Cascone | b5324e7 | 2018-11-25 02:26:32 -0800 | [diff] [blame] | 28 | |
| 29 | static final Criterion MATCH_ETH_TYPE_IPV4 = Criteria.matchEthType( |
| 30 | EthType.EtherType.IPV4.ethType()); |
| 31 | static final Criterion MATCH_ETH_TYPE_IPV6 = Criteria.matchEthType( |
| 32 | EthType.EtherType.IPV6.ethType()); |
| 33 | static final Criterion MATCH_ETH_DST_NONE = Criteria.matchEthDst( |
| 34 | MacAddress.NONE); |
| 35 | static final Criterion MATCH_ETH_TYPE_MPLS = Criteria.matchEthType( |
| 36 | EthType.EtherType.MPLS_UNICAST.ethType()); |
| 37 | static final Criterion MATCH_MPLS_BOS_TRUE = Criteria.matchMplsBos(true); |
| 38 | static final Criterion MATCH_MPLS_BOS_FALSE = Criteria.matchMplsBos(false); |
| 39 | |
Carmelo Cascone | 356ab8b | 2019-09-25 01:02:53 -0700 | [diff] [blame] | 40 | private Commons() { |
Carmelo Cascone | b5324e7 | 2018-11-25 02:26:32 -0800 | [diff] [blame] | 41 | // hides constructor. |
| 42 | } |
| 43 | } |