Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration')
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryConfigurationHelper.java89
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryReference.java52
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryReferencePluginProvided.java25
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryReferenceServerSupplied.java29
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryReferenceUserDefined.java20
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryReferenceUserSpecified.java23
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFVersion.java39
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/AbstractJSFLibraryReferenceImpl.java158
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/JSFLibraryReferenceFacadeFactory.java77
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/JSFLibraryReferencePluginProvidedImpl.java44
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/JSFLibraryReferenceServerSuppliedImpl.java53
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/JSFLibraryReferenceUserSpecifiedImpl.java42
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/Messages.java33
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/messages.properties1
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/package-info.java18
15 files changed, 0 insertions, 703 deletions
diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryConfigurationHelper.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryConfigurationHelper.java
deleted file mode 100644
index 2f677d793..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryConfigurationHelper.java
+++ /dev/null
@@ -1,89 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.core.jsflibraryconfiguration;
-
-import java.util.Collection;
-import java.util.HashSet;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.jdt.core.IClasspathEntry;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.core.JavaModelException;
-import org.eclipse.jst.jsf.core.internal.JSFCorePlugin;
-import org.eclipse.jst.jsf.core.jsflibraryconfiguration.internal.JSFLibraryReferenceFacadeFactory;
-
-/**
- * Helper class for adopters needing to deal with JSF Library References
- *
- * <p><b>Provisional API - subject to change</b></p>
- * @since WTP JSF 1.0
- * @deprecated
- */
-public final class JSFLibraryConfigurationHelper {
- /**
- * container id for JSF Library Classpath Containers
- */
- public static final String JSF_LIBRARY_CP_CONTAINER_ID="org.eclipse.jst.jsf.core.internal.jsflibrarycontainer"; //$NON-NLS-1$
-
- /**
- * @param project
- * @return collection of references
- */
- public static Collection<JSFLibraryReference> getJSFLibraryReferences(IProject project) {
- Collection<JSFLibraryReference> results = new HashSet<JSFLibraryReference>();
- IJavaProject jproj = JavaCore.create(project);
- try {
- IClasspathEntry[] entries = jproj.getRawClasspath();
- boolean foundImpl = false;
- for (int i=0;i<entries.length;i++){
- JSFLibraryReference ref = JSFLibraryReferenceFacadeFactory.create(entries[i]);
- if (ref != null){
- results.add(ref);
- if (ref.isJSFImplementation())
- foundImpl = true;
- }
- }
- if (! foundImpl){
- results.add(JSFLibraryReferenceFacadeFactory.createServerSuppliedJSFLibRef());
- }
- } catch (JavaModelException e) {
- JSFCorePlugin.log(e, "Exception occurred calling getJSFLibraryReferences for "+project.getName()); //$NON-NLS-1$
- }
- return results;
- }
-
- /**
- * @param cpEntry
- * @return boolean indicating that the classpath entry is a JSF Libary Classpath Container
- */
- public static boolean isJSFLibraryContainer(IClasspathEntry cpEntry) {
- if (cpEntry.getEntryKind() != IClasspathEntry.CPE_CONTAINER)
- return false;
-
- IPath path = cpEntry.getPath();
- return path != null && path.segmentCount() == 2 && JSF_LIBRARY_CP_CONTAINER_ID.equals(path.segment(0));
- }
-
- /**
- * @param project
- * @return true if the JSF Faceted project is configured to use system supplied implementation
- */
- public static boolean isConfiguredForSystemSuppliedImplementation(IProject project) {
- Collection<JSFLibraryReference> refs = getJSFLibraryReferences(project);
- for(JSFLibraryReference ref : refs){
- if (ref instanceof JSFLibraryReferenceServerSupplied)
- return true;
- }
- return false;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryReference.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryReference.java
deleted file mode 100644
index 17fe475aa..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryReference.java
+++ /dev/null
@@ -1,52 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.core.jsflibraryconfiguration;
-
-import java.util.Collection;
-
-import org.eclipse.jdt.core.IClasspathEntry;
-
-/**
- * Represents a reference to a JSF Library on a project
- *
- * <p><b>Provisional API - subject to change</b></p>
- * @deprecated
- */
-public abstract interface JSFLibraryReference {
- /**
- * @return id for the library
- */
- public String getId();
- /**
- * @return name
- */
- public String getName();
- /**
- * @return collection of jars as {@link IClasspathEntry}s
- */
- public Collection<IClasspathEntry> getJars();
- /**
- * @return {@link JSFVersion} value
- */
- public JSFVersion getMaxSupportedVersion();
- /**
- * @return label user sees for this library
- */
- public String getLabel();
- /**
- * @return flag
- */
- public boolean isJSFImplementation();
- /**
- * @return is deployed (marked as J2EE Module Dependency)
- */
- public boolean isDeployed();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryReferencePluginProvided.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryReferencePluginProvided.java
deleted file mode 100644
index 8535cef57..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryReferencePluginProvided.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.core.jsflibraryconfiguration;
-
-/**
- * A reference to a plugin-defined JSF Library
- *
- * <p><b>Provisional API - subject to change</b></p>
- *
- * @deprecated
- */
-public interface JSFLibraryReferencePluginProvided extends JSFLibraryReferenceUserSpecified, JSFLibraryReferenceUserDefined {
- /**
- * @return plugin id. May return null if plugin id cannot be determined.
- */
- public String getPluginId();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryReferenceServerSupplied.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryReferenceServerSupplied.java
deleted file mode 100644
index 2ee576b4a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryReferenceServerSupplied.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.core.jsflibraryconfiguration;
-
-/**
- * A reference to a JSF Library where the implementation library is presumed to be coming from the
- * server
- *
- * <p><b>Provisional API - subject to change</b></p>
- *
- * @deprecated
- */
-public interface JSFLibraryReferenceServerSupplied extends
- JSFLibraryReference {
-
- /**
- * Constant used for server supplied virtual JSF Library referencew
- */
- public static final String ID = "_ServerSupplied_"; //$NON-NLS-1$
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryReferenceUserDefined.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryReferenceUserDefined.java
deleted file mode 100644
index f5e69d373..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryReferenceUserDefined.java
+++ /dev/null
@@ -1,20 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.core.jsflibraryconfiguration;
-
-
-/**
- * Represents an reference to a user specified JSF Library
- * @deprecated use JSFLibraryReferenceUserSpecified
- */
-public interface JSFLibraryReferenceUserDefined extends JSFLibraryReference {
- //
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryReferenceUserSpecified.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryReferenceUserSpecified.java
deleted file mode 100644
index a65cbab44..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFLibraryReferenceUserSpecified.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.core.jsflibraryconfiguration;
-
-
-/**
- * Represents an reference to a user specified JSF Library
- *
- * <p><b>Provisional API - subject to change</b></p>
- *
- * @deprecated
- */
-public interface JSFLibraryReferenceUserSpecified extends JSFLibraryReference {
- //
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFVersion.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFVersion.java
deleted file mode 100644
index 244f00c19..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/JSFVersion.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.core.jsflibraryconfiguration;
-
-/**
- * Enumeration of JavaServer Faces Versions
- *
- * <p><b>Provisional API - subject to change</b></p>
- *
- * @deprecated
- */
-public enum JSFVersion {
-
- /**
- * Unknown version support
- */
- UNKNOWN,
- /**
- * Supports JSF Version 1.0
- */
- V1_0,
- /**
- * Supports JSF Version 1.1
- */
- V1_1,
- /**
- * Supports JSF Version 1.1
- */
- V1_2;
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/AbstractJSFLibraryReferenceImpl.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/AbstractJSFLibraryReferenceImpl.java
deleted file mode 100644
index 7251d44e6..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/AbstractJSFLibraryReferenceImpl.java
+++ /dev/null
@@ -1,158 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.core.jsflibraryconfiguration.internal;
-
-
-
-
-import java.util.Collection;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Set;
-
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jdt.core.IClasspathEntry;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryInternalReference;
-import org.eclipse.jst.jsf.core.internal.jsflibraryregistry.ArchiveFile;
-import org.eclipse.jst.jsf.core.internal.jsflibraryregistry.JSFLibrary;
-import org.eclipse.jst.jsf.core.jsflibraryconfiguration.JSFLibraryReference;
-import org.eclipse.jst.jsf.core.jsflibraryconfiguration.JSFVersion;
-/**
- * @author gekessle
- * @deprecated
- */
-public abstract class AbstractJSFLibraryReferenceImpl implements JSFLibraryReference {
-
- /**
- * The {@link org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryInternalReference} being wrapped
- */
- protected JSFLibraryInternalReference libRef;
- private String _id;
- private String _label;
- private boolean _isImplementation;
- private boolean _isDeloyed;
-
- /**
- * Constructor for "virtual" JSF Library References like "ServerSupplied"
- * @param id
- * @param label
- * @param isImplementation
- */
- public AbstractJSFLibraryReferenceImpl(String id, String label, boolean isImplementation){
- _id = id;
- _label = label;
- _isImplementation = isImplementation;
- }
-
- /**
- * Constructor non-virtual library references
- * @param libRef
- * @param isDeployed
- */
- public AbstractJSFLibraryReferenceImpl(JSFLibraryInternalReference libRef, boolean isDeployed){
- this.libRef = libRef;
- _isDeloyed = isDeployed;
- }
-
- public String getId() {
- if (libRef != null)
- return libRef.getID();
-
- return _id;
- }
-
- public String getLabel() {
- if (libRef != null)
- return libRef.getLabel();
-
- return _label;
- }
-
- public boolean isDeployed() {
- return _isDeloyed;
- }
-
- public boolean isJSFImplementation() {
- if (libRef != null)
- return libRef.isImplementation();
-
- return _isImplementation;
- }
-
- /**
- * @return the JSFLibrary underpinning the reference.
- * May be null if the library is missing or cannot be resolved from the registry.
- */
- protected JSFLibrary getLibrary(){
- return libRef.getLibrary();
- }
-
- public Collection<IClasspathEntry> getJars() {
- Set<IClasspathEntry> results = new HashSet<IClasspathEntry>();
- if (getLibrary() != null){
- List jars = getLibrary().getArchiveFiles();
- for (Iterator it= jars.iterator();it.hasNext();){
- ArchiveFile jar = (ArchiveFile)it.next();
- String path = jar.getResolvedSourceLocation();
- results.add(JavaCore.newLibraryEntry(new Path(path), null, null));
- }
- }
- return results;
- }
-
- public JSFVersion getMaxSupportedVersion() {
- if (getLibrary() != null)
- return adaptVersion(getLibrary().getJSFVersion());
- return null;
- }
-
- private JSFVersion adaptVersion(
- org.eclipse.jst.jsf.core.internal.jsflibraryregistry.JSFVersion version) {
-
- switch (version.getValue()){
- case org.eclipse.jst.jsf.core.internal.jsflibraryregistry.JSFVersion.V1_1:
- return JSFVersion.V1_1;
- case org.eclipse.jst.jsf.core.internal.jsflibraryregistry.JSFVersion.V1_2:
- return JSFVersion.V1_2;
- default:
- return JSFVersion.UNKNOWN;
-
- }
- }
-
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.jsf.core.jsflibraryconfiguration.JSFLibraryReference#getName()
- */
- public String getName() {
- if (getLibrary()!= null) {
- return getLibrary().getName();
- }
- return getId();
- }
-
- public String toString(){
- StringBuffer buf = new StringBuffer("id: "); //$NON-NLS-1$
- buf.append(getId());
- buf.append(", label: "); //$NON-NLS-1$
- buf.append(getLabel());
- buf.append(", isDeployed: "); //$NON-NLS-1$
- buf.append(isDeployed());
- buf.append(", isImpl: "); //$NON-NLS-1$
- buf.append(isJSFImplementation());
- buf.append(", version: "); //$NON-NLS-1$
- buf.append(getMaxSupportedVersion().name());
-
- return buf.toString();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/JSFLibraryReferenceFacadeFactory.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/JSFLibraryReferenceFacadeFactory.java
deleted file mode 100644
index 5205610b1..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/JSFLibraryReferenceFacadeFactory.java
+++ /dev/null
@@ -1,77 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.core.jsflibraryconfiguration.internal;
-
-import org.eclipse.jdt.core.IClasspathAttribute;
-import org.eclipse.jdt.core.IClasspathEntry;
-import org.eclipse.jst.j2ee.classpathdep.IClasspathDependencyConstants;
-import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryRegistryUtil;
-import org.eclipse.jst.jsf.core.internal.jsflibraryregistry.PluginProvidedJSFLibrary;
-import org.eclipse.jst.jsf.core.jsflibraryconfiguration.JSFLibraryConfigurationHelper;
-import org.eclipse.jst.jsf.core.jsflibraryconfiguration.JSFLibraryReference;
-import org.eclipse.jst.jsf.core.jsflibraryconfiguration.JSFLibraryReferenceServerSupplied;
-
-/**
- * Factory for producing facade objects for references to the internal EMF JSF Library classes
- * @deprecated
- */
-public class JSFLibraryReferenceFacadeFactory {
- /**
- * Returns a JSFLibraryReferenceUserSpecified (or JSFLibraryReferenceUserDefined}) or JSFLibraryReferencePluginProvided instance.
- * Will not create a JSFLibraryReferenceServerSupplied as there is no cp entry. Use createServerSuppliedJSFLibRef instead.
- * @param classpathEntry
- * @return an instance of JSFLibraryInternalReference. Null will be returned if the cpEntry is not a JSF Library reference.
- */
- public static JSFLibraryReference create(final IClasspathEntry classpathEntry) {
- if (JSFLibraryConfigurationHelper.isJSFLibraryContainer(classpathEntry)){
- return createReference(classpathEntry);
- }
- return null;
- }
-
- /**
- * @return instance of {@link JSFLibraryReferenceServerSupplied}
- */
- public static JSFLibraryReferenceServerSupplied createServerSuppliedJSFLibRef(){
- return new JSFLibraryReferenceServerSuppliedImpl();
- }
-
-
- /**
- * @param classpathEntry
- * @return {@link JSFLibraryReference}
- */
- private static JSFLibraryReference createReference(
- final IClasspathEntry classpathEntry) {
-
- String libID = classpathEntry.getPath().segment(1);
- org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryInternalReference libRef = JSFLibraryRegistryUtil.getInstance().getJSFLibraryReferencebyID(libID);
- if (libRef!= null){
- boolean isDeployed = getJ2EEModuleDependency(classpathEntry);
- if (libRef.getLibrary() instanceof PluginProvidedJSFLibrary)
- return new JSFLibraryReferencePluginProvidedImpl(libRef, isDeployed);
-
- return new JSFLibraryReferenceUserSpecifiedImpl(libRef, isDeployed);
- }
- return null;
- }
-
- private static boolean getJ2EEModuleDependency(IClasspathEntry classpathEntry) {
- IClasspathAttribute[] attrs = classpathEntry.getExtraAttributes();
- for (int i=0;i<attrs.length;i++){
- IClasspathAttribute attr = attrs[i];
- if (attr.getName().equals(IClasspathDependencyConstants.CLASSPATH_COMPONENT_DEPENDENCY)){
- return true;
- }
- }
- return false;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/JSFLibraryReferencePluginProvidedImpl.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/JSFLibraryReferencePluginProvidedImpl.java
deleted file mode 100644
index 426ad89c5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/JSFLibraryReferencePluginProvidedImpl.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.core.jsflibraryconfiguration.internal;
-
-import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryInternalReference;
-import org.eclipse.jst.jsf.core.internal.jsflibraryregistry.PluginProvidedJSFLibrary;
-import org.eclipse.jst.jsf.core.jsflibraryconfiguration.JSFLibraryReferencePluginProvided;
-
-/**
- * @deprecated
- */
-public class JSFLibraryReferencePluginProvidedImpl extends AbstractJSFLibraryReferenceImpl implements JSFLibraryReferencePluginProvided {
-
- /**
- * Constructor
- * @param libRef
- * @param isDeployed
- */
- public JSFLibraryReferencePluginProvidedImpl(JSFLibraryInternalReference libRef, boolean isDeployed) {
- super(libRef, isDeployed);
- }
-
- public String getPluginId() {
- if (getLibrary() != null)
- return ((PluginProvidedJSFLibrary) getLibrary()).getPluginID();
-
- return null;
- }
-
- public String toString() {
- StringBuffer buf = new StringBuffer("PluginProvided: ("); //$NON-NLS-1$
- buf.append(super.toString());
-
- return buf.toString();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/JSFLibraryReferenceServerSuppliedImpl.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/JSFLibraryReferenceServerSuppliedImpl.java
deleted file mode 100644
index a813bb9cd..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/JSFLibraryReferenceServerSuppliedImpl.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.core.jsflibraryconfiguration.internal;
-
-import org.eclipse.jst.jsf.core.internal.jsflibraryregistry.JSFLibrary;
-import org.eclipse.jst.jsf.core.jsflibraryconfiguration.JSFLibraryReferenceServerSupplied;
-import org.eclipse.jst.jsf.core.jsflibraryconfiguration.JSFVersion;
-
-/**
- * @author gekessle
- * @deprecated
- */
-public class JSFLibraryReferenceServerSuppliedImpl
- extends AbstractJSFLibraryReferenceImpl
- implements JSFLibraryReferenceServerSupplied {
-
- /**
- * Library display Label
- */
- public final static String SERVER_SUPPLIED = Messages.JSFLibraryReferenceServerSuppliedImpl_Label;
- /**
- * Constructor
- */
- public JSFLibraryReferenceServerSuppliedImpl(){
- //TODO: replace label with constant
- super(JSFLibraryReferenceServerSupplied.ID, SERVER_SUPPLIED, true);
- }
-
- public String toString() {
- StringBuffer buf = new StringBuffer("ServerSupplied: ("); //$NON-NLS-1$
- buf.append(super.toString());
- buf.append(")"); //$NON-NLS-1$
-
- return buf.toString();
- }
-
- protected JSFLibrary getLibrary(){
- return null;
- }
-
- public JSFVersion getMaxSupportedVersion() {
- return JSFVersion.UNKNOWN;
- }
-//
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/JSFLibraryReferenceUserSpecifiedImpl.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/JSFLibraryReferenceUserSpecifiedImpl.java
deleted file mode 100644
index 4bb735fcd..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/JSFLibraryReferenceUserSpecifiedImpl.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.core.jsflibraryconfiguration.internal;
-
-import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryInternalReference;
-import org.eclipse.jst.jsf.core.jsflibraryconfiguration.JSFLibraryReferenceUserDefined;
-import org.eclipse.jst.jsf.core.jsflibraryconfiguration.JSFLibraryReferenceUserSpecified;
-
-/**
- * Implementation of a reference to a user specified JSF Library
- * @deprecated
- */
-public class JSFLibraryReferenceUserSpecifiedImpl extends AbstractJSFLibraryReferenceImpl implements JSFLibraryReferenceUserSpecified, JSFLibraryReferenceUserDefined{
- /**
- * @param libRef of type {@link JSFLibraryInternalReference}
- * @param isDeployed
- */
- public JSFLibraryReferenceUserSpecifiedImpl(
- JSFLibraryInternalReference libRef, boolean isDeployed) {
-
- super(libRef, isDeployed);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.jsf.core.jsflibraryconfiguration.internal.AbstractJSFLibraryReferenceImpl#toString()
- */
- public String toString() {
- StringBuffer buf = new StringBuffer("UserSpecified: ("); //$NON-NLS-1$
- buf.append(super.toString());
- buf.append(")"); //$NON-NLS-1$
-
- return buf.toString();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/Messages.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/Messages.java
deleted file mode 100644
index bd5fbe519..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/Messages.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.core.jsflibraryconfiguration.internal;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * String resource handler.
- *
- */
-public class Messages extends NLS {
- private static final String BUNDLE_NAME = "org.eclipse.jst.jsf.core.jsflibraryconfiguration.internal.messages"; //$NON-NLS-1$
- /**
- * see messages.properties
- */
- public static String JSFLibraryReferenceServerSuppliedImpl_Label;
- static {
- // initialize resource bundle
- NLS.initializeMessages(BUNDLE_NAME, Messages.class);
- }
-
- private Messages() {
- //
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/messages.properties b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/messages.properties
deleted file mode 100644
index 5e97f3894..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/internal/messages.properties
+++ /dev/null
@@ -1 +0,0 @@
-JSFLibraryReferenceServerSuppliedImpl_Label=Server Supplied
diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/package-info.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/package-info.java
deleted file mode 100644
index d17bacc75..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/jsflibraryconfiguration/package-info.java
+++ /dev/null
@@ -1,18 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2007 Oracle Corporation.
- * 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:
- * Oracle - initial API and implementation
- *
- ********************************************************************************/
-
-/**
- * API for configuring JSF Library References.
- *
- * <p><b>Provisional API - subject to change</b></p>
- */
-package org.eclipse.jst.jsf.core.jsflibraryconfiguration;

Back to the top