站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > NetBeans API Javadoc 5.0.0

AntBasedProjectType (NetBeans Ant Project API) - NetBeans API Javadoc 5.0.0

 

org.netbeans.spi.project.support.ant
Interface AntBasedProjectType


public interface AntBasedProjectType

Plugin for an Ant project type. Register one instance to default lookup in order to define an Ant project type.


Method Summary
 Project createProject(AntProjectHelper helper)
          Create the project object with a support class.
 String getPrimaryConfigurationDataElementName(boolean shared)
          Get the simple name of the XML element that should be used to store the project's specific configuration data in nbproject/project.xml (inside <configuration>) or nbproject/private/private.xml (inside <project-private>).
 String getPrimaryConfigurationDataElementNamespace(boolean shared)
          Get the namespace of the XML element that should be used to store the project's specific configuration data in nbproject/project.xml (inside <configuration>) or nbproject/private/private.xml (inside <project-private>).
 String getType()
          Get a unique type identifier for this kind of project.
 

Method Detail

getType

public String getType()
Get a unique type identifier for this kind of project. No two registered AntBasedProjectType instances may share the same type. The type is stored in nbproject/project.xml in the type element. It is forbidden for the result of this method to change from call to call.

Returns:
the project type

createProject

public Project createProject(AntProjectHelper helper)
                      throws IOException
Create the project object with a support class. Normally the project should retain a reference to the helper object in order to implement various required methods. Do not do any caching here; the infrastructure will call this method only when the project needs to be loaded into memory.

Parameters:
helper - a helper object encapsulating the generic project structure
Returns:
a project implementation
Throws:
IOException - if there is some problem loading additional data

getPrimaryConfigurationDataElementName

public String getPrimaryConfigurationDataElementName(boolean shared)
Get the simple name of the XML element that should be used to store the project's specific configuration data in nbproject/project.xml (inside <configuration>) or nbproject/private/private.xml (inside <project-private>). It is forbidden for the result of this method to change from call to call.

Parameters:
shared - if true, refers to project.xml, else refers to private.xml
Returns:
a simple name; data is recommended but not required

getPrimaryConfigurationDataElementNamespace

public String getPrimaryConfigurationDataElementNamespace(boolean shared)
Get the namespace of the XML element that should be used to store the project's specific configuration data in nbproject/project.xml (inside <configuration>) or nbproject/private/private.xml (inside <project-private>). It is forbidden for the result of this method to change from call to call.

Parameters:
shared - if true, refers to project.xml, else refers to private.xml
Returns:
an XML namespace, e.g. http://www.netbeans.org/ns/j2se-project or http://www.netbeans.org/ns/j2se-project-private

 

Built on May 3 2007.  |  Portions Copyright 1997-2005 Sun Microsystems, Inc. All rights reserved.