test_class.declarator: inheritanceAnalyser
test_class.original_string: InheritanceAnalyser inheritanceAnalyser;
test_class.type: InheritanceAnalyser
test_class.var_name: inheritanceAnalyser
test_class.file: core/src/test/java/com/github/jsr330/analysis/InheritanceAnalyserTest.java
test_class.identifier: InheritanceAnalyserTest
test_case.body: @Test
      public void analyse_NoInheritances() {
          Map<String, Class<?>> classes = new HashMap<String, Class<?>>();
          Map<String, Class<?>[]> inheritances;
          
          classes.put(Object.class.getName(), Object.class);
          classes.put(CharSequence.class.getName(), CharSequence.class);
          classes.put(Runnable.class.getName(), Runnable.class);
          
          inheritances = inheritanceAnalyser.analyse(classes);
          
          assertNotNull(inheritances);
          assertEquals(0, inheritances.size());
      }
test_case.class_method_signature: InheritanceAnalyserTest.analyse_NoInheritances()
test_case.full_signature: @Test public void analyse_NoInheritances()
test_case.identifier: analyse_NoInheritances
test_case.invocations: put getName put getName put getName analyse assertNotNull assertEquals size
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void analyse_NoInheritances()
focal_class.declarator: EMPTY_STRING_ARRAY = new String[] {}
focal_class.modifier: private static final
focal_class.original_string: private static final String[] EMPTY_STRING_ARRAY = new String[] {};
focal_class.type: String[]
focal_class.var_name: EMPTY_STRING_ARRAY
focal_class.declarator: EMPTY_CLASS_ARRAY = new Class<?>[] {}
focal_class.modifier: private static final
focal_class.original_string: private static final Class<?>[] EMPTY_CLASS_ARRAY = new Class<?>[] {};
focal_class.type: Class<?>[]
focal_class.var_name: EMPTY_CLASS_ARRAY
focal_class.declarator: LOGGER = LoggerFactory.getLogger(InheritanceAnalyser.class)
focal_class.modifier: private static final
focal_class.original_string: private static final Logger LOGGER = LoggerFactory.getLogger(InheritanceAnalyser.class);
focal_class.type: Logger
focal_class.var_name: LOGGER
focal_class.file: core/src/main/java/com/github/jsr330/analysis/InheritanceAnalyser.java
focal_class.identifier: InheritanceAnalyser
focal_class.interfaces: implements ClassAnalyser<Map<String, Class<?>[]>>
focal_class.class_method_signature: InheritanceAnalyser.analyse(Map<String, Class<?>> classes)
focal_class.full_signature: @Override public Map<String, Class<?>[]> analyse(Map<String, Class<?>> classes)
focal_class.identifier: analyse
focal_class.modifiers: @Override public
focal_class.parameters: (Map<String, Class<?>> classes)
focal_class.return: Map<String, Class<?>[]>
focal_class.signature: Map<String, Class<?>[]> analyse(Map<String, Class<?>> classes)
focal_method.body: @Override
      public Map<String, Class<?>[]> analyse(Map<String, Class<?>> classes) {
          Map<String, Class<?>[]> inheritances = new TreeMap<String, Class<?>[]>();
          List<Class<?>> classList = new ArrayList<Class<?>>();
          String[] classNames = classes.keySet().toArray(EMPTY_STRING_ARRAY);
          Class<?> type;
          
          for (Map.Entry<String, Class<?>> entry : classes.entrySet()) {
              classList.clear();
              LOGGER.debug("analyse - looking for {}", entry.getKey());
              for (String className : classNames) {
                  if (!entry.getKey().equals(className)) {
                      type = classes.get(className);
                      if (entry.getValue().isAssignableFrom(type) && !type.isInterface() && !Modifier.isAbstract(type.getModifiers())) {
                          classList.add(type);
                          LOGGER.debug("analyse - found {}", type);
                      }
                  }
              }
              if (!classList.isEmpty()) {
                  inheritances.put(entry.getKey(), classList.toArray(EMPTY_CLASS_ARRAY));
              }
          }
          
          return inheritances;
      }
focal_method.class_method_signature: InheritanceAnalyser.analyse(Map<String, Class<?>> classes)
focal_method.full_signature: @Override public Map<String, Class<?>[]> analyse(Map<String, Class<?>> classes)
focal_method.identifier: analyse
focal_method.invocations: toArray keySet entrySet clear debug getKey equals getKey get isAssignableFrom getValue isInterface isAbstract getModifiers add debug isEmpty put getKey toArray
focal_method.modifiers: @Override public
focal_method.parameters: (Map<String, Class<?>> classes)
focal_method.return: Map<String, Class<?>[]>
focal_method.signature: Map<String, Class<?>[]> analyse(Map<String, Class<?>> classes)