blob: 89892070ee833c2e9c75abd5a4e5287863e5b30a [file] [log] [blame]
lishuaid470eb92015-11-20 15:25:03 +08001/*
Brian O'Connor5ab426f2016-04-09 01:19:45 -07002 * Copyright 2015-present Open Networking Laboratory
lishuaid470eb92015-11-20 15:25:03 +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.vtn.table;
17
18import org.onlab.packet.IpAddress;
19import org.onlab.packet.MacAddress;
20import org.onosproject.net.DeviceId;
21import org.onosproject.net.flowobjective.Objective;
22import org.onosproject.vtnrsc.SegmentationId;
23
24/**
25 * L3ForwardService interface provide the rules in L3Forward table which is Table(30).
26 */
27public interface L3ForwardService {
28
29 /**
30 * Assemble the L3Forward table rules.
31 * Match: ipv4 type, vnid and destination ip.
32 * Action: set eth_src, set eth_dst, set vnid and goto L2Forward Table(50).
33 *
34 * @param deviceId Device Id
35 * @param l3Vni the vni of L3 network
36 * @param dstVmIP destination vm ip
37 * @param dstVni the vni of the destination network (l2vni)
38 * @param dstVmGwMac destination VM gateway mac
39 * @param dstVmMac destination VM mac
40 * @param type the operation type of the flow rules
41 */
42 void programRouteRules(DeviceId deviceId, SegmentationId l3Vni,
43 IpAddress dstVmIP, SegmentationId dstVni,
44 MacAddress dstVmGwMac, MacAddress dstVmMac,
45 Objective.Operation type);
46
47}