APISonar


org.eclipse.core.runtime.ILog.log

> org > eclipse > core > runtime > ILog > log
org APIs eclipse APIs core APIs runtime APIs ILog APIs log APIs

Example 1
public static void log(String message, Throwable error) {
        ILog log = getLog();
        if (log != null) {
            log.log(new Status(error == null ? IStatus.INFO : IStatus.ERROR,
                    XMindCommandPlugin.PLUGIN_ID, message, error));
        }
    }
Example 2
static public void log(Throwable ex) {
		ILog log = EasyDroolsPlugin.getDefault().getLog();
		StringWriter stringWriter = new StringWriter();
		ex.printStackTrace(new PrintWriter(stringWriter));
		String msg = stringWriter.getBuffer().toString();
		Status status = new Status(IStatus.ERROR, BUNDLE_ID, IStatus.ERROR, msg, null);
		log.log(status);
	}
Example 3
private final ILog eclipseLog;

    public void info(Object message)
    {
        if (message instanceof Throwable) {
            info(message.toString(), (Throwable)message);
            return;
        }
        eclipseLog.log(new Status(
            Status.INFO,
            corePluginID,
            message == null ? null : message.toString()));
    }
Example 4
private static ILog eclipseLog;

    private static void writeEclipseLog(IStatus status) {
        if (eclipseLog != null) {
            eclipseLog.log(status);
        }
    }