forked from KNEMC/KLALB
Replace the combined node-info protocol with independent profile, external-endpoint, and extra-route requests. Aggregate consumers use NodeInfoQueryCoordinator and validate response source addresses. BREAKING CHANGE: nodeinfotinyreq/resp and nodeinfofullreq/resp are removed. Peers must use the profile, external-endpoint, and extra-route request pairs.
45 lines
1006 B
Java
45 lines
1006 B
Java
package org.kne.cloud.network.srv6;
|
|
|
|
import java.util.Objects;
|
|
|
|
public final class NodeProfile {
|
|
private final String deviceName;
|
|
private final String deviceDescription;
|
|
|
|
public NodeProfile(String deviceName, String deviceDescription) {
|
|
this.deviceName = deviceName;
|
|
this.deviceDescription = deviceDescription;
|
|
}
|
|
|
|
public String getDeviceName() {
|
|
return deviceName;
|
|
}
|
|
|
|
public String getDeviceDescription() {
|
|
return deviceDescription;
|
|
}
|
|
|
|
@Override
|
|
public int hashCode() {
|
|
return Objects.hash(deviceName, deviceDescription);
|
|
}
|
|
|
|
@Override
|
|
public boolean equals(Object obj) {
|
|
if (this == obj) {
|
|
return true;
|
|
}
|
|
if (!(obj instanceof NodeProfile)) {
|
|
return false;
|
|
}
|
|
NodeProfile other = (NodeProfile) obj;
|
|
return Objects.equals(deviceName, other.deviceName)
|
|
&& Objects.equals(deviceDescription, other.deviceDescription);
|
|
}
|
|
|
|
@Override
|
|
public String toString() {
|
|
return "NodeProfile [deviceName=" + deviceName + ", deviceDescription=" + deviceDescription + "]";
|
|
}
|
|
}
|