package org.opendaylight.unimgr.mef.nrp.api;
-import org.opendaylight.yang.gen.v1.urn.mef.yang.nrp._interface.rev171221.NrpConnectivityServiceEndPointAttrs;
-import org.opendaylight.yang.gen.v1.urn.onf.params.xml.ns.yang.tapi.common.rev171113.Uuid;
-import org.opendaylight.yang.gen.v1.urn.onf.params.xml.ns.yang.tapi.connectivity.rev171113.ConnectivityServiceEndPoint;
-
import java.util.Objects;
+import org.opendaylight.yang.gen.v1.urn.mef.yang.nrp._interface.rev180321.NrpConnectivityServiceEndPointAttrs;
+import org.opendaylight.yang.gen.v1.urn.onf.otcc.yang.tapi.connectivity.rev180307.ConnectivityServiceEndPoint;
+import org.opendaylight.yang.gen.v1.urn.onf.otcc.yang.tapi.topology.rev180307.OwnedNodeEdgePointRef;
+
+
/**
+ * Class handling common attributes for presto yang endpoints.
* @see ConnectivityServiceEndPoint
* @author bartosz.michalik@amartus.com
*/
*/
private final NrpConnectivityServiceEndPointAttrs attrs;
- private Uuid systemNepUuid;
+ private OwnedNodeEdgePointRef ref;
+ private String localId;
/**
* Initialize endpoint.
return attrs;
}
- public Uuid getSystemNepUuid() {
- return systemNepUuid;
- }
- public EndPoint setSystemNepUuid(Uuid systemNepUuid) {
- this.systemNepUuid = systemNepUuid;
+ public EndPoint setNepRef(OwnedNodeEdgePointRef newRef) {
+ ref = newRef;
return this;
}
+ public OwnedNodeEdgePointRef getNepRef() {
+ return ref;
+ }
+
@Override
- public boolean equals(Object o) {
- if (this == o) return true;
- if (o == null || getClass() != o.getClass()) return false;
- EndPoint endPoint = (EndPoint) o;
- return Objects.equals(endpoint, endPoint.endpoint) &&
- Objects.equals(attrs, endPoint.attrs) &&
- Objects.equals(systemNepUuid, endPoint.systemNepUuid);
+ public boolean equals(Object other) {
+ if (this == other) {
+ return true;
+ }
+ if (other == null || getClass() != other.getClass()) {
+ return false;
+ }
+ EndPoint endPoint = (EndPoint) other;
+ return Objects.equals(endpoint, endPoint.endpoint)
+ && Objects.equals(attrs, endPoint.attrs)
+ && Objects.equals(ref, endPoint.ref);
}
@Override
public int hashCode() {
- return Objects.hash(endpoint, attrs, systemNepUuid);
+ return Objects.hash(endpoint, attrs, ref);
+ }
+
+ public void setLocalId(String localId) {
+ this.localId = localId;
+ }
+
+ public String getLocalId() {
+ return localId;
}
}