public URL getAlias() { if (__checkAliases && !_aliasChecked) { try { String abs=_file.getAbsolutePath(); String can=_file.getCanonicalPath(); if (abs.length()!=can.length() || !abs.equals(can)) _alias=new File(can).toURI().toURL(); _aliasChecked=true; if (_alias!=null && Log.isDebugEnabled()) { Log.debug("ALIAS abs="+abs); Log.debug("ALIAS can="+can); } } catch(Exception e) { Log.warn(Log.EXCEPTION,e); return getURL(); } } return _alias; }
if (!oldScanKeys.contains(entry.getKey())) Log.debug("File added: "+entry.getKey()); reportAddition ((String)entry.getKey()); bulkChanges.add(entry.getKey()); Log.debug("File changed: "+entry.getKey()); reportChange((String)entry.getKey()); oldScanKeys.remove(entry.getKey()); Log.debug("File removed: "+filename); reportRemoval(filename); bulkChanges.add(filename);
protected void newThread() { synchronized (_threadsLock) { if (_threads.size()<_maxThreads) { PoolThread thread =new PoolThread(); _threads.add(thread); thread.setName(_name+"-"+_id++); thread.start(); } else if (!_warned) { _warned=true; Log.debug("Max threads for {}",this); } } }
Log.debug(e); return new String(bytes,0,n);
Log.debug(Log.EXCEPTION,e2); throw e;
Log.debug("Out of threads for {}",this);
public static void extract(Resource resource, File directory, boolean deleteOnExit) throws IOException if(Log.isDebugEnabled())Log.debug("Extract "+resource+" to "+directory); boolean subEntryIsDir = (subEntryName != null && subEntryName.endsWith("/")?true:false); if (Log.isDebugEnabled()) Log.debug("Extracting entry = "+subEntryName+" from jar "+jarFileURL); if (Log.isDebugEnabled()) Log.debug("Skipping entry: "+entryName); continue;
Log.debug(Log.EXCEPTION,e); return new BadResource(url,e.toString());
/** Add a parent child relationship * @param parent * @param child * @param relationship */ private void add(Object parent, Object child, String relationship) { if (Log.isDebugEnabled()) Log.debug("Container "+parent+" + "+child+" as "+relationship); if (_listeners!=null) { Relationship event=new Relationship(this,parent,child,relationship); for (int i=0; i<LazyList.size(_listeners); i++) ((Listener)LazyList.get(_listeners, i)).add(event); } }
/** remove a parent child relationship * @param parent * @param child * @param relationship */ private void remove(Object parent, Object child, String relationship) { if (Log.isDebugEnabled()) Log.debug("Container "+parent+" - "+child+" as "+relationship); if (_listeners!=null) { Relationship event=new Relationship(this,parent,child,relationship); for (int i=0; i<LazyList.size(_listeners); i++) ((Listener)LazyList.get(_listeners, i)).remove(event); } }
public final void start() throws Exception { synchronized (_lock) { try { if (_state == STARTED || _state == STARTING) return; setStarting(); doStart(); Log.debug("started {}",this); setStarted(); } catch (Exception e) { Log.warn("failed " + this,e); setFailed(e); throw e; } catch (Error e) { Log.warn("failed " + this,e); setFailed(e); throw e; } } }
public final void stop() throws Exception { synchronized (_lock) { try { if (_state == STOPPING || _state == STOPPED) return; setStopping(); doStop(); Log.debug("stopped {}",this); setStopped(); } catch (Exception e) { Log.warn("failed " + this,e); setFailed(e); throw e; } catch (Error e) { Log.warn("failed " + this,e); setFailed(e); throw e; } } }
/** * Get a name to object binding from this Context * * @param name a <code>Name</code> value * @return a <code>Binding</code> value */ protected Binding getBinding (Name name) { if(Log.isDebugEnabled())Log.debug("Looking up binding for "+name.toString()+" for context="+_name); return (Binding) _bindings.get(name.toString()); }
/** * Get a name to object binding from this Context * * @param name as a String * @return null or the Binding */ protected Binding getBinding (String name) { if(Log.isDebugEnabled())Log.debug("Looking up binding for "+name+" for context="+_name); return (Binding) _bindings.get(name); }
protected void removeBinding (Name name) { String key = name.toString(); if (Log.isDebugEnabled()) Log.debug("Removing binding with key="+key); _bindings.remove(key); }
public void close() { try { out.close(); } catch(IOException e) { Log.debug(e); setError(); } }
/** * Add a name to object binding to this Context. * * @param name a <code>Name</code> value * @param obj an <code>Object</code> value */ protected void addBinding (Name name, Object obj) { String key = name.toString(); if(Log.isDebugEnabled())Log.debug("Adding binding with key="+key+" obj="+obj+" for context="+_name); _bindings.put (key, new Binding (key, obj)); }
public void warning(SAXParseException ex) { Log.debug(Log.EXCEPTION, ex); Log.warn("WARNING@" + getLocationString(ex) + " : " + ex.toString()); }
public void fatalError(SAXParseException ex) throws SAXException { _error = ex; Log.debug(Log.EXCEPTION, ex); Log.warn("FATAL@" + getLocationString(ex) + " : " + ex.toString()); throw ex; }
public void handle(HttpConnection connection) throws IOException, ServletException { String target=connection.getRequest().getPathInfo(); if (Log.isDebugEnabled()) { Log.debug("REQUEST "+target+" on "+connection); handle(target, connection.getRequest(), connection.getResponse(), Handler.REQUEST); Log.debug("RESPONSE "+target+" "+connection.getResponse().getStatus()); } else handle(target, connection.getRequest(), connection.getResponse(), Handler.REQUEST); }