diff options
author | uid8428 | 2012-02-15 16:58:53 +0000 |
---|---|---|
committer | uid8428 | 2012-02-15 16:58:53 +0000 |
commit | 8b329ecade2a594147fdc8c40c0ddc4dc0187308 (patch) | |
tree | 335dc60dbea119ca918ceb7cf274189adc490801 /common | |
parent | f35b3600f2d50552f18990eabe876ea2389eade0 (diff) | |
download | webtools.dali-8b329ecade2a594147fdc8c40c0ddc4dc0187308.tar.gz webtools.dali-8b329ecade2a594147fdc8c40c0ddc4dc0187308.tar.xz webtools.dali-8b329ecade2a594147fdc8c40c0ddc4dc0187308.zip |
Rework validation resources etc.
Diffstat (limited to 'common')
3 files changed, 0 insertions, 83 deletions
diff --git a/common/plugins/org.eclipse.jpt.common.core/plugin.xml b/common/plugins/org.eclipse.jpt.common.core/plugin.xml index 6110a45534..41368dbd85 100644 --- a/common/plugins/org.eclipse.jpt.common.core/plugin.xml +++ b/common/plugins/org.eclipse.jpt.common.core/plugin.xml @@ -38,13 +38,6 @@ <adapter type="org.eclipse.jpt.common.core.resource.ProjectResourceLocator"/> </factory> - <!-- ResourceReference -> IResource --> - <factory - adaptableType="org.eclipse.jpt.common.core.ResourceReference" - class="org.eclipse.jpt.common.core.internal.ResourceReferenceAdapterFactory"> - <adapter type="org.eclipse.core.resources.IResource"/> - </factory> - </extension> diff --git a/common/plugins/org.eclipse.jpt.common.core/src/org/eclipse/jpt/common/core/ResourceReference.java b/common/plugins/org.eclipse.jpt.common.core/src/org/eclipse/jpt/common/core/ResourceReference.java deleted file mode 100644 index 8075a9ec6b..0000000000 --- a/common/plugins/org.eclipse.jpt.common.core/src/org/eclipse/jpt/common/core/ResourceReference.java +++ /dev/null @@ -1,32 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Oracle. 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 - ******************************************************************************/ -package org.eclipse.jpt.common.core; - -import org.eclipse.core.resources.IResource; - -/** - * An object that has a corresponding {@link IResource} - * <p> - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * @see org.eclipse.jpt.common.core.internal.ResourceReferenceAdapterFactory - */ -public interface ResourceReference { - /** - * Return the resource of which this object is a part - */ - IResource getResource(); -} diff --git a/common/plugins/org.eclipse.jpt.common.core/src/org/eclipse/jpt/common/core/internal/ResourceReferenceAdapterFactory.java b/common/plugins/org.eclipse.jpt.common.core/src/org/eclipse/jpt/common/core/internal/ResourceReferenceAdapterFactory.java deleted file mode 100644 index f97e5d0dd1..0000000000 --- a/common/plugins/org.eclipse.jpt.common.core/src/org/eclipse/jpt/common/core/internal/ResourceReferenceAdapterFactory.java +++ /dev/null @@ -1,44 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Oracle. 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 - ******************************************************************************/ -package org.eclipse.jpt.common.core.internal; - -import org.eclipse.core.resources.IResource; -import org.eclipse.core.runtime.IAdapterFactory; -import org.eclipse.jpt.common.core.ResourceReference; - -/** - * Factory to build adapters for a {@link ResourceReference}:<ul> - * <li>{@link IResource} - * </ul> - * See <code>org.eclipse.jpt.common.core plugin.xml</code>. - */ -public class ResourceReferenceAdapterFactory - implements IAdapterFactory -{ - private static final Class<?>[] ADAPTER_LIST = new Class[] { IResource.class }; - - public Class<?>[] getAdapterList() { - return ADAPTER_LIST; - } - - public Object getAdapter(Object adaptableObject, @SuppressWarnings("rawtypes") Class adapterType) { - if (adaptableObject instanceof ResourceReference) { - return this.getAdapter((ResourceReference) adaptableObject, adapterType); - } - return null; - } - - private Object getAdapter(ResourceReference resourceReference, Class <?>adapterType) { - if (adapterType == IResource.class) { - return resourceReference.getResource(); - } - return null; - } -} |