blob: 85c5d2b3942ecb8632170df078b6b48cab338937 [file] [log] [blame]
/*******************************************************************************
* Copyright (c) 2005, 2007 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.j2ee.internal.project.facet;
import org.eclipse.jst.j2ee.internal.plugin.IJ2EEModuleConstants;
import org.eclipse.jst.j2ee.project.facet.IUtilityFacetInstallDataModelProperties;
import org.eclipse.jst.j2ee.project.facet.J2EEModuleFacetInstallDataModelProvider;
import org.eclipse.wst.common.project.facet.core.IProjectFacetVersion;
public class UtilityFacetInstallDataModelProvider extends J2EEModuleFacetInstallDataModelProvider implements IUtilityFacetInstallDataModelProperties {
public UtilityFacetInstallDataModelProvider()
{
super();
}
public Object getDefaultProperty(String propertyName) {
if (FACET_ID.equals(propertyName)) {
return UTILITY;
} else if (propertyName.equals(MODULE_URI)) {
String projectName = model.getStringProperty(FACET_PROJECT_NAME).replace(' ', '_');
return projectName + IJ2EEModuleConstants.JAR_EXT;
}
return super.getDefaultProperty(propertyName);
}
protected int convertFacetVersionToJ2EEVersion(IProjectFacetVersion version) {
return 0;
}
}