org.mevenide.netbeans.j2ee
Class J2eeModuleProviderImpl

java.lang.Object
  extended by org.netbeans.modules.j2ee.deployment.devmodules.spi.J2eeModuleProvider
      extended by org.mevenide.netbeans.j2ee.J2eeModuleProviderImpl

public class J2eeModuleProviderImpl
extends org.netbeans.modules.j2ee.deployment.devmodules.spi.J2eeModuleProvider

implementatiomn of J2eeMoudleProvider that is used by the IDE for deployment of j2ee applications. the implementation is provided in the project's lookup.

Author:
Milos Kleint (mkleint@codehaus.org)

Nested Class Summary
 
Nested classes/interfaces inherited from class org.netbeans.modules.j2ee.deployment.devmodules.spi.J2eeModuleProvider
org.netbeans.modules.j2ee.deployment.devmodules.spi.J2eeModuleProvider.ConfigSupport
 
Field Summary
static java.lang.String SERVERID_PROPERTY
          property that stores the preferred server instanceid for deployment
 
Constructor Summary
J2eeModuleProviderImpl(org.mevenide.netbeans.api.project.MavenProject proj)
          Creates a new instance of J2eeModuleProviderImpl
 
Method Summary
 org.openide.filesystems.FileObject findDeploymentConfigurationFile(java.lang.String str)
          Finds source deployment configuration file object for the given deployment configuration file name.
 java.io.File getDeploymentConfigurationFile(java.lang.String str)
          Returns source deployment configuration file path for the given deployment configuration file name.
 java.lang.String getDeploymentName()
          Return name to be used in deployment of the module.
 org.netbeans.modules.j2ee.deployment.devmodules.api.J2eeModule getJ2eeModule()
           
 org.netbeans.modules.j2ee.deployment.devmodules.api.ModuleChangeReporter getModuleChangeReporter()
           
 java.lang.String getServerID()
          This method is used to determin type of target server.
 java.lang.String getServerInstanceID()
          Id of server isntance for deployment.
 org.openide.filesystems.FileObject[] getSourceRoots()
          Returns list of root directories for source files including configuration files.
 void setServerInstanceID(java.lang.String str)
           
 boolean useDefaultServer()
          If the module wants to specify a target server instance for deployment it needs to override this method to return false.
 
Methods inherited from class org.netbeans.modules.j2ee.deployment.devmodules.spi.J2eeModuleProvider
addConfigurationFilesListener, addInstanceListener, fireServerChange, getConfigSupport, getConfigurationFiles, getConfigurationFiles, getEnterpriseResourceDirectory, getInstanceProperties, getServerDebugInfo, getSourceFileMap, hasVerifierSupport, removeConfigurationFilesListener, removeInstanceListener, verify
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SERVERID_PROPERTY

public static final java.lang.String SERVERID_PROPERTY
property that stores the preferred server instanceid for deployment

See Also:
Constant Field Values
Constructor Detail

J2eeModuleProviderImpl

public J2eeModuleProviderImpl(org.mevenide.netbeans.api.project.MavenProject proj)
Creates a new instance of J2eeModuleProviderImpl

Method Detail

findDeploymentConfigurationFile

public org.openide.filesystems.FileObject findDeploymentConfigurationFile(java.lang.String str)
Finds source deployment configuration file object for the given deployment configuration file name.

Specified by:
findDeploymentConfigurationFile in class org.netbeans.modules.j2ee.deployment.devmodules.spi.J2eeModuleProvider
Parameters:
name - file name of the deployement configuration file.
Returns:
FileObject of the configuration descriptor file; null if the file does not exists.

getDeploymentConfigurationFile

public java.io.File getDeploymentConfigurationFile(java.lang.String str)
Returns source deployment configuration file path for the given deployment configuration file name.

Specified by:
getDeploymentConfigurationFile in class org.netbeans.modules.j2ee.deployment.devmodules.spi.J2eeModuleProvider
Parameters:
name - file name of the deployement configuration file.
Returns:
non-null absolute path to the deployment configuration file.

getJ2eeModule

public org.netbeans.modules.j2ee.deployment.devmodules.api.J2eeModule getJ2eeModule()
Specified by:
getJ2eeModule in class org.netbeans.modules.j2ee.deployment.devmodules.spi.J2eeModuleProvider

getModuleChangeReporter

public org.netbeans.modules.j2ee.deployment.devmodules.api.ModuleChangeReporter getModuleChangeReporter()
Specified by:
getModuleChangeReporter in class org.netbeans.modules.j2ee.deployment.devmodules.spi.J2eeModuleProvider

getSourceRoots

public org.openide.filesystems.FileObject[] getSourceRoots()
Returns list of root directories for source files including configuration files. Examples: file objects for src/java, src/conf. Note: If there is a standard configuration root, it should be the first one in the returned list.

Overrides:
getSourceRoots in class org.netbeans.modules.j2ee.deployment.devmodules.spi.J2eeModuleProvider

getDeploymentName

public java.lang.String getDeploymentName()
Return name to be used in deployment of the module.

Overrides:
getDeploymentName in class org.netbeans.modules.j2ee.deployment.devmodules.spi.J2eeModuleProvider

setServerInstanceID

public void setServerInstanceID(java.lang.String str)
Specified by:
setServerInstanceID in class org.netbeans.modules.j2ee.deployment.devmodules.spi.J2eeModuleProvider

useDefaultServer

public boolean useDefaultServer()
If the module wants to specify a target server instance for deployment it needs to override this method to return false.

Overrides:
useDefaultServer in class org.netbeans.modules.j2ee.deployment.devmodules.spi.J2eeModuleProvider

getServerInstanceID

public java.lang.String getServerInstanceID()
Id of server isntance for deployment. The default implementation returns the default server instance selected in Server Registry. The return value may not be null. If modules override this method they also need to override useDefaultServer.

Overrides:
getServerInstanceID in class org.netbeans.modules.j2ee.deployment.devmodules.spi.J2eeModuleProvider

getServerID

public java.lang.String getServerID()
This method is used to determin type of target server. The return value must correspond to value returned from getServerInstanceID.

Overrides:
getServerID in class org.netbeans.modules.j2ee.deployment.devmodules.spi.J2eeModuleProvider


Copyright © 2005 The Codehaus. All Rights Reserved.