opensubscriber
   Find in this group all groups
 
Unknown more information…

e : ecs-dev@jakarta.apache.org 27 July 2008 • 9:15PM -0400

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

REPLY TO AUTHOR
 
REPLY TO GROUP




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@jaka...
For additional commands, e-mail: ecs-dev-help@jaka...

Bookmark with:

Delicious   Digg   reddit   Facebook   StumbleUpon

opensubscriber is not affiliated with the authors of this message nor responsible for its content.