Skip to content

Commit 36e7620

Browse files
committed
https://issues.apache.org/jira/browse/CODEC-120 Migrate to JUnit 4 No [codec] code changes yet. This is all set up for 2.0, Java 5 and JUnit 4. git-svn-id: https://svn.apache.org/repos/asf/commons/proper/codec/trunk@1087590 13f79535-47bb-0310-9956-ffa450edef68
1 parent af1ad3d commit 36e7620

11 files changed

Lines changed: 32 additions & 29 deletions

File tree

build.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ limitations under the License.
8989
windowtitle="${component.title} (Version ${component.version})"
9090
bottom="${component.name} version ${component.version} - Copyright © 2002-${current.year} - Apache Software Foundation"
9191
use="true"
92-
link="http://download.oracle.com/javase/1.4.2/docs/api/"
92+
link="http://download.oracle.com/javase/1.5.0/docs/api/"
9393
encoding="${compile.encoding}">
9494
<classpath refid="compile.classpath"/>
9595
</javadoc>

pom.xml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
<modelVersion>4.0.0</modelVersion>
2020
<groupId>commons-codec</groupId>
2121
<artifactId>commons-codec</artifactId>
22-
<version>1.6-SNAPSHOT</version>
22+
<version>2.0-SNAPSHOT</version>
2323
<name>Commons Codec</name>
2424
<inceptionYear>2002</inceptionYear>
2525
<description>
@@ -180,15 +180,15 @@
180180
<dependency>
181181
<groupId>junit</groupId>
182182
<artifactId>junit</artifactId>
183-
<version>3.8.2</version>
183+
<version>4.8.2</version>
184184
<scope>test</scope>
185185
</dependency>
186186
</dependencies>
187187
<properties>
188-
<maven.compile.source>1.4</maven.compile.source>
189-
<maven.compile.target>1.4</maven.compile.target>
188+
<maven.compile.source>1.5</maven.compile.source>
189+
<maven.compile.target>1.5</maven.compile.target>
190190
<commons.componentid>codec</commons.componentid>
191-
<commons.release.version>1.6</commons.release.version>
191+
<commons.release.version>2.0</commons.release.version>
192192
<!-- The RC version used in the staging repository URL. -->
193193
<commons.rc.version>RC1</commons.rc.version>
194194
<commons.jira.id>CODEC</commons.jira.id>
@@ -276,7 +276,7 @@
276276
<artifactId>clirr-maven-plugin</artifactId>
277277
<version>2.3</version>
278278
<configuration>
279-
<comparisonVersion>1.4</comparisonVersion>
279+
<comparisonVersion>1.5</comparisonVersion>
280280
<minSeverity>info</minSeverity>
281281
</configuration>
282282
</plugin>
@@ -287,7 +287,7 @@
287287
<configuration>
288288
<linksource>true</linksource>
289289
<links>
290-
<link>http://download.oracle.com/javase/1.4.2/docs/api/</link>
290+
<link>http://download.oracle.com/javase/1.5.0/docs/api/</link>
291291
</links>
292292
</configuration>
293293
</plugin>

src/changes/changes.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@
2222
<author>Gary D. Gregory</author>
2323
</properties>
2424
<body>
25+
<release version="2.0" date="TBA" description="Feature and fix release.">
26+
</release>
2527
<release version="1.5" date="29 March 2011" description="Feature and fix release.">
2628
<action dev="sebb" type="fix" issue="CODEC-89">
2729
new Base64().encode() appends a CRLF, and chunks results into 76 character lines.

src/java/org/apache/commons/codec/CharEncoding.java

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
/**
2121
* Character encoding names required of every implementation of the Java platform.
2222
*
23-
* From the Java documentation <a href="http://java.sun.com/j2se/1.4.2/docs/api/java/nio/charset/Charset.html">Standard
23+
* From the Java documentation <a href="http://download.oracle.com/javase/1.5.0/docs/api/java/nio/charset/Charset.html">Standard
2424
* charsets</a>:
2525
* <p>
2626
* <cite>Every implementation of the Java platform is required to support the following character encodings. Consult the
@@ -47,7 +47,7 @@
4747
* This perhaps would best belong in the [lang] project. Even if a similar interface is defined in [lang], it is not
4848
* forseen that [codec] would be made to depend on [lang].
4949
*
50-
* @see <a href="http://java.sun.com/j2se/1.4.2/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
50+
* @see <a href="http://download.oracle.com/javase/1.5.0/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
5151
* @author Apache Software Foundation
5252
* @since 1.4
5353
* @version $Id$
@@ -59,7 +59,7 @@ public class CharEncoding {
5959
* Every implementation of the Java platform is required to support this character encoding.
6060
* </p>
6161
*
62-
* @see <a href="http://java.sun.com/j2se/1.4.2/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
62+
* @see <a href="http://download.oracle.com/javase/1.5.0/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
6363
*/
6464
public static final String ISO_8859_1 = "ISO-8859-1";
6565

@@ -71,7 +71,7 @@ public class CharEncoding {
7171
* Every implementation of the Java platform is required to support this character encoding.
7272
* </p>
7373
*
74-
* @see <a href="http://java.sun.com/j2se/1.4.2/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
74+
* @see <a href="http://download.oracle.com/javase/1.5.0/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
7575
*/
7676
public static final String US_ASCII = "US-ASCII";
7777

@@ -84,7 +84,7 @@ public class CharEncoding {
8484
* Every implementation of the Java platform is required to support this character encoding.
8585
* </p>
8686
*
87-
* @see <a href="http://java.sun.com/j2se/1.4.2/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
87+
* @see <a href="http://download.oracle.com/javase/1.5.0/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
8888
*/
8989
public static final String UTF_16 = "UTF-16";
9090

@@ -96,7 +96,7 @@ public class CharEncoding {
9696
* Every implementation of the Java platform is required to support this character encoding.
9797
* </p>
9898
*
99-
* @see <a href="http://java.sun.com/j2se/1.4.2/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
99+
* @see <a href="http://download.oracle.com/javase/1.5.0/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
100100
*/
101101
public static final String UTF_16BE = "UTF-16BE";
102102

@@ -108,7 +108,7 @@ public class CharEncoding {
108108
* Every implementation of the Java platform is required to support this character encoding.
109109
* </p>
110110
*
111-
* @see <a href="http://java.sun.com/j2se/1.4.2/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
111+
* @see <a href="http://download.oracle.com/javase/1.5.0/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
112112
*/
113113
public static final String UTF_16LE = "UTF-16LE";
114114

@@ -120,7 +120,7 @@ public class CharEncoding {
120120
* Every implementation of the Java platform is required to support this character encoding.
121121
* </p>
122122
*
123-
* @see <a href="http://java.sun.com/j2se/1.4.2/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
123+
* @see <a href="http://download.oracle.com/javase/1.5.0/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
124124
*/
125125
public static final String UTF_8 = "UTF-8";
126126
}

src/java/org/apache/commons/codec/binary/StringUtils.java

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,10 @@
2323

2424
/**
2525
* Converts String to and from bytes using the encodings required by the Java specification. These encodings are specified in <a
26-
* href="http://java.sun.com/j2se/1.4.2/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
26+
* href="http://download.oracle.com/javase/1.5.0/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
2727
*
2828
* @see CharEncoding
29-
* @see <a href="http://java.sun.com/j2se/1.4.2/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
29+
* @see <a href="http://download.oracle.com/javase/1.5.0/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
3030
* @author <a href="mailto:ggregory@seagullsw.com">Gary Gregory</a>
3131
* @version $Id$
3232
* @since 1.4
@@ -42,7 +42,7 @@ public class StringUtils {
4242
* @return encoded bytes, or <code>null</code> if the input string was <code>null</code>
4343
* @throws IllegalStateException
4444
* Thrown when the charset is missing, which should be never according the the Java specification.
45-
* @see <a href="http://java.sun.com/j2se/1.4.2/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
45+
* @see <a href="http://download.oracle.com/javase/1.5.0/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
4646
* @see #getBytesUnchecked(String, String)
4747
*/
4848
public static byte[] getBytesIso8859_1(String string) {
@@ -58,7 +58,7 @@ public static byte[] getBytesIso8859_1(String string) {
5858
* @return encoded bytes, or <code>null</code> if the input string was <code>null</code>
5959
* @throws IllegalStateException
6060
* Thrown when the charset is missing, which should be never according the the Java specification.
61-
* @see <a href="http://java.sun.com/j2se/1.4.2/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
61+
* @see <a href="http://download.oracle.com/javase/1.5.0/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
6262
* @see #getBytesUnchecked(String, String)
6363
*/
6464
public static byte[] getBytesUsAscii(String string) {
@@ -74,7 +74,7 @@ public static byte[] getBytesUsAscii(String string) {
7474
* @return encoded bytes, or <code>null</code> if the input string was <code>null</code>
7575
* @throws IllegalStateException
7676
* Thrown when the charset is missing, which should be never according the the Java specification.
77-
* @see <a href="http://java.sun.com/j2se/1.4.2/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
77+
* @see <a href="http://download.oracle.com/javase/1.5.0/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
7878
* @see #getBytesUnchecked(String, String)
7979
*/
8080
public static byte[] getBytesUtf16(String string) {
@@ -90,7 +90,7 @@ public static byte[] getBytesUtf16(String string) {
9090
* @return encoded bytes, or <code>null</code> if the input string was <code>null</code>
9191
* @throws IllegalStateException
9292
* Thrown when the charset is missing, which should be never according the the Java specification.
93-
* @see <a href="http://java.sun.com/j2se/1.4.2/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
93+
* @see <a href="http://download.oracle.com/javase/1.5.0/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
9494
* @see #getBytesUnchecked(String, String)
9595
*/
9696
public static byte[] getBytesUtf16Be(String string) {
@@ -106,7 +106,7 @@ public static byte[] getBytesUtf16Be(String string) {
106106
* @return encoded bytes, or <code>null</code> if the input string was <code>null</code>
107107
* @throws IllegalStateException
108108
* Thrown when the charset is missing, which should be never according the the Java specification.
109-
* @see <a href="http://java.sun.com/j2se/1.4.2/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
109+
* @see <a href="http://download.oracle.com/javase/1.5.0/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
110110
* @see #getBytesUnchecked(String, String)
111111
*/
112112
public static byte[] getBytesUtf16Le(String string) {
@@ -122,7 +122,7 @@ public static byte[] getBytesUtf16Le(String string) {
122122
* @return encoded bytes, or <code>null</code> if the input string was <code>null</code>
123123
* @throws IllegalStateException
124124
* Thrown when the charset is missing, which should be never according the the Java specification.
125-
* @see <a href="http://java.sun.com/j2se/1.4.2/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
125+
* @see <a href="http://download.oracle.com/javase/1.5.0/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
126126
* @see #getBytesUnchecked(String, String)
127127
*/
128128
public static byte[] getBytesUtf8(String string) {

src/java/org/apache/commons/codec/net/BCodec.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ public BCodec() {
6464
* @param charset
6565
* the default string charset to use.
6666
*
67-
* @see <a href="http://java.sun.com/j2se/1.4.2/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
67+
* @see <a href="http://download.oracle.com/javase/1.5.0/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
6868
*/
6969
public BCodec(final String charset) {
7070
super();

src/java/org/apache/commons/codec/net/QCodec.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ public QCodec() {
119119
* @param charset
120120
* the default string charset to use.
121121
*
122-
* @see <a href="http://java.sun.com/j2se/1.4.2/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
122+
* @see <a href="http://download.oracle.com/javase/1.5.0/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
123123
*/
124124
public QCodec(final String charset) {
125125
super();

src/java/org/apache/commons/codec/net/RFC1522Codec.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ abstract class RFC1522Codec {
7676
* process.
7777
* @throws UnsupportedEncodingException thrown if charset is not supported
7878
*
79-
* @see <a href="http://java.sun.com/j2se/1.4.2/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
79+
* @see <a href="http://download.oracle.com/javase/1.5.0/docs/api/java/nio/charset/Charset.html">Standard charsets</a>
8080
*/
8181
protected String encodeText(final String text, final String charset)
8282
throws EncoderException, UnsupportedEncodingException

src/site/site.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
<item name="Overview" href="/index.html"/>
2828
<item name="Download" href="http://commons.apache.org/codec/download_codec.cgi"/>
2929
<item name="Users guide" href="/userguide.html"/>
30-
<item name="Javadoc (1.4 release)" href="api-release/index.html"/>
30+
<item name="Javadoc (1.5 release)" href="api-release/index.html"/>
3131
</menu>
3232

3333
<menu name="Development">

src/site/xdoc/index.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,7 @@ The <a href="source-repository.html">subversion repository</a> can be
8383
<!-- ================================================== -->
8484
<section name="Releases">
8585
<ul>
86+
<li>Codec 2.0 requires Java 1.5</li>
8687
<li>Codec 1.5 requires Java 1.4</li>
8788
<li>Codec 1.4 requires Java 1.4</li>
8889
</ul>

0 commit comments

Comments
 (0)