Merge "Increase timeout for waiting for broker service in sal-binding-it."
[controller.git] / opendaylight / md-sal / sal-rest-connector / src / test / java / org / opendaylight / controller / sal / restconf / impl / test / structures / Cont.java
1 /*
2  * Copyright (c) 2014 Cisco Systems, 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 package org.opendaylight.controller.sal.restconf.impl.test.structures;
9
10 public class Cont extends LstItem {
11     String name = null;
12
13     public Cont(String name) {
14         super();
15         this.name = name;
16     }
17
18     public String getName() {
19         return name;
20     }
21
22     @Override
23     public boolean equals(Object obj) {
24         if (this == obj) {
25             return true;
26         }
27         if (!this.getClass().equals(obj.getClass())) {
28             return false;
29         }
30         if (!super.equals(obj)) {
31             return false;
32         }
33         Cont cont = (Cont) obj;
34         if (this.name == null) {
35             if (cont.name != null) {
36                 return false;
37             }
38         } else if (!this.name.equals(cont.name)) {
39             return false;
40         }
41         return true;
42     }
43
44     @Override
45     public int hashCode() {
46         final int prime = 31;
47         int result = super.hashCode();
48         result = prime * result + ((this.name == null) ? 0 : this.name.hashCode());
49         return result;
50     }
51
52     @Override
53     public String toString() {
54         return name;
55     }
56
57 }