use of org.opennms.netmgt.model.BridgeMacLink in project opennms by OpenNMS.
the class BroadcastDomain method printTopologyBFT.
public static String printTopologyBFT(List<BridgeMacLink> bft) {
StringBuffer strbfr = new StringBuffer();
for (BridgeMacLink link : bft) {
strbfr.append("nodeid:[");
strbfr.append(link.getNode().getId());
strbfr.append("]:");
strbfr.append(link.getMacAddress());
strbfr.append(":bridgeport:");
strbfr.append(link.getBridgePort());
strbfr.append("\n");
}
return strbfr.toString();
}
use of org.opennms.netmgt.model.BridgeMacLink in project opennms by OpenNMS.
the class EnhancedLinkdServiceImpl method store.
@Override
public void store(BroadcastDomain domain, Date now) {
for (SharedSegment segment : domain.getTopology()) {
for (BridgeBridgeLink link : segment.getBridgeBridgeLinks()) {
link.setBridgeBridgeLinkLastPollTime(new Date());
saveBridgeBridgeLink(link);
}
for (BridgeMacLink link : segment.getBridgeMacLinks()) {
link.setBridgeMacLinkLastPollTime(new Date());
saveBridgeMacLink(link);
}
}
for (Integer nodeid : domain.getBridgeNodesOnDomain()) {
m_bridgeMacLinkDao.deleteByNodeIdOlderThen(nodeid, now);
m_bridgeMacLinkDao.flush();
m_bridgeBridgeLinkDao.deleteByNodeIdOlderThen(nodeid, now);
m_bridgeBridgeLinkDao.deleteByDesignatedNodeIdOlderThen(nodeid, now);
m_bridgeBridgeLinkDao.flush();
}
}
Aggregations