APISonar


lucee.commons.io.log.Log.log

> lucee > commons > io > log > Log > log
lucee APIs commons APIs io APIs log APIs Log APIs log APIs

Example 1
private final Log log;

	public URL getResource(String name) {
		log.log(Log.LEVEL_DEBUG, "LogClassLoader", "getResource");
		return cl.getResource(name);
	}
Example 2
private final Log log;

	public synchronized void setPackageAssertionStatus(String packageName, boolean enabled) {
		log.log(Log.LEVEL_DEBUG, "LogClassLoader", "setPackageAssertionStatus");
		cl.setPackageAssertionStatus(packageName, enabled);
	}
Example 3
private static Class<?> loadVMClass(Resource toolsJar, Log log, JavaVendor vendor) {
		try {
			ClassLoader loader = ClassLoader.getSystemClassLoader();
			String cls = vendor.getVirtualMachineClassName();
			// if (!vendor.isIBM()) {
			loader = new URLClassLoader(new URL[] { ((FileResource) toolsJar).toURI().toURL() }, loader);
			// }
			return loader.loadClass(cls);
		}
		catch (Exception e) {
			log.log(Log.LEVEL_INFO, "Instrumentation", e);

		}
		return null;
	}
Example 4
public static void error(Log log, String msg) {
		if (log != null) log.log(Log.LEVEL_ERROR, "scope-context", msg);
		else LogUtil.logGlobal(ThreadLocalPageContext.getConfig(), Log.LEVEL_ERROR, "scope", msg);
	}
Example 5
private Log log;

	private void log(SpoolerTask task, Exception e, boolean before) {
		if (task instanceof SpoolerTaskPro) {
			SpoolerTaskPro taskp = (SpoolerTaskPro) task;
			SpoolerTaskListener listener = taskp.getListener();
			if (listener != null) listener.listen(config, e, before);
		}
		if (e == null) log.log(Log.LEVEL_INFO, "remote-client", "sucessfully executed: " + task.subject());
		else log.log(Log.LEVEL_ERROR, "remote-client", "failed to execute: " + task.subject(), e);
	}
Example 6
public void removeTags(Log logger, String[] relpath) throws IOException {
		if (ArrayUtil.isEmpty(relpath)) return;
		Resource file = config.getDefaultTagMapping().getPhysical();
		for (int i = 0; i < relpath.length; i++) {
			logger.log(Log.LEVEL_INFO, "extension", "remove Tag " + relpath[i]);
			removeFromDirectory(file, relpath[i]);
		}
	}
Example 7
public void removeTLDs(Log logger, String[] names) throws IOException {
		if (ArrayUtil.isEmpty(names)) return;
		Resource file = config.getTldFile();
		for (int i = 0; i < names.length; i++) {
			logger.log(Log.LEVEL_INFO, "extension", "remove TLD file " + names[i]);
			removeFromDirectory(file, names[i]);
		}
	}
Example 8
private void removeApplications(Config config, Log logger, String[] realpathes) throws PageException, IOException, SAXException {
		if (ArrayUtil.isEmpty(realpathes)) return;
		for (int i = 0; i < realpathes.length; i++) {
			logger.log(Log.LEVEL_INFO, "extension", "remove application " + realpathes[i]);
			removeFiles(config, config.getRootDirectory(), realpathes[i]);
		}
	}