You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ecs-dev@jakarta.apache.org by rd...@apache.org on 2008/07/27 15:15:04 UTC

svn commit: r680100 - /jakarta/ecs/trunk/src/java/org/apache/ecs/ECSDefaults.java

Author: rdonkin
Date: Sun Jul 27 06:15:04 2008
New Revision: 680100

URL: http://svn.apache.org/viewvc?rev=680100&view=rev
Log:
ECS-2 dynamic configuration of ECSDefaults, https://issues.apache.org/jira/browse/ECS-2. Contributed by Mauro Manfrin.

Modified:
    jakarta/ecs/trunk/src/java/org/apache/ecs/ECSDefaults.java

Modified: jakarta/ecs/trunk/src/java/org/apache/ecs/ECSDefaults.java
URL: http://svn.apache.org/viewvc/jakarta/ecs/trunk/src/java/org/apache/ecs/ECSDefaults.java?rev=680100&r1=680099&r2=680100&view=diff
==============================================================================
--- jakarta/ecs/trunk/src/java/org/apache/ecs/ECSDefaults.java (original)
+++ jakarta/ecs/trunk/src/java/org/apache/ecs/ECSDefaults.java Sun Jul 27 06:15:04 2008
@@ -37,7 +37,7 @@
     This singleton allows the properties to gracefully default in the 
     case of an error.
     */
-    private static ECSDefaults defaults = new ECSDefaults();
+    private final static ECSDefaults defaults = new ECSDefaults();
 
     //  now follows the private methods called by the 
     private ResourceBundle resource;
@@ -147,6 +147,14 @@
     {
         return defaults.codeset;
     }
+    
+    /**
+        Changes the default codeset dinamically.
+    */
+    public static void setDefaultCodeset(String codeset)
+    {
+        defaults.codeset=codeset;
+    }
 
     /**
         Position of tag relative to start and end.
@@ -165,6 +173,14 @@
     }
 
     /**
+        Changes the default caseType dinamically.
+    */
+    public static void setDefaultCaseType(int case_type)
+    {
+        defaults.case_type=case_type;
+    }
+
+    /**
         Default start-of-tag character.  
     */
     public static char getDefaultStartTag()
@@ -189,6 +205,14 @@
     }
 
     /**
+        Changes the default caseType dinamically.
+    */
+    public static void setDefaultPrettyPrint(boolean pretty_print)
+    {
+        defaults.pretty_print=pretty_print;
+    }
+    
+    /**
         This private constructor is used to create the singleton used in the public static methods. 
     */
     private ECSDefaults ()



---------------------------------------------------------------------
To unsubscribe, e-mail: ecs-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: ecs-dev-help@jakarta.apache.org