{
server.setAttribute(name, attrib);
}
catch (ReflectionException re)
{
ManagementException me = new ManagementException();
me.setMessage(SETATTRIB_REFLECT_ERR, new Object[] {attrib.getName(), name});
me.setRootCause(re);
throw me;
}
catch (InstanceNotFoundException infe)
{
ManagementException me = new ManagementException();
me.setMessage(MBEAN_NOTFOUND, new Object[] {name});
me.setRootCause(infe);
throw me;
}
catch (AttributeNotFoundException anfe)
{
ManagementException me = new ManagementException();
me.setMessage(ATTRIB_NOTFOUND, new Object[] {attrib.getName(), name});
me.setRootCause(anfe);
throw me;
}
catch (MBeanException mbe)
{
ManagementException me = new ManagementException();
me.setMessage(SETATTRIB_EXCEPTION, new Object[] {attrib.getName(), name});
me.setRootCause(mbe);
throw me;
}
catch (InvalidAttributeValueException iave)
{
ManagementException me = new ManagementException();
me.setMessage(INVALID_ATTRIB_VALUE, new Object[] {attrib.getValue(), attrib.getName(), name});
me.setRootCause(iave);
throw me;
}
}