2 * Copyright (c) 2013, 2015 IBM Corporation and others. All rights reserved.
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
9 package org.opendaylight.neutron.spi;
11 import javax.xml.bind.annotation.XmlAccessType;
12 import javax.xml.bind.annotation.XmlAccessorType;
13 import javax.xml.bind.annotation.XmlElement;
14 import javax.xml.bind.annotation.XmlRootElement;
17 @XmlAccessorType(XmlAccessType.NONE)
18 public final class NeutronRouterInterface extends NeutronObject<NeutronRouterInterface> {
19 private static final long serialVersionUID = 1L;
21 // See OpenStack Network API v2.0 Reference for description of
22 // annotated attributes
24 @XmlElement(name = "subnet_id")
27 @XmlElement(name = "port_id")
30 public NeutronRouterInterface() {
33 public NeutronRouterInterface(String subnetUUID, String portUUID) {
34 this.subnetUUID = subnetUUID;
35 this.portUUID = portUUID;
38 public String getSubnetUUID() {
42 public void setSubnetUUID(String subnetUUID) {
43 this.subnetUUID = subnetUUID;
46 public String getPortUUID() {
50 public void setPortUUID(String portUUID) {
51 this.portUUID = portUUID;
55 protected boolean extractField(String field, NeutronRouterInterface ans) {
58 ans.setSubnetUUID(this.getSubnetUUID());
61 ans.setPortUUID(this.getPortUUID());
64 return super.extractField(field, ans);
70 public String toString() {
71 return "NeutronRouterInterface [" + "subnetUUID=" + subnetUUID + ", portUUID=" + portUUID + ", id=" + uuid
72 + ", tenantID=" + tenantID + "]";