langtools/src/jdk.javadoc/share/classes/com/sun/tools/doclets/internal/toolkit/util/Utils.java
changeset 38617 d93a7f64e231
parent 36526 3b41f1c69604
equal deleted inserted replaced
38616:31e503b8ea65 38617:d93a7f64e231
    31 import java.lang.annotation.Target;
    31 import java.lang.annotation.Target;
    32 import java.text.Collator;
    32 import java.text.Collator;
    33 import java.util.*;
    33 import java.util.*;
    34 
    34 
    35 import javax.tools.JavaFileManager.Location;
    35 import javax.tools.JavaFileManager.Location;
    36 import javax.tools.StandardLocation;
       
    37 
    36 
    38 import com.sun.javadoc.*;
    37 import com.sun.javadoc.*;
    39 import com.sun.javadoc.AnnotationDesc.ElementValuePair;
       
    40 import com.sun.tools.doclets.internal.toolkit.*;
    38 import com.sun.tools.doclets.internal.toolkit.*;
    41 import com.sun.tools.javac.util.StringUtils;
    39 import com.sun.tools.javac.util.StringUtils;
    42 
    40 
    43 /**
    41 /**
    44  * Utilities Class for Doclets.
    42  * Utilities Class for Doclets.
    49  *  deletion without notice.</b>
    47  *  deletion without notice.</b>
    50  *
    48  *
    51  * @author Atul M Dambalkar
    49  * @author Atul M Dambalkar
    52  * @author Jamie Ho
    50  * @author Jamie Ho
    53  */
    51  */
       
    52 @Deprecated
    54 public class Utils {
    53 public class Utils {
    55     /**
    54     /**
    56      * Return array of class members whose documentation is to be generated.
    55      * Return array of class members whose documentation is to be generated.
    57      * If the member is deprecated do not include such a member in the
    56      * If the member is deprecated do not include such a member in the
    58      * returned array.
    57      * returned array.
   443         return false;
   442         return false;
   444     }
   443     }
   445 
   444 
   446     private boolean isDeclarationTarget(AnnotationDesc targetAnno) {
   445     private boolean isDeclarationTarget(AnnotationDesc targetAnno) {
   447         // The error recovery steps here are analogous to TypeAnnotations
   446         // The error recovery steps here are analogous to TypeAnnotations
   448         ElementValuePair[] elems = targetAnno.elementValues();
   447         AnnotationDesc.ElementValuePair[] elems = targetAnno.elementValues();
   449         if (elems == null
   448         if (elems == null
   450             || elems.length != 1
   449             || elems.length != 1
   451             || !"value".equals(elems[0].element().name())
   450             || !"value".equals(elems[0].element().name())
   452             || !(elems[0].value().value() instanceof AnnotationValue[]))
   451             || !(elems[0].value().value() instanceof AnnotationValue[]))
   453             return true;    // error recovery
   452             return true;    // error recovery