Adding nemo engine.
[nemo.git] / nemo-impl / src / main / java / org / opendaylight / nemo / intent / algorithm / Vertex.java
1 /*\r
2  * Copyright (c) 2015 Huawei, Inc. and others. All rights reserved.\r
3  *\r
4  * This program and the accompanying materials are made available under the\r
5  * terms of the Eclipse Public License v1.0 which accompanies this distribution,\r
6  * and is available at http://www.eclipse.org/legal/epl-v10.html\r
7  */\r
8 \r
9 package org.opendaylight.nemo.intent.algorithm;\r
10 \r
11 /**\r
12  * A vertex in the network topology.\r
13  *\r
14  * @author Zhigang Ji\r
15  */\r
16 public class Vertex {\r
17     private String id;\r
18 \r
19     public Vertex(String id) {\r
20         super();\r
21 \r
22         this.id = id;\r
23 \r
24         return;\r
25     }\r
26 \r
27     public String getId() {\r
28         return id;\r
29     }\r
30 \r
31     @Override\r
32     public boolean equals(Object obj) {\r
33         return ((Vertex)obj).getId().equals(id);\r
34     }\r
35 \r
36     @Override\r
37     public String toString() {\r
38         return "Vertex{" +\r
39                 "id='" + id + '\'' +\r
40                 '}';\r
41     }\r
42 }\r