blob: 4b623e4afbf80df7771a4e5b896320c5353ef127 [file] [log] [blame]
Jonathan Hart1236a9b2013-06-18 22:10:05 +12001package net.onrc.onos.ofcontroller.bgproute;
2
Jonathan Hart4dfc3652013-08-02 20:22:36 +12003import java.util.Collections;
Jonathan Hart1236a9b2013-06-18 22:10:05 +12004import java.util.List;
Jonathan Hart1236a9b2013-06-18 22:10:05 +12005
6import org.codehaus.jackson.annotate.JsonProperty;
Jonathan Hart832a7cb2013-06-24 11:25:35 +12007import org.openflow.util.HexString;
Jonathan Hart1236a9b2013-06-18 22:10:05 +12008
9public class Configuration {
Jonathan Hart832a7cb2013-06-24 11:25:35 +120010 private long bgpdAttachmentDpid;
11 private short bgpdAttachmentPort;
12 private List<String> switches;
Jonathan Hart9575cb62013-07-05 13:43:49 +120013 private List<Interface> interfaces;
Jonathan Hart832a7cb2013-06-24 11:25:35 +120014 private List<BgpPeer> peers;
Jonathan Hart1236a9b2013-06-18 22:10:05 +120015
16 public Configuration() {
17 // TODO Auto-generated constructor stub
18 }
19
Jonathan Hart832a7cb2013-06-24 11:25:35 +120020 public long getBgpdAttachmentDpid() {
21 return bgpdAttachmentDpid;
22 }
23
24 @JsonProperty("bgpdAttachmentDpid")
25 public void setBgpdAttachmentDpid(String bgpdAttachmentDpid) {
26 this.bgpdAttachmentDpid = HexString.toLong(bgpdAttachmentDpid);
27 }
28
29 public short getBgpdAttachmentPort() {
30 return bgpdAttachmentPort;
31 }
32
33 @JsonProperty("bgpdAttachmentPort")
34 public void setBgpdAttachmentPort(short bgpdAttachmentPort) {
35 this.bgpdAttachmentPort = bgpdAttachmentPort;
36 }
37
Jonathan Hart1236a9b2013-06-18 22:10:05 +120038 public List<String> getSwitches() {
Jonathan Hart4dfc3652013-08-02 20:22:36 +120039 return Collections.unmodifiableList(switches);
Jonathan Hart1236a9b2013-06-18 22:10:05 +120040 }
41
42 @JsonProperty("switches")
43 public void setSwitches(List<String> switches) {
44 this.switches = switches;
45 }
46
Jonathan Hart9575cb62013-07-05 13:43:49 +120047 public List<Interface> getInterfaces() {
Jonathan Hart4dfc3652013-08-02 20:22:36 +120048 return Collections.unmodifiableList(interfaces);
Jonathan Hart832a7cb2013-06-24 11:25:35 +120049 }
50
51 @JsonProperty("interfaces")
Jonathan Hart9575cb62013-07-05 13:43:49 +120052 public void setInterfaces(List<Interface> interfaces) {
Jonathan Hart832a7cb2013-06-24 11:25:35 +120053 this.interfaces = interfaces;
54 }
55
56 public List<BgpPeer> getPeers() {
Jonathan Hart4dfc3652013-08-02 20:22:36 +120057 return Collections.unmodifiableList(peers);
Jonathan Hart832a7cb2013-06-24 11:25:35 +120058 }
59
60 @JsonProperty("bgpPeers")
61 public void setPeers(List<BgpPeer> peers) {
62 this.peers = peers;
63 }
64
Jonathan Hart1236a9b2013-06-18 22:10:05 +120065}