cleanup / abuse system fix / prepping for a release
[mir.git] / source / mir / producer / reader / ProducerConfigReader.java
index 631573f..3b10689 100755 (executable)
@@ -43,7 +43,7 @@ import mir.producer.CompositeProducerNode;
 import mir.producer.ProducerFactory;
 import mir.producer.ProducerNode;
 import mir.producer.SimpleProducerVerb;
-import mir.util.ExceptionFunctions;
+import mir.util.ExceptionRoutines;
 import mir.util.xml.XMLParserEngine;
 import mir.util.xml.XMLParserExc;
 import mir.util.xml.XMLParserFailure;
@@ -54,7 +54,7 @@ public class ProducerConfigReader {
 
   public ProducerConfigReader() {
     super();
-  };
+  }
 
   public void parse(Reader aReader, ProducerNodeBuilderLibrary aBuilderLibrary, List aProducerFactories) throws ProducerConfigFailure {
     try {
@@ -65,7 +65,7 @@ public class ProducerConfigReader {
 
     }
     catch (Throwable e) {
-      Throwable root = ExceptionFunctions.traceCauseException(e);
+      Throwable root = ExceptionRoutines.traceCauseException(e);
 
       if ((root instanceof XMLParserExc) && ((XMLParserExc) root).getHasLocation()) {
         XMLParserExc f = (XMLParserExc) root;
@@ -83,7 +83,7 @@ public class ProducerConfigReader {
 
     }
     catch (Throwable e) {
-      Throwable root = ExceptionFunctions.traceCauseException(e);
+      Throwable root = ExceptionRoutines.traceCauseException(e);
 
       if ((root instanceof XMLParserExc) && ((XMLParserExc) root).getHasLocation()) {
         XMLParserExc f = (XMLParserExc) root;
@@ -104,8 +104,7 @@ public class ProducerConfigReader {
       if (aTag.equals("producers")) {
         return new ProducersSectionHandler(producers);
       }
-      else
-        throw new XMLParserExc("Tag 'producers' expected, tag '"+aTag+"' found");
+                       throw new XMLParserExc("Tag 'producers' expected, tag '"+aTag+"' found");
     }
 
     public void endElement(mir.util.xml.SectionHandler aHandler) {
@@ -201,14 +200,12 @@ public class ProducerConfigReader {
           throw new XMLParserExc("Verbs already processed");
         if (body!=null)
           throw new XMLParserExc("Verbs should come before body");
-        else
-          return new ProducerVerbsSectionHandler();
+                               return new ProducerVerbsSectionHandler();
       }
       else if (aTag.equals("body")) {
         if (body==null)
           return new ProducerNodeSectionHandler();
-        else
-          throw new XMLParserExc("Body already processed");
+                               throw new XMLParserExc("Body already processed");
       }
       throw new XMLParserExc("Unexpected tag: '"+aTag+"'");
     }
@@ -288,8 +285,7 @@ public class ProducerConfigReader {
 
         return new ProducerNodeSectionHandler();
       }
-      else
-        throw new XMLParserExc("Only 'verb' tags allowed here, '" + aTag + "' encountered.");
+                       throw new XMLParserExc("Only 'verb' tags allowed here, '" + aTag + "' encountered.");
     }
 
     public void endElement(mir.util.xml.SectionHandler aHandler) {
@@ -472,9 +468,7 @@ public class ProducerConfigReader {
       if (producerNode.getNrSubNodes()==1) {
         return producerNode.getSubNode(0);
       }
-      else {
-        return producerNode;
-      }
+                       return producerNode;
     }
 
     public void finishSection() {