You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by se...@apache.org on 2013/04/17 15:30:10 UTC

svn commit: r1468905 - in /commons/proper/io/trunk/src: changes/changes.xml main/java/org/apache/commons/io/ByteOrderMark.java

Author: sebb
Date: Wed Apr 17 13:30:10 2013
New Revision: 1468905

URL: http://svn.apache.org/r1468905
Log:
IO-341 A constant for holding the BOM character (U+FEFF)

Modified:
    commons/proper/io/trunk/src/changes/changes.xml
    commons/proper/io/trunk/src/main/java/org/apache/commons/io/ByteOrderMark.java

Modified: commons/proper/io/trunk/src/changes/changes.xml
URL: http://svn.apache.org/viewvc/commons/proper/io/trunk/src/changes/changes.xml?rev=1468905&r1=1468904&r2=1468905&view=diff
==============================================================================
--- commons/proper/io/trunk/src/changes/changes.xml (original)
+++ commons/proper/io/trunk/src/changes/changes.xml Wed Apr 17 13:30:10 2013
@@ -47,6 +47,9 @@ The <action> type attribute can be add,u
   <body>
     <!-- The release date is the date RC is cut -->
     <release version="2.5" date="2013-??-??" description="New features and bug fixes.">    
+      <action issue="IO-341" dev="sebb" type="add">
+         A constant for holding the BOM character (U+FEFF)
+      </action>            
       <action issue="IO-314" dev="sebb" type="fix">
         Deprecate and then remove all methods that use the default encoding
       </action>            

Modified: commons/proper/io/trunk/src/main/java/org/apache/commons/io/ByteOrderMark.java
URL: http://svn.apache.org/viewvc/commons/proper/io/trunk/src/main/java/org/apache/commons/io/ByteOrderMark.java?rev=1468905&r1=1468904&r2=1468905&view=diff
==============================================================================
--- commons/proper/io/trunk/src/main/java/org/apache/commons/io/ByteOrderMark.java (original)
+++ commons/proper/io/trunk/src/main/java/org/apache/commons/io/ByteOrderMark.java Wed Apr 17 13:30:10 2013
@@ -53,6 +53,13 @@ public class ByteOrderMark implements Se
      */
     public static final ByteOrderMark UTF_32LE = new ByteOrderMark("UTF-32LE", 0xFF, 0xFE, 0x00, 0x00);
     
+    /**
+     * Unicode BOM character; external form depends on the encoding. 
+     * @see <a href="http://unicode.org/faq/utf_bom.html#BOM">Byte Order Mark (BOM) FAQ</a>
+     * @since 2.5
+     */
+    public static final char UTF_BOM = '\uFEFF';
+
     private final String charsetName;
     private final int[] bytes;