1 23 24 29 30 package com.sun.appserv.management.util.jmx; 31 32 import javax.management.Notification ; 33 import javax.management.AttributeChangeNotification ; 34 import javax.management.ObjectName ; 35 36 39 public class AttributeChangeNotificationBuilder extends NotificationBuilder 40 { 41 public 42 AttributeChangeNotificationBuilder( 43 final ObjectName source ) 44 { 45 super( AttributeChangeNotification.ATTRIBUTE_CHANGE, source ); 46 } 47 48 public final Notification 49 buildNew() 50 { 51 throw new IllegalArgumentException (); 52 } 53 54 public final Notification 55 buildNew( 56 final String key, 57 final Object value ) 58 { 59 throw new IllegalArgumentException (); 60 } 61 62 public final AttributeChangeNotification 63 buildAttributeChange( 64 final String msg, 65 final String attributeName, 66 final String attributeType, 67 final Object oldValue, 68 final Object newValue ) 69 { 70 final AttributeChangeNotification notif = new AttributeChangeNotification ( 71 getSource(), 72 nextSequenceNumber(), 73 now(), 74 msg, 75 attributeName, 76 attributeType, 77 oldValue, 78 newValue ); 79 80 return( notif ); 81 } 82 } 83 84 85 86 87 88 | Popular Tags |