/** * Logs performance event failures to the platform's performance log */ private void logFailure(PerformanceStats stats, String pluginId, long elapsed) { //may have failed to get the performance log service if (log == null) return; if (pluginId == null) pluginId = Platform.PI_RUNTIME; String msg = "Performance failure: " + stats.getEvent() + " blame: " + stats.getBlameString() + " context: " + stats.getContext() + " duration: " + elapsed; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ Status status = new Status(IStatus.WARNING, pluginId, 1, msg, new RuntimeException()); log.log(new FrameworkLogEntry(status, status.getPlugin(), status.getSeverity(), status.getCode(), status.getMessage(), 0, status.getException(), null)); }
/** * @see IStatus#getSeverity() */ public int getSeverity() { if (this.children == NO_CHILDREN) return super.getSeverity(); int severity = -1; for (int i = 0, max = this.children.length; i < max; i++) { int childrenSeverity = this.children[i].getSeverity(); if (childrenSeverity > severity) { severity = childrenSeverity; } } return severity; } /**
/** * @see IStatus#getSeverity() */ @Override public int getSeverity() { if (this.children == NO_CHILDREN) return super.getSeverity(); int severity = -1; for (int i = 0, max = this.children.length; i < max; i++) { int childrenSeverity = this.children[i].getSeverity(); if (childrenSeverity > severity) { severity = childrenSeverity; } } return severity; } /**
/** * @see IStatus#getSeverity() */ public int getSeverity() { if (this.children == NO_CHILDREN) return super.getSeverity(); int severity = -1; for (int i = 0, max = this.children.length; i < max; i++) { int childrenSeverity = this.children[i].getSeverity(); if (childrenSeverity > severity) { severity = childrenSeverity; } } return severity; } /**
/** * @see IStatus#getSeverity() */ public int getSeverity() { if (this.children == NO_CHILDREN) return super.getSeverity(); int severity = -1; for (int i = 0, max = this.children.length; i < max; i++) { int childrenSeverity = this.children[i].getSeverity(); if (childrenSeverity > severity) { severity = childrenSeverity; } } return severity; } /**
/** * @see IStatus#getSeverity() */ public int getSeverity() { if (this.children == NO_CHILDREN) return super.getSeverity(); int severity = -1; for (int i = 0, max = this.children.length; i < max; i++) { int childrenSeverity = this.children[i].getSeverity(); if (childrenSeverity > severity) { severity = childrenSeverity; } } return severity; } /**
/** * @see IStatus#getSeverity() */ public int getSeverity() { if (this.children == NO_CHILDREN) return super.getSeverity(); int severity = -1; for (int i = 0, max = this.children.length; i < max; i++) { int childrenSeverity = this.children[i].getSeverity(); if (childrenSeverity > severity) { severity = childrenSeverity; } } return severity; } /**
/** * Logs performance event failures to the platform's performance log */ private void logFailure(PerformanceStats stats, String pluginId, long elapsed) { //may have failed to get the performance log service if (log == null) return; if (pluginId == null) pluginId = Platform.PI_RUNTIME; String msg = "Performance failure: " + stats.getEvent() + " blame: " + stats.getBlameString() + " context: " + stats.getContext() + " duration: " + elapsed; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ Status status = new Status(IStatus.WARNING, pluginId, 1, msg, new RuntimeException()); log.log(new FrameworkLogEntry(status, status.getPlugin(), status.getSeverity(), status.getCode(), status.getMessage(), 0, status.getException(), null)); }
/** * Logs performance event failures to the platform's performance log */ private void logFailure(PerformanceStats stats, String pluginId, long elapsed) { //may have failed to get the performance log service if (log == null) return; if (pluginId == null) pluginId = Platform.PI_RUNTIME; String msg = "Performance failure: " + stats.getEvent() + " blame: " + stats.getBlameString() + " context: " + stats.getContext() + " duration: " + elapsed; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ Status status = new Status(IStatus.WARNING, pluginId, 1, msg, new RuntimeException()); log.log(new FrameworkLogEntry(status, status.getPlugin(), status.getSeverity(), status.getCode(), status.getMessage(), 0, status.getException(), null)); }