@Override
  public void sendAttributeChangeNotification(Attribute oldAttribute, Attribute newAttribute)
      throws MBeanException, RuntimeOperationsException {
    if (oldAttribute == null || newAttribute == null) {
      throw new RuntimeOperationsException(new IllegalArgumentException(
          "Attribute cannot be null."));
    }
    if (!oldAttribute.getName().equals(newAttribute.getName())) {
      throw new RuntimeOperationsException(new IllegalArgumentException(
          "Attribute names cannot be different."));
    }

    // TODO: the source must be the object name of the MBean if the listener was registered through
    // MBeanServer
    Object oldValue = oldAttribute.getValue();
    AttributeChangeNotification n = new AttributeChangeNotification(this, 1,
        System.currentTimeMillis(), "Attribute value changed", oldAttribute.getName(),
        oldValue == null ? null : oldValue.getClass().getName(), oldValue, newAttribute.getValue());
    sendAttributeChangeNotification(n);
  }
@author <a href="mailto:biorn_steedom@users.sourceforge.net">Simone Bordet</a>
@version $Revision: 1.14 $
geode-core/src/main/java/org/apache/geode/admin/jmx/internal/MX4JModelMBean.java