diff options
author | Ashlee Young <ashlee@onosfw.com> | 2015-10-23 08:31:31 -0700 |
---|---|---|
committer | Ashlee Young <ashlee@onosfw.com> | 2015-10-23 08:31:31 -0700 |
commit | e52e67767076b29cb01939aa7bdd8fee9d205cc1 (patch) | |
tree | b8c2d28231bccc2a280fea429a9af7297c62f58f /framework/src/onos/incubator/api/src/main/java/org/onosproject/incubator/net/intf/Interface.java | |
parent | a912c5ce9968da5936a695064f22083898e7b93d (diff) |
Update ONOS src to commit id 69b36d5d11e81e28e56b46ba44e4b8cd701c5867
Change-Id: I9c13045711dbf9c0181106b66a6bf22c72bcf330
Signed-off-by: Ashlee Young <ashlee@onosfw.com>
Diffstat (limited to 'framework/src/onos/incubator/api/src/main/java/org/onosproject/incubator/net/intf/Interface.java')
-rw-r--r-- | framework/src/onos/incubator/api/src/main/java/org/onosproject/incubator/net/intf/Interface.java | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/framework/src/onos/incubator/api/src/main/java/org/onosproject/incubator/net/intf/Interface.java b/framework/src/onos/incubator/api/src/main/java/org/onosproject/incubator/net/intf/Interface.java index 69d14bce..b9d3eadf 100644 --- a/framework/src/onos/incubator/api/src/main/java/org/onosproject/incubator/net/intf/Interface.java +++ b/framework/src/onos/incubator/api/src/main/java/org/onosproject/incubator/net/intf/Interface.java @@ -30,7 +30,8 @@ import static com.google.common.base.Preconditions.checkNotNull; /** * An Interface maps network configuration information (such as addresses and - * vlans) to a port in the network. + * vlans) to a port in the network. This is considered a L2/L3 network + * interface. */ @Beta public class Interface { @@ -51,9 +52,9 @@ public class Interface { Set<InterfaceIpAddress> ipAddresses, MacAddress macAddress, VlanId vlan) { this.connectPoint = checkNotNull(connectPoint); - this.ipAddresses = Sets.newHashSet(checkNotNull(ipAddresses)); - this.macAddress = checkNotNull(macAddress); - this.vlan = checkNotNull(vlan); + this.ipAddresses = ipAddresses == null ? Sets.newHashSet() : ipAddresses; + this.macAddress = macAddress == null ? MacAddress.NONE : macAddress; + this.vlan = vlan == null ? VlanId.NONE : vlan; } /** |