--- old/make/Makefile-classic 2012-01-19 16:21:04.000000000 -0800
+++ new/make/Makefile-classic 2012-01-19 16:21:04.000000000 -0800
@@ -1,5 +1,5 @@
#
-# Copyright (c) 2007, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2007, 2012 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
@@ -115,7 +115,6 @@
JAVADOC_JAR = $(LIB_DIR)/javadoc.jar
JAVAH_JAR = $(LIB_DIR)/javah.jar
JAVAP_JAR = $(LIB_DIR)/javap.jar
-APT_JAR = $(LIB_DIR)/apt.jar
CLASSES_JAR = $(DIST_DIR)/classes.jar
SRC_ZIP = $(DIST_DIR)/src.zip
@@ -163,7 +162,7 @@
#----- useful macros
-TOOLS = javac javadoc javah javap apt
+TOOLS = javac javadoc javah javap
SOURCE_LEVEL = 5
BOOTSTRAP_TARGET_LEVEL = 5
@@ -319,28 +318,6 @@
( $(ECHO) Main-Class: sun.tools.javap.Main ) > $(BUILD_DIR)/javap.mf
$(BOOTJAR) -cfm $@ $(BUILD_DIR)/javap.mf $(patsubst %,-C $(CLASSES_DIR) %, $(JAVAP_DIRS))
-#----- apt
-
-APT_DIRS = \
- com/sun/mirror \
- com/sun/tools/apt
-
-APT_RESOURCE_FILES = \
- $(shell find $(patsubst %,$(SRC_CLASSES_DIR)/%,$(APT_DIRS)) -name SCCS -prune -o -name \*.properties -print )
-
-APT_JAVA_FILES = \
- $(shell find $(patsubst %,$(SRC_CLASSES_DIR)/%,$(APT_DIRS)) -name SCCS -prune -o -name \*.java -print ) \
- $(patsubst $(SRC_CLASSES_DIR)/%.properties,$(GENSRC_DIR)/%.java,$(APT_RESOURCE_FILES))
-
-$(APT_JAR): $(APT_JAVA_FILES) $(JAVAC_JAR) \
- $(patsubst $(SRC_CLASSES_DIR)/%.properties,$(GENSRC_DIR)/%.java,$(APT_RESOURCE_FILES))
- $(MKDIR) -p $(CLASSES_DIR) $(@D)
- $(BOOT_JAVAC) -sourcepath "" -classpath $(CLASSES_DIR) -d $(CLASSES_DIR) -target $(TARGET_LEVEL) $(NO_PROPRIETARY_API_WARNINGS) \
- $(APT_JAVA_FILES) \
- $(patsubst $(SRC_CLASSES_DIR)/%.properties,$(GENSRC_DIR)/%.java,$(APT_RESOURCE_FILES))
- ( $(ECHO) Main-Class: com.sun.tools.apt.Main ; $(ECHO) Class-Path: javac.jar ) > $(BUILD_DIR)/apt.mf
- $(BOOTJAR) -cfm $@ $(BUILD_DIR)/apt.mf $(patsubst %,-C $(CLASSES_DIR) %, $(APT_DIRS))
-
#-----
build-tools: $(BUILDTOOLCLASSES_DIR)/CompileProperties/CompileProperties.class
@@ -366,7 +343,7 @@
#----- all classes
-$(DIST_DIR)/%/classes.jar: $(JAVAC_JAR) $(JAVADOC_JAR) $(JAVAH_JAR) $(JAVAP_JAR) $(APT_JAR)
+$(DIST_DIR)/%/classes.jar: $(JAVAC_JAR) $(JAVADOC_JAR) $(JAVAH_JAR) $(JAVAP_JAR)
$(MKDIR) -p $(@D)
$(BOOTJAR) -cf $@ -C $(CLASSES_DIR) .
@@ -401,7 +378,6 @@
- $(TESTJAVA) -jar $(JAVADOC_JAR) -version
$(TESTJAVA) -jar $(JAVAH_JAR) -version
- $(TESTJAVA) -jar $(JAVAP_JAR) -version
- $(TESTJAVA) -jar $(APT_JAR) -version
#-----
--- old/make/build.properties 2012-01-19 16:21:05.000000000 -0800
+++ new/make/build.properties 2012-01-19 16:21:05.000000000 -0800
@@ -1,5 +1,5 @@
#
-# Copyright (c) 2007, 2010, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2007, 2012, 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
@@ -159,15 +159,6 @@
#
-apt.includes = \
- com/sun/mirror/ \
- com/sun/tools/apt/
-
-apt.tests = \
- tools/apt/
-
-#
-
# The following files require the latest JDK to be available.
# The API can be provided by using a suitable boot.java.home
# or by setting import.jdk
--- old/make/build.xml 2012-01-19 16:21:05.000000000 -0800
+++ new/make/build.xml 2012-01-19 16:21:05.000000000 -0800
@@ -83,7 +83,7 @@
- global property definitions
- general top level targets
- general diagnostic/debugging targets
- - groups of targets for each tool: javac, javadoc, doclets, javah, javap, apt
+ - groups of targets for each tool: javac, javadoc, doclets, javah, javap
Within each group, the following targets are provided, where applicable
build-bootstrap-TOOL build the bootstrap version of the tool
build-classes-TOOL build the classes for the tool
@@ -245,11 +245,11 @@
/>
An annotation processor is constructed by a - * {@linkplain AnnotationProcessorFactory factory}, which provides it with an - * {@linkplain AnnotationProcessorEnvironment environment} that - * encapsulates the state it needs. - * Messages regarding warnings and errors encountered during processing - * should be directed to the environment's {@link Messager}, - * and new files may be created using the environment's {@link Filer}. - * - *
Each annotation processor is created to process annotations - * of a particular annotation type or set of annotation types. - * It may use its environment to find the program elements with - * annotations of those types. It may freely examine any other program - * elements in the course of its processing. - * - * @deprecated All components of this API have been superseded by the - * standardized annotation processing API. The replacement for the - * functionality of this interface is {@link - * javax.annotation.processing.Processor}. - * - * @author Joseph D. Darcy - * @author Scott Seligman - * @since 1.5 - */ -@Deprecated -@SuppressWarnings("deprecation") -public interface AnnotationProcessor { - - /** - * Process all program elements supported by this annotation processor. - */ - void process(); -} --- old/src/share/classes/com/sun/mirror/apt/AnnotationProcessorEnvironment.java 2012-01-19 16:21:08.000000000 -0800 +++ /dev/null 2012-01-10 11:47:00.807870926 -0800 @@ -1,182 +0,0 @@ -/* - * Copyright (c) 2004, 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. Oracle designates this - * particular file as subject to the "Classpath" exception as provided - * 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 - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 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 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.mirror.apt; - - -import java.util.Collection; -import java.util.Map; - -import com.sun.mirror.declaration.*; -import com.sun.mirror.util.*; - - -/** - * The environment encapsulating the state needed by an annotation processor. - * An annotation processing tool makes this environment available - * to all annotation processors. - * - *
When an annotation processing tool is invoked, it is given a - * set of type declarations on which to operate. These - * are refered to as the specified types. - * The type declarations said to be included in this invocation - * consist of the specified types and any types nested within them. - * - *
{@link DeclarationFilter} - * provides a simple way to select just the items of interest - * when a method returns a collection of declarations. - * - * @deprecated All components of this API have been superseded by the - * standardized annotation processing API. The replacement for the - * functionality of this interface is {@link - * javax.annotation.processing.ProcessingEnvironment}. - * - * @author Joseph D. Darcy - * @author Scott Seligman - * @since 1.5 - */ -@Deprecated -@SuppressWarnings("deprecation") -public interface AnnotationProcessorEnvironment { - - /** - * Returns the options passed to the annotation processing tool. - * Options are returned in the form of a map from option name - * (such as "-encoding") to option value. - * For an option with no value (such as "-help"), the - * corresponding value in the map is null. - * - *
Options beginning with "-A" are processor-specific.
- * Such options are unrecognized by the tool, but intended to be used by
- * some annotation processor.
- *
- * @return the options passed to the tool
- */
- Map Each implementation of an AnnotationProcessorFactory
- * must provide a public no-argument constructor to be used by tools to
- * instantiate the factory.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is {@link
- * javax.annotation.processing.Processor}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface AnnotationProcessorFactory {
-
- /**
- * Returns the options recognized by this factory or by any of the
- * processors it may create.
- * Only {@linkplain AnnotationProcessorEnvironment#getOptions()
- * processor-specific} options are included, each of which begins
- * with "-A". For example, if this factory recognizes
- * options such as -Adebug -Aloglevel=3, it will
- * return the strings "-Adebug" and "-Aloglevel".
- *
- * A tool might use this information to determine if any
- * options provided by a user are unrecognized by any processor,
- * in which case it may wish to report an error.
- *
- * @return the options recognized by this factory or by any of the
- * processors it may create, or an empty collection if none
- */
- Collection There are two distinguished locations (subtrees within the
- * file system) where newly created files are placed:
- * one for new source files, and one for new class files.
- * (These might be specified on a tool's command line, for example,
- * using flags such as -s and -d.)
- * Auxiliary files may be created in either location.
- *
- * During each run of an annotation processing tool, a file
- * with a given pathname may be created only once. If that file already
- * exists before the first attempt to create it, the old contents will
- * be deleted. Any subsequent attempt to create the same file during
- * a run will fail.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is {@link
- * javax.annotation.processing.Filer}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface Filer {
-
- /**
- * Creates a new source file and returns a writer for it.
- * The file's name and path (relative to the root of all newly created
- * source files) is based on the type to be declared in that file.
- * If more than one type is being declared, the name of the principal
- * top-level type (the public one, for example) should be used.
- *
- * The {@linkplain java.nio.charset.Charset charset} used to
- * encode the file is determined by the implementation.
- * An annotation processing tool may have an -encoding
- * flag or the like for specifying this. It will typically use
- * the platform's default encoding if none is specified.
- *
- * @param name canonical (fully qualified) name of the principal type
- * being declared in this file
- * @return a writer for the new file
- * @throws IOException if the file cannot be created
- */
- PrintWriter createSourceFile(String name) throws IOException;
-
- /**
- * Creates a new class file, and returns a stream for writing to it.
- * The file's name and path (relative to the root of all newly created
- * class files) is based on the name of the type being written.
- *
- * @param name canonical (fully qualified) name of the type being written
- * @return a stream for writing to the new file
- * @throws IOException if the file cannot be created
- */
- OutputStream createClassFile(String name) throws IOException;
-
- /**
- * Creates a new text file, and returns a writer for it.
- * The file is located along with either the
- * newly created source or newly created binary files. It may be
- * named relative to some package (as are source and binary files),
- * and from there by an arbitrary pathname. In a loose sense, the
- * pathname of the new file will be the concatenation of
- * loc, pkg, and relPath.
- *
- * A {@linkplain java.nio.charset.Charset charset} for
- * encoding the file may be provided. If none is given, the
- * charset used to encode source files
- * (see {@link #createSourceFile(String)}) will be used.
- *
- * @param loc location of the new file
- * @param pkg package relative to which the file should be named,
- * or the empty string if none
- * @param relPath final pathname components of the file
- * @param charsetName the name of the charset to use, or null if none
- * is being explicitly specified
- * @return a writer for the new file
- * @throws IOException if the file cannot be created
- */
- PrintWriter createTextFile(Location loc,
- String pkg,
- File relPath,
- String charsetName) throws IOException;
-
- /**
- * Creates a new binary file, and returns a stream for writing to it.
- * The file is located along with either the
- * newly created source or newly created binary files. It may be
- * named relative to some package (as are source and binary files),
- * and from there by an arbitrary pathname. In a loose sense, the
- * pathname of the new file will be the concatenation of
- * loc, pkg, and relPath.
- *
- * @param loc location of the new file
- * @param pkg package relative to which the file should be named,
- * or the empty string if none
- * @param relPath final pathname components of the file
- * @return a stream for writing to the new file
- * @throws IOException if the file cannot be created
- */
- OutputStream createBinaryFile(Location loc,
- String pkg,
- File relPath) throws IOException;
-
-
- /**
- * Locations (subtrees within the file system) where new files are created.
- *
- * @deprecated All components of this API have been superseded by
- * the standardized annotation processing API. The replacement
- * for the functionality of this enum is {@link
- * javax.tools.StandardLocation}.
- */
- @Deprecated
- enum Location {
- /** The location of new source files. */
- SOURCE_TREE,
- /** The location of new class files. */
- CLASS_TREE
- }
-}
--- old/src/share/classes/com/sun/mirror/apt/Messager.java 2012-01-19 16:21:09.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,92 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.apt;
-
-import com.sun.mirror.util.SourcePosition;
-
-/**
- * A Messager provides the way for
- * an annotation processor to report error messages, warnings, and
- * other notices.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is {@link
- * javax.annotation.processing.Messager}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface Messager {
-
- /**
- * Prints an error message.
- * Equivalent to printError(null, msg).
- * @param msg the message, or an empty string if none
- */
- void printError(String msg);
-
- /**
- * Prints an error message.
- * @param pos the position where the error occured, or null if it is
- * unknown or not applicable
- * @param msg the message, or an empty string if none
- */
- void printError(SourcePosition pos, String msg);
-
- /**
- * Prints a warning message.
- * Equivalent to printWarning(null, msg).
- * @param msg the message, or an empty string if none
- */
- void printWarning(String msg);
-
- /**
- * Prints a warning message.
- * @param pos the position where the warning occured, or null if it is
- * unknown or not applicable
- * @param msg the message, or an empty string if none
- */
- void printWarning(SourcePosition pos, String msg);
-
- /**
- * Prints a notice.
- * Equivalent to printNotice(null, msg).
- * @param msg the message, or an empty string if none
- */
- void printNotice(String msg);
-
- /**
- * Prints a notice.
- * @param pos the position where the noticed occured, or null if it is
- * unknown or not applicable
- * @param msg the message, or an empty string if none
- */
- void printNotice(SourcePosition pos, String msg);
-}
--- old/src/share/classes/com/sun/mirror/apt/RoundCompleteEvent.java 2012-01-19 16:21:09.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,75 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.apt;
-
-/**
- * Event for the completion of a round of annotation processing.
- *
- * While this class extends the serializable EventObject, it
- * cannot meaningfully be serialized because all of the annotation
- * processing tool's internal state would potentially be needed.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. This class has no direct
- * analog in the standardized API because the different round model
- * renders it unnecessary.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public abstract class RoundCompleteEvent extends java.util.EventObject {
- private RoundState rs;
-
- /**
- * The current AnnotationProcessorEnvironment is regarded
- * as the source of events.
- *
- * @param source The source of events
- * @param rs The state of the round
- */
- protected RoundCompleteEvent(AnnotationProcessorEnvironment source,
- RoundState rs) {
- super(source);
- this.rs = rs;
- }
-
- /**
- * Return round state.
- */
- public RoundState getRoundState() {
- return rs;
- }
-
- /**
- * Return source.
- */
- public AnnotationProcessorEnvironment getSource() {
- return (AnnotationProcessorEnvironment)super.getSource();
- }
-}
--- old/src/share/classes/com/sun/mirror/apt/RoundCompleteListener.java 2012-01-19 16:21:09.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,49 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.apt;
-
-/**
- * Listener for the completion of a round of annotation processing.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. This interface has no
- * direct analog in the standardized API because the different round
- * model renders it unnecessary.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface RoundCompleteListener extends AnnotationProcessorListener {
- /**
- * Invoked after all processors for a round have run to completion.
- *
- * @param event An event for round completion
- */
- void roundComplete(RoundCompleteEvent event);
-}
--- old/src/share/classes/com/sun/mirror/apt/RoundState.java 2012-01-19 16:21:09.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,66 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.apt;
-
-/**
- * Represents the status of a completed round of annotation processing.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is {@link
- * javax.annotation.processing.RoundEnvironment}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface RoundState {
- /**
- * Returns true if this was the last round of annotation
- * processing; returns false if there will be a subsequent round.
- */
- boolean finalRound();
-
- /**
- * Returns true if an error was raised in this round of processing;
- * returns false otherwise.
- */
- boolean errorRaised();
-
- /**
- * Returns true if new source files were created in this round of
- * processing; returns false otherwise.
- */
- boolean sourceFilesCreated();
-
- /**
- * Returns true if new class files were created in this round of
- * processing; returns false otherwise.
- */
- boolean classFilesCreated();
-}
--- old/src/share/classes/com/sun/mirror/apt/package-info.java 2012-01-19 16:21:09.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,38 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-/**
- * Classes used to communicate information between {@linkplain
- * com.sun.mirror.apt.AnnotationProcessor annotation processors} and
- * an annotation processing tool.
- *
- * The {@code apt} tool and its associated API have been superseded
- * by the standardized annotation processing API. The replacement for
- * the functionality in this package is {@link
- * javax.annotation.processing}.
- *
- * @since 1.5
- */
-package com.sun.mirror.apt;
--- old/src/share/classes/com/sun/mirror/declaration/AnnotationMirror.java 2012-01-19 16:21:10.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,87 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.declaration;
-
-import java.util.Map;
-import com.sun.mirror.type.AnnotationType;
-import com.sun.mirror.util.SourcePosition;
-
-
-/**
- * Represents an annotation. An annotation associates a value with
- * each element of an annotation type.
- *
- * Annotations should not be compared using reference-equality
- * ("=="). There is no guarantee that any particular
- * annotation will always be represented by the same object.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is {@link
- * javax.lang.model.element.AnnotationMirror}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface AnnotationMirror {
-
- /**
- * Returns the annotation type of this annotation.
- *
- * @return the annotation type of this annotation
- */
- AnnotationType getAnnotationType();
-
- /**
- * Returns the source position of the beginning of this annotation.
- * Returns null if the position is unknown or not applicable.
- *
- * This source position is intended for use in providing diagnostics,
- * and indicates only approximately where an annotation begins.
- *
- * @return the source position of the beginning of this annotation or
- * null if the position is unknown or not applicable
- */
- SourcePosition getPosition();
-
- /**
- * Returns this annotation's elements and their values.
- * This is returned in the form of a map that associates elements
- * with their corresponding values.
- * Only those elements and values explicitly present in the
- * annotation are included, not those that are implicitly assuming
- * their default values.
- * The order of the map matches the order in which the
- * elements appear in the annotation's source.
- *
- * @return this annotation's elements and their values,
- * or an empty map if there are none
- */
- Map This source position is intended for use in providing diagnostics,
- * and indicates only approximately where an annotation value begins.
- *
- * @return the source position of the beginning of this annotation value or
- * null if the position is unknown or not applicable
- */
- SourcePosition getPosition();
-
- /**
- * Returns a string representation of this value.
- * This is returned in a form suitable for representing this value
- * in the source code of an annotation.
- *
- * @return a string representation of this value
- */
- String toString();
-}
--- old/src/share/classes/com/sun/mirror/declaration/ClassDeclaration.java 2012-01-19 16:21:10.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,89 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.declaration;
-
-
-import java.util.Collection;
-
-import com.sun.mirror.type.ClassType;
-
-
-/**
- * Represents the declaration of a class.
- * For the declaration of an interface, see {@link InterfaceDeclaration}.
- * Provides access to information about the class, its members, and
- * its constructors.
- * Note that an {@linkplain EnumDeclaration enum} is a kind of class.
- *
- * While a ClassDeclaration represents the declaration
- * of a class, a {@link ClassType} represents a class type.
- * See {@link TypeDeclaration} for more on this distinction.
- *
- * {@link com.sun.mirror.util.DeclarationFilter}
- * provides a simple way to select just the items of interest
- * when a method returns a collection of declarations.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is included in {@link
- * javax.lang.model.element.TypeElement}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- *
- * @see ClassType
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface ClassDeclaration extends TypeDeclaration {
-
- /**
- * Returns the class type directly extended by this class.
- * The only class with no superclass is java.lang.Object,
- * for which this method returns null.
- *
- * @return the class type directly extended by this class, or null
- * if there is none
- */
- ClassType getSuperclass();
-
- /**
- * Returns the constructors of this class.
- * This includes the default constructor if this class has
- * no constructors explicitly declared.
- *
- * @return the constructors of this class
- *
- * @see com.sun.mirror.util.DeclarationFilter
- */
- Collection Declarations should be compared using the {@link #equals(Object)}
- * method. There is no guarantee that any particular declaration will
- * always be represented by the same object.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is {@link
- * javax.lang.model.element.Element}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- *
- * @see Declarations
- * @see TypeMirror
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface Declaration {
-
- /**
- * Tests whether an object represents the same declaration as this.
- *
- * @param obj the object to be compared with this declaration
- * @return true if the specified object represents the same
- * declaration as this
- */
- boolean equals(Object obj);
-
- /**
- * Returns the text of the documentation ("javadoc") comment of
- * this declaration.
- *
- * @return the documentation comment of this declaration, or null
- * if there is none
- */
- String getDocComment();
-
- /**
- * Returns the annotations that are directly present on this declaration.
- *
- * @return the annotations directly present on this declaration;
- * an empty collection if there are none
- */
- Collection The annotation returned by this method could contain an element
- * whose value is of type Class.
- * This value cannot be returned directly: information necessary to
- * locate and load a class (such as the class loader to use) is
- * not available, and the class might not be loadable at all.
- * Attempting to read a Class object by invoking the relevant
- * method on the returned annotation
- * will result in a {@link MirroredTypeException},
- * from which the corresponding {@link TypeMirror} may be extracted.
- * Similarly, attempting to read a Class[]-valued element
- * will result in a {@link MirroredTypesException}.
- *
- * This source position is intended for use in providing
- * diagnostics, and indicates only approximately where a declaration
- * begins.
- *
- * @return the source position of the beginning of this declaration,
- * or null if the position is unknown or not applicable
- */
- SourcePosition getPosition();
-
- /**
- * Applies a visitor to this declaration.
- *
- * @param v the visitor operating on this declaration
- */
- void accept(DeclarationVisitor v);
-}
--- old/src/share/classes/com/sun/mirror/declaration/EnumConstantDeclaration.java 2012-01-19 16:21:11.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,48 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.declaration;
-
-
-/**
- * Represents an enum constant declaration.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is included in {@link
- * javax.lang.model.element.VariableElement}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface EnumConstantDeclaration extends FieldDeclaration {
- /**
- * {@inheritDoc}
- */
- EnumDeclaration getDeclaringType();
-}
--- old/src/share/classes/com/sun/mirror/declaration/EnumDeclaration.java 2012-01-19 16:21:11.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,55 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.declaration;
-
-
-import java.util.Collection;
-
-
-/**
- * Represents the declaration of an enum type.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is included in {@link
- * javax.lang.model.element.TypeElement}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface EnumDeclaration extends ClassDeclaration {
-
- /**
- * Returns the enum constants defined for this enum.
- *
- * @return the enum constants defined for this enum,
- * or an empty collection if there are none
- */
- Collection While an InterfaceDeclaration represents the
- * declaration of an interface, an {@link InterfaceType}
- * represents an interface type.
- * See {@link TypeDeclaration} for more on this distinction.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is included in {@link
- * javax.lang.model.element.TypeElement}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- *
- * @see InterfaceType
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface InterfaceDeclaration extends TypeDeclaration {
-}
--- old/src/share/classes/com/sun/mirror/declaration/MemberDeclaration.java 2012-01-19 16:21:12.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,57 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.declaration;
-
-
-/**
- * Represents a declaration that may be a member or constructor of a declared
- * type. This includes fields, constructors, methods, and (since they
- * may be nested) declared types themselves.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is {@link
- * javax.lang.model.element.Element}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface MemberDeclaration extends Declaration {
-
- /**
- * Returns the type declaration within which this member or constructor
- * is declared.
- * If this is the declaration of a top-level type (a non-nested class
- * or interface), returns null.
- *
- * @return the type declaration within which this member or constructor
- * is declared, or null if there is none
- */
- TypeDeclaration getDeclaringType();
-}
--- old/src/share/classes/com/sun/mirror/declaration/MethodDeclaration.java 2012-01-19 16:21:13.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,59 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.declaration;
-
-
-import com.sun.mirror.type.TypeMirror;
-import com.sun.mirror.type.VoidType;
-
-
-/**
- * Represents a method of a class or interface.
- * Note that an
- * {@linkplain AnnotationTypeElementDeclaration annotation type element}
- * is a kind of method.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is included in {@link
- * javax.lang.model.element.ExecutableElement}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface MethodDeclaration extends ExecutableDeclaration {
-
- /**
- * Returns the formal return type of this method.
- * Returns {@link VoidType} if this method does not return a value.
- *
- * @return the formal return type of this method
- */
- TypeMirror getReturnType();
-}
--- old/src/share/classes/com/sun/mirror/declaration/Modifier.java 2012-01-19 16:21:13.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,77 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.declaration;
-
-
-/**
- * Represents a modifier on the declaration of a program element such
- * as a class, method, or field.
- *
- * Not all modifiers are applicable to all kinds of declarations.
- * When two or more modifiers appear in the source code of a declaration,
- * then it is customary, though not required, that they appear in the same
- * order as the constants listed in the detail section below.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this enum is {@link javax.lang.model.element.Modifier}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public enum Modifier {
-
- // See JLS2 sections 8.1.1, 8.3.1, 8.4.3, 8.8.3, and 9.1.1.
- // java.lang.reflect.Modifier includes INTERFACE, but that's a VMism.
-
- /** The modifier public */ PUBLIC,
- /** The modifier protected */ PROTECTED,
- /** The modifier private */ PRIVATE,
- /** The modifier abstract */ ABSTRACT,
- /** The modifier static */ STATIC,
- /** The modifier final */ FINAL,
- /** The modifier transient */ TRANSIENT,
- /** The modifier volatile */ VOLATILE,
- /** The modifier synchronized */ SYNCHRONIZED,
- /** The modifier native */ NATIVE,
- /** The modifier strictfp */ STRICTFP;
-
-
- private String lowercase = null; // modifier name in lowercase
-
- /**
- * Returns this modifier's name in lowercase.
- */
- public String toString() {
- if (lowercase == null) {
- lowercase = name().toLowerCase(java.util.Locale.US);
- }
- return lowercase;
- }
-}
--- old/src/share/classes/com/sun/mirror/declaration/PackageDeclaration.java 2012-01-19 16:21:13.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,101 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.declaration;
-
-
-import java.util.Collection;
-
-
-/**
- * Represents the declaration of a package. Provides access to information
- * about the package and its members.
- *
- * {@link com.sun.mirror.util.DeclarationFilter}
- * provides a simple way to select just the items of interest
- * when a method returns a collection of declarations.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is {@link
- * javax.lang.model.element.PackageElement}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface PackageDeclaration extends Declaration {
-
- /**
- * Returns the fully qualified name of this package.
- * This is also known as the package's canonical name.
- *
- * @return the fully qualified name of this package, or the
- * empty string if this is the unnamed package
- */
- String getQualifiedName();
-
- /**
- * Returns the declarations of the top-level classes in this package.
- * Interfaces are not included, but enum types are.
- *
- * @return the declarations of the top-level classes in this package
- *
- * @see com.sun.mirror.util.DeclarationFilter
- */
- Collection
- * While a TypeDeclaration represents the declaration
- * of a class or interface, a {@link DeclaredType} represents a class
- * or interface type, the latter being a use
- * (or invocation) of the former.
- * The distinction is most apparent with generic types,
- * for which a single declaration can define a whole
- * family of types. For example, the declaration of
- * {@code java.util.Set} corresponds to the parameterized types
- * {@code java.util.Set {@link com.sun.mirror.util.DeclarationFilter}
- * provides a simple way to select just the items of interest
- * when a method returns a collection of declarations.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is included in {@link
- * javax.lang.model.element.TypeElement}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- *
- * @see DeclaredType
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface TypeDeclaration extends MemberDeclaration {
-
- /**
- * Returns the package within which this type is declared.
- *
- * @return the package within which this type is declared
- */
- PackageDeclaration getPackage();
-
- /**
- * Returns the fully qualified name of this class or interface
- * declaration. More precisely, it returns the canonical
- * name.
- * The name of a generic type does not include any reference
- * to its formal type parameters.
- * For example, the the fully qualified name of the interface declaration
- * {@code java.util.Set The {@code apt} tool and its associated API have been superseded
- * by the standardized annotation processing API. The replacement for
- * the functionality in this package is {@link
- * javax.lang.model.element}.
- *
- * @since 1.5
- */
-package com.sun.mirror.declaration;
--- old/src/share/classes/com/sun/mirror/overview.html 2012-01-19 16:21:14.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,111 +0,0 @@
-
-
- Also included is support for writing
-{@linkplain com.sun.mirror.apt.AnnotationProcessor annotation processors}
-to examine and process the annotations
-of program elements. An annotation processor may, as an example, create
-new source files and XML documents to be used in conjunction with the
-original code.
-
-
- Programs are modeled in their static, or build-time, form.
-This differs from the {@linkplain java.lang.reflect reflection} API,
-which provides run-time information about classes and objects.
-
- The API does not provide direct support for generating new code.
-
-
- Types are represented by the {@link com.sun.mirror.type.TypeMirror}
-interface and its hierarchy of subinterfaces in the
-package {@link com.sun.mirror.type}. Types include primitive types,
-class and interface types, array types, type variables, and wildcards.
-The interface hierarchy is depicted
- here.
-
- The API makes a clear distinction between declarations and types.
-This is most significant for generic types, where a single declaration
-can define an infinite family of types. For example, the declaration of
-java.util.Set defines the raw type java.util.Set,
-the parameterized type {@code java.util.Set A program being modeled may be incomplete, in that
-it may depend on an unknown class or interface type.
-This may be the result of a processing error such as a missing class file,
-or perhaps the missing type is to be created by an annotation processor.
-See {@link com.sun.mirror.type.DeclaredType} for information on
-how such unknown types are handled.
-
-
- The {@link com.sun.mirror.apt} package supports the writing
-of annotation processors. It provides the mechanism for them to
-interact with an annotation processing tool.
-
-
-@since 1.5
-
-
-
--- old/src/share/classes/com/sun/mirror/type/AnnotationType.java 2012-01-19 16:21:14.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,52 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.type;
-
-
-import com.sun.mirror.declaration.AnnotationTypeDeclaration;
-
-
-/**
- * Represents an annotation type.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is included in {@link
- * javax.lang.model.type.DeclaredType}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface AnnotationType extends InterfaceType {
-
- /**
- * {@inheritDoc}
- */
- AnnotationTypeDeclaration getDeclaration();
-}
--- old/src/share/classes/com/sun/mirror/type/ArrayType.java 2012-01-19 16:21:14.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,53 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.type;
-
-
-/**
- * Represents an array type.
- * A multidimensional array type is represented as an array type
- * whose component type is also an array type.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is {@link
- * javax.lang.model.type.ArrayType}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface ArrayType extends ReferenceType {
-
- /**
- * Returns the component type of this array type.
- *
- * @return the component type of this array type
- */
- TypeMirror getComponentType();
-}
--- old/src/share/classes/com/sun/mirror/type/ClassType.java 2012-01-19 16:21:15.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,74 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.type;
-
-
-import com.sun.mirror.declaration.*;
-
-
-/**
- * Represents a class type.
- * Interface types are represented separately by {@link InterfaceType}.
- * Note that an {@linkplain EnumType enum} is a kind of class.
- *
- * While a {@link ClassDeclaration} represents the declaration
- * of a class, a ClassType represents a class type.
- * See {@link TypeDeclaration} for more on this distinction.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is included in {@link
- * javax.lang.model.type.DeclaredType}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface ClassType extends DeclaredType {
-
- /**
- * {@inheritDoc}
- */
- ClassDeclaration getDeclaration();
-
- /**
- * Returns the class type that is a direct supertype of this one.
- * This is the superclass of this type's declaring class, with any
- * type arguments substituted in.
- * The only class with no superclass is java.lang.Object,
- * for which this method returns null.
- *
- * For example, the class type extended by
- * {@code java.util.TreeSet While a TypeDeclaration represents the declaration
- * of a class or interface, a DeclaredType represents a class
- * or interface type, the latter being a use of the former.
- * See {@link TypeDeclaration} for more on this distinction.
- *
- * A DeclaredType may represent a type
- * for which details (declaration, supertypes, etc.) are unknown.
- * This may be the result of a processing error, such as a missing class file,
- * and is indicated by {@link #getDeclaration()} returning null.
- * Other method invocations on such an unknown type will not, in general,
- * return meaningful results.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is included in {@link
- * javax.lang.model.type.DeclaredType}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface DeclaredType extends ReferenceType {
-
- /**
- * Returns the declaration of this type.
- *
- * Returns null if this type's declaration is unknown. This may
- * be the result of a processing error, such as a missing class file.
- *
- * @return the declaration of this type, or null if unknown
- */
- TypeDeclaration getDeclaration();
-
- /**
- * Returns the type that contains this type as a member.
- * Returns null if this is a top-level type.
- *
- * For example, the containing type of {@code O.I For example, the interface type extended by
- * {@code java.util.Set While an {@link InterfaceDeclaration} represents the
- * declaration of an interface, an InterfaceType
- * represents an interface type.
- * See {@link TypeDeclaration} for more on this distinction.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is included in {@link
- * javax.lang.model.type.DeclaredType}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface InterfaceType extends DeclaredType {
-
- /**
- * {@inheritDoc}
- */
- InterfaceDeclaration getDeclaration();
-}
--- old/src/share/classes/com/sun/mirror/type/MirroredTypeException.java 2012-01-19 16:21:15.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,88 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.type;
-
-
-import java.lang.annotation.Annotation;
-
-import com.sun.mirror.declaration.Declaration;
-
-
-/**
- * Thrown when an application attempts to access the {@link Class} object
- * corresponding to a {@link TypeMirror}.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this exception is {@link
- * javax.lang.model.type.MirroredTypeException}.
- *
- * @see MirroredTypesException
- * @see Declaration#getAnnotation(Class)
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public class MirroredTypeException extends RuntimeException {
-
- private static final long serialVersionUID = 1;
-
- private transient TypeMirror type; // cannot be serialized
- private String name; // type's qualified "name"
-
- /**
- * Constructs a new MirroredTypeException for the specified type.
- *
- * @param type the type being accessed
- */
- public MirroredTypeException(TypeMirror type) {
- super("Attempt to access Class object for TypeMirror " + type);
- this.type = type;
- name = type.toString();
- }
-
- /**
- * Returns the type mirror corresponding to the type being accessed.
- * The type mirror may be unavailable if this exception has been
- * serialized and then read back in.
- *
- * @return the type mirror, or null if unavailable
- */
- public TypeMirror getTypeMirror() {
- return type;
- }
-
- /**
- * Returns the fully qualified name of the type being accessed.
- * More precisely, returns the canonical name of a class,
- * interface, array, or primitive, and returns "void" for
- * the pseudo-type representing the type of void.
- *
- * @return the fully qualified name of the type being accessed
- */
- public String getQualifiedName() {
- return name;
- }
-}
--- old/src/share/classes/com/sun/mirror/type/MirroredTypesException.java 2012-01-19 16:21:16.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,97 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.type;
-
-
-import java.lang.annotation.Annotation;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
-
-import com.sun.mirror.declaration.Declaration;
-
-
-/**
- * Thrown when an application attempts to access a sequence of {@link Class}
- * objects each corresponding to a {@link TypeMirror}.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this exception is {@link
- * javax.lang.model.type.MirroredTypesException}.
- *
- * @see MirroredTypeException
- * @see Declaration#getAnnotation(Class)
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public class MirroredTypesException extends RuntimeException {
-
- private static final long serialVersionUID = 1;
-
- private transient Collection Types may be compared using the utility methods in
- * {@link Types}.
- * There is no guarantee that any particular type will
- * always be represented by the same object.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is {@link
- * javax.lang.model.type.TypeMirror}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- *
- * @see Declaration
- * @see Types
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface TypeMirror {
-
- /**
- * Returns a string representation of this type.
- * Any names embedded in the expression are qualified.
- *
- * @return a string representation of this type
- */
- String toString();
-
- /**
- * Tests whether two types represent the same type.
- *
- * @param obj the object to be compared with this type
- * @return true if the specified object represents the same
- * type as this.
- */
- boolean equals(Object obj);
-
- /**
- * Applies a visitor to this type.
- *
- * @param v the visitor operating on this type
- */
- void accept(TypeVisitor v);
-}
--- old/src/share/classes/com/sun/mirror/type/TypeVariable.java 2012-01-19 16:21:16.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,57 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.type;
-
-
-import com.sun.mirror.declaration.*;
-
-
-/**
- * Represents a type variable.
- * A type variable is declared by a
- * {@linkplain TypeParameterDeclaration type parameter} of a
- * type, method, or constructor.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is {@link
- * javax.lang.model.type.TypeVariable}.
- *
- * @author Joe Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface TypeVariable extends ReferenceType {
-
- /**
- * Returns the type parameter that declared this type variable.
- *
- * @return the type parameter that declared this type variable
- */
- TypeParameterDeclaration getDeclaration();
-}
--- old/src/share/classes/com/sun/mirror/type/VoidType.java 2012-01-19 16:21:17.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,49 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.type;
-
-
-import com.sun.mirror.declaration.MethodDeclaration;
-
-
-/**
- * A pseudo-type representing the type of void.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is included in {@link
- * javax.lang.model.type.NoType}.
- *
- * @see MethodDeclaration#getReturnType()
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface VoidType extends TypeMirror {
-}
--- old/src/share/classes/com/sun/mirror/type/WildcardType.java 2012-01-19 16:21:17.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,74 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.type;
-
-
-import java.util.Collection;
-
-
-/**
- * Represents a wildcard type argument.
- * Examples include: A wildcard may have its upper bound explicitly set by an
- * extends clause, its lower bound explicitly set by a
- * super clause, or neither (but not both).
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is {@link
- * javax.lang.model.type.WildcardType}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface WildcardType extends TypeMirror {
-
- /**
- * Returns the upper bounds of this wildcard.
- * If no upper bound is explicitly declared, then
- * an empty collection is returned.
- *
- * @return the upper bounds of this wildcard
- */
- Collection The {@code apt} tool and its associated API have been
- * superseded by the standardized annotation processing API. The
- * replacement for the functionality in this package is {@link
- * javax.lang.model.type}.
- *
- * @since 1.5
- */
-package com.sun.mirror.type;
--- old/src/share/classes/com/sun/mirror/util/DeclarationFilter.java 2012-01-19 16:21:17.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,319 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.util;
-
-
-import java.util.ArrayList;
-import java.util.Collection;
-
-import com.sun.mirror.declaration.Declaration;
-import com.sun.mirror.declaration.Modifier;
-
-import static com.sun.mirror.declaration.Modifier.*;
-
-
-/**
- * A filter for selecting just the items of interest
- * from a collection of declarations.
- * The filter is said to select or to match those declarations.
- * Filters can be created in several ways:
- * by the static methods described below,
- * by negating or composing existing filters,
- * or by subclasses that implement arbitrary matching rules.
- *
- * A subclass can create an arbitrary filter simply by implementing
- * the {@link #matches(Declaration)} method.
- *
- * Examples.
- * Selecting the public declarations from a collection:
- * To control the processing done on a declaration, users of this
- * class pass in their own visitors for pre and post processing. The
- * preprocessing visitor is called before the contained declarations
- * are scanned; the postprocessing visitor is called after the
- * contained declarations are scanned.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this class is {@link
- * javax.lang.model.util.ElementScanner6}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-class DeclarationScanner implements DeclarationVisitor {
- protected DeclarationVisitor pre;
- protected DeclarationVisitor post;
-
- DeclarationScanner(DeclarationVisitor pre, DeclarationVisitor post) {
- this.pre = pre;
- this.post = post;
- }
-
- /**
- * Visits a declaration.
- *
- * @param d the declaration to visit
- */
- public void visitDeclaration(Declaration d) {
- d.accept(pre);
- d.accept(post);
- }
-
- /**
- * Visits a package declaration.
- *
- * @param d the declaration to visit
- */
- public void visitPackageDeclaration(PackageDeclaration d) {
- d.accept(pre);
-
- for(ClassDeclaration classDecl: d.getClasses()) {
- classDecl.accept(this);
- }
-
- for(InterfaceDeclaration interfaceDecl: d.getInterfaces()) {
- interfaceDecl.accept(this);
- }
-
- d.accept(post);
- }
-
- /**
- * Visits a member or constructor declaration.
- *
- * @param d the declaration to visit
- */
- public void visitMemberDeclaration(MemberDeclaration d) {
- visitDeclaration(d);
- }
-
- /**
- * Visits a type declaration.
- *
- * @param d the declaration to visit
- */
- public void visitTypeDeclaration(TypeDeclaration d) {
- d.accept(pre);
-
- for(TypeParameterDeclaration tpDecl: d.getFormalTypeParameters()) {
- tpDecl.accept(this);
- }
-
- for(FieldDeclaration fieldDecl: d.getFields()) {
- fieldDecl.accept(this);
- }
-
- for(MethodDeclaration methodDecl: d.getMethods()) {
- methodDecl.accept(this);
- }
-
- for(TypeDeclaration typeDecl: d.getNestedTypes()) {
- typeDecl.accept(this);
- }
-
- d.accept(post);
- }
-
- /**
- * Visits a class declaration.
- *
- * @param d the declaration to visit
- */
- public void visitClassDeclaration(ClassDeclaration d) {
- d.accept(pre);
-
- for(TypeParameterDeclaration tpDecl: d.getFormalTypeParameters()) {
- tpDecl.accept(this);
- }
-
- for(FieldDeclaration fieldDecl: d.getFields()) {
- fieldDecl.accept(this);
- }
-
- for(MethodDeclaration methodDecl: d.getMethods()) {
- methodDecl.accept(this);
- }
-
- for(TypeDeclaration typeDecl: d.getNestedTypes()) {
- typeDecl.accept(this);
- }
-
- for(ConstructorDeclaration ctorDecl: d.getConstructors()) {
- ctorDecl.accept(this);
- }
-
- d.accept(post);
- }
-
- /**
- * Visits an enum declaration.
- *
- * @param d the declaration to visit
- */
- public void visitEnumDeclaration(EnumDeclaration d) {
- visitClassDeclaration(d);
- }
-
- /**
- * Visits an interface declaration.
- *
- * @param d the declaration to visit
- */
- public void visitInterfaceDeclaration(InterfaceDeclaration d) {
- visitTypeDeclaration(d);
- }
-
- /**
- * Visits an annotation type declaration.
- *
- * @param d the declaration to visit
- */
- public void visitAnnotationTypeDeclaration(AnnotationTypeDeclaration d) {
- visitInterfaceDeclaration(d);
- }
-
- /**
- * Visits a field declaration.
- *
- * @param d the declaration to visit
- */
- public void visitFieldDeclaration(FieldDeclaration d) {
- visitMemberDeclaration(d);
- }
-
- /**
- * Visits an enum constant declaration.
- *
- * @param d the declaration to visit
- */
- public void visitEnumConstantDeclaration(EnumConstantDeclaration d) {
- visitFieldDeclaration(d);
- }
-
- /**
- * Visits a method or constructor declaration.
- *
- * @param d the declaration to visit
- */
- public void visitExecutableDeclaration(ExecutableDeclaration d) {
- d.accept(pre);
-
- for(TypeParameterDeclaration tpDecl: d.getFormalTypeParameters()) {
- tpDecl.accept(this);
- }
-
- for(ParameterDeclaration pDecl: d.getParameters()) {
- pDecl.accept(this);
- }
-
- d.accept(post);
- }
-
- /**
- * Visits a constructor declaration.
- *
- * @param d the declaration to visit
- */
- public void visitConstructorDeclaration(ConstructorDeclaration d) {
- visitExecutableDeclaration(d);
- }
-
- /**
- * Visits a method declaration.
- *
- * @param d the declaration to visit
- */
- public void visitMethodDeclaration(MethodDeclaration d) {
- visitExecutableDeclaration(d);
- }
-
- /**
- * Visits an annotation type element declaration.
- *
- * @param d the declaration to visit
- */
- public void visitAnnotationTypeElementDeclaration(
- AnnotationTypeElementDeclaration d) {
- visitMethodDeclaration(d);
- }
-
- /**
- * Visits a parameter declaration.
- *
- * @param d the declaration to visit
- */
- public void visitParameterDeclaration(ParameterDeclaration d) {
- visitDeclaration(d);
- }
-
- /**
- * Visits a type parameter declaration.
- *
- * @param d the declaration to visit
- */
- public void visitTypeParameterDeclaration(TypeParameterDeclaration d) {
- visitDeclaration(d);
- }
-}
--- old/src/share/classes/com/sun/mirror/util/DeclarationVisitor.java 2012-01-19 16:21:18.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,149 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.util;
-
-import com.sun.mirror.declaration.*;
-
-
-/**
- * A visitor for declarations, in the style of the standard visitor
- * design pattern. Classes implementing this interface are used to
- * operate on a declaration when the kind of declaration is unknown at
- * compile time. When a visitor is passed to a declaration's {@link
- * Declaration#accept accept} method, the most specific
- * visitXxx method applicable to that declaration is
- * invoked.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is {@link
- * javax.lang.model.element.ElementVisitor}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface DeclarationVisitor {
-
- /**
- * Visits a declaration.
- * @param d the declaration to visit
- */
- public void visitDeclaration(Declaration d);
-
- /**
- * Visits a package declaration.
- * @param d the declaration to visit
- */
- public void visitPackageDeclaration(PackageDeclaration d);
-
- /**
- * Visits a member or constructor declaration.
- * @param d the declaration to visit
- */
- public void visitMemberDeclaration(MemberDeclaration d);
-
- /**
- * Visits a type declaration.
- * @param d the declaration to visit
- */
- public void visitTypeDeclaration(TypeDeclaration d);
-
- /**
- * Visits a class declaration.
- * @param d the declaration to visit
- */
- public void visitClassDeclaration(ClassDeclaration d);
-
- /**
- * Visits an enum declaration.
- * @param d the declaration to visit
- */
- public void visitEnumDeclaration(EnumDeclaration d);
-
- /**
- * Visits an interface declaration.
- * @param d the declaration to visit
- */
- public void visitInterfaceDeclaration(InterfaceDeclaration d);
-
- /**
- * Visits an annotation type declaration.
- * @param d the declaration to visit
- */
- public void visitAnnotationTypeDeclaration(AnnotationTypeDeclaration d);
-
- /**
- * Visits a field declaration.
- * @param d the declaration to visit
- */
- public void visitFieldDeclaration(FieldDeclaration d);
-
- /**
- * Visits an enum constant declaration.
- * @param d the declaration to visit
- */
- public void visitEnumConstantDeclaration(EnumConstantDeclaration d);
-
- /**
- * Visits a method or constructor declaration.
- * @param d the declaration to visit
- */
- public void visitExecutableDeclaration(ExecutableDeclaration d);
-
- /**
- * Visits a constructor declaration.
- * @param d the declaration to visit
- */
- public void visitConstructorDeclaration(ConstructorDeclaration d);
-
- /**
- * Visits a method declaration.
- * @param d the declaration to visit
- */
- public void visitMethodDeclaration(MethodDeclaration d);
-
- /**
- * Visits an annotation type element declaration.
- * @param d the declaration to visit
- */
- public void visitAnnotationTypeElementDeclaration(
- AnnotationTypeElementDeclaration d);
-
- /**
- * Visits a parameter declaration.
- * @param d the declaration to visit
- */
- public void visitParameterDeclaration(ParameterDeclaration d);
-
- /**
- * Visits a type parameter declaration.
- * @param d the declaration to visit
- */
- public void visitTypeParameterDeclaration(TypeParameterDeclaration d);
-}
--- old/src/share/classes/com/sun/mirror/util/DeclarationVisitors.java 2012-01-19 16:21:18.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,104 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.util;
-
-/**
- * Utilities to create specialized DeclarationVisitor instances.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. There is no direct
- * replacement for the functionality of this class in the standardized
- * API due to that API's different visitor structure.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public class DeclarationVisitors {
- private DeclarationVisitors(){} // do not instantiate.
-
- /**
- * A visitor that has no side effects and keeps no state.
- */
- public static final DeclarationVisitor NO_OP = new SimpleDeclarationVisitor();
-
- /**
- * Return a DeclarationVisitor that will scan the
- * declaration structure, visiting declarations contained in
- * another declaration. For example, when visiting a class, the
- * fields, methods, constructors, etc. of the class are also
- * visited. The order in which the contained declarations are scanned is
- * not specified.
- *
- * The pre and post
- * DeclarationVisitor parameters specify,
- * respectively, the processing the scanner will do before or
- * after visiting the contained declarations. If only one of pre
- * and post processing is needed, use {@link
- * DeclarationVisitors#NO_OP DeclarationVisitors.NO_OP} for the
- * other parameter.
- *
- * @param pre visitor representing processing to do before
- * visiting contained declarations.
- *
- * @param post visitor representing processing to do after
- * visiting contained declarations.
- */
- public static DeclarationVisitor getDeclarationScanner(DeclarationVisitor pre,
- DeclarationVisitor post) {
- return new DeclarationScanner(pre, post);
- }
-
- /**
- * Return a DeclarationVisitor that will scan the
- * declaration structure, visiting declarations contained in
- * another declaration in source code order. For example, when
- * visiting a class, the fields, methods, constructors, etc. of
- * the class are also visited. The order in which the contained
- * declarations are visited is as close to source code order as
- * possible; declaration mirrors created from class files instead
- * of source code will not have source position information.
- *
- * The pre and post
- * DeclarationVisitor parameters specify,
- * respectively, the processing the scanner will do before or
- * after visiting the contained declarations. If only one of pre
- * and post processing is needed, use {@link
- * DeclarationVisitors#NO_OP DeclarationVisitors.NO_OP} for the other parameter.
- *
- * @param pre visitor representing processing to do before
- * visiting contained declarations.
- *
- * @param post visitor representing processing to do after
- * visiting contained declarations.
- */
- public static DeclarationVisitor getSourceOrderDeclarationScanner(DeclarationVisitor pre,
- DeclarationVisitor post) {
- return new SourceOrderDeclScanner(pre, post);
- }
-}
--- old/src/share/classes/com/sun/mirror/util/Declarations.java 2012-01-19 16:21:18.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,69 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.util;
-
-
-import com.sun.mirror.declaration.*;
-
-
-/**
- * Utility methods for operating on declarations.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this interface is {@link
- * javax.lang.model.util.Elements}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public interface Declarations {
-
- /**
- * Tests whether one type, method, or field declaration hides another.
- *
- * @param sub the first member
- * @param sup the second member
- * @return true if and only if the first member hides
- * the second
- */
- boolean hides(MemberDeclaration sub, MemberDeclaration sup);
-
- /**
- * Tests whether one method overrides another. When a
- * non-abstract method overrides an abstract one, the
- * former is also said to implement the latter.
- *
- * @param sub the first method
- * @param sup the second method
- * @return true if and only if the first method overrides
- * the second
- */
- boolean overrides(MethodDeclaration sub, MethodDeclaration sup);
-}
--- old/src/share/classes/com/sun/mirror/util/SimpleDeclarationVisitor.java 2012-01-19 16:21:18.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,216 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.util;
-
-
-import com.sun.mirror.declaration.*;
-
-
-/**
- * A simple visitor for declarations.
- *
- * The implementations of the methods of this class do nothing but
- * delegate up the declaration hierarchy. A subclass should override the
- * methods that correspond to the kinds of declarations on which it
- * will operate.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this class is {@link
- * javax.lang.model.util.SimpleElementVisitor6}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public class SimpleDeclarationVisitor implements DeclarationVisitor {
-
- /**
- * Creates a new SimpleDeclarationVisitor.
- */
- public SimpleDeclarationVisitor(){}
-
- /**
- * Visits a declaration.
- * The implementation does nothing.
- * @param d the declaration to visit
- */
- public void visitDeclaration(Declaration d) {
- }
-
- /**
- * Visits a package declaration.
- * The implementation simply invokes
- * {@link #visitDeclaration visitDeclaration}.
- * @param d the declaration to visit
- */
- public void visitPackageDeclaration(PackageDeclaration d) {
- visitDeclaration(d);
- }
-
- /**
- * Visits a member or constructor declaration.
- * The implementation simply invokes
- * {@link #visitDeclaration visitDeclaration}.
- * @param d the declaration to visit
- */
- public void visitMemberDeclaration(MemberDeclaration d) {
- visitDeclaration(d);
- }
-
- /**
- * Visits a type declaration.
- * The implementation simply invokes
- * {@link #visitMemberDeclaration visitMemberDeclaration}.
- * @param d the declaration to visit
- */
- public void visitTypeDeclaration(TypeDeclaration d) {
- visitMemberDeclaration(d);
- }
-
- /**
- * Visits a class declaration.
- * The implementation simply invokes
- * {@link #visitTypeDeclaration visitTypeDeclaration}.
- * @param d the declaration to visit
- */
- public void visitClassDeclaration(ClassDeclaration d) {
- visitTypeDeclaration(d);
- }
-
- /**
- * Visits an enum declaration.
- * The implementation simply invokes
- * {@link #visitClassDeclaration visitClassDeclaration}.
- * @param d the declaration to visit
- */
- public void visitEnumDeclaration(EnumDeclaration d) {
- visitClassDeclaration(d);
- }
-
- /**
- * Visits an interface declaration.
- * The implementation simply invokes
- * {@link #visitTypeDeclaration visitTypeDeclaration}.
- * @param d the declaration to visit
- */
- public void visitInterfaceDeclaration(InterfaceDeclaration d) {
- visitTypeDeclaration(d);
- }
-
- /**
- * Visits an annotation type declaration.
- * The implementation simply invokes
- * {@link #visitInterfaceDeclaration visitInterfaceDeclaration}.
- * @param d the declaration to visit
- */
- public void visitAnnotationTypeDeclaration(AnnotationTypeDeclaration d) {
- visitInterfaceDeclaration(d);
- }
-
- /**
- * Visits a field declaration.
- * The implementation simply invokes
- * {@link #visitMemberDeclaration visitMemberDeclaration}.
- * @param d the declaration to visit
- */
- public void visitFieldDeclaration(FieldDeclaration d) {
- visitMemberDeclaration(d);
- }
-
- /**
- * Visits an enum constant declaration.
- * The implementation simply invokes
- * {@link #visitFieldDeclaration visitFieldDeclaration}.
- * @param d the declaration to visit
- */
- public void visitEnumConstantDeclaration(EnumConstantDeclaration d) {
- visitFieldDeclaration(d);
- }
-
- /**
- * Visits a method or constructor declaration.
- * The implementation simply invokes
- * {@link #visitMemberDeclaration visitMemberDeclaration}.
- * @param d the declaration to visit
- */
- public void visitExecutableDeclaration(ExecutableDeclaration d) {
- visitMemberDeclaration(d);
- }
-
- /**
- * Visits a constructor declaration.
- * The implementation simply invokes
- * {@link #visitExecutableDeclaration visitExecutableDeclaration}.
- * @param d the declaration to visit
- */
- public void visitConstructorDeclaration(ConstructorDeclaration d) {
- visitExecutableDeclaration(d);
- }
-
- /**
- * Visits a method declaration.
- * The implementation simply invokes
- * {@link #visitExecutableDeclaration visitExecutableDeclaration}.
- * @param d the declaration to visit
- */
- public void visitMethodDeclaration(MethodDeclaration d) {
- visitExecutableDeclaration(d);
- }
-
- /**
- * Visits an annotation type element declaration.
- * The implementation simply invokes
- * {@link #visitMethodDeclaration visitMethodDeclaration}.
- * @param d the declaration to visit
- */
- public void visitAnnotationTypeElementDeclaration(
- AnnotationTypeElementDeclaration d) {
- visitMethodDeclaration(d);
- }
-
- /**
- * Visits a parameter declaration.
- * The implementation simply invokes
- * {@link #visitDeclaration visitDeclaration}.
- * @param d the declaration to visit
- */
- public void visitParameterDeclaration(ParameterDeclaration d) {
- visitDeclaration(d);
- }
-
- /**
- * Visits a type parameter declaration.
- * The implementation simply invokes
- * {@link #visitDeclaration visitDeclaration}.
- * @param d the declaration to visit
- */
- public void visitTypeParameterDeclaration(TypeParameterDeclaration d) {
- visitDeclaration(d);
- }
-}
--- old/src/share/classes/com/sun/mirror/util/SimpleTypeVisitor.java 2012-01-19 16:21:18.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,175 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.util;
-
-
-import com.sun.mirror.type.*;
-
-
-/**
- * A simple visitor for types.
- *
- * The implementations of the methods of this class do nothing but
- * delegate up the type hierarchy. A subclass should override the
- * methods that correspond to the kinds of types on which it will
- * operate.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this class is {@link
- * javax.lang.model.util.SimpleTypeVisitor6}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public class SimpleTypeVisitor implements TypeVisitor {
-
- /**
- * Creates a new SimpleTypeVisitor.
- */
- public SimpleTypeVisitor() {}
-
- /**
- * Visits a type mirror.
- * The implementation does nothing.
- * @param t the type to visit
- */
- public void visitTypeMirror(TypeMirror t) {
- }
-
- /**
- * Visits a primitive type.
- * The implementation simply invokes
- * {@link #visitTypeMirror visitTypeMirror}.
- * @param t the type to visit
- */
- public void visitPrimitiveType(PrimitiveType t) {
- visitTypeMirror(t);
- }
-
- /**
- * Visits a void type.
- * The implementation simply invokes
- * {@link #visitTypeMirror visitTypeMirror}.
- * @param t the type to visit
- */
- public void visitVoidType(VoidType t) {
- visitTypeMirror(t);
- }
-
- /**
- * Visits a reference type.
- * The implementation simply invokes
- * {@link #visitTypeMirror visitTypeMirror}.
- * @param t the type to visit
- */
- public void visitReferenceType(ReferenceType t) {
- visitTypeMirror(t);
- }
-
- /**
- * Visits a declared type.
- * The implementation simply invokes
- * {@link #visitReferenceType visitReferenceType}.
- * @param t the type to visit
- */
- public void visitDeclaredType(DeclaredType t) {
- visitReferenceType(t);
- }
-
- /**
- * Visits a class type.
- * The implementation simply invokes
- * {@link #visitDeclaredType visitDeclaredType}.
- * @param t the type to visit
- */
- public void visitClassType(ClassType t) {
- visitDeclaredType(t);
- }
-
- /**
- * Visits an enum type.
- * The implementation simply invokes
- * {@link #visitClassType visitClassType}.
- * @param t the type to visit
- */
- public void visitEnumType(EnumType t) {
- visitClassType(t);
- }
-
- /**
- * Visits an interface type.
- * The implementation simply invokes
- * {@link #visitDeclaredType visitDeclaredType}.
- * @param t the type to visit
- */
- public void visitInterfaceType(InterfaceType t) {
- visitDeclaredType(t);
- }
-
- /**
- * Visits an annotation type.
- * The implementation simply invokes
- * {@link #visitInterfaceType visitInterfaceType}.
- * @param t the type to visit
- */
- public void visitAnnotationType(AnnotationType t) {
- visitInterfaceType(t);
- }
-
- /**
- * Visits an array type.
- * The implementation simply invokes
- * {@link #visitReferenceType visitReferenceType}.
- * @param t the type to visit
- */
- public void visitArrayType(ArrayType t) {
- visitReferenceType(t);
- }
-
- /**
- * Visits a type variable.
- * The implementation simply invokes
- * {@link #visitReferenceType visitReferenceType}.
- * @param t the type to visit
- */
- public void visitTypeVariable(TypeVariable t) {
- visitReferenceType(t);
- }
-
- /**
- * Visits a wildcard.
- * The implementation simply invokes
- * {@link #visitTypeMirror visitTypeMirror}.
- * @param t the type to visit
- */
- public void visitWildcardType(WildcardType t) {
- visitTypeMirror(t);
- }
-}
--- old/src/share/classes/com/sun/mirror/util/SourceOrderDeclScanner.java 2012-01-19 16:21:19.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,258 +0,0 @@
-/*
- * 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
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.mirror.util;
-
-import com.sun.mirror.declaration.*;
-
-import java.util.SortedSet;
-import java.util.TreeSet;
-
-/**
- * A visitor for declarations that scans declarations contained within
- * the given declaration in source code order. For example, when
- * visiting a class, the methods, fields, constructors, and nested
- * types of the class are also visited.
- *
- * To control the processing done on a declaration, users of this
- * class pass in their own visitors for pre and post processing. The
- * preprocessing visitor is called before the contained declarations
- * are scanned; the postprocessing visitor is called after the
- * contained declarations are scanned.
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this class is {@link
- * javax.lang.model.util.SimpleElementVisitor6}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-class SourceOrderDeclScanner extends DeclarationScanner {
- static class SourceOrderComparator implements java.util.Comparator The number of type arguments must either equal the
- * number of the declaration's formal type parameters, or must be
- * zero. If zero, and if the declaration is generic,
- * then the declaration's raw type is returned.
- *
- * If a parameterized type is being returned, its declaration
- * must not be contained within a generic outer class.
- * The parameterized type {@code Outer If the containing type is a parameterized type,
- * the number of type arguments must equal the
- * number of the declaration's formal type parameters.
- * If it is not parameterized or if it is null, this method is
- * equivalent to getDeclaredType(decl, typeArgs).
- *
- * @param containing the containing type, or null if none
- * @param decl the type declaration
- * @param typeArgs the actual type arguments
- * @return the type corresponding to the type declaration and
- * actual type arguments,
- * contained within the given type
- * @throws IllegalArgumentException if too many or too few
- * type arguments are given, or if an inappropriate type
- * argument, declaration, or containing type is provided
- */
- DeclaredType getDeclaredType(DeclaredType containing,
- TypeDeclaration decl,
- TypeMirror... typeArgs);
-}
--- old/src/share/classes/com/sun/mirror/util/package-info.java 2012-01-19 16:21:19.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,37 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-/**
- * Utilities to assist in the processing of {@linkplain
- * com.sun.mirror.declaration declarations} and {@linkplain
- * com.sun.mirror.type types}.
- *
- * The {@code apt} tool and its associated API have been superseded
- * by the standardized annotation processing API. The replacement for
- * the functionality in this package is {@link javax.lang.model.util}.
- *
- * @since 1.5
- */
-package com.sun.mirror.util;
--- old/src/share/classes/com/sun/tools/apt/Main.java 2012-01-19 16:21:20.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,115 +0,0 @@
-/*
- * Copyright (c) 2004, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.apt;
-
-import java.io.PrintWriter;
-import com.sun.mirror.apt.AnnotationProcessorFactory;
-
-/**
- * The main program for the command-line tool apt.
- *
- * Nothing described in this source file is 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.
- */
-public class Main {
-
- static {
- ClassLoader loader = Main.class.getClassLoader();
- if (loader != null)
- loader.setPackageAssertionStatus("com.sun.tools.apt", true);
- }
-
- /** Command line interface. If args is null, a
- * NullPointerException is thrown.
- * @param args The command line parameters.
- */
- public static void main(String... args) {
- System.exit(process(args));
- }
-
- /** Programatic interface. If args is null, a
- * NullPointerException is thrown.
- * Output is directed to System.err.
- * @param args The command line parameters.
- */
- public static int process(String... args) {
- return processing(null, null, args);
- }
-
- /** Programmatic interface. If any argument
- * is null, a NullPointerException is thrown.
- * @param args The command line parameters.
- * @param out Where the tool's output is directed.
- */
- public static int process(PrintWriter out, String... args) {
- if (out == null)
- throw new NullPointerException("Parameter out cannot be null.");
- return processing(null, out, args);
- }
-
- /** Programmatic interface. If factory or args
- * is null, a NullPointerException is thrown.
- * The "-factory" and "-factorypath"
- * command line parameters are ignored by this entry point.
- * Output is directed to System.err.
- *
- * @param factory The annotation processor factory to use
- * @param args The command line parameters.
- */
- public static int process(AnnotationProcessorFactory factory, String... args) {
- return process(factory, new PrintWriter(System.err, true), args);
- }
-
- /** Programmatic interface. If any argument
- * is null, a NullPointerException is thrown.
- * The "-factory" and "-factorypath"
- * command line parameters are ignored by this entry point.
- *
- * @param factory The annotation processor factory to use
- * @param args The command line parameters.
- * @param out Where the tool's output is directed.
- */
- public static int process(AnnotationProcessorFactory factory, PrintWriter out,
- String... args) {
- if (out == null)
- throw new NullPointerException("Parameter out cannot be null.");
- if (factory == null)
- throw new NullPointerException("Parameter factory cannot be null");
- return processing(factory, out, args);
- }
-
- private static int processing(AnnotationProcessorFactory factory,
- PrintWriter out,
- String... args) {
- if (out == null)
- out = new PrintWriter(System.err, true);
- com.sun.tools.apt.main.Main compiler =
- new com.sun.tools.apt.main.Main("apt", out);
- return compiler.compile(args, factory);
- }
-}
--- old/src/share/classes/com/sun/tools/apt/comp/AnnotationProcessingError.java 2012-01-19 16:21:20.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,33 +0,0 @@
-/*
- * 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
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.apt.comp;
-
-public class AnnotationProcessingError extends Error {
- private static final long serialVersionUID = 3279196183341719287L;
- AnnotationProcessingError(Throwable cause) {
- super(cause);
- }
-}
--- old/src/share/classes/com/sun/tools/apt/comp/Apt.java 2012-01-19 16:21:20.000000000 -0800
+++ /dev/null 2012-01-10 11:47:00.807870926 -0800
@@ -1,509 +0,0 @@
-/*
- * Copyright (c) 2004, 2011, 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. Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * 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
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 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 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.apt.comp;
-
-import com.sun.tools.javac.code.*;
-import com.sun.tools.javac.comp.*;
-import com.sun.tools.javac.tree.*;
-import com.sun.tools.javac.util.*;
-import com.sun.tools.javac.tree.TreeScanner;
-import com.sun.tools.javac.util.Context;
-import com.sun.tools.apt.util.Bark;
-import com.sun.tools.javac.util.Position;
-
-import java.util.*;
-import java.util.regex.*;
-import java.lang.reflect.*;
-import java.lang.reflect.InvocationTargetException;
-import java.io.IOException;
-
-import com.sun.tools.apt.*;
-import com.sun.tools.apt.comp.*;
-import com.sun.tools.javac.code.Symbol.*;
-
-import com.sun.mirror.declaration.TypeDeclaration;
-import com.sun.mirror.declaration.AnnotationTypeDeclaration;
-import com.sun.mirror.apt.*;
-// import com.sun.mirror.apt.AnnotationProcessorFactory;
-import com.sun.mirror.apt.AnnotationProcessors;
-
-import com.sun.tools.apt.mirror.AptEnv;
-import com.sun.tools.apt.mirror.apt.FilerImpl;
-import com.sun.tools.apt.mirror.apt.AnnotationProcessorEnvironmentImpl;
-
-
-import static com.sun.tools.apt.mirror.declaration.DeclarationMaker.isJavaIdentifier;
-
-/**
- * Apt compiler phase.
- *
- * 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.
- */
-@SuppressWarnings("deprecation")
-public class Apt extends ListBuffer 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.
- */
-@SuppressWarnings("deprecation")
-public class AptJavaCompiler extends com.sun.tools.javac.main.JavaCompiler {
- /** The context key for the compiler. */
- protected static final Context.Key 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.
- */
-public class CommandLine {
- /**
- * Process Win32-style command files for the specified command line
- * arguments and return the resulting arguments. A command file argument
- * is of the form '@file' where 'file' is the name of the file whose
- * contents are to be parsed for additional arguments. The contents of
- * the command file are parsed using StreamTokenizer and the original
- * '@file' argument replaced with the resulting tokens. Recursive command
- * files are not supported. The '@' character itself can be quoted with
- * the sequence '@@'.
- */
- public static String[] parse(String[] args)
- throws IOException
- {
- ListBuffer 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.
- */
-@SuppressWarnings("deprecation")
-public class Main {
-
- /** For testing: enter any options you want to be set implicitly
- * here.
- */
- static String[] forcedOpts = {
- // Preserve parameter names from class files if the class was
- // compiled with debug enabled
- "-XDsave-parameter-names"
- };
-
- /** The name of the compiler, for use in diagnostics.
- */
- String ownName;
-
- /** The writer to use for diagnostic output.
- */
- PrintWriter out;
-
-
- /** Instantiated factory to use in lieu of discovery process.
- */
- AnnotationProcessorFactory providedFactory = null;
-
- /** Map representing original command-line arguments.
- */
- Map
- *
- * @return the value
- */
- Object getValue();
-
- /**
- * Returns the source position of the beginning of this annotation value.
- * Returns null if the position is unknown or not applicable.
- *
- *
- * Note: This method is unlike
- * others in this and related interfaces. It operates on run-time
- * reflective information -- representations of annotation types
- * currently loaded into the VM -- rather than on the mirrored
- * representations defined by and used throughout these
- * interfaces. It is intended for callers that are written to
- * operate on a known, fixed set of annotation types.
- *
- *
- * @param the annotation type
- * @param annotationType the Class object corresponding to
- * the annotation type
- * @return the annotation of this declaration having the specified type
- *
- * @see #getAnnotationMirrors()
- */
- A getAnnotation(Class annotationType);
-
- /**
- * Returns the modifiers of this declaration, excluding annotations.
- * Implicit modifiers, such as the public and static
- * modifiers of interface members, are included.
- *
- * @return the modifiers of this declaration in undefined order;
- * an empty collection if there are none
- */
- Collection Characteristics of the API
-
-A program is represented at the language level, rather than at the
-level of the virtual machine. Nested classes, for example, are
-handled as first-class constructs,
-rather than in the translated form understood by the VM.
-Both source code and compiled code (class files) may be modeled
-in this way.
-
- Declarations and Types
-
-The mirror API represents program constructs principally through the
-{@link com.sun.mirror.declaration.Declaration} interface
-and its hierarchy of subinterfaces in the package {@link
-com.sun.mirror.declaration}. A Declaration represents a
-program element such as a package, class, or method.
-The interface hierarchy is depicted
- here.
-
- Utilities and Tool Support
-
-The {@link com.sun.mirror.util} package provides
-utilities to assist in the processing of declarations and types.
-Included is support for using the visitor design pattern when
-operating on declaration and type objects.
-
-}
- * is the type {@code O}, and the containing type of
- * {@code O} is the type {@code O
- * ?
- * ? extends Number
- * ? super T
- *
- *
- *
- * Selecting class declarations (including enums):
- *
- * result = FILTER_PUBLIC.filter(decls);
- * Selecting class declarations but excluding enums:
- *
- * classFilter = DeclarationFilter.getFilter(ClassDeclaration.class);
- * result = classFilter.filter(decls);
- * Selecting declarations named "Bob":
- *
- * enumFilter = DeclarationFilter.getFilter(EnumDeclaration.class);
- * compoundFilter = classFilter.and(enumFilter.not());
- * result = compoundFilter.filter(decls);
- *
- * @deprecated All components of this API have been superseded by the
- * standardized annotation processing API. The replacement for the
- * functionality of this class is {@link
- * javax.lang.model.util.ElementFilter}.
- *
- * @author Joseph D. Darcy
- * @author Scott Seligman
- * @since 1.5
- */
-@Deprecated
-@SuppressWarnings("deprecation")
-public class DeclarationFilter {
-
- // Predefined filters for convenience.
-
- /**
- * A filter that selects only public declarations.
- */
- public static final DeclarationFilter FILTER_PUBLIC =
- new AccessFilter(PUBLIC);
-
- /**
- * A filter that selects only protected declarations.
- */
- public static final DeclarationFilter FILTER_PROTECTED =
- new AccessFilter(PROTECTED);
-
- /**
- * A filter that selects only public or protected
- * declarations.
- */
- public static final DeclarationFilter FILTER_PUBLIC_OR_PROTECTED =
- new AccessFilter(PUBLIC, PROTECTED);
-
- /**
- * A filter that selects only package-private (default)
- * declarations.
- */
- public static final DeclarationFilter FILTER_PACKAGE =
- new AccessFilter();
-
- /**
- * A filter that selects only private declarations.
- */
- public static final DeclarationFilter FILTER_PRIVATE =
- new AccessFilter(PRIVATE);
-
-
- /**
- * Constructs an identity filter: one that selects all declarations.
- */
- public DeclarationFilter() {
- }
-
-
-
- // Methods to create a filter.
-
- /**
- * Returns a filter that selects declarations containing all of a
- * collection of modifiers.
- *
- * @param mods the modifiers to match (non-null)
- * @return a filter that matches declarations containing mods
- */
- public static DeclarationFilter getFilter(
- final Collection
- * nameFilter = new DeclarationFilter() {
- * public boolean matches(Declaration d) {
- * return d.getSimpleName().equals("Bob");
- * }
- * };
- * result = nameFilter.filter(decls);
- *
- *
- */
- static class AptTreeScanner extends TreeScanner {
-
- // Set of fully qualified names of annotation types present in
- // examined source
- private Set