test_class.declarator: testMbean = new TestMbean()
test_class.modifier: protected
test_class.original_string: protected TestMbean testMbean = new TestMbean();
test_class.type: TestMbean
test_class.var_name: testMbean
test_class.declarator: mbeanInfoAssembler = new MBeanInfoAssembler()
test_class.modifier: protected
test_class.original_string: protected MBeanInfoAssembler mbeanInfoAssembler = new MBeanInfoAssembler();
test_class.type: MBeanInfoAssembler
test_class.var_name: mbeanInfoAssembler
test_class.file: modules/flowable-jmx/src/test/java/org/flowable/management/jmx/MBeanInfoAssemblerTest.java
test_class.identifier: MBeanInfoAssemblerTest
test_case.body: @Test
      public void testNullInputs() throws JMException {
  
          // at least one of the first parameters should be not null
          assertThat(mbeanInfoAssembler.getMBeanInfo(null, null, "")).isNull();
  
          // mbean should be not null
          assertThat(mbeanInfoAssembler.getMBeanInfo(testMbean, testMbean, null)).isNull();
  
          // it should return something if at least one of the first parameters
          // are
          // not null
          NotManagedMBean notManagedMbean = new NotManagedMBean();
          assertThat(mbeanInfoAssembler.getMBeanInfo(null, notManagedMbean, "someName")).isNotNull();
          assertThat(mbeanInfoAssembler.getMBeanInfo(notManagedMbean, null, "someName")).isNotNull();
  
      }
test_case.class_method_signature: MBeanInfoAssemblerTest.testNullInputs()
test_case.full_signature: @Test public void testNullInputs()
test_case.identifier: testNullInputs
test_case.invocations: isNull assertThat getMBeanInfo isNull assertThat getMBeanInfo isNotNull assertThat getMBeanInfo isNotNull assertThat getMBeanInfo
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testNullInputs()
focal_class.declarator: LOGGER = LoggerFactory.getLogger(MBeanInfoAssembler.class)
focal_class.modifier: private static final
focal_class.original_string: private static final Logger LOGGER = LoggerFactory.getLogger(MBeanInfoAssembler.class);
focal_class.type: Logger
focal_class.var_name: LOGGER
focal_class.declarator: cache = new WeakHashMap<>(10)
focal_class.modifier: protected final
focal_class.original_string: protected final WeakHashMap<Class<?>, MBeanAttributesAndOperations> cache = new WeakHashMap<>(10);
focal_class.type: WeakHashMap<Class<?>, MBeanAttributesAndOperations>
focal_class.var_name: cache
focal_class.file: modules/flowable-jmx/src/main/java/org/flowable/management/jmx/MBeanInfoAssembler.java
focal_class.identifier: MBeanInfoAssembler
focal_class.class_method_signature: MBeanInfoAssembler.MBeanInfoAssembler()
focal_class.full_signature: public  MBeanInfoAssembler()
focal_class.identifier: MBeanInfoAssembler
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.signature:  MBeanInfoAssembler()
focal_class.class_method_signature: MBeanInfoAssembler.getMBeanInfo(Object defaultManagedBean, Object customManagedBean, String objectName)
focal_class.full_signature: public ModelMBeanInfo getMBeanInfo(Object defaultManagedBean, Object customManagedBean, String objectName)
focal_class.identifier: getMBeanInfo
focal_class.modifiers: public
focal_class.parameters: (Object defaultManagedBean, Object customManagedBean, String objectName)
focal_class.return: ModelMBeanInfo
focal_class.signature: ModelMBeanInfo getMBeanInfo(Object defaultManagedBean, Object customManagedBean, String objectName)
focal_class.class_method_signature: MBeanInfoAssembler.extractAttributesAndOperations(Class<?> managedClass, Map<String, ManagedAttributeInfo> attributes, Set<ManagedOperationInfo> operations)
focal_class.full_signature: private void extractAttributesAndOperations(Class<?> managedClass, Map<String, ManagedAttributeInfo> attributes, Set<ManagedOperationInfo> operations)
focal_class.identifier: extractAttributesAndOperations
focal_class.modifiers: private
focal_class.parameters: (Class<?> managedClass, Map<String, ManagedAttributeInfo> attributes, Set<ManagedOperationInfo> operations)
focal_class.return: void
focal_class.signature: void extractAttributesAndOperations(Class<?> managedClass, Map<String, ManagedAttributeInfo> attributes, Set<ManagedOperationInfo> operations)
focal_class.class_method_signature: MBeanInfoAssembler.doExtractAttributesAndOperations(Class<?> managedClass, Map<String, ManagedAttributeInfo> attributes, Set<ManagedOperationInfo> operations)
focal_class.full_signature: private void doExtractAttributesAndOperations(Class<?> managedClass, Map<String, ManagedAttributeInfo> attributes, Set<ManagedOperationInfo> operations)
focal_class.identifier: doExtractAttributesAndOperations
focal_class.modifiers: private
focal_class.parameters: (Class<?> managedClass, Map<String, ManagedAttributeInfo> attributes, Set<ManagedOperationInfo> operations)
focal_class.return: void
focal_class.signature: void doExtractAttributesAndOperations(Class<?> managedClass, Map<String, ManagedAttributeInfo> attributes, Set<ManagedOperationInfo> operations)
focal_class.class_method_signature: MBeanInfoAssembler.capitalize(String text)
focal_class.full_signature: public static String capitalize(String text)
focal_class.identifier: capitalize
focal_class.modifiers: public static
focal_class.parameters: (String text)
focal_class.return: String
focal_class.signature: String capitalize(String text)
focal_class.class_method_signature: MBeanInfoAssembler.doDoExtractAttributesAndOperations(Class<?> managedClass, Map<String, ManagedAttributeInfo> attributes, Set<ManagedOperationInfo> operations)
focal_class.full_signature: private void doDoExtractAttributesAndOperations(Class<?> managedClass, Map<String, ManagedAttributeInfo> attributes, Set<ManagedOperationInfo> operations)
focal_class.identifier: doDoExtractAttributesAndOperations
focal_class.modifiers: private
focal_class.parameters: (Class<?> managedClass, Map<String, ManagedAttributeInfo> attributes, Set<ManagedOperationInfo> operations)
focal_class.return: void
focal_class.signature: void doDoExtractAttributesAndOperations(Class<?> managedClass, Map<String, ManagedAttributeInfo> attributes, Set<ManagedOperationInfo> operations)
focal_class.class_method_signature: MBeanInfoAssembler.extractMbeanAttributes(Object managedBean, Map<String, ManagedAttributeInfo> attributes, Set<ModelMBeanAttributeInfo> mBeanAttributes, Set<ModelMBeanOperationInfo> mBeanOperations)
focal_class.full_signature: private void extractMbeanAttributes(Object managedBean, Map<String, ManagedAttributeInfo> attributes, Set<ModelMBeanAttributeInfo> mBeanAttributes, Set<ModelMBeanOperationInfo> mBeanOperations)
focal_class.identifier: extractMbeanAttributes
focal_class.modifiers: private
focal_class.parameters: (Object managedBean, Map<String, ManagedAttributeInfo> attributes, Set<ModelMBeanAttributeInfo> mBeanAttributes, Set<ModelMBeanOperationInfo> mBeanOperations)
focal_class.return: void
focal_class.signature: void extractMbeanAttributes(Object managedBean, Map<String, ManagedAttributeInfo> attributes, Set<ModelMBeanAttributeInfo> mBeanAttributes, Set<ModelMBeanOperationInfo> mBeanOperations)
focal_class.class_method_signature: MBeanInfoAssembler.extractMbeanOperations(Object managedBean, Set<ManagedOperationInfo> operations, Set<ModelMBeanOperationInfo> mBeanOperations)
focal_class.full_signature: private void extractMbeanOperations(Object managedBean, Set<ManagedOperationInfo> operations, Set<ModelMBeanOperationInfo> mBeanOperations)
focal_class.identifier: extractMbeanOperations
focal_class.modifiers: private
focal_class.parameters: (Object managedBean, Set<ManagedOperationInfo> operations, Set<ModelMBeanOperationInfo> mBeanOperations)
focal_class.return: void
focal_class.signature: void extractMbeanOperations(Object managedBean, Set<ManagedOperationInfo> operations, Set<ModelMBeanOperationInfo> mBeanOperations)
focal_class.class_method_signature: MBeanInfoAssembler.extractMbeanNotifications(Object managedBean, Set<ModelMBeanNotificationInfo> mBeanNotifications)
focal_class.full_signature: private void extractMbeanNotifications(Object managedBean, Set<ModelMBeanNotificationInfo> mBeanNotifications)
focal_class.identifier: extractMbeanNotifications
focal_class.modifiers: private
focal_class.parameters: (Object managedBean, Set<ModelMBeanNotificationInfo> mBeanNotifications)
focal_class.return: void
focal_class.signature: void extractMbeanNotifications(Object managedBean, Set<ModelMBeanNotificationInfo> mBeanNotifications)
focal_class.class_method_signature: MBeanInfoAssembler.getDescription(Object managedBean, String objectName)
focal_class.full_signature: private String getDescription(Object managedBean, String objectName)
focal_class.identifier: getDescription
focal_class.modifiers: private
focal_class.parameters: (Object managedBean, String objectName)
focal_class.return: String
focal_class.signature: String getDescription(Object managedBean, String objectName)
focal_class.class_method_signature: MBeanInfoAssembler.getName(Object managedBean, String objectName)
focal_class.full_signature: private String getName(Object managedBean, String objectName)
focal_class.identifier: getName
focal_class.modifiers: private
focal_class.parameters: (Object managedBean, String objectName)
focal_class.return: String
focal_class.signature: String getName(Object managedBean, String objectName)
focal_method.body: public ModelMBeanInfo getMBeanInfo(Object defaultManagedBean, Object customManagedBean, String objectName) throws JMException {
  
          if ((defaultManagedBean == null && customManagedBean == null) || objectName == null)
              return null;
          // skip proxy classes
          if (defaultManagedBean != null && Proxy.isProxyClass(defaultManagedBean.getClass())) {
              LOGGER.trace("Skip creating ModelMBeanInfo due proxy class {}", defaultManagedBean.getClass());
              return null;
          }
  
          // maps and lists to contain information about attributes and operations
          Map<String, ManagedAttributeInfo> attributes = new LinkedHashMap<>();
          Set<ManagedOperationInfo> operations = new LinkedHashSet<>();
          Set<ModelMBeanAttributeInfo> mBeanAttributes = new LinkedHashSet<>();
          Set<ModelMBeanOperationInfo> mBeanOperations = new LinkedHashSet<>();
          Set<ModelMBeanNotificationInfo> mBeanNotifications = new LinkedHashSet<>();
  
          // extract details from default managed bean
          if (defaultManagedBean != null) {
              extractAttributesAndOperations(defaultManagedBean.getClass(), attributes, operations);
              extractMbeanAttributes(defaultManagedBean, attributes, mBeanAttributes, mBeanOperations);
              extractMbeanOperations(defaultManagedBean, operations, mBeanOperations);
              extractMbeanNotifications(defaultManagedBean, mBeanNotifications);
          }
  
          // extract details from custom managed bean
          if (customManagedBean != null) {
              extractAttributesAndOperations(customManagedBean.getClass(), attributes, operations);
              extractMbeanAttributes(customManagedBean, attributes, mBeanAttributes, mBeanOperations);
              extractMbeanOperations(customManagedBean, operations, mBeanOperations);
              extractMbeanNotifications(customManagedBean, mBeanNotifications);
          }
  
          // create the ModelMBeanInfo
          String name = getName(customManagedBean != null ? customManagedBean : defaultManagedBean, objectName);
          String description = getDescription(customManagedBean != null ? customManagedBean : defaultManagedBean, objectName);
          ModelMBeanAttributeInfo[] arrayAttributes = mBeanAttributes.toArray(new ModelMBeanAttributeInfo[mBeanAttributes.size()]);
          ModelMBeanOperationInfo[] arrayOperations = mBeanOperations.toArray(new ModelMBeanOperationInfo[mBeanOperations.size()]);
          ModelMBeanNotificationInfo[] arrayNotifications = mBeanNotifications.toArray(new ModelMBeanNotificationInfo[mBeanNotifications.size()]);
  
          ModelMBeanInfo info = new ModelMBeanInfoSupport(name, description, arrayAttributes, null, arrayOperations, arrayNotifications);
          LOGGER.trace("Created ModelMBeanInfo {}", info);
          return info;
      }
focal_method.class_method_signature: MBeanInfoAssembler.getMBeanInfo(Object defaultManagedBean, Object customManagedBean, String objectName)
focal_method.full_signature: public ModelMBeanInfo getMBeanInfo(Object defaultManagedBean, Object customManagedBean, String objectName)
focal_method.identifier: getMBeanInfo
focal_method.invocations: isProxyClass getClass trace getClass extractAttributesAndOperations getClass extractMbeanAttributes extractMbeanOperations extractMbeanNotifications extractAttributesAndOperations getClass extractMbeanAttributes extractMbeanOperations extractMbeanNotifications getName getDescription toArray size toArray size toArray size trace
focal_method.modifiers: public
focal_method.parameters: (Object defaultManagedBean, Object customManagedBean, String objectName)
focal_method.return: ModelMBeanInfo
focal_method.signature: ModelMBeanInfo getMBeanInfo(Object defaultManagedBean, Object customManagedBean, String objectName)