HomeSort by relevance Sort by last modified time
    Searched refs:Charset (Results 1 - 25 of 127) sorted by null

1 2 3 4 5 6

  /external/guava/guava/src/com/google/common/base/
Charsets.java 19 import java.nio.charset.Charset;
22 * Contains constant definitions for the six standard {@link Charset} instances, which are
34 public static final Charset US_ASCII = Charset.forName("US-ASCII");
39 public static final Charset ISO_8859_1 = Charset.forName("ISO-8859-1");
44 public static final Charset UTF_8 = Charset.forName("UTF-8");
49 public static final Charset UTF_16BE = Charset.forName("UTF-16BE")
    [all...]
  /packages/apps/Email/src/org/apache/james/mime4j/util/
CharsetUtil.java 23 import java.nio.charset.IllegalCharsetNameException;
24 import java.nio.charset.UnsupportedCharsetException;
35 * the Java 1.4 <code>java.nio.charset.Charset</code> class but knows many
796 private static class Charset implements Comparable<Charset> {
801 private Charset(String canonical, String mime, String[] aliases) {
807 public int compareTo(Charset c) {
812 private static Charset[] JAVA_CHARSETS = {
813 new Charset("ISO8859_1", "ISO-8859-1",
    [all...]
  /libcore/luni/src/main/java/java/nio/charset/spi/
CharsetProvider.java 17 package java.nio.charset.spi;
19 import java.nio.charset.Charset;
37 public abstract Iterator<Charset> charsets();
40 * Returns the named charset.
42 * If the charset is unavailable the method returns <code>null</code>.
47 * @return the charset, or <code>null</code> if unavailable.
49 public abstract Charset charsetForName(String charsetName);
  /external/guava/guava-tests/test/com/google/common/base/
CharsetsTest.java 21 import java.nio.charset.Charset;
30 assertEquals(Charset.forName("US-ASCII"), Charsets.US_ASCII);
34 assertEquals(Charset.forName("ISO-8859-1"), Charsets.ISO_8859_1);
38 assertEquals(Charset.forName("UTF-8"), Charsets.UTF_8);
42 assertEquals(Charset.forName("UTF-16BE"), Charsets.UTF_16BE);
46 assertEquals(Charset.forName("UTF-16LE"), Charsets.UTF_16LE);
50 assertEquals(Charset.forName("UTF-16"), Charsets.UTF_16);
  /packages/apps/Email/src/com/beetstra/jutf7/
CharsetProvider.java 27 import java.nio.charset.Charset;
34 * Charset service-provider class used for both variants of the UTF-7 charset
35 * and the modified-UTF-7 charset.
40 public class CharsetProvider extends java.nio.charset.spi.CharsetProvider {
54 private Charset utf7charset = new UTF7Charset(UTF7_NAME, UTF7_ALIASES, false);
55 private Charset utf7oCharset = new UTF7Charset(UTF7_O_NAME, UTF7_O_ALIASES, true);
56 private Charset imap4charset = new ModifiedUTF7Charset(UTF7_M_NAME, UTF7_M_ALIASES);
57 private List<Charset> charsets;
72 Charset charset = iter.next(); local
77 Charset charset = iter.next(); local
    [all...]
UTF7StyleCharset.java 27 import java.nio.charset.Charset;
28 import java.nio.charset.CharsetDecoder;
29 import java.nio.charset.CharsetEncoder;
40 abstract class UTF7StyleCharset extends Charset {
58 * @param canonicalName The name as defined in java.nio.charset.Charset
59 * @param aliases The aliases as defined in java.nio.charset.Charset
72 * @see java.nio.charset.Charset#contains(java.nio.charset.Charset)
    [all...]
  /libcore/luni/src/test/java/libcore/java/nio/charset/
CharsetTest.java 17 package libcore.java.nio.charset;
21 import java.nio.charset.Charset;
22 import java.nio.charset.CharsetEncoder;
28 assertNotNull(Charset.forName("ISO-8859-1"));
29 assertNotNull(Charset.forName("US-ASCII"));
30 assertNotNull(Charset.forName("UTF-16"));
31 assertNotNull(Charset.forName("UTF-16BE"));
32 assertNotNull(Charset.forName("UTF-16LE"));
33 assertNotNull(Charset.forName("UTF-8"))
    [all...]
  /libcore/luni/src/main/java/java/nio/charset/
Charsets.java 17 package java.nio.charset;
22 * charset's name.
24 * Also various special-case charset conversions (for performance).
30 * A cheap and type-safe constant for the ISO-8859-1 Charset.
32 public static final Charset ISO_8859_1 = Charset.forName("ISO-8859-1");
35 * A cheap and type-safe constant for the US-ASCII Charset.
37 public static final Charset US_ASCII = Charset.forName("US-ASCII");
40 * A cheap and type-safe constant for the UTF-8 Charset
    [all...]
Charset.java 18 package java.nio.charset;
23 import java.nio.charset.spi.CharsetProvider;
36 * A charset is a named mapping between Unicode characters and byte sequences. Every
37 * {@code Charset} can <i>decode</i>, converting a byte sequence into a sequence of characters,
39 * Use the method {@link #canEncode} to find out whether a charset supports both.
45 * all characters can necessarily be represented by a given charset. The method {@link #contains}
46 * can be used to determine whether every character representable by one charset can also be
92 * <tr> <th>Charset</th> <th>Encoder writes</th> </tr>
107 * <tr> <th>Charset</th> <th>BE BOM</th> <th>LE BOM</th> <th>No BOM</th> </tr>
113 * <h4>Charset names</h4
219 Charset charset = NativeConverter.charsetForName(charsetName); local
220 charsets.put(charset.name(), charset); local
    [all...]
CharsetICU.java 10 package java.nio.charset;
14 final class CharsetICU extends Charset {
30 public boolean contains(Charset cs) {
  /external/apache-harmony/nio_char/src/test/java/tests/api/java/nio/charset/
CharsetProviderTest.java 16 package tests.api.java.nio.charset;
21 import java.nio.charset.Charset;
22 import java.nio.charset.UnsupportedCharsetException;
23 import java.nio.charset.spi.CharsetProvider;
28 import tests.api.java.nio.charset.CharsetTest.MockCharset;
31 * Test charset providers managed by Charset.
60 + "java.nio.charset.spi.CharsetProvider";
90 * Test the method isSupported(String) with charset supported by som
    [all...]
ISOCharsetDecoderTest.java 17 package tests.api.java.nio.charset;
21 import java.nio.charset.Charset;
29 cs = Charset.forName("iso-8859-1");
CharsetTest.java 17 package tests.api.java.nio.charset;
21 import java.nio.charset.Charset;
22 import java.nio.charset.CharsetDecoder;
23 import java.nio.charset.CharsetEncoder;
24 import java.nio.charset.CoderResult;
25 import java.nio.charset.IllegalCharsetNameException;
26 import java.nio.charset.UnsupportedCharsetException;
27 import java.nio.charset.spi.CharsetProvider;
37 * Test class java.nio.Charset
    [all...]
GBCharsetEncoderTest.java 17 package tests.api.java.nio.charset;
20 import java.nio.charset.CharacterCodingException;
21 import java.nio.charset.Charset;
24 * test case specific activity of gb18030 charset encoder
28 // charset for gb180303
29 private static final Charset CS = Charset.forName("gb18030");
ASCCharsetDecoderTest.java 17 package tests.api.java.nio.charset;
21 import java.nio.charset.Charset;
26 cs = Charset.forName("ascii");
GBCharsetDecoderTest.java 17 package tests.api.java.nio.charset;
21 import java.nio.charset.Charset;
29 cs = Charset.forName("gb18030");
UTF16BECharsetDecoderTest.java 17 package tests.api.java.nio.charset;
21 import java.nio.charset.Charset;
29 cs = Charset.forName("utf-16be");
UTF16LECharsetDecoderTest.java 17 package tests.api.java.nio.charset;
21 import java.nio.charset.Charset;
29 cs = Charset.forName("utf-16le");
  /libcore/luni/src/main/java/java/net/
URLDecoder.java 21 import java.nio.charset.Charset;
45 return UriCodec.decode(s, true, Charset.defaultCharset(), true);
67 return UriCodec.decode(s, true, Charset.forName(encoding), true);
URLEncoder.java 21 import java.nio.charset.Charset;
22 import java.nio.charset.Charsets;
54 * Encodes {@code s} using the {@link Charset} named by {@code charsetName}.
57 return ENCODER.encode(s, Charset.forName(charsetName));
  /external/apache-harmony/nio_char/src/test/java/org/apache/harmony/nio_char/tests/java/nio/charset/
CharsetTest.java 17 package org.apache.harmony.nio_char.tests.java.nio.charset;
21 import java.nio.charset.Charset;
22 import java.nio.charset.CharsetDecoder;
23 import java.nio.charset.CharsetEncoder;
24 import java.nio.charset.CoderResult;
25 import java.nio.charset.IllegalCharsetNameException;
45 // Populate the known charset vars
46 Set names = Charset.availableCharsets().keySet();
57 * @tests java.nio.charset.Charset#isRegistered(
    [all...]
CharsetEncoderTest.java 17 package org.apache.harmony.nio_char.tests.java.nio.charset;
23 import java.nio.charset.Charset;
24 import java.nio.charset.CharsetDecoder;
25 import java.nio.charset.CharsetEncoder;
26 import java.nio.charset.CoderMalfunctionError;
27 import java.nio.charset.CoderResult;
34 * @tests java.nio.charset.CharsetEncoder.CharsetEncoder(
35 * java.nio.charset.Charset, float, float
    [all...]
  /dalvik/tests/062-character-encodings/src/
Main.java 1 import java.nio.charset.Charset;
17 SortedMap<String, Charset> all = Charset.availableCharsets();
19 for (Map.Entry<String, Charset> e : all.entrySet()) {
  /external/guava/guava/src/com/google/common/hash/
HashFunction.java 20 import java.nio.charset.Charset;
186 * Shortcut for {@code newHasher().putString(input, charset).hash()}. Characters are encoded
187 * using the given {@link Charset}. The implementation <i>might</i> perform better than its
190 HashCode hashString(CharSequence input, Charset charset);
  /libcore/luni/src/test/java/libcore/java/util/
OldAndroidLocaleTest.java 19 import java.nio.charset.Charset;
206 assertTrue("Charset " + encodings[i] + " must be supported",
207 Charset.isSupported(encodings[i]));
209 Charset cs = Charset.forName(encodings[i]);
218 assertFalse("Charset IBM-37 must not be supported",
219 Charset.isSupported("IBM-37"));
222 assertFalse("Charset KLINGON must not be supported",
223 Charset.isSupported("KLINGON"))
    [all...]

Completed in 849 milliseconds

1 2 3 4 5 6