Beispiel #1
0
 private void scanConfig(String graniteConfigProperties) {
   // if config overriding exists
   Scanner scanner =
       ScannerFactory.createScanner(
           this,
           graniteConfigProperties != null ? graniteConfigProperties : GRANITE_CONFIG_PROPERTIES);
   try {
     scanner.scan();
   } catch (Exception e) {
     log.error(e, "Could not scan classpath for configuration");
   }
 }
  @Override
  public Set<Class<?>> scan(Set<String> packageNames) {
    Set<Class<?>> classes = new HashSet<Class<?>>();

    Scanner scanner =
        ScannerFactory.createScanner(new MessagingScannedItemHandler(packageNames, classes), null);
    try {
      scanner.scan();
    } catch (Exception e) {
      log.error(e, "Could not scan classpath for @RemoteAlias");
    }

    return classes;
  }