1 19 20 package org.netbeans.modules.ruby.railsprojects; 21 22 import java.io.IOException ; 23 import org.netbeans.api.project.Project; 24 import org.netbeans.modules.ruby.spi.project.support.rake.RakeBasedProjectType; 25 import org.netbeans.modules.ruby.spi.project.support.rake.RakeProjectHelper; 26 27 31 public final class RailsProjectType implements RakeBasedProjectType { 32 33 public static final String TYPE = "org.netbeans.modules.ruby.railsprojects"; private static final String PROJECT_CONFIGURATION_NAME = "data"; public static final String PROJECT_CONFIGURATION_NAMESPACE = "http://www.netbeans.org/ns/rails-project/1"; private static final String PRIVATE_CONFIGURATION_NAME = "data"; private static final String PRIVATE_CONFIGURATION_NAMESPACE = "http://www.netbeans.org/ns/rails-project-private/1"; 39 40 public RailsProjectType() {} 41 42 public String getType() { 43 return TYPE; 44 } 45 46 public Project createProject(RakeProjectHelper helper) throws IOException { 47 return new RailsProject(helper); 48 } 49 50 public String getPrimaryConfigurationDataElementName(boolean shared) { 51 return shared ? PROJECT_CONFIGURATION_NAME : PRIVATE_CONFIGURATION_NAME; 52 } 53 54 public String getPrimaryConfigurationDataElementNamespace(boolean shared) { 55 return shared ? PROJECT_CONFIGURATION_NAMESPACE : PRIVATE_CONFIGURATION_NAMESPACE; 56 } 57 58 } 59 | Popular Tags |