|
1 /* |
|
2 * Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: |
|
15 * |
|
16 * Event listener interface |
|
17 * |
|
18 */ |
|
19 package com.nokia.tracecompiler.engine; |
|
20 |
|
21 import com.nokia.tracecompiler.model.TraceCompilerException; |
|
22 |
|
23 /** |
|
24 * Event listener interface |
|
25 * |
|
26 */ |
|
27 public interface TraceCompilerEngineEvents { |
|
28 |
|
29 /** |
|
30 * Posts an error event to TraceCompiler |
|
31 * |
|
32 * @param exception |
|
33 * the error data |
|
34 */ |
|
35 public void postError(TraceCompilerException exception); |
|
36 |
|
37 /** |
|
38 * Posts an error event to TraceCompiler |
|
39 * |
|
40 * @param message |
|
41 * the error message |
|
42 * @param source |
|
43 * the error source |
|
44 * @param postEvent |
|
45 * defines is error event also posted to trace event view |
|
46 */ |
|
47 public void postErrorMessage(String message, Object source, boolean postEvent); |
|
48 |
|
49 /** |
|
50 * Posts a warning event to TraceCompiler |
|
51 * |
|
52 * @param message |
|
53 * the warning message |
|
54 * @param source |
|
55 * the warning source |
|
56 */ |
|
57 public void postWarningMessage(String message, Object source); |
|
58 |
|
59 /** |
|
60 * Posts an info event to TraceCompiler |
|
61 * |
|
62 * @param message |
|
63 * the info message |
|
64 * @param source |
|
65 * the info source |
|
66 */ |
|
67 public void postInfoMessage(String message, Object source); |
|
68 |
|
69 /** |
|
70 * Posts a critical assertion failed event |
|
71 * |
|
72 * @param message |
|
73 * the message |
|
74 * @param source |
|
75 * the source of the assertion |
|
76 * @throws TraceCompilerException |
|
77 */ |
|
78 public void postCriticalAssertionFailed(String message, Object source) throws TraceCompilerException; |
|
79 |
|
80 /** |
|
81 * Posts an assertion failed event |
|
82 * |
|
83 * @param message |
|
84 * the message |
|
85 * @param source |
|
86 * the source of the assertion |
|
87 */ |
|
88 public void postAssertionFailed(String message, Object source); |
|
89 |
|
90 /** |
|
91 * Gets the processing error |
|
92 * |
|
93 * @return the error |
|
94 */ |
|
95 public boolean hasErrorHappened(); |
|
96 |
|
97 |
|
98 } |