Package org.zeroturnaround.javarebel

Examples of org.zeroturnaround.javarebel.Reloader


      return;
    }

    log.echo("JRebel: WebObjects support enabled");
    WOEventClassListener listener = new WOEventClassListener();
    Reloader reloader = ReloaderFactory.getInstance();
    reloader.addClassReloadListener(listener);
  }
View Full Code Here


    doReset();
  }
 
  @SuppressWarnings("unchecked")
  public synchronized void updateLoadedClasses(NSNotification notification) {
    Reloader reloader = ReloaderFactory.getInstance();
    if (notification != null) {
      WORequest request = (WORequest) notification.object();
      String key = "/" + WOApplication.application().resourceRequestHandlerKey();
      if (request.uri().indexOf(request.adaptorPrefix()) != 0 || request.uri().indexOf(key) >= 0) {
        return;
      }
    }
    NSDictionary classList = WOClassCacheAccessor.getClassCache();
    String unknownClassName = "com.webobjects.foundation._NSUtilities$_NoClassUnderTheSun";
    Class<?> unknownClass = WOClassCacheAccessor.classForName(unknownClassName);
    Enumeration<String> en = classList.keyEnumerator();
    while(en.hasMoreElements()) {
      String className = en.nextElement();
      if (className.equals(unknownClassName)) {
        continue;
      }
      Class<?> clazz = WOClassCacheAccessor.classForName(className);

      if (clazz != null && clazz.isPrimitive()) {
        continue;
      }

      if (clazz == null || clazz.equals(unknownClass)) {
        WOClassCacheAccessor.removeClassForName(className);
        continue;
      }
      reloader.checkAndReload(clazz);
    }
    doReset();
  }
View Full Code Here

TOP

Related Classes of org.zeroturnaround.javarebel.Reloader

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.