3 * Copyright (c) 2013 Cisco Systems, Inc. and others. All rights reserved.
5 * This program and the accompanying materials are made available under the
6 * terms of the Eclipse Public License v1.0 which accompanies this distribution,
7 * and is available at http://www.eclipse.org/legal/epl-v10.html
10 package org.opendaylight.controller.sal.core;
12 import javax.xml.bind.annotation.XmlElement;
13 import javax.xml.bind.annotation.XmlRootElement;
18 * @brief Class representing tables
20 * Describes supported # of datapath tables
23 public class Tables extends Property {
24 private static final long serialVersionUID = 1L;
25 @XmlElement(name="value")
26 private byte tablesValue;
28 public static final String TablesPropName = "tables";
30 * Construct a Tables property
32 * @param tables the Tables
33 * @return Constructed object
35 public Tables(byte tables) {
36 super(TablesPropName);
37 this.tablesValue = tables;
41 * Private constructor used for JAXB mapping
44 super(TablesPropName);
49 public Tables clone() {
50 return new Tables(this.tablesValue);
53 public byte getValue() {
54 return this.tablesValue;
58 public int hashCode() {
60 int result = super.hashCode();
61 result = prime * result + tablesValue;
66 public boolean equals(Object obj) {
69 if (!super.equals(obj))
71 if (getClass() != obj.getClass())
73 Tables other = (Tables) obj;
74 if (tablesValue != other.tablesValue)
80 public String toString() {
81 return "Tables[" + tablesValue + "]";