code: public List<ModuleRef> getModules() {
          scanSpec.performScan = false;
          try (ScanResult scanResult = scan()) {
              return scanResult.getModules();
          }
      }
docs: Returns {@link ModuleRef} references for all the visible modules.
  
  @return a list of {@link ModuleRef} references for all the visible modules.
  @throws ClassGraphException
  if any of the worker threads throws an uncaught exception, or the scan was interrupted.