equal
deleted
inserted
replaced
40 proc.getOutputStream.close |
40 proc.getOutputStream.close |
41 val output = Source.fromInputStream(proc.getInputStream, charset).mkString |
41 val output = Source.fromInputStream(proc.getInputStream, charset).mkString |
42 val rc = proc.waitFor |
42 val rc = proc.waitFor |
43 (output, rc) |
43 (output, rc) |
44 } |
44 } |
45 |
|
46 } |
45 } |
47 |
46 |
48 |
47 |
49 class Isabelle_System |
48 class Isabelle_System |
50 { |
49 { |
51 |
|
52 /** unique ids **/ |
50 /** unique ids **/ |
53 |
51 |
54 private var id_count: BigInt = 0 |
52 private var id_count: BigInt = 0 |
55 def id(): String = synchronized { id_count += 1; "j" + id_count } |
53 def id(): String = synchronized { id_count += 1; "j" + id_count } |
56 |
54 |
242 else None |
240 else None |
243 } |
241 } |
244 } |
242 } |
245 |
243 |
246 |
244 |
|
245 |
247 /** system tools **/ |
246 /** system tools **/ |
248 |
247 |
249 /* external processes */ |
248 /* external processes */ |
250 |
249 |
251 def execute(redirect: Boolean, args: String*): Process = |
250 def execute(redirect: Boolean, args: String*): Process = |
294 else new FileInputStream(fifo) |
293 else new FileInputStream(fifo) |
295 new BufferedReader(new InputStreamReader(stream, Isabelle_System.charset)) |
294 new BufferedReader(new InputStreamReader(stream, Isabelle_System.charset)) |
296 } |
295 } |
297 |
296 |
298 |
297 |
|
298 |
299 /** Isabelle resources **/ |
299 /** Isabelle resources **/ |
300 |
300 |
301 /* components */ |
301 /* components */ |
302 |
302 |
303 def components(): List[String] = |
303 def components(): List[String] = |