/**
* Enable this <CODE>SnmpMibTable</CODE> to send a notification.
*
* <p>
* @param notification The notification to send.
*/
private synchronized void sendNotification(Notification notification) {
// loop on listener
//
for(java.util.Enumeration<NotificationListener> k = handbackTable.keys();
k.hasMoreElements(); ) {
NotificationListener listener = k.nextElement();
// Get the associated handback list and the associated filter list
//
java.util.Vector<?> handbackList = handbackTable.get(listener) ;
java.util.Vector<NotificationFilter> filterList =
filterTable.get(listener) ;
// loop on handback
//
java.util.Enumeration<NotificationFilter> f = filterList.elements();
for(java.util.Enumeration<?> h = handbackList.elements();
h.hasMoreElements(); ) {
Object handback = h.nextElement();
NotificationFilter filter = f.nextElement();
if ((filter == null) ||
(filter.isNotificationEnabled(notification))) {
listener.handleNotification(notification,handback) ;
}
}
}
}
SnmpMibTable.java 文件源码
java
阅读 26
收藏 0
点赞 0
评论 0
项目:jdk8u-jdk
作者:
评论列表
文章目录