1 8 9 package mx4j.tools.remote.soap.axis.ser; 10 11 import java.io.IOException ; 12 import javax.management.MBeanServerNotification ; 13 import javax.management.Notification ; 14 import javax.xml.namespace.QName ; 15 16 import org.apache.axis.encoding.SerializationContext; 17 import org.apache.axis.wsdl.fromJava.Types; 18 import org.w3c.dom.Element ; 19 20 23 public class MBeanServerNotificationSer extends NotificationSer 24 { 25 static final String MBEAN_NAME = "mbeanName"; 26 private static final QName MBEAN_NAME_QNAME = new QName ("", MBEAN_NAME); 27 28 protected void onSerialize(SerializationContext context, Notification notification) throws IOException 29 { 30 super.onSerialize(context, notification); 31 MBeanServerNotification serverNotification = (MBeanServerNotification )notification; 32 context.serialize(MBEAN_NAME_QNAME, null, serverNotification.getMBeanName()); 33 } 34 35 public Element writeSchema(Class aClass, Types types) throws Exception 36 { 37 return super.writeSchema(aClass, types); 39 } 40 } 41 | Popular Tags |