[Esbox-commits] r2275 - in branches/work_Ed/org.maemo.esbox.scratchbox.core: . src/org/maemo/esbox/internal/scratchbox/adapters
eswartz at garage.maemo.org
eswartz at garage.maemo.org
Wed Oct 7 17:50:41 EEST 2009
Author: eswartz
Date: 2009-10-07 17:50:40 +0300 (Wed, 07 Oct 2009)
New Revision: 2275
Added:
branches/work_Ed/org.maemo.esbox.scratchbox.core/src/org/maemo/esbox/internal/scratchbox/adapters/ESboxDebianDeploySupportAdapterFactory.java
Modified:
branches/work_Ed/org.maemo.esbox.scratchbox.core/plugin.xml
Log:
Fix #4547 -- add IDebianDeploySupportAdapter to tag an ISDKTarget into which Debian packages may be installed.
Also, move IDebianPackageBuilderAdapter into org.maemo.mica.linux.packages.core.
Modified: branches/work_Ed/org.maemo.esbox.scratchbox.core/plugin.xml
===================================================================
--- branches/work_Ed/org.maemo.esbox.scratchbox.core/plugin.xml 2009-10-07 14:01:44 UTC (rev 2274)
+++ branches/work_Ed/org.maemo.esbox.scratchbox.core/plugin.xml 2009-10-07 14:50:40 UTC (rev 2275)
@@ -42,7 +42,6 @@
type="org.maemo.mica.internal.api.cpp.launch.adapters.IGdbServerSupportAdapter">
</adapter>
</factory>
- <!-- specific to sbox -->
<factory
adaptableType="org.maemo.esbox.internal.api.scratchbox.core.sdk.AbstractScratchboxSDKTarget"
class="org.maemo.esbox.internal.scratchbox.adapters.ESBoxSBRSHLaunchAdapterFactory">
@@ -50,7 +49,6 @@
type="org.maemo.mica.internal.api.protocol.launch.sbrsh.ISBRSHLaunchAdapter">
</adapter>
</factory>
- <!-- specific to sbox -->
<factory
adaptableType="org.maemo.esbox.internal.api.scratchbox.core.sdk.AbstractScratchboxSDKTarget"
class="org.maemo.esbox.internal.scratchbox.adapters.ESboxMaemoTargetEnvironmentModifierAdapterFactory">
@@ -58,7 +56,6 @@
type="org.maemo.mica.common.launch.adapters.ITargetEnvironmentModifierAdapter">
</adapter>
</factory>
- <!-- specific to sbox -->
<factory
adaptableType="org.maemo.esbox.internal.api.scratchbox.core.sdk.AbstractScratchboxSDKTarget"
class="org.maemo.esbox.internal.scratchbox.adapters.ESboxMaemoEmulatorExecutionEnvironmentProviderAdapterFactory">
@@ -66,6 +63,14 @@
type="org.maemo.mica.common.core.adapters.IExecutionEnvironmentProviderAdapter">
</adapter>
</factory>
+ <factory
+ adaptableType="org.maemo.esbox.internal.api.scratchbox.core.sdk.AbstractScratchboxSDKTarget"
+ class="org.maemo.esbox.internal.scratchbox.adapters.ESboxDebianDeploySupportAdapterFactory">
+ <adapter
+ type="org.maemo.mica.linux.packages.core.adapters.IDebianDeploySupportAdapter">
+ </adapter>
+ </factory>
+
</extension>
<extension
Added: branches/work_Ed/org.maemo.esbox.scratchbox.core/src/org/maemo/esbox/internal/scratchbox/adapters/ESboxDebianDeploySupportAdapterFactory.java
===================================================================
--- branches/work_Ed/org.maemo.esbox.scratchbox.core/src/org/maemo/esbox/internal/scratchbox/adapters/ESboxDebianDeploySupportAdapterFactory.java (rev 0)
+++ branches/work_Ed/org.maemo.esbox.scratchbox.core/src/org/maemo/esbox/internal/scratchbox/adapters/ESboxDebianDeploySupportAdapterFactory.java 2009-10-07 14:50:40 UTC (rev 2275)
@@ -0,0 +1,49 @@
+/*******************************************************************************
+ * Copyright (c) 2009 Nokia 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:
+ * Ed Swartz (Nokia) - initial API and implementation
+ *******************************************************************************/
+
+package org.maemo.esbox.internal.scratchbox.adapters;
+
+import org.eclipse.core.runtime.IAdapterFactory;
+import org.maemo.esbox.scratchbox.core.sdk.IScratchboxSDKTarget;
+import org.maemo.mica.linux.packages.core.adapters.IDebianDeploySupportAdapter;
+
+/**
+ * Scratchbox targets support Debian package installation.
+ * @author eswartz
+ *
+ */
+public class ESboxDebianDeploySupportAdapterFactory implements IAdapterFactory {
+
+ /* (non-Javadoc)
+ * @see org.eclipse.core.runtime.IAdapterFactory#getAdapter(java.lang.Object, java.lang.Class)
+ */
+ public Object getAdapter(Object adaptableObject, Class adapterType) {
+ if (adapterType.equals(IDebianDeploySupportAdapter.class)
+ && adaptableObject instanceof IScratchboxSDKTarget) {
+ return new IDebianDeploySupportAdapter() {
+
+ public boolean supportsDebianInstallation() {
+ return true;
+ }
+
+ };
+ }
+ return null;
+ }
+
+ /* (non-Javadoc)
+ * @see org.eclipse.core.runtime.IAdapterFactory#getAdapterList()
+ */
+ public Class[] getAdapterList() {
+ return new Class[] { IDebianDeploySupportAdapter.class };
+ }
+
+}
Property changes on: branches/work_Ed/org.maemo.esbox.scratchbox.core/src/org/maemo/esbox/internal/scratchbox/adapters/ESboxDebianDeploySupportAdapterFactory.java
___________________________________________________________________
Name: svn:eol-style
+ native
More information about the Esbox-commits
mailing list