Code ASCII java
Résolu
nour_master
Messages postés
10
Date d'inscription
mardi 11 novembre 2008
Statut
Membre
Dernière intervention
17 décembre 2008
-
12 nov. 2008 à 11:48
choubaka Messages postés 39442 Date d'inscription jeudi 4 avril 2002 Statut Modérateur Dernière intervention 1 août 2025 -
choubaka Messages postés 39442 Date d'inscription jeudi 4 avril 2002 Statut Modérateur Dernière intervention 1 août 2025 -
Bonjour,
je cherche une methode java qui permet de retournet la chaine binaire coresponante a une chaine de caractere
je cherche une methode java qui permet de retournet la chaine binaire coresponante a une chaine de caractere
A voir également:
- Code ASCII java
- Code ascii - Guide
- Waptrick java football - Télécharger - Jeux vidéo
- Jeux java itel - Télécharger - Jeux vidéo
- Code puk bloqué - Guide
- Eclipse java - Télécharger - Langages
2 réponses
choubaka
Messages postés
39442
Date d'inscription
jeudi 4 avril 2002
Statut
Modérateur
Dernière intervention
1 août 2025
2 105
12 nov. 2008 à 15:46
12 nov. 2008 à 15:46
Salut
il y a la méthode ci dessous de l'objet String
getBytes()
Convert this String into bytes according to the platform's default character encoding, storing the result into a new byte array.
il y a la méthode ci dessous de l'objet String
getBytes()
Convert this String into bytes according to the platform's default character encoding, storing the result into a new byte array.
choubaka
Messages postés
39442
Date d'inscription
jeudi 4 avril 2002
Statut
Modérateur
Dernière intervention
1 août 2025
2 105
13 nov. 2008 à 23:08
13 nov. 2008 à 23:08
salut
suivant ce lien
http://java.sun.com/j2se/1.3/docs/api/java/lang/package-summary.html#charenc
si tu regardes bien, il y a une remarque concernant la machine virtuelle java
"Every instance of the Java virtual machine has a default character encoding. The default encoding is determined during virtual-machine startup and typically depends upon the locale and encoding being used by the underlying operating system."
en fait, tu dois vérifier ceci
par défaut, c'est le US-ASCII qui est implémenté, tu dois modifier les paramètre de ta machine virtuelle et mettre l'UTF-8 si tu veux du 8 bits
suivant ce lien
http://java.sun.com/j2se/1.3/docs/api/java/lang/package-summary.html#charenc
si tu regardes bien, il y a une remarque concernant la machine virtuelle java
"Every instance of the Java virtual machine has a default character encoding. The default encoding is determined during virtual-machine startup and typically depends upon the locale and encoding being used by the underlying operating system."
en fait, tu dois vérifier ceci
Every implementation of the Java platform is required to support the following character encodings. Consult the release documentation for your implementation to see if any other encodings are supported. US-ASCII Seven-bit ASCII, a.k.a. ISO646-US, a.k.a. the Basic Latin block of the Unicode character set ISO-8859-1 ISO Latin Alphabet No. 1, a.k.a. ISO-LATIN-1 UTF-8 Eight-bit Unicode Transformation Format UTF-16BE Sixteen-bit Unicode Transformation Format, big-endian byte order UTF-16LE Sixteen-bit Unicode Transformation Format, little-endian byte order UTF-16 Sixteen-bit Unicode Transformation Format, byte order specified by a mandatory initial byte-order mark (either order accepted on input, big-endian used on output)
par défaut, c'est le US-ASCII qui est implémenté, tu dois modifier les paramètre de ta machine virtuelle et mettre l'UTF-8 si tu veux du 8 bits
13 nov. 2008 à 13:26
merci encord