|
org.netbeans.api.web.webmodule 1.9 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.netbeans.modules.web.api.webmodule.WebModule
public final class WebModule
This class encapsulates a web module.
A client may obtain a WebModule
instance using
method getWebModule(org.openide.filesystems.FileObject)
, for any
FileObject
in the web module directory structure.
Use the classpath API to obtain the classpath for the document base (this classpath is used for code completion of JSPs). An example:
WebModule wm = ...; FileObject docRoot = wm.getDocumentBase (); ClassPath cp = ClassPath.getClassPath(docRoot, ClassPath.EXECUTE);
Note that no particular directory structure for web module is guaranteed by this API.
Field Summary | |
---|---|
static String |
J2EE_13_LEVEL
|
static String |
J2EE_14_LEVEL
|
static String |
JAVA_EE_5_LEVEL
|
Method Summary | |
---|---|
boolean |
equals(Object obj)
|
String |
getContextPath()
Returns the context path of the web module. |
org.openide.filesystems.FileObject |
getDeploymentDescriptor()
Returns the deployment descriptor ( web.xml file) of the web module. |
org.openide.filesystems.FileObject |
getDocumentBase()
Returns the folder that contains sources of the static documents for the web module (html, JSPs, etc.). |
String |
getJ2eePlatformVersion()
Returns the J2EE platform version of this module. |
org.openide.filesystems.FileObject[] |
getJavaSources()
Deprecated. This method is deprecated, because its return values does not contain enough information about the source roots. Source roots are usually implemented by a org.netbeans.api.project.SourceGroup ,
which is more than just a container for a FileObject . |
org.netbeans.modules.j2ee.metadata.model.api.MetadataModel<org.netbeans.modules.j2ee.dd.api.web.WebAppMetadata> |
getMetadataModel()
Returns a model describing the metadata of this web module (servlets, resources, etc.). |
org.openide.filesystems.FileObject |
getWebInf()
Returns the WEB-INF folder for the web module. |
static WebModule |
getWebModule(org.openide.filesystems.FileObject file)
Finds the web module for the given file. |
int |
hashCode()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String J2EE_13_LEVEL
public static final String J2EE_14_LEVEL
public static final String JAVA_EE_5_LEVEL
Method Detail |
---|
public static WebModule getWebModule(org.openide.filesystems.FileObject file)
file
- the file to find the web module for.
NullPointerException
- if the file
parameter is null.public org.openide.filesystems.FileObject getDocumentBase()
public org.openide.filesystems.FileObject getWebInf()
The WEB-INF folder would typically be a child of the folder returned
by getDocumentBase()
but does not need to be.
public org.openide.filesystems.FileObject getDeploymentDescriptor()
web.xml
file) of the web module.
getWebInf()
but does not need to be.
web.xml
file; can be null.public String getContextPath()
public String getJ2eePlatformVersion()
J2EE_13_LEVEL
, J2EE_14_LEVEL
or
JAVA_EE_5_LEVEL
.
@Deprecated public org.openide.filesystems.FileObject[] getJavaSources()
org.netbeans.api.project.SourceGroup
,
which is more than just a container for a FileObject
.
Note that not all the java source roots in the project (e.g. in a freeform project) belong to the web module.
public org.netbeans.modules.j2ee.metadata.model.api.MetadataModel<org.netbeans.modules.j2ee.dd.api.web.WebAppMetadata> getMetadataModel()
public boolean equals(Object obj)
equals
in class Object
public int hashCode()
hashCode
in class Object
|
org.netbeans.api.web.webmodule 1.9 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |