equal
deleted
inserted
replaced
18 import isabelle.IsarDocument |
18 import isabelle.IsarDocument |
19 |
19 |
20 |
20 |
21 class Prover(isabelle_system: IsabelleSystem) |
21 class Prover(isabelle_system: IsabelleSystem) |
22 { |
22 { |
23 private var process: Isar = null |
|
24 |
|
25 private val commands = new mutable.HashMap[IsarDocument.Command_ID, Command] |
|
26 |
|
27 |
|
28 /* outer syntax keywords */ |
23 /* outer syntax keywords */ |
29 |
24 |
30 val decl_info = new EventBus[(String, String)] |
25 val decl_info = new EventBus[(String, String)] |
31 |
26 |
32 private val keyword_decls = new mutable.HashSet[String] { |
27 private val keyword_decls = new mutable.HashSet[String] { |
57 */ |
52 */ |
58 decl_info += (k_v => _completions += k_v._1) |
53 decl_info += (k_v => _completions += k_v._1) |
59 |
54 |
60 |
55 |
61 /* event handling */ |
56 /* event handling */ |
|
57 |
|
58 private var process: Isar = null |
|
59 |
|
60 private val commands = new mutable.HashMap[IsarDocument.Command_ID, Command] |
|
61 |
62 |
62 |
63 private var initialized = false |
63 private var initialized = false |
64 |
64 |
65 val activated = new EventBus[Unit] |
65 val activated = new EventBus[Unit] |
66 val command_info = new EventBus[Command] |
66 val command_info = new EventBus[Command] |
162 } |
162 } |
163 } |
163 } |
164 |
164 |
165 |
165 |
166 def start(logic: String) { |
166 def start(logic: String) { |
167 val results = new EventBus[IsabelleProcess.Result] |
167 val results = new EventBus[IsabelleProcess.Result] + handle_result |
168 results += handle_result |
|
169 results.logger = Log.log(Log.ERROR, null, _) |
168 results.logger = Log.log(Log.ERROR, null, _) |
170 process = new Isar(isabelle_system, results, "-m", "xsymbols", logic) |
169 process = new Isar(isabelle_system, results, "-m", "xsymbols", logic) |
171 } |
170 } |
172 |
171 |
173 def stop() { |
172 def stop() { |