Java Charset getPreferredEncoding()

PreviousNext

Return:

the encoding we want to use, currently hardcoded to ISO-8859-1

//package com.java2s;
/* NOTICE: This file has been changed by Plutext Pty Ltd for use in docx4j.
 * The package name has been changed; there may also be other changes.
 * 
 * This notice is included to meet the condition in clause 4(b) of the License. 
 */

import java.nio.charset.Charset;

public class Main {
    private static final Charset ISO_8859_1 = Charset.forName("ISO-8859-1");

    /**
     * @return the encoding we want to use, currently hardcoded to ISO-8859-1
     */
    public static String getPreferredEncoding() {
        return ISO_8859_1.name();
    }
}
PreviousNext

Related