01: /**************************************************************************/
02: /* N I C E */
03: /* A high-level object-oriented research language */
04: /* (c) Daniel Bonniot 2003 */
05: /* */
06: /* This program is free software; you can redistribute it and/or modify */
07: /* it under the terms of the GNU General Public License as published by */
08: /* the Free Software Foundation; either version 2 of the License, or */
09: /* (at your option) any later version. */
10: /* */
11: /**************************************************************************/package bossa.modules;
12:
13: /**
14: The listener interface for compilation events.
15:
16: @author Daniel Bonniot (bonniot@users.sourceforge.net)
17: */
18:
19: import bossa.util.*;
20:
21: public interface CompilationListener {
22: void error(Location location, String message);
23:
24: void warning(Location location, String message);
25:
26: /** A bug occured in the compiler.
27: @param url the adress where a bug report should be submitted.
28: */
29: void bug(String stackTrace, String url);
30:
31: /** Reports the progress of compilation.
32: phase can be: parsing, type-checking, generating code, ...
33: the package can be null if the phase applies to the whole program
34: (testing dispatch, creating the archive, compiling to native code, ...).
35: */
36: void progress(String packageName, String phase);
37:
38: /** Gives an approximation of how much of the compilation has been completed.
39: @param proportion the current progress
40: (0.0 = just started, 1.0 = complete).
41: */
42: void progress(float proportion);
43: }
|