diff --git a/src/share/classes/com/sun/tools/doclets/internal/toolkit/resources/doclet.xml b/src/share/classes/com/sun/tools/doclets/internal/toolkit/resources/doclet.xml index fa1f618178214afdd657f05cfba1dc731ca6857c..a88acc9b314a55f400c3c89cc2d17241fe74139e 100644 --- a/src/share/classes/com/sun/tools/doclets/internal/toolkit/resources/doclet.xml +++ b/src/share/classes/com/sun/tools/doclets/internal/toolkit/resources/doclet.xml @@ -1,7 +1,7 @@ <?xml version='1.0' encoding='utf-8'?> <!-- - Copyright 2003-2009 Sun Microsystems, Inc. All Rights Reserved. + Copyright 2003-2009 Sun Microsystems, Inc. All Rights Reserved. DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. This code is free software; you can redistribute it and/or modify it @@ -44,7 +44,7 @@ <PackageTags/> <PackageFooter/> </PackageDoc> - + <AnnotationTypeDoc> <AnnotationTypeHeader/> <DeprecationInfo/> @@ -52,7 +52,7 @@ <AnnotationTypeDescription/> <AnnotationTypeTagInfo/> <MemberSummary> - <AnnotationTypeRequiredMemberSummary/> + <AnnotationTypeRequiredMemberSummary/> <AnnotationTypeOptionalMemberSummary/> </MemberSummary> <AnnotationTypeRequiredMemberDetails> @@ -77,16 +77,16 @@ <MemberFooter/> </AnnotationTypeOptionalMember> <Footer/> - </AnnotationTypeOptionalMemberDetails> + </AnnotationTypeOptionalMemberDetails> <AnnotationTypeFooter/> </AnnotationTypeDoc> - + <ClassDoc> <ClassHeader/> <ClassTree/> <TypeParamInfo/> <SuperInterfacesInfo/> - <ImplementedInterfacesInfo/> + <ImplementedInterfacesInfo/> <SubClassInfo/> <SubInterfacesInfo/> <InterfaceUsageInfo/> @@ -100,7 +100,7 @@ <NestedClassesInheritedSummary/> <EnumConstantsSummary/> <FieldsSummary/> - <FieldsInheritedSummary/> + <FieldsInheritedSummary/> <ConstructorsSummary/> <MethodsSummary/> <MethodsInheritedSummary/> @@ -155,7 +155,7 @@ </MethodDetails> <ClassFooter/> </ClassDoc> - + <ConstantSummary> <Header/> <Contents/> @@ -166,12 +166,12 @@ <ClassHeader/> <ConstantMembers/> <ClassFooter/> - </ClassConstantSummary> + </ClassConstantSummary> </PackageConstantSummary> - </ConstantSummaries> + </ConstantSummaries> <Footer/> </ConstantSummary> - + <SerializedForm> <Header/> <SerializedFormSummaries> diff --git a/test/com/sun/javadoc/testCRLineSeparator/TestCRLineSeparator.java b/test/com/sun/javadoc/testCRLineSeparator/TestCRLineSeparator.java index 94122cd1f584d5f15e86dde8bb09d8167485c0a7..f2f0ae043e179eadee8e768ed501f9117685595f 100644 --- a/test/com/sun/javadoc/testCRLineSeparator/TestCRLineSeparator.java +++ b/test/com/sun/javadoc/testCRLineSeparator/TestCRLineSeparator.java @@ -32,6 +32,9 @@ * @run main TestCRLineSeparator */ +import java.io.*; +import java.util.*; + public class TestCRLineSeparator extends JavadocTester { //Test information. @@ -39,7 +42,7 @@ public class TestCRLineSeparator extends JavadocTester { //Javadoc arguments. private static final String[] ARGS = new String[] { - "-d", BUG_ID, "-sourcepath", SRC_DIR, "pkg" + "-d", BUG_ID, "-sourcepath", ".", "pkg" }; //Input for string search tests. @@ -53,7 +56,8 @@ public class TestCRLineSeparator extends JavadocTester { * The entry point of the test. * @param args the array of command line arguments. */ - public static void main(String[] args) { + public static void main(String[] args) throws Exception { + initFiles(new File(SRC_DIR), new File("."), "pkg"); TestCRLineSeparator tester = new TestCRLineSeparator(); run(tester, ARGS, TEST, NEGATED_TEST); tester.printSummary(); @@ -72,4 +76,36 @@ public class TestCRLineSeparator extends JavadocTester { public String getBugName() { return getClass().getName(); } + + // recursively copy files from fromDir to toDir, replacing newlines + // with \r + static void initFiles(File fromDir, File toDir, String f) throws IOException { + File from_f = new File(fromDir, f); + File to_f = new File(toDir, f); + if (from_f.isDirectory()) { + to_f.mkdirs(); + for (String child: from_f.list()) { + initFiles(from_f, to_f, child); + } + } else { + List<String> lines = new ArrayList<String>(); + BufferedReader in = new BufferedReader(new FileReader(from_f)); + try { + String line; + while ((line = in.readLine()) != null) + lines.add(line); + } finally { + in.close(); + } + BufferedWriter out = new BufferedWriter(new FileWriter(to_f)); + try { + for (String line: lines) { + out.write(line); + out.write("\r"); + } + } finally { + out.close(); + } + } + } } diff --git a/test/com/sun/javadoc/testCRLineSeparator/pkg/MyClass.java b/test/com/sun/javadoc/testCRLineSeparator/pkg/MyClass.java index fb833e7c176585b16d4419bbc8649f1965024212..e54d38787a702d8bee9aa741da3367af0cd60ee0 100644 --- a/test/com/sun/javadoc/testCRLineSeparator/pkg/MyClass.java +++ b/test/com/sun/javadoc/testCRLineSeparator/pkg/MyClass.java @@ -21,4 +21,11 @@ * have any questions. */ -package pkg; /** * Line 1 * Line 2 */ public class MyClass {} +package pkg; + +/** + * Line 1 + * Line 2 + */ +public class MyClass {} + diff --git a/test/com/sun/javadoc/testHref/package-list b/test/com/sun/javadoc/testHref/package-list index 7fd0dd341f68963a8ec34b85c27b6ea257ecdec2..46af8ccb0d04ce5e452800b35a8958de24839d11 100644 --- a/test/com/sun/javadoc/testHref/package-list +++ b/test/com/sun/javadoc/testHref/package-list @@ -1 +1 @@ -java.lang +java.lang diff --git a/test/com/sun/javadoc/testLinkOption/testNewLineInLink/package.html b/test/com/sun/javadoc/testLinkOption/testNewLineInLink/package.html index 7079f01cd7a6c4a2c13cc2d9c3db63f5fa850e3d..a03aa66b10190525b34eb5f12120bef2fce8b1b9 100644 --- a/test/com/sun/javadoc/testLinkOption/testNewLineInLink/package.html +++ b/test/com/sun/javadoc/testLinkOption/testNewLineInLink/package.html @@ -1,6 +1,6 @@ -<html> -<body> -{@link java.awt.Color#getAlpha() -getAlpha} -</body> -</html> +<html> +<body> +{@link java.awt.Color#getAlpha() +getAlpha} +</body> +</html> diff --git a/test/com/sun/javadoc/testNoPackagesFile/TestNoPackagesFile.java b/test/com/sun/javadoc/testNoPackagesFile/TestNoPackagesFile.java index d2ee69a435f14f306b3640d5d1b8168bd0b22805..6b1c2e622623334361683119269a8cec8edc3a24 100644 --- a/test/com/sun/javadoc/testNoPackagesFile/TestNoPackagesFile.java +++ b/test/com/sun/javadoc/testNoPackagesFile/TestNoPackagesFile.java @@ -52,7 +52,7 @@ public class TestNoPackagesFile extends JavadocTester { TestNoPackagesFile tester = new TestNoPackagesFile(); run(tester, ARGS, NO_TEST, NO_TEST); if ((new java.io.File(BUG_ID + FS + "packages.html")).exists()) { - throw new Error("Test Fails: packages file should not be " + "generated anymore."); + throw new Error("Test Fails: packages file should not be " + "generated anymore."); } else { System.out.println("Test passes: packages.html not found."); } diff --git a/test/com/sun/javadoc/testOverridenMethods/TestMultiInheritence.java b/test/com/sun/javadoc/testOverridenMethods/TestMultiInheritence.java index 48859b65d8149b0b79bc8ae48f856a7f13c7716f..38cd053934a4656e2a0a06480eb226dadecc69be 100644 --- a/test/com/sun/javadoc/testOverridenMethods/TestMultiInheritence.java +++ b/test/com/sun/javadoc/testOverridenMethods/TestMultiInheritence.java @@ -46,7 +46,7 @@ public class TestMultiInheritence extends JavadocTester { //Method foo() is inherited from BOTH I2 and I3 private static final String[][] TEST = { {BUG_ID + FS + "pkg3" + FS + "I1.html", - "Methods inherited from interface pkg3." + "<A HREF=\"../pkg3/I2.html\" title=\"interface in pkg3\">I2</A>"}, + "Methods inherited from interface pkg3." + "<A HREF=\"../pkg3/I2.html\" title=\"interface in pkg3\">I2</A>"}, {BUG_ID + FS + "pkg3" + FS +"I1.html", "Methods inherited from interface pkg3." + "<A HREF=\"../pkg3/I3.html\" title=\"interface in pkg3\">I3</A>"}, diff --git a/test/com/sun/javadoc/testRelativeLinks/pkg/package.html b/test/com/sun/javadoc/testRelativeLinks/pkg/package.html index 4bda85c3d91a83bb5ad9c5b8b2b3bfb7d75c03fb..42d6dffee0bc9b8adba61ed02272cc970dba368d 100644 --- a/test/com/sun/javadoc/testRelativeLinks/pkg/package.html +++ b/test/com/sun/javadoc/testRelativeLinks/pkg/package.html @@ -1,6 +1,7 @@ -<html> - <body> - Here is a relative link in a package: - <a href="relative-package-link.html">relative package link</a>. - </body> -</html> \ No newline at end of file +<html> + <body> + Here is a relative link in a package: + <a href="relative-package-link.html">relative package link</a>. + </body> +</html> + diff --git a/test/com/sun/javadoc/testTaglets/TestTaglets.java b/test/com/sun/javadoc/testTaglets/TestTaglets.java index 9ea11e844c73fb672517a82045c1d70fd3d3bc77..99b07368eb445cdd643a305fbbdaf2999048a1ae 100644 --- a/test/com/sun/javadoc/testTaglets/TestTaglets.java +++ b/test/com/sun/javadoc/testTaglets/TestTaglets.java @@ -55,7 +55,7 @@ public class TestTaglets extends JavadocTester { //Input for string search tests. private static final String[][] TEST_4654308 = new String[][] { - {"4654308" + FS + "C.html", "<B>Foo:</B><DD>my only method is " + "<A HREF=\"C.html#method()\"><CODE>here</CODE></A>"} + {"4654308" + FS + "C.html", "<B>Foo:</B><DD>my only method is " + "<A HREF=\"C.html#method()\"><CODE>here</CODE></A>"} }; private static final String[][] NEGATED_TEST_4654308 = NO_TEST; diff --git a/test/com/sun/javadoc/testWarnings/pkg/package.html b/test/com/sun/javadoc/testWarnings/pkg/package.html index 015223b4830ed6615666f01082997b753b48a549..6fe786d606ad194d12cf6981426b908778c12041 100644 --- a/test/com/sun/javadoc/testWarnings/pkg/package.html +++ b/test/com/sun/javadoc/testWarnings/pkg/package.html @@ -1,3 +1,4 @@ -<HTML> - Testing. -<HTML> \ No newline at end of file +<HTML> + Testing. +<HTML> + diff --git a/test/tools/javah/SubClassConsts.win b/test/tools/javah/SubClassConsts.win index 67beec38354080ee411f7a924a931abbb7fc9dfe..4f8d56925a4eb2e09bfbf9fb0df276e14896f4e0 100644 --- a/test/tools/javah/SubClassConsts.win +++ b/test/tools/javah/SubClassConsts.win @@ -1,31 +1,31 @@ -/* DO NOT EDIT THIS FILE - it is machine generated */ -#include <jni.h> -/* Header for class SubClassConsts */ - -#ifndef _Included_SubClassConsts -#define _Included_SubClassConsts -#ifdef __cplusplus -extern "C" { -#endif -#undef SubClassConsts_serialVersionUID -#define SubClassConsts_serialVersionUID 6733861379283244755i64 -#undef SubClassConsts_SUPER_INT_CONSTANT -#define SubClassConsts_SUPER_INT_CONSTANT 3L -#undef SubClassConsts_SUPER_FLOAT_CONSTANT -#define SubClassConsts_SUPER_FLOAT_CONSTANT 99.3f -#undef SubClassConsts_SUPER_DOUBLE_CONSTANT -#define SubClassConsts_SUPER_DOUBLE_CONSTANT 33.2 -#undef SubClassConsts_SUPER_BOOLEAN_CONSTANT -#define SubClassConsts_SUPER_BOOLEAN_CONSTANT 0L -#undef SubClassConsts_SUB_INT_CONSTANT -#define SubClassConsts_SUB_INT_CONSTANT 2L -#undef SubClassConsts_SUB_DOUBLE_CONSTANT -#define SubClassConsts_SUB_DOUBLE_CONSTANT 2.25 -#undef SubClassConsts_SUB_FLOAT_CONSTANT -#define SubClassConsts_SUB_FLOAT_CONSTANT 7.9f -#undef SubClassConsts_SUB_BOOLEAN_CONSTANT -#define SubClassConsts_SUB_BOOLEAN_CONSTANT 1L -#ifdef __cplusplus -} -#endif -#endif +/* DO NOT EDIT THIS FILE - it is machine generated */ +#include <jni.h> +/* Header for class SubClassConsts */ + +#ifndef _Included_SubClassConsts +#define _Included_SubClassConsts +#ifdef __cplusplus +extern "C" { +#endif +#undef SubClassConsts_serialVersionUID +#define SubClassConsts_serialVersionUID 6733861379283244755i64 +#undef SubClassConsts_SUPER_INT_CONSTANT +#define SubClassConsts_SUPER_INT_CONSTANT 3L +#undef SubClassConsts_SUPER_FLOAT_CONSTANT +#define SubClassConsts_SUPER_FLOAT_CONSTANT 99.3f +#undef SubClassConsts_SUPER_DOUBLE_CONSTANT +#define SubClassConsts_SUPER_DOUBLE_CONSTANT 33.2 +#undef SubClassConsts_SUPER_BOOLEAN_CONSTANT +#define SubClassConsts_SUPER_BOOLEAN_CONSTANT 0L +#undef SubClassConsts_SUB_INT_CONSTANT +#define SubClassConsts_SUB_INT_CONSTANT 2L +#undef SubClassConsts_SUB_DOUBLE_CONSTANT +#define SubClassConsts_SUB_DOUBLE_CONSTANT 2.25 +#undef SubClassConsts_SUB_FLOAT_CONSTANT +#define SubClassConsts_SUB_FLOAT_CONSTANT 7.9f +#undef SubClassConsts_SUB_BOOLEAN_CONSTANT +#define SubClassConsts_SUB_BOOLEAN_CONSTANT 1L +#ifdef __cplusplus +} +#endif +#endif