i changed the exception-handling of the new producers and localizers to use the multe...
[mir.git] / source / mircoders / global / ProducerEngine.java
index 33ebb65..b59a523 100755 (executable)
@@ -4,6 +4,8 @@ import java.util.*;
 import java.io.*;
 import mir.producer.*;
 import mir.util.*;
+import multex.Exc;
+import multex.Failure;
 
 public class ProducerEngine {
   private Map producers;
@@ -18,9 +20,8 @@ public class ProducerEngine {
       log = new PrintWriter(new FileWriter(new File("/tmp/producer.log")));
     }
     catch (Exception e) {
-      throw new RuntimeException(e.getMessage());
+      throw new ProducerEngineRuntimeExc("Creating PrintWriter log failed",e);
     }
-
     queueThread = new Thread(new ProducerJobQueueThread());
     queueThread.start();
   }
@@ -136,4 +137,11 @@ public class ProducerEngine {
     }
   }
 
+
+  public static class ProducerEngineRuntimeExc extends Failure {
+    public ProducerEngineRuntimeExc(String msg, Exception cause){
+      super(msg,cause);
+    }
+  }
+
 }
\ No newline at end of file