2 * Copyright (c) 2013 Cisco Systems, Inc. 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
8 package org.opendaylight.controller.config.api;
11 * Wrapper around strings to make {@link JmxAttributeValidationException} type
14 public class JmxAttribute {
15 private final String attributeName;
17 public JmxAttribute(final String attributeName) {
18 if (attributeName == null) {
19 throw new NullPointerException("Parameter 'attributeName' is null");
21 this.attributeName = attributeName;
25 * Name of attribute in JMX.
27 public String getAttributeName() {
32 public boolean equals(final Object o) {
36 if (o == null || getClass() != o.getClass()) {
40 JmxAttribute that = (JmxAttribute) o;
42 if (!attributeName.equals(that.attributeName)) {
50 public int hashCode() {
51 return attributeName.hashCode();
55 public String toString() {
56 return "JmxAttribute{'" + attributeName + "'}";