KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > netbeans > modules > ruby > spi > project > support > rake > RakeBasedProjectType


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.ruby.spi.project.support.rake;
21
22 import java.io.IOException JavaDoc;
23 import org.netbeans.api.project.Project;
24
25 /**
26  * Plugin for an Ant project type.
27  * Register one instance to default lookup in order to define an Ant project type.
28  * @author Jesse Glick
29  */

30 public interface RakeBasedProjectType {
31
32     /**
33      * Get a unique type identifier for this kind of project.
34      * No two registered {@link RakeBasedProjectType} instances may share the same type.
35      * The type is stored in <code>nbproject/project.xml</code> in the <code>type</code> element.
36      * It is forbidden for the result of this method to change from call to call.
37      * @return the project type
38      */

39     String JavaDoc getType();
40     
41     /**
42      * Create the project object with a support class.
43      * Normally the project should retain a reference to the helper object in
44      * order to implement various required methods.
45      * Do <em>not</em> do any caching here; the infrastructure will call this
46      * method only when the project needs to be loaded into memory.
47      * @param helper a helper object encapsulating the generic project structure
48      * @return a project implementation
49      * @throws IOException if there is some problem loading additional data
50      */

51     Project createProject(RakeProjectHelper helper) throws IOException JavaDoc;
52     
53     /**
54      * Get the simple name of the XML element that should be used to store
55      * the project's specific configuration data in <code>nbproject/project.xml</code>
56      * (inside <code>&lt;configuration&gt;</code>) or <code>nbproject/private/private.xml</code>
57      * (inside <code>&lt;project-private&gt;</code>).
58      * It is forbidden for the result of this method to change from call to call.
59      * @param shared if true, refers to <code>project.xml</code>, else refers to
60      * <code>private.xml</code>
61      * @return a simple name; <samp>data</samp> is recommended but not required
62      */

63     String JavaDoc getPrimaryConfigurationDataElementName(boolean shared);
64     
65     /**
66      * Get the namespace of the XML element that should be used to store
67      * the project's specific configuration data in <code>nbproject/project.xml</code>
68      * (inside <code>&lt;configuration&gt;</code>) or <code>nbproject/private/private.xml</code>
69      * (inside <code>&lt;project-private&gt;</code>).
70      * It is forbidden for the result of this method to change from call to call.
71      * @param shared if true, refers to <code>project.xml</code>, else refers to
72      * <code>private.xml</code>
73      * @return an XML namespace, e.g. <samp>http://www.netbeans.org/ns/j2se-project</samp>
74      * or <samp>http://www.netbeans.org/ns/j2se-project-private</samp>
75      */

76     String JavaDoc getPrimaryConfigurationDataElementNamespace(boolean shared);
77
78 }
79
Popular Tags