This change breaks backwards compatibility but I think is justified. I agree that...
commit332b3ccb8a5de488a5957af91343d39f9b855d0d
authorRobert Burrell Donkin <rdonkin@apache.org>
Sun, 6 Jul 2008 10:23:15 +0000 (6 10:23 +0000)
committerRobert Burrell Donkin <rdonkin@apache.org>
Sun, 6 Jul 2008 10:23:15 +0000 (6 10:23 +0000)
treebb5d4c7d1956308f395c6f0dd8f1976253e89cb6
parentaa01ba5851b49b919aea62237ca1a9d4ffae67b2
This change breaks backwards compatibility but I think is justified. I agree that defaulting is appropriate for TEXT types but is very unreliable for other types. For many types conversion to characters is not appropriate (for example, image/png). For other types, the type itself contains charset meta-data (for example application/xhtml+xml). By defaulting in these cases information is lost: it is not possible to destinguish between the case when the charset parameters is explicitly set to us-ascii and when the charset is unset. Non TEXT types cannot be assumed to default to us-ascii and so this behaviour is potentially dangerous.

git-svn-id: https://svn.eu.apache.org/repos/asf/james/mime4j/trunk@674281 13f79535-47bb-0310-9956-ffa450edef68
src/main/java/org/apache/james/mime4j/ContentDescriptor.java
src/main/java/org/apache/james/mime4j/DefaultBodyDescriptor.java
src/test/java/org/apache/james/mime4j/BaseTestForBodyDescriptors.java