Author: adelmelle
Date: Sun May 24 11:35:19 2015
New Revision: 1681436

URL: http://svn.apache.org/r1681436
Log:
FOP-2472: Add method to allow clearing the hyphenation tree cache at runtime, 
as suggested by Marc Wiest

Modified:
    xmlgraphics/fop/trunk/src/java/org/apache/fop/hyphenation/Hyphenator.java

Modified: 
xmlgraphics/fop/trunk/src/java/org/apache/fop/hyphenation/Hyphenator.java
URL: 
http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/hyphenation/Hyphenator.java?rev=1681436&r1=1681435&r2=1681436&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/hyphenation/Hyphenator.java 
(original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/hyphenation/Hyphenator.java 
Sun May 24 11:35:19 2015
@@ -64,6 +64,14 @@ public final class Hyphenator {
     }
 
     /**
+     * Clears the default hyphenation tree cache.<br>
+     * This method can be used if the underlying data files are changed at 
runtime.
+     */
+    public static synchronized void clearHyphenationTreeCache() {
+        hTreeCache = new HyphenationTreeCache();
+    }
+
+    /**
      * Returns a hyphenation tree for a given language and country,
      * with fallback from (lang,country) to (lang).
      * The hyphenation trees are cached.



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to