1 package org.opendaylight.controller.web;
3 import java.net.InetAddress;
6 * Information about a clustered controller to send to the UI frontend
9 public class ClusterNodeBean {
10 private final byte[] address;
11 private final String name;
12 private final Boolean me;
13 private final Boolean coordinator;
15 public static class Builder {
17 private final byte[] address;
18 private final String name;
21 private Boolean me = null;
22 private Boolean coordinator = null;
24 public Builder(InetAddress address) {
25 this.address = address.getAddress();
26 this.name = address.getHostAddress();
29 public Builder highlightMe() {
34 public Builder iAmCoordinator() {
35 this.coordinator = true;
39 public ClusterNodeBean build() {
40 return new ClusterNodeBean(this);
44 private ClusterNodeBean(Builder builder) {
45 this.address = builder.address;
46 this.name = builder.name;
48 this.coordinator = builder.coordinator;