Tabnine Logo
Watcher
Code IndexAdd Tabnine to your IDE (free)

How to use
Watcher
in
org.hotswap.agent.watch

Best Java code snippets using org.hotswap.agent.watch.Watcher (Showing top 7 results out of 315)

origin: HotswapProjects/HotswapAgent

/**
 * Callback method from ch.qos.logback.core.joran.GenericConfigurator.
 *
 * @param configurator the configurator object
 * @param url          configuration file url
 */
public void initLogback(final Object configurator, final URL url) {
  try {
    final URI uri = url.toURI();
    // skip double registration on reload
    if (registeredURIs.contains(uri))
      return;
    LOGGER.debug("Watching '{}' URL for Logback configuration changes.", url);
    registeredURIs.add(uri);
    watcher.addEventListener(appClassLoader, uri, new WatchEventListener() {
      @Override
      public void onEvent(WatchFileEvent event) {
        if (event.getEventType() != FileEvent.DELETE)
          reload(configurator, url);
      }
    });
  } catch (Exception e) {
    LOGGER.error("Exception initializing logback configurator {} on url {}.", e, configurator, url);
  }
}
origin: HotswapProjects/HotswapAgent

public static void close(ClassLoader classLoader) {
  Map<String, ClassLoader> registerMap = extraRepositories.remove(classLoader);
  if (registerMap != null) {
    for (ClassLoader loader : registerMap.values()) {
      PluginManager.getInstance().getWatcher().closeClassLoader(loader);
    }
  }
}
origin: HotswapProjects/HotswapAgent

LOGGER.debug("Watching '{}' URI for Log4j2 configuration changes.", configURI);
registeredURIs.add(configURI);
watcher.addEventListener(appClassLoader, parentUri, new WatchEventListener() {
origin: HotswapProjects/HotswapAgent

watcher.addEventListener(appClassLoader, uri, new WatchEventListener() {
  @Override
  public void onEvent(WatchFileEvent event) {
origin: HotswapProjects/HotswapAgent

  LOGGER.info("Initialize hotswap on URL {}.", uri);
  listener = new AutoHotswapPathEventListener(this);
  watcher.addEventListener(null, uri, listener);
} catch (URISyntaxException e) {
  LOGGER.error("Unable to watch path '{}' for changes.", e, resource);
origin: HotswapProjects/HotswapAgent

  continue;
} else {
  watcher.addEventListener(appClassLoader, basePackageURL, new WatchEventListener() {
    @Override
    public void onEvent(WatchFileEvent event) {
origin: HotswapProjects/HotswapAgent

LOGGER.info("Registering archive path '{}'", archivePath);
watcher.addEventListener(appClassLoader, uri, new WatchEventListener() {
  @Override
  public void onEvent(WatchFileEvent event) {
org.hotswap.agent.watchWatcher

Most used methods

  • addEventListener
  • closeClassLoader

Popular in Java

  • Reading from database using SQL prepared statement
  • getApplicationContext (Context)
  • findViewById (Activity)
  • scheduleAtFixedRate (ScheduledExecutorService)
  • IOException (java.io)
    Signals a general, I/O-related error. Error details may be specified when calling the constructor, a
  • TreeSet (java.util)
    TreeSet is an implementation of SortedSet. All optional operations (adding and removing) are support
  • JComboBox (javax.swing)
  • JFrame (javax.swing)
  • Logger (org.apache.log4j)
    This is the central class in the log4j package. Most logging operations, except configuration, are d
  • SAXParseException (org.xml.sax)
    Encapsulate an XML parse error or warning.> This module, both source code and documentation, is in t
  • PhpStorm for WordPress
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyStudentsTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now