1/*
2 * Copyright (c) 1998, 2014, Oracle and/or its affiliates. All rights reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * This code is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License version 2 only, as
7 * published by the Free Software Foundation.  Oracle designates this
8 * particular file as subject to the "Classpath" exception as provided
9 * by Oracle in the LICENSE file that accompanied this code.
10 *
11 * This code is distributed in the hope that it will be useful, but WITHOUT
12 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
14 * version 2 for more details (a copy is included in the LICENSE file that
15 * accompanied this code).
16 *
17 * You should have received a copy of the GNU General Public License version
18 * 2 along with this work; if not, write to the Free Software Foundation,
19 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
20 *
21 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
22 * or visit www.oracle.com if you need additional information or have any
23 * questions.
24 */
25
26package com.sun.javadoc;
27
28/**
29 * Represents a java package.  Provides access to information
30 * about the package, the package's comment and tags, and the
31 * classes in the package.
32 * <p>
33 * Each method whose return type is an array will return an empty
34 * array (never null) when there are no objects in the result.
35 *
36 * @since 1.2
37 * @author Kaiyang Liu (original)
38 * @author Robert Field (rewrite)
39 *
40 * @deprecated
41 *   The declarations in this package have been superseded by those
42 *   in the package {@code jdk.javadoc.doclet}.
43 *   For more information, see the <i>Migration Guide</i> in the documentation for that package.
44 */
45@Deprecated
46public interface PackageDoc extends Doc {
47
48    /**
49     * Get all classes and interfaces in the package, filtered to the specified
50     * <a href="{@docRoot}/com/sun/javadoc/package-summary.html#included">access
51     * modifier option</a>.
52     *
53     * @return       filtered classes and interfaces in this package
54     * @param filter Specifying true filters according to the specified access
55     *               modifier option.
56     *               Specifying false includes all classes and interfaces
57     *               regardless of access modifier option.
58     * @since 1.4
59     */
60    ClassDoc[] allClasses(boolean filter);
61
62    /**
63     * Get all
64     * <a href="{@docRoot}/com/sun/javadoc/package-summary.html#included">included</a>
65     * classes and interfaces in the package.  Same as allClasses(true).
66     *
67     * @return all included classes and interfaces in this package.
68     */
69    ClassDoc[] allClasses();
70
71    /**
72     * Get included
73     * <a href="{@docRoot}/com/sun/javadoc/package-summary.html#class">ordinary</a>
74     * classes (that is, exclude exceptions, errors, enums, interfaces, and
75     * annotation types)
76     * in this package.
77     *
78     * @return included ordinary classes in this package.
79     */
80    ClassDoc[] ordinaryClasses();
81
82    /**
83     * Get included Exception classes in this package.
84     *
85     * @return included Exceptions in this package.
86     */
87    ClassDoc[] exceptions();
88
89    /**
90     * Get included Error classes in this package.
91     *
92     * @return included Errors in this package.
93     */
94    ClassDoc[] errors();
95
96    /**
97     * Get included enum types in this package.
98     *
99     * @return included enum types in this package.
100     * @since 1.5
101     */
102    ClassDoc[] enums();
103
104    /**
105     * Get included interfaces in this package, omitting annotation types.
106     *
107     * @return included interfaces in this package.
108     */
109    ClassDoc[] interfaces();
110
111    /**
112     * Get included annotation types in this package.
113     *
114     * @return included annotation types in this package.
115     * @since 1.5
116     */
117    AnnotationTypeDoc[] annotationTypes();
118
119    /**
120     * Get the annotations of this package.
121     * Return an empty array if there are none.
122     *
123     * @return the annotations of this package.
124     * @since 1.5
125     */
126    AnnotationDesc[] annotations();
127
128    /**
129     * Lookup a class or interface within this package.
130     *
131     * @param className A String containing the name of the class to look up.
132     * @return ClassDoc of found class or interface,
133     * or null if not found.
134     */
135    ClassDoc findClass(String className);
136}
137