Fix NPE triggered after disabling SG on a port
[netvirt.git] / openstack / net-virt / src / main / java / org / opendaylight / netvirt / openstack / netvirt / api / Router.java
1 /*
2  * Copyright (c) 2014, 2015 Red Hat, Inc. and others. All rights reserved.
3  *
4  * This program and the accompanying materials are made available under the
5  * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6  * and is available at http://www.eclipse.org/legal/epl-v10.html
7  */
8
9 package org.opendaylight.netvirt.openstack.netvirt.api;
10
11 import java.net.InetAddress;
12
13 /**
14  * A Router
15  */
16 public interface Router {
17
18     void addInterface(String interfaceName, InetAddress address, int mask);
19
20     void addInterface(String interfaceName, String macAddress, InetAddress address, int mask);
21
22     void updateInterface(String interfaceName, InetAddress address, int mask);
23
24     void updateInterface(String interfaceName, String macAddress, InetAddress address, int mask);
25
26     void removeInterface(String interfaceName);
27
28     void addRoute(String destinationCidr, InetAddress nextHop);
29
30     void addRoute(String destinationCidr, InetAddress nextHop, Integer priority);
31
32     void removeRoute(String destinationCidr, InetAddress nextHop);
33
34     void removeRoute(String destinationCidr, InetAddress nextHop, Integer priority);
35
36     void addDefaultRoute(InetAddress nextHop);
37
38     void addDefaultRoute(InetAddress nextHop, Integer priority);
39
40     void addNatRule(InetAddress matchAddress, InetAddress rewriteAddress);
41
42 }