KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > netbeans > modules > apisupport > project > universe > ModuleEntry


1 /*
2  * The contents of this file are subject to the terms of the Common Development
3  * and Distribution License (the License). You may not use this file except in
4  * compliance with the License.
5  *
6  * You can obtain a copy of the License at http://www.netbeans.org/cddl.html
7  * or http://www.netbeans.org/cddl.txt.
8  *
9  * When distributing Covered Code, include this CDDL Header Notice in each file
10  * and include the License file at http://www.netbeans.org/cddl.txt.
11  * If applicable, add the following below the CDDL Header, with the fields
12  * enclosed by brackets [] replaced by your own identifying information:
13  * "Portions Copyrighted [year] [name of copyright owner]"
14  *
15  * The Original Software is NetBeans. The Initial Developer of the Original
16  * Software is Sun Microsystems, Inc. Portions Copyright 1997-2006 Sun
17  * Microsystems, Inc. All Rights Reserved.
18  */

19
20 package org.netbeans.modules.apisupport.project.universe;
21
22 import java.io.File JavaDoc;
23 import java.util.Set JavaDoc;
24 import org.netbeans.modules.apisupport.project.ManifestManager;
25
26 /**
27  * One known module.
28  * Falls into four categories:
29  * <ol>
30  * <li>Modules inside netbeans.org (with source).
31  * <li>Modules with source in an external suite.
32  * <li>Standalone external modules with source.
33  * <li>JARs from a NB binary. May or may not have an associated source dir.
34  * </ol>
35  */

36 public interface ModuleEntry extends Comparable JavaDoc {
37
38     /**
39      * Get a relative source path inside netbeans.org CVS.
40      * Note that if the entry is from netbeans.org CVS yet was scanned as a
41      * side effect of loading an external module that defined netbeans.dest.dir,
42      * this will be null - such secondary entries are essentially based on the
43      * actual JAR, only adding in a non-null {@link #getSourceLocation}.
44      * @return e.g. java/project, or null for external modules
45      */

46     String JavaDoc getNetBeansOrgPath();
47     
48     /**
49      * Get the source location of this module, if there is one.
50      */

51     File JavaDoc getSourceLocation();
52     
53     /**
54      * Get a code name base.
55      * @return e.g. org.netbeans.modules.java.project
56      */

57     String JavaDoc getCodeNameBase();
58     
59     /**
60      * Get the directory to which the module is built.
61      * @return e.g. .../nbbuild/netbeans/ide6
62      */

63     File JavaDoc getClusterDirectory();
64     
65     /**
66      * Get the module JAR file.
67      * @return e.g. .../nbbuild/netbeans/ide6/modules/org-netbeans-modules-java-project.jar
68      */

69     File JavaDoc getJarLocation();
70     
71     /**
72      * Get any added class path entries, as a path suffix (may be empty).
73      */

74     String JavaDoc getClassPathExtensions();
75     
76     /**
77      * Path which resolves to the root of the NetBeans binary installation used for this module.
78      */

79     File JavaDoc getDestDir();
80     
81     /**
82      * Returns either the module release version or <code>null</code> if
83      * there isn't any.
84      */

85     String JavaDoc getReleaseVersion();
86     
87     /**
88      * Returns either the module specification version or <code>null</code>
89      * if there isn't any.
90      */

91     String JavaDoc getSpecificationVersion();
92     
93     /**
94      * Returns array of provided tokens by the module. Can be empty.
95      */

96     String JavaDoc[] getProvidedTokens();
97     
98     /**
99      * Get localized name of this module. Implementations should use
100      * lazy-loading from localizing bundle to keep performance up. If the
101      * localized name is not found <code>getCodeNameBase()</code> is
102      * returned.
103      */

104     String JavaDoc getLocalizedName();
105     
106     /**
107      * Get category of this module. Implementations should use lazy-loading
108      * from localizing bundle to keep performance up.
109      */

110     String JavaDoc getCategory();
111     
112     /**
113      * Get long description of this module. Implementations should use
114      * lazy-loading from localizing bundle to keep performance up.
115      */

116     String JavaDoc getLongDescription();
117     
118     /**
119      * Get short description of this module. Implementations should use
120      * lazy-loading from localizing bundle to keep performance up.
121      */

122     String JavaDoc getShortDescription();
123     
124     /**
125      * Get array of public packages exported by this module entry.
126      * @return array of public packages. May be empty but not <code>null</code>.
127      */

128     ManifestManager.PackageExport[] getPublicPackages();
129     
130     /**
131      * Get a set of names of all <em>nonempty</em> packages this module
132      * contains.
133      */

134     Set JavaDoc<String JavaDoc> getAllPackageNames();
135     
136     /**
137      * Get array of friends of this module.
138      */

139     boolean isDeclaredAsFriend(String JavaDoc cnb);
140     
141     /**
142      * Get a set of class names defined in this module's public packages.
143      */

144     Set JavaDoc<String JavaDoc> getPublicClassNames();
145     
146     /**
147      * Check whether this module is marked as deprecated.
148      */

149     boolean isDeprecated();
150
151     /**
152      * Get a list of code name bases for modules which this module has (runtime) dependencies on.
153      */

154     String JavaDoc[] getRunDependencies();
155
156 }
157
Popular Tags