From: <ls...@us...> - 2011-02-28 21:10:48
|
Revision: 5794 http://jnode.svn.sourceforge.net/jnode/?rev=5794&view=rev Author: lsantha Date: 2011-02-28 21:10:38 +0000 (Mon, 28 Feb 2011) Log Message: ----------- Integrating OpenJDK 6 b21. Modified Paths: -------------- classlib6/core/src/openjdk/langtools/com/sun/mirror/util/SourceOrderDeclScanner.java classlib6/core/src/openjdk/langtools/com/sun/source/util/TreePath.java classlib6/core/src/openjdk/langtools/com/sun/tools/apt/main/JavaCompiler.java classlib6/core/src/openjdk/langtools/com/sun/tools/apt/main/Main.java classlib6/core/src/openjdk/langtools/com/sun/tools/apt/mirror/util/SourcePositionImpl.java classlib6/core/src/openjdk/langtools/com/sun/tools/apt/resources/apt.properties classlib6/core/src/openjdk/langtools/com/sun/tools/apt/resources/apt_ja.properties classlib6/core/src/openjdk/langtools/com/sun/tools/apt/resources/apt_zh_CN.properties classlib6/core/src/openjdk/langtools/com/sun/tools/doclets/formats/html/markup/HtmlDocWriter.java classlib6/core/src/openjdk/langtools/com/sun/tools/doclets/internal/toolkit/util/MessageRetriever.java classlib6/core/src/openjdk/langtools/com/sun/tools/doclets/internal/toolkit/util/SourceToHTMLConverter.java classlib6/core/src/openjdk/langtools/com/sun/tools/doclets/internal/toolkit/util/Util.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/api/JavacScope.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/api/JavacTaskImpl.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/api/JavacTool.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/api/JavacTrees.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/api/WrappingJavaFileManager.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/code/Attribute.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/code/BoundKind.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/code/Flags.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/code/Kinds.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/code/Lint.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/code/Scope.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/code/Source.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/code/Symbol.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/code/Symtab.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/code/Type.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/code/TypeTags.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/code/Types.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/comp/Annotate.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/comp/Attr.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/comp/AttrContext.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/comp/AttrContextEnv.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/comp/Check.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/comp/ConstFold.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/comp/Enter.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/comp/Env.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/comp/Flow.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/comp/Infer.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/comp/Lower.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/comp/MemberEnter.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/comp/Resolve.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/comp/Todo.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/comp/TransTypes.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/jvm/ClassReader.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/jvm/ClassWriter.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/main/CommandLine.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/main/JavaCompiler.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/main/JavacOption.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/main/Main.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/main/OptionName.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/main/RecognizedOptions.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/parser/Scanner.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/processing/AnnotationProcessingError.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/processing/JavacFiler.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/processing/JavacMessager.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/processing/JavacProcessingEnvironment.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/processing/JavacRoundEnvironment.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/processing/PrintingProcessor.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/processing/ServiceProxy.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/resources/compiler.properties classlib6/core/src/openjdk/langtools/com/sun/tools/javac/resources/compiler_ja.properties classlib6/core/src/openjdk/langtools/com/sun/tools/javac/resources/compiler_zh_CN.properties classlib6/core/src/openjdk/langtools/com/sun/tools/javac/resources/javac.properties classlib6/core/src/openjdk/langtools/com/sun/tools/javac/resources/javac_ja.properties classlib6/core/src/openjdk/langtools/com/sun/tools/javac/resources/javac_zh_CN.properties classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/Abort.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/Bits.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/ByteBuffer.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/ClientCodeException.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/Constants.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/Context.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/Convert.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/DiagnosticFormatter.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/FatalError.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/JCDiagnostic.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/LayoutCharacters.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/List.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/ListBuffer.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/Log.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/MandatoryWarningHandler.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/Messages.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/Name.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/Options.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/Pair.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/Position.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/PropagatedException.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/Warner.java classlib6/core/src/openjdk/langtools/com/sun/tools/javadoc/ClassDocImpl.java classlib6/core/src/openjdk/langtools/com/sun/tools/javadoc/DocEnv.java classlib6/core/src/openjdk/langtools/com/sun/tools/javadoc/DocImpl.java classlib6/core/src/openjdk/langtools/com/sun/tools/javadoc/ExecutableMemberDocImpl.java classlib6/core/src/openjdk/langtools/com/sun/tools/javadoc/FieldDocImpl.java classlib6/core/src/openjdk/langtools/com/sun/tools/javadoc/JavadocClassReader.java classlib6/core/src/openjdk/langtools/com/sun/tools/javadoc/JavadocTodo.java classlib6/core/src/openjdk/langtools/com/sun/tools/javadoc/JavadocTool.java classlib6/core/src/openjdk/langtools/com/sun/tools/javadoc/PackageDocImpl.java classlib6/core/src/openjdk/langtools/com/sun/tools/javadoc/RootDocImpl.java classlib6/core/src/openjdk/langtools/com/sun/tools/javadoc/SourcePositionImpl.java classlib6/core/src/openjdk/langtools/com/sun/tools/javadoc/resources/javadoc.properties classlib6/core/src/openjdk/langtools/com/sun/tools/javadoc/resources/javadoc_ja.properties classlib6/core/src/openjdk/langtools/com/sun/tools/javadoc/resources/javadoc_zh_CN.properties Added Paths: ----------- classlib6/core/src/openjdk/langtools/com/sun/tools/javac/file/ classlib6/core/src/openjdk/langtools/com/sun/tools/javac/file/BaseFileObject.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/file/CacheFSInfo.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/file/FSInfo.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/file/JavacFileManager.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/file/Paths.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/file/RegularFileObject.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/file/RelativePath.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/file/SymbolArchive.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/file/ZipArchive.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/file/ZipFileIndex.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/file/ZipFileIndexArchive.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/BaseFileManager.java classlib6/core/src/openjdk/langtools/com/sun/tools/javac/util/CloseableURLClassLoader.java classlib6/core/src/openjdk/sun/sun/misc/IOUtils.java classlib6/core/src/openjdk/sun/sun/misc/JavaSecurityProtectionDomainAccess.java Modified: classlib6/core/src/openjdk/langtools/com/sun/mirror/util/SourceOrderDeclScanner.java =================================================================== --- classlib6/core/src/openjdk/langtools/com/sun/mirror/util/SourceOrderDeclScanner.java 2011-02-28 21:00:09 UTC (rev 5793) +++ classlib6/core/src/openjdk/langtools/com/sun/mirror/util/SourceOrderDeclScanner.java 2011-02-28 21:10:38 UTC (rev 5794) @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, 2005, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2010, Oracle and/or its affiliates. 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 Modified: classlib6/core/src/openjdk/langtools/com/sun/source/util/TreePath.java =================================================================== --- classlib6/core/src/openjdk/langtools/com/sun/source/util/TreePath.java 2011-02-28 21:00:09 UTC (rev 5793) +++ classlib6/core/src/openjdk/langtools/com/sun/source/util/TreePath.java 2011-02-28 21:10:38 UTC (rev 5794) @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2006, 2010, Oracle and/or its affiliates. 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 Modified: classlib6/core/src/openjdk/langtools/com/sun/tools/apt/main/JavaCompiler.java =================================================================== --- classlib6/core/src/openjdk/langtools/com/sun/tools/apt/main/JavaCompiler.java 2011-02-28 21:00:09 UTC (rev 5793) +++ classlib6/core/src/openjdk/langtools/com/sun/tools/apt/main/JavaCompiler.java 2011-02-28 21:10:38 UTC (rev 5794) @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2009, Oracle and/or its affiliates. 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 @@ -26,20 +26,14 @@ package com.sun.tools.apt.main; import java.io.*; -import java.nio.CharBuffer; -import java.util.Set; -import java.util.HashSet; import java.util.Map; -import java.util.HashMap; import javax.tools.JavaFileManager; import javax.tools.JavaFileObject; +import com.sun.tools.javac.file.JavacFileManager; import com.sun.tools.javac.util.*; import com.sun.tools.javac.code.*; -import com.sun.tools.javac.tree.*; -import com.sun.tools.javac.parser.*; -import com.sun.tools.javac.comp.*; import com.sun.tools.javac.jvm.*; import com.sun.tools.javac.code.Symbol.*; @@ -239,6 +233,7 @@ ListBuffer<ClassSymbol> classes = new ListBuffer<ClassSymbol>(); try { + JavacFileManager fm = (JavacFileManager)fileManager; //parse all files ListBuffer<JCCompilationUnit> trees = new ListBuffer<JCCompilationUnit>(); for (List<String> l = filenames; l.nonEmpty(); l = l.tail) { @@ -256,7 +251,8 @@ continue; } } - trees.append(parse(l.head)); + JavaFileObject fo = fm.getJavaFileObjectsFromStrings(List.of(l.head)).iterator().next(); + trees.append(parse(fo)); } //enter symbols for all files Modified: classlib6/core/src/openjdk/langtools/com/sun/tools/apt/main/Main.java =================================================================== --- classlib6/core/src/openjdk/langtools/com/sun/tools/apt/main/Main.java 2011-02-28 21:00:09 UTC (rev 5793) +++ classlib6/core/src/openjdk/langtools/com/sun/tools/apt/main/Main.java 2011-02-28 21:10:38 UTC (rev 5794) @@ -26,7 +26,6 @@ package com.sun.tools.apt.main; import java.io.File; -import java.io.FileOutputStream; import java.io.FileWriter; import java.io.IOException; import java.io.PrintWriter; @@ -37,14 +36,15 @@ import java.util.Map; import java.util.HashMap; import java.util.Collections; -import java.util.Collection; import java.net.URLClassLoader; import java.net.URL; -import java.io.File; import java.net.MalformedURLException; -import com.sun.tools.javac.util.Paths; +import javax.tools.JavaFileManager; +import javax.tools.StandardLocation; + +import com.sun.tools.javac.file.JavacFileManager; import com.sun.tools.javac.code.Source; import com.sun.tools.javac.code.Symbol; import com.sun.tools.javac.code.Type; @@ -56,6 +56,8 @@ import com.sun.tools.apt.util.Bark; import com.sun.mirror.apt.AnnotationProcessorFactory; +import static com.sun.tools.javac.file.Paths.pathToURLs; + /** This class provides a commandline interface to the apt build-time * tool. * @@ -766,6 +768,7 @@ providedFactory = factory; Context context = new Context(); + JavacFileManager.preRegister(context); options = Options.instance(context); Bark bark; @@ -779,7 +782,6 @@ // prefixed to command line arguments. processArgs(forcedOpts); - /* * A run of apt only gets passed the most recently generated * files; the initial run of apt gets passed the files from @@ -862,14 +864,14 @@ } origOptions = Collections.unmodifiableMap(origOptions); + JavacFileManager fm = (JavacFileManager) context.get(JavaFileManager.class); { // Note: it might be necessary to check for an empty // component ("") of the source path or class path - Paths paths = Paths.instance(context); String sourceDest = options.get("-s"); - if (paths.sourcePath() != null) { - for(File f: paths.sourcePath()) + if (fm.hasLocation(StandardLocation.SOURCE_PATH)) { + for(File f: fm.getLocation(StandardLocation.SOURCE_PATH)) augmentedSourcePath += (f + File.pathSeparator); augmentedSourcePath += (sourceDest == null)?".":sourceDest; } else { @@ -880,8 +882,8 @@ } String classDest = options.get("-d"); - if (paths.userClassPath() != null) { - for(File f: paths.userClassPath()) + if (fm.hasLocation(StandardLocation.CLASS_PATH)) { + for(File f: fm.getLocation(StandardLocation.CLASS_PATH)) baseClassPath += (f + File.pathSeparator); // put baseClassPath into map to handle any // value needed for the classloader @@ -908,9 +910,8 @@ * uses. */ String aptclasspath = ""; - Paths paths = Paths.instance(context); String bcp = ""; - Collection<File> bootclasspath = paths.bootClassPath(); + Iterable<? extends File> bootclasspath = fm.getLocation(StandardLocation.PLATFORM_CLASS_PATH); if (bootclasspath != null) { for(File f: bootclasspath) @@ -1271,59 +1272,4 @@ } } } - - // Borrowed from DocletInvoker - /** - * Utility method for converting a search path string to an array - * of directory and JAR file URLs. - * - * @param path the search path string - * @return the resulting array of directory and JAR file URLs - */ - static URL[] pathToURLs(String path) { - StringTokenizer st = new StringTokenizer(path, File.pathSeparator); - URL[] urls = new URL[st.countTokens()]; - int count = 0; - while (st.hasMoreTokens()) { - URL url = fileToURL(new File(st.nextToken())); - if (url != null) { - urls[count++] = url; - } - } - if (urls.length != count) { - URL[] tmp = new URL[count]; - System.arraycopy(urls, 0, tmp, 0, count); - urls = tmp; - } - return urls; - } - - /** - * Returns the directory or JAR file URL corresponding to the specified - * local file name. - * - * @param file the File object - * @return the resulting directory or JAR file URL, or null if unknown - */ - static URL fileToURL(File file) { - String name; - try { - name = file.getCanonicalPath(); - } catch (IOException e) { - name = file.getAbsolutePath(); - } - name = name.replace(File.separatorChar, '/'); - if (!name.startsWith("/")) { - name = "/" + name; - } - // If the file does not exist, then assume that it's a directory - if (!file.isFile()) { - name = name + "/"; - } - try { - return new URL("file", "", name); - } catch (MalformedURLException e) { - throw new IllegalArgumentException("file"); - } - } } Modified: classlib6/core/src/openjdk/langtools/com/sun/tools/apt/mirror/util/SourcePositionImpl.java =================================================================== --- classlib6/core/src/openjdk/langtools/com/sun/tools/apt/mirror/util/SourcePositionImpl.java 2011-02-28 21:00:09 UTC (rev 5793) +++ classlib6/core/src/openjdk/langtools/com/sun/tools/apt/mirror/util/SourcePositionImpl.java 2011-02-28 21:10:38 UTC (rev 5794) @@ -67,15 +67,15 @@ public String toString() { int ln = line(); return (ln == Position.NOPOS) - ? sourcefile.toString() - : sourcefile + ":" + ln; + ? sourcefile.getName() + : sourcefile.getName() + ":" + ln; } /** * {@inheritDoc} */ public File file() { - return new File(sourcefile.toString()); + return new File(sourcefile.toUri()); } /** Modified: classlib6/core/src/openjdk/langtools/com/sun/tools/apt/resources/apt.properties =================================================================== --- classlib6/core/src/openjdk/langtools/com/sun/tools/apt/resources/apt.properties 2011-02-28 21:00:09 UTC (rev 5793) +++ classlib6/core/src/openjdk/langtools/com/sun/tools/apt/resources/apt.properties 2011-02-28 21:10:38 UTC (rev 5794) @@ -1,12 +1,12 @@ # -# Copyright 2004-2006 Sun Microsystems, Inc. All Rights Reserved. +# Copyright (c) 2004, 2006, Oracle and/or its affiliates. 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 # under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. Sun designates this +# published by the Free Software Foundation. Oracle designates this # particular file as subject to the "Classpath" exception as provided -# by Sun in the LICENSE file that accompanied this code. +# by Oracle in the LICENSE file that accompanied this code. # # This code is distributed in the hope that it will be useful, but WITHOUT # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or @@ -18,9 +18,9 @@ # 2 along with this work; if not, write to the Free Software Foundation, # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. # -# Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, -# CA 95054 USA or visit www.sun.com if you need additional information or -# have any questions. +# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA +# or visit www.oracle.com if you need additional information or have any +# questions. # apt.msg.usage.header=\ Modified: classlib6/core/src/openjdk/langtools/com/sun/tools/apt/resources/apt_ja.properties =================================================================== --- classlib6/core/src/openjdk/langtools/com/sun/tools/apt/resources/apt_ja.properties 2011-02-28 21:00:09 UTC (rev 5793) +++ classlib6/core/src/openjdk/langtools/com/sun/tools/apt/resources/apt_ja.properties 2011-02-28 21:10:38 UTC (rev 5794) @@ -1,12 +1,12 @@ # -# Copyright 2004-2006 Sun Microsystems, Inc. All Rights Reserved. +# Copyright (c) 2004, 2006, Oracle and/or its affiliates. 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 # under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. Sun designates this +# published by the Free Software Foundation. Oracle designates this # particular file as subject to the "Classpath" exception as provided -# by Sun in the LICENSE file that accompanied this code. +# by Oracle in the LICENSE file that accompanied this code. # # This code is distributed in the hope that it will be useful, but WITHOUT # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or @@ -18,9 +18,9 @@ # 2 along with this work; if not, write to the Free Software Foundation, # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. # -# Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, -# CA 95054 USA or visit www.sun.com if you need additional information or -# have any questions. +# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA +# or visit www.oracle.com if you need additional information or have any +# questions. # apt.msg.usage.header=\ Modified: classlib6/core/src/openjdk/langtools/com/sun/tools/apt/resources/apt_zh_CN.properties =================================================================== --- classlib6/core/src/openjdk/langtools/com/sun/tools/apt/resources/apt_zh_CN.properties 2011-02-28 21:00:09 UTC (rev 5793) +++ classlib6/core/src/openjdk/langtools/com/sun/tools/apt/resources/apt_zh_CN.properties 2011-02-28 21:10:38 UTC (rev 5794) @@ -1,12 +1,12 @@ # -# Copyright 2005-2006 Sun Microsystems, Inc. All Rights Reserved. +# Copyright (c) 2005, 2006, Oracle and/or its affiliates. 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 # under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. Sun designates this +# published by the Free Software Foundation. Oracle designates this # particular file as subject to the "Classpath" exception as provided -# by Sun in the LICENSE file that accompanied this code. +# by Oracle in the LICENSE file that accompanied this code. # # This code is distributed in the hope that it will be useful, but WITHOUT # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or @@ -18,9 +18,9 @@ # 2 along with this work; if not, write to the Free Software Foundation, # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. # -# Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, -# CA 95054 USA or visit www.sun.com if you need additional information or -# have any questions. +# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA +# or visit www.oracle.com if you need additional information or have any +# questions. # apt.msg.usage.header=\ Modified: classlib6/core/src/openjdk/langtools/com/sun/tools/doclets/formats/html/markup/HtmlDocWriter.java =================================================================== --- classlib6/core/src/openjdk/langtools/com/sun/tools/doclets/formats/html/markup/HtmlDocWriter.java 2011-02-28 21:00:09 UTC (rev 5793) +++ classlib6/core/src/openjdk/langtools/com/sun/tools/doclets/formats/html/markup/HtmlDocWriter.java 2011-02-28 21:10:38 UTC (rev 5794) @@ -25,14 +25,13 @@ package com.sun.tools.doclets.formats.html.markup; -import com.sun.tools.doclets.internal.toolkit.*; - -import com.sun.javadoc.*; import java.io.*; import java.util.*; -import com.sun.tools.doclets.internal.toolkit.util.*; +import com.sun.javadoc.*; +import com.sun.tools.doclets.internal.toolkit.*; + /** * Class for the Html Format Code Generation specific to JavaDoc. * This Class contains methods related to the Html Code Generation which @@ -56,8 +55,9 @@ super(configuration, null, configuration.destDirName + filename, configuration.docencoding); + // use File to normalize file separators configuration.message.notice("doclet.Generating_0", - configuration.destDirName + filename); + new File(configuration.destDirName, filename)); } public HtmlDocWriter(Configuration configuration, @@ -65,10 +65,10 @@ super(configuration, configuration.destDirName + path, filename, configuration.docencoding); + // use File to normalize file separators configuration.message.notice("doclet.Generating_0", - configuration.destDirName + - ((path.length() > 0)? - path + File.separator: "") + filename); + new File(configuration.destDirName, + ((path.length() > 0)? path + File.separator: "") + filename)); } /** Modified: classlib6/core/src/openjdk/langtools/com/sun/tools/doclets/internal/toolkit/util/MessageRetriever.java =================================================================== --- classlib6/core/src/openjdk/langtools/com/sun/tools/doclets/internal/toolkit/util/MessageRetriever.java 2011-02-28 21:00:09 UTC (rev 5793) +++ classlib6/core/src/openjdk/langtools/com/sun/tools/doclets/internal/toolkit/util/MessageRetriever.java 2011-02-28 21:10:38 UTC (rev 5794) @@ -81,46 +81,14 @@ } /** - * get and format message string from resource - * - * @param key selects message from resource - */ - public String getText(String key) { - return getText(key, (String)null); - } - - /** * Get and format message string from resource * * @param key selects message from resource - * @param a1 Argument, to be repalced in the message. - */ - public String getText(String key, String a1) { - return getText(key, a1, null); - } - - /** - * Get and format message string from resource - * - * @param key selects message from resource - * @param a1 first argument to be replaced in the message. - * @param a2 second argument to be replaced in the message. - */ - public String getText(String key, String a1, String a2) { - return getText(key, a1, a2, null); - } - - /** - * Get and format message string from resource - * - * @param key selects message from resource - * @param a1 first argument to be replaced in the message. - * @param a2 second argument to be replaced in the message. - * @param a3 third argument to be replaced in the message. + * @param args arguments to be replaced in the message. * @throws MissingResourceException when the key does not * exist in the properties file. */ - public String getText(String key, String a1, String a2, String a3) throws MissingResourceException { + public String getText(String key, Object... args) throws MissingResourceException { if (messageRB == null) { try { messageRB = ResourceBundle.getBundle(resourcelocation); @@ -130,7 +98,7 @@ } } String message = messageRB.getString(key); - return MessageFormat.format(message, a1, a2, a3); + return MessageFormat.format(message, args); } /** @@ -195,261 +163,61 @@ * * @param pos the position of the source * @param key selects message from resource + * @param args arguments to be replaced in the message. */ - public void error(SourcePosition pos, String key) { - printError(pos, getText(key)); + public void error(SourcePosition pos, String key, Object... args) { + printError(pos, getText(key, args)); } /** * Print error message, increment error count. * * @param key selects message from resource + * @param args arguments to be replaced in the message. */ - public void error(String key) { - printError(getText(key)); + public void error(String key, Object... args) { + printError(getText(key, args)); } /** - * Print error message, increment error count. - * - * @param pos the position of the source - * @param key selects message from resource - * @param a1 first argument to be replaced in the message. - */ - public void error(SourcePosition pos, String key, String a1) { - printError(pos, getText(key, a1)); - } - - /** - * Print error message, increment error count. - * - * @param key selects message from resource - * @param a1 first argument to be replaced in the message. - */ - public void error(String key, String a1) { - printError(getText(key, a1)); - } - - /** - * Print error message, increment error count. - * - * @param pos the position of the source - * @param key selects message from resource - * @param a1 first argument to be replaced in the message. - * @param a2 second argument to be replaced in the message. - */ - public void error(SourcePosition pos, String key, String a1, String a2) { - printError(pos, getText(key, a1, a2)); - } - - /** - * Print error message, increment error count. - * - * @param key selects message from resource - * @param a1 first argument to be replaced in the message. - * @param a2 second argument to be replaced in the message. - */ - public void error(String key, String a1, String a2) { - printError(getText(key, a1, a2)); - } - - /** - * Print error message, increment error count. - * - * @param pos the position of the source - * @param key selects message from resource - * @param a1 first argument to be replaced in the message. - * @param a2 second argument to be replaced in the message. - * @param a3 third argument to be replaced in the message. - */ - public void error(SourcePosition pos, String key, String a1, String a2, String a3) { - printError(pos, getText(key, a1, a2, a3)); - } - - /** - * Print error message, increment error count. - * - * @param key selects message from resource - * @param a1 first argument to be replaced in the message. - * @param a2 second argument to be replaced in the message. - * @param a3 third argument to be replaced in the message. - */ - public void error(String key, String a1, String a2, String a3) { - printError(getText(key, a1, a2, a3)); - } - - /** * Print warning message, increment warning count. * * @param pos the position of the source * @param key selects message from resource + * @param args arguments to be replaced in the message. */ - public void warning(SourcePosition pos, String key) { - printWarning(pos, getText(key)); + public void warning(SourcePosition pos, String key, Object... args) { + printWarning(pos, getText(key, args)); } /** * Print warning message, increment warning count. * * @param key selects message from resource + * @param args arguments to be replaced in the message. */ - public void warning(String key) { - printWarning(getText(key)); + public void warning(String key, Object... args) { + printWarning(getText(key, args)); } /** - * Print warning message, increment warning count. - * - * @param pos the position of the source - * @param key selects message from resource - * @param a1 first argument to be replaced in the message. - */ - public void warning(SourcePosition pos, String key, String a1) { - printWarning(pos, getText(key, a1)); - } - - /** - * Print warning message, increment warning count. - * - * @param key selects message from resource - * @param a1 first argument to be replaced in the message. - */ - public void warning(String key, String a1) { - printWarning(getText(key, a1)); - } - - /** - * Print warning message, increment warning count. - * - * @param pos the position of the source - * @param key selects message from resource - * @param a1 first argument to be replaced in the message. - * @param a2 second argument to be replaced in the message. - */ - public void warning(SourcePosition pos, String key, String a1, String a2) { - printWarning(pos, getText(key, a1, a2)); - } - - /** - * Print warning message, increment warning count. - * - * @param key selects message from resource - * @param a1 first argument to be replaced in the message. - * @param a2 second argument to be replaced in the message. - */ - public void warning(String key, String a1, String a2) { - printWarning(getText(key, a1, a2)); - } - - /** - * Print warning message, increment warning count. - * - * @param pos the position of the source - * @param key selects message from resource - * @param a1 first argument to be replaced in the message. - * @param a2 second argument to be replaced in the message. - * @param a3 third argument to be replaced in the message. - */ - public void warning(SourcePosition pos, String key, String a1, String a2, String a3) { - printWarning(pos, getText(key, a1, a2, a3)); - } - - /** - * Print warning message, increment warning count. - * - * @param key selects message from resource - * @param a1 first argument to be replaced in the message. - * @param a2 second argument to be replaced in the message. - * @param a3 third argument to be replaced in the message. - */ - public void warning(String key, String a1, String a2, String a3) { - printWarning(getText(key, a1, a2, a3)); - } - - /** * Print a message. * * @param pos the position of the source * @param key selects message from resource + * @param args arguments to be replaced in the message. */ - public void notice(SourcePosition pos, String key) { - printNotice(pos, getText(key)); + public void notice(SourcePosition pos, String key, Object... args) { + printNotice(pos, getText(key, args)); } /** * Print a message. * * @param key selects message from resource + * @param args arguments to be replaced in the message. */ - public void notice(String key) { - printNotice(getText(key)); + public void notice(String key, Object... args) { + printNotice(getText(key, args)); } - - /** - * Print a message. - * @param pos the position of the source - * @param key selects message from resource - * @param a1 first argument to be replaced in the message. - */ - public void notice(SourcePosition pos, String key, String a1) { - printNotice(pos, getText(key, a1)); - } - - /** - * Print a message. - * - * @param key selects message from resource - * @param a1 first argument to be replaced in the message. - */ - public void notice(String key, String a1) { - printNotice(getText(key, a1)); - } - - /** - * Print a message. - * - * @param pos the position of the source - * @param key selects message from resource - * @param a1 first argument to be replaced in the message. - * @param a2 second argument to be replaced in the message. - */ - public void notice(SourcePosition pos, String key, String a1, String a2) { - printNotice(pos, getText(key, a1, a2)); - } - - /** - * Print a message. - * - * @param key selects message from resource - * @param a1 first argument to be replaced in the message. - * @param a2 second argument to be replaced in the message. - */ - public void notice(String key, String a1, String a2) { - printNotice(getText(key, a1, a2)); - } - - /** - * Print a message. - * - * @param pos the position of the source - * @param key selects message from resource - * @param a1 first argument to be replaced in the message. - * @param a2 second argument to be replaced in the message. - * @param a3 third argument to be replaced in the message. - */ - public void notice(SourcePosition pos, String key, String a1, String a2, String a3) { - printNotice(pos, getText(key, a1, a2, a3)); - } - - /** - * Print a message. - * - * @param key selects message from resource - * @param a1 first argument to be replaced in the message. - * @param a2 second argument to be replaced in the message. - * @param a3 third argument to be replaced in the message. - */ - public void notice(String key, String a1, String a2, String a3) { - printNotice(getText(key, a1, a2, a3)); - } } Modified: classlib6/core/src/openjdk/langtools/com/sun/tools/doclets/internal/toolkit/util/SourceToHTMLConverter.java =================================================================== --- classlib6/core/src/openjdk/langtools/com/sun/tools/doclets/internal/toolkit/util/SourceToHTMLConverter.java 2011-02-28 21:00:09 UTC (rev 5793) +++ classlib6/core/src/openjdk/langtools/com/sun/tools/doclets/internal/toolkit/util/SourceToHTMLConverter.java 2011-02-28 21:10:38 UTC (rev 5794) @@ -25,11 +25,13 @@ package com.sun.tools.doclets.internal.toolkit.util; -import com.sun.tools.doclets.internal.toolkit.*; -import com.sun.javadoc.*; import java.io.*; import java.util.*; +import javax.tools.FileObject; +import com.sun.javadoc.*; +import com.sun.tools.doclets.internal.toolkit.*; + /** * Converts Java Source Code to HTML. * @@ -123,16 +125,27 @@ if (cd == null || outputdir == null) { return; } - File file; + try { SourcePosition sp = cd.position(); - if (sp == null || (file = sp.file()) == null) { + if (sp == null) + return; + Reader r; + // temp hack until we can update SourcePosition API. + if (sp instanceof com.sun.tools.javadoc.SourcePositionImpl) { + FileObject fo = ((com.sun.tools.javadoc.SourcePositionImpl) sp).fileObject(); + if (fo == null) return; + r = fo.openReader(true); + } else { + File file = sp.file(); + if (file == null) + return; + r = new FileReader(file); } - try { + LineNumberReader reader = new LineNumberReader(r); int lineno = 1; String line; StringBuffer output = new StringBuffer(); - LineNumberReader reader = new LineNumberReader(new FileReader(file)); try { while ((line = reader.readLine()) != null) { output.append(formatLine(line, configuration.sourcetab, lineno)); @@ -260,12 +273,12 @@ * @param docs the array of <code>Doc</code>s to add anchors for. * @param hash the <code>HashMap</code> to add to. */ - protected static void addToHash(Doc[] docs, HashMap hash) { + protected static void addToHash(Doc[] docs, HashMap<Integer,String> hash) { if(docs == null) { return; } for(int i = 0; i < docs.length; i++) { - hash.put(new Integer(docs[i].position().line()), getAnchor(docs[i])); + hash.put(docs[i].position().line(), getAnchor(docs[i])); } } Modified: classlib6/core/src/openjdk/langtools/com/sun/tools/doclets/internal/toolkit/util/Util.java =================================================================== --- classlib6/core/src/openjdk/langtools/com/sun/tools/doclets/internal/toolkit/util/Util.java 2011-02-28 21:00:09 UTC (rev 5793) +++ classlib6/core/src/openjdk/langtools/com/sun/tools/doclets/internal/toolkit/util/Util.java 2011-02-28 21:10:38 UTC (rev 5794) @@ -25,10 +25,11 @@ package com.sun.tools.doclets.internal.toolkit.util; +import java.io.*; +import java.util.*; + import com.sun.javadoc.*; import com.sun.tools.doclets.internal.toolkit.*; -import java.util.*; -import java.io.*; /** * Utilities Class for Doclets. @@ -579,7 +580,7 @@ * @param docencoding Encoding to be used for this file. * @exception IOException Exception raised by the FileWriter is passed on * to next level. - * @exception UnSupportedEncodingException Exception raised by the + * @exception UnsupportedEncodingException Exception raised by the * OutputStreamWriter is passed on to next level. * @return Writer Writer for the file getting generated. * @see java.io.FileOutputStream @@ -598,9 +599,7 @@ fos = new FileOutputStream(filename); } if (docencoding == null) { - OutputStreamWriter oswriter = new OutputStreamWriter(fos); - docencoding = oswriter.getEncoding(); - return oswriter; + return new OutputStreamWriter(fos); } else { return new OutputStreamWriter(fos, docencoding); } Modified: classlib6/core/src/openjdk/langtools/com/sun/tools/javac/api/JavacScope.java =================================================================== --- classlib6/core/src/openjdk/langtools/com/sun/tools/javac/api/JavacScope.java 2011-02-28 21:00:09 UTC (rev 5793) +++ classlib6/core/src/openjdk/langtools/com/sun/tools/javac/api/JavacScope.java 2011-02-28 21:10:38 UTC (rev 5794) @@ -1,12 +1,12 @@ /* - * Copyright 2006 Sun Microsystems, Inc. All Rights Reserved. + * Copyright (c) 2006, Oracle and/or its affiliates. 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 * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. Sun designates this + * published by the Free Software Foundation. Oracle designates this * particular file as subject to the "Classpath" exception as provided - * by Sun in the LICENSE file that accompanied this code. + * by Oracle in the LICENSE file that accompanied this code. * * This code is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or @@ -18,9 +18,9 @@ * 2 along with this work; if not, write to the Free Software Foundation, * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. * - * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, - * CA 95054 USA or visit www.sun.com if you need additional information or - * have any questions. + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. */ package com.sun.tools.javac.api; @@ -65,7 +65,7 @@ /** * Provides an implementation of Scope. * - * <p><b>This is NOT part of any API supported by Sun Microsystems. + * <p><b>This is NOT part of any supported API. * If you write code that depends on this, you do so at your own * risk. This code and its internal interfaces are subject to change * or deletion without notice.</b></p> Modified: classlib6/core/src/openjdk/langtools/com/sun/tools/javac/api/JavacTaskImpl.java =================================================================== --- classlib6/core/src/openjdk/langtools/com/sun/tools/javac/api/JavacTaskImpl.java 2011-02-28 21:00:09 UTC (rev 5793) +++ classlib6/core/src/openjdk/langtools/com/sun/tools/javac/api/JavacTaskImpl.java 2011-02-28 21:10:38 UTC (rev 5794) @@ -1,5 +1,5 @@ /* - * Copyright (c) 2005, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2005, 2010, Oracle and/or its affiliates. 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 @@ -42,6 +42,7 @@ import com.sun.tools.javac.code.*; import com.sun.tools.javac.code.Symbol.*; import com.sun.tools.javac.comp.*; +import com.sun.tools.javac.file.JavacFileManager; import com.sun.tools.javac.main.*; import com.sun.tools.javac.model.*; import com.sun.tools.javac.parser.Parser; @@ -53,9 +54,9 @@ import com.sun.tools.javac.main.JavaCompiler; /** - * Provides access to functionality specific to the Sun Java Compiler, javac. + * Provides access to functionality specific to the JDK Java Compiler, javac. * - * <p><b>This is NOT part of any API supported by Sun Microsystems. + * <p><b>This is NOT part of any supported API. * If you write code that depends on this, you do so at your own * risk. This code and its internal interfaces are subject to change * or deletion without notice.</b></p> @@ -381,8 +382,8 @@ return results; } // where - private void handleFlowResults(List<Env<AttrContext>> list, ListBuffer<Element> elems) { - for (Env<AttrContext> env: list) { + private void handleFlowResults(Queue<Env<AttrContext>> queue, ListBuffer<Element> elems) { + for (Env<AttrContext> env: queue) { switch (env.tree.getTag()) { case JCTree.CLASSDEF: JCClassDecl cdef = (JCClassDecl) env.tree; @@ -396,7 +397,7 @@ break; } } - genList.appendList(list); + genList.addAll(queue); } @@ -424,13 +425,13 @@ analyze(null); // ensure all classes have been parsed, entered, and analyzed if (classes == null) { - compiler.generate(compiler.desugar(genList.toList()), results); + compiler.generate(compiler.desugar(genList), results); genList.clear(); } else { Filter f = new Filter() { public void process(Env<AttrContext> env) { - compiler.generate(compiler.desugar(List.of(env)), results); + compiler.generate(compiler.desugar(ListBuffer.of(env)), results); } }; f.run(genList, classes); @@ -472,30 +473,29 @@ } abstract class Filter { - void run(ListBuffer<Env<AttrContext>> list, Iterable<? extends TypeElement> classes) { + void run(Queue<Env<AttrContext>> list, Iterable<? extends TypeElement> classes) { Set<TypeElement> set = new HashSet<TypeElement>(); for (TypeElement item: classes) set.add(item); - List<Env<AttrContext>> defer = List.<Env<AttrContext>>nil(); - while (list.nonEmpty()) { - Env<AttrContext> env = list.next(); + ListBuffer<Env<AttrContext>> defer = ListBuffer.<Env<AttrContext>>lb(); + while (list.peek() != null) { + Env<AttrContext> env = list.remove(); ClassSymbol csym = env.enclClass.sym; if (csym != null && set.contains(csym.outermostClass())) process(env); else - defer = defer.prepend(env); + defer = defer.append(env); } - for (List<Env<AttrContext>> l = defer; l.nonEmpty(); l = l.tail) - list.prepend(l.head); + list.addAll(defer); } abstract void process(Env<AttrContext> env); } /** - * For internal use by Sun Microsystems only. This method will be + * For internal use only. This method will be * removed without warning. */ public Context getContext() { @@ -503,7 +503,7 @@ } /** - * For internal use by Sun Microsystems only. This method will be + * For internal use only. This method will be * removed without warning. */ public void updateContext(Context newContext) { @@ -511,7 +511,7 @@ } /** - * For internal use by Sun Microsystems only. This method will be + * For internal use only. This method will be * removed without warning. */ public Type parseType(String expr, TypeElement scope) { Modified: classlib6/core/src/openjdk/langtools/com/sun/tools/javac/api/JavacTool.java =================================================================== --- classlib6/core/src/openjdk/langtools/com/sun/tools/javac/api/JavacTool.java 2011-02-28 21:00:09 UTC (rev 5793) +++ classlib6/core/src/openjdk/langtools/com/sun/tools/javac/api/JavacTool.java 2011-02-28 21:10:38 UTC (rev 5794) @@ -31,7 +31,6 @@ import java.io.PrintWriter; import java.io.Writer; import java.util.ArrayList; -import java.util.Arrays; import java.util.Collections; import java.util.EnumSet; import java.util.Iterator; @@ -42,13 +41,13 @@ import javax.tools.*; import com.sun.source.util.JavacTask; +import com.sun.tools.javac.file.JavacFileManager; import com.sun.tools.javac.main.JavacOption.OptionKind; import com.sun.tools.javac.main.JavacOption; import com.sun.tools.javac.main.Main; import com.sun.tools.javac.main.RecognizedOptions.GrumpyHelper; import com.sun.tools.javac.main.RecognizedOptions; import com.sun.tools.javac.util.Context; -import com.sun.tools.javac.util.JavacFileManager; import com.sun.tools.javac.util.Log; import com.sun.tools.javac.util.Options; import com.sun.tools.javac.util.Pair; @@ -57,7 +56,7 @@ /** * TODO: describe com.sun.tools.javac.api.Tool * - * <p><b>This is NOT part of any API supported by Sun Microsystems. + * <p><b>This is NOT part of any supported API. * If you write code that depends on this, you do so at your own * risk. This code and its internal interfaces are subject to change * or deletion without notice.</b></p> Modified: classlib6/core/src/openjdk/langtools/com/sun/tools/javac/api/JavacTrees.java =================================================================== --- classlib6/core/src/openjdk/langtools/com/sun/tools/javac/api/JavacTrees.java 2011-02-28 21:00:09 UTC (rev 5793) +++ classlib6/core/src/openjdk/langtools/com/sun/tools/javac/api/JavacTrees.java 2011-02-28 21:10:38 UTC (rev 5794) @@ -68,7 +68,7 @@ /** * Provides an implementation of Trees. * - * <p><b>This is NOT part of any API supported by Sun Microsystems. + * <p><b>This is NOT part of any supported API. * If you write code that depends on this, you do so at your own * risk. This code and its internal interfaces are subject to change * or deletion without notice.</b></p> Modified: classlib6/core/src/openjdk/langtools/com/sun/tools/javac/api/WrappingJavaFileManager.java =================================================================== --- classlib6/core/src/openjdk/langtools/com/sun/tools/javac/api/WrappingJavaFileManager.java 2011-02-28 21:00:09 UTC (rev 5793) +++ classlib6/core/src/openjdk/langtools/com/sun/tools/javac/api/WrappingJavaFileManager.java 2011-02-28 21:10:38 UTC (rev 5794) @@ -1,12 +1,12 @@ /* - * Copyright 2006 Sun Microsystems, Inc. All Rights Reserved. + * Copyright (c) 2006, Oracle and/or its affiliates. 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 * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. Sun designates this + * published by the Free Software Foundation. Oracle designates this * particular file as subject to the "Classpath" exception as provided - * by Sun in the LICENSE file that accompanied this code. + * by Oracle in the LICENSE file that accompanied this code. * * This code is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or @@ -18,9 +18,9 @@ * 2 along with this work; if not, write to the Free Software Foundation, * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. * - * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, - * CA 95054 USA or visit www.sun.com if you need additional information or - * have any questions. + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. */ package com.sun.tools.javac.api; @@ -43,7 +43,7 @@ * <p>This class might be moved to {@link javax.tools} in a future * release. * - * <p><b>This is NOT part of any API supported by Sun Microsystems. + * <p><b>This is NOT part of any supported API. * If you write code that depends on this, you do so at your own * risk. This code and its internal interfaces are subject to change * or deletion without notice.</b></p> Modified: classlib6/core/src/openjdk/langtools/com/sun/tools/javac/code/Attribute.java =================================================================== --- classlib6/core/src/openjdk/langtools/com/sun/tools/javac/code/Attribute.java 2011-02-28 21:00:09 UTC (rev 5793) +++ classlib6/core/src/openjdk/langtools/com/sun/tools/javac/code/Attribute.java 2011-02-28 21:10:38 UTC (rev 5794) @@ -1,12 +1,12 @@ /* - * Copyright 2003-2005 Sun Microsystems, Inc. All Rights Reserved. + * Copyright (c) 2003, 2005, Oracle and/or its affiliates. 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 * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. Sun designates this + * published by the Free Software Foundation. Oracle designates this * particular file as subject to the "Classpath" exception as provided - * by Sun in the LICENSE file that accompanied this code. + * by Oracle in the LICENSE file that accompanied this code. * * This code is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or @@ -18,9 +18,9 @@ * 2 along with this work; if not, write to the Free Software Foundation, * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. * - * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, - * CA 95054 USA or visit www.sun.com if you need additional information or - * have any questions. + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. */ package com.sun.tools.javac.code; @@ -39,8 +39,8 @@ /** An annotation value. * - * <p><b>This is NOT part of any API supported by Sun Microsystems. If - * you write code that depends on this, you do so at your own risk. + * <p><b>This is NOT part of any supported API. + * If you write code that depends on this, you do so at your own risk. * This code and its internal interfaces are subject to change or * deletion without notice.</b> */ Modified: classlib6/core/src/openjdk/langtools/com/sun/tools/javac/code/BoundKind.java =================================================================== --- classlib6/core/src/openjdk/langtools/com/sun/tools/javac/code/BoundKind.java 2011-02-28 21:00:09 UTC (rev 5793) +++ classlib6/core/src/openjdk/langtools/com/sun/tools/javac/code/BoundKind.java 2011-02-28 21:10:38 UTC (rev 5794) @@ -1,12 +1,12 @@ /* - * Copyright 2003-2005 Sun Microsystems, Inc. All Rights Reserved. + * Copyright (c) 2003, 2005, Oracle and/or its affiliates. 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 * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. Sun designates this + * published by the Free Software Foundation. Oracle designates this * particular file as subject to the "Classpath" exception as provided - * by Sun in the LICENSE file that accompanied this code. + * by Oracle in the LICENSE file that accompanied this code. * * This code is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or @@ -18,9 +18,9 @@ * 2 along with this work; if not, write to the Free Software Foundation, * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. * - * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, - * CA 95054 USA or visit www.sun.com if you need additional information or - * have any questions. + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. */ package com.sun.tools.javac.code; Modified: classlib6/core/src/openjdk/langtools/com/sun/tools/javac/code/Flags.java =================================================================== --- classlib6/core/src/openjdk/langtools/com/sun/tools/javac/code/Flags.java 2011-02-28 21:00:09 UTC (rev 5793) +++ classlib6/core/src/openjdk/langtools/com/sun/tools/javac/code/Flags.java 2011-02-28 21:10:38 UTC (rev 5794) @@ -1,12 +1,12 @@ /* - * Copyright 1999-2006 Sun Microsystems, Inc. All Rights Reserved. + * Copyright (c) 1999, 2006, Oracle and/or its affiliates. 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 * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. Sun designates this + * published by the Free Software Foundation. Oracle designates this * particular file as subject to the "Classpath" exception as provided - * by Sun in the LICENSE file that accompanied this code. + * by Oracle in the LICENSE file that accompanied this code. * * This code is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or @@ -18,9 +18,9 @@ * 2 along with this work; if not, write to the Free Software Foundation, * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. * - * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, - * CA 95054 USA or visit www.sun.com if you need additional information or - * have any questions. + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit ... [truncated message content] |