1 25 26 package org.objectweb.j2eemanagement.servlets; 27 28 import java.io.IOException ; 29 import java.io.PrintWriter ; 30 import java.util.ArrayList ; 31 32 import javax.management.NotificationListener ; 33 import javax.management.Notification ; 34 35 39 public class MyListener implements NotificationListener { 40 41 43 private ArrayList listNotifications = null; 44 45 47 public MyListener() { 48 listNotifications = new ArrayList (); 49 } 50 51 53 public void handleNotification(Notification notification, Object handback) { 54 String s = "Notification = " + notification.toString() + ", Handback = "+ handback.toString(); 55 listNotifications.add(s); 56 } 57 58 60 public ArrayList getlistNotifications() { 61 return listNotifications; 62 } 63 64 } 65 | Popular Tags |