OperationProps operation = new OperationProps(name);
String displayName = withNamePrefix ? "[" + mbean.objectName() + "] " + rhqOperation.displayName() : rhqOperation.displayName();
operation.setDisplayName(displayName);
if (managedAttr != null) {
debug("Operation has ManagedAttribute annotation " + managedAttr);
operation.setDescription(managedAttr.description());
} else if (managedOp != null) {
debug("Operation has ManagedOperation annotation " + managedOp);
operation.setDescription(managedOp.description());
} else {
debug("Operation has no managed annotations, so take the description from the display name.");