ServletModule exception cleanup + different error templates for admin + open postings...
[mir.git] / source / mir / config / MirPropertiesConfiguration.java
index 4d2775b..2e39bfb 100755 (executable)
@@ -53,16 +53,16 @@ public class MirPropertiesConfiguration extends PropertiesConfiguration {
   private static ServletContext context;
   private static String contextPath;
 
-  //if one of these properties is not present a new 
+  //if one of these properties is not present a new
   //property is added with its default value;
   private  static NeededProperty[] neededWithValue =
   {
-       new NeededProperty("Producer.DocRoot",""),
-               new NeededProperty("Producer.ImageRoot",""),
-               new NeededProperty("Producer.Image.Path",""),
-               new NeededProperty("Producer.Media.Path",""),
-               new NeededProperty("Producer.RealMedia.Path",""),
-               new NeededProperty("Producer.Image.IconPath","")
+        new NeededProperty("Producer.DocRoot",""),
+                new NeededProperty("Producer.ImageRoot",""),
+                new NeededProperty("Producer.Image.Path",""),
+                new NeededProperty("Producer.Media.Path",""),
+                new NeededProperty("Producer.RealMedia.Path",""),
+                new NeededProperty("Producer.Image.IconPath","")
   };
 
   /**
@@ -110,10 +110,10 @@ public class MirPropertiesConfiguration extends PropertiesConfiguration {
     return context;
   }
 
-       /**
-        * Returns all properties in a Map
-        * @return Map
-        */
+        /**
+         * Returns all properties in a Map
+         * @return Map
+         */
   public Map allSettings() {
     Iterator iterator = this.getKeys();
     Map returnMap = new HashMap();
@@ -153,11 +153,11 @@ public class MirPropertiesConfiguration extends PropertiesConfiguration {
    * Checks if one property is missing and adds a default value
    */
   private void checkMissing() {
-               for (int i = 0; i < neededWithValue.length; i++) {
-                       if (super.getProperty(neededWithValue[i].getKey()) == null) {
-                               addProperty(neededWithValue[i].getKey(), neededWithValue[i].getValue());
-                       }
-               }
+                for (int i = 0; i < neededWithValue.length; i++) {
+                        if (super.getProperty(neededWithValue[i].getKey()) == null) {
+                                addProperty(neededWithValue[i].getKey(), neededWithValue[i].getValue());
+                        }
+                }
   }
 
   public File getFile(String key) throws FileNotFoundException {
@@ -217,28 +217,28 @@ public class MirPropertiesConfiguration extends PropertiesConfiguration {
     public PropertiesConfigFailure(String msg, Throwable cause) {
       super(msg, cause);
     }
-    
+
   }
-  
-       /**
-        * A Class for properties to be checked
-        * @author idefix
-        */
-       private static class NeededProperty {
-               private String _key;
-               private String _value;
-       
-               public NeededProperty(String key, String value) {
-                       _key = key;
-                       _value = value;
-               }
-               
-               public String getKey() {
-                       return _key;
-               }
-               
-               public String getValue() {
-                       return _value;
-               }
-       }
+
+        /**
+         * A Class for properties to be checked
+         * @author idefix
+         */
+        private static class NeededProperty {
+                private String _key;
+                private String _value;
+
+                public NeededProperty(String key, String value) {
+                        _key = key;
+                        _value = value;
+                }
+
+                public String getKey() {
+                        return _key;
+                }
+
+                public String getValue() {
+                        return _value;
+                }
+        }
 }