Disable syslog in heat-translator for functest integration
[parser.git] / verigraph / src / main / java / it / polito / escape / verify / model / Neighbour.java
1 /*******************************************************************************
2  * Copyright (c) 2017 Politecnico di Torino and others.
3  *
4  * All rights reserved. This program and the accompanying materials
5  * are made available under the terms of the Apache License, Version 2.0
6  * which accompanies this distribution, and is available at
7  * http://www.apache.org/licenses/LICENSE-2.0
8  *******************************************************************************/
9
10 package it.polito.escape.verify.model;
11
12 import javax.xml.bind.annotation.XmlTransient;
13
14 import io.swagger.annotations.ApiModel;
15 import io.swagger.annotations.ApiModelProperty;
16
17 @ApiModel(value = "Neighbour")
18 public class Neighbour {
19
20         @ApiModelProperty(required = false, hidden = true)
21         @XmlTransient
22         private long    id;
23
24         @ApiModelProperty(      required = true,
25                                                 example = "nat",
26                                                 value = "The neighbour name must refer to an existing node of the same graph")
27         private String  name;
28
29         public Neighbour() {
30
31         }
32
33         public Neighbour(long id, String name) {
34                 this.id = id;
35                 this.name = name;
36         }
37
38         public long getId() {
39                 return id;
40         }
41
42         public void setId(long id) {
43                 this.id = id;
44         }
45
46         public String getName() {
47                 return name;
48         }
49
50         public void setName(String name) {
51                 this.name = name;
52         }
53
54         @Override
55         public int hashCode() {
56                 final int prime = 31;
57                 int result = 1;
58                 result = prime * result + ((name == null) ? 0 : name.hashCode());
59                 return result;
60         }
61
62         @Override
63         public boolean equals(Object obj) {
64                 if (this == obj)
65                         return true;
66                 else
67                         return false;
68         }
69
70 }