get rid of generated nested class
Stefan Schuermans

Stefan Schuermans commited on 2011-09-11 10:54:20
Showing 1 changed files, with 3 additions and 6 deletions.

... ...
@@ -34,12 +34,9 @@ public class Msg implements MessageIf
34 34
    */
35 35
   public void message(MsgType type, String txt)
36 36
   {
37
-    switch (type)
38
-    {
39
-      case Err:  System.out.print("error: ");   break;
40
-      case Warn: System.out.print("warning: "); break;
41
-      case Info: System.out.print("info: ");    break;
42
-    }
37
+    if (type == MsgType.Err)  System.out.print("error: ");
38
+    if (type == MsgType.Warn) System.out.print("warning: ");
39
+    if (type == MsgType.Info) System.out.print("info: ");
43 40
     System.out.print(txt);
44 41
   }
45 42
 }
46 43