Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'bundles/org.eclipse.wst.wsdl.validation/src/wsdlvalidate/org/eclipse/wst/wsdl/validation/internal/xml/DefaultXMLValidator.java')
-rw-r--r--bundles/org.eclipse.wst.wsdl.validation/src/wsdlvalidate/org/eclipse/wst/wsdl/validation/internal/xml/DefaultXMLValidator.java561
1 files changed, 0 insertions, 561 deletions
diff --git a/bundles/org.eclipse.wst.wsdl.validation/src/wsdlvalidate/org/eclipse/wst/wsdl/validation/internal/xml/DefaultXMLValidator.java b/bundles/org.eclipse.wst.wsdl.validation/src/wsdlvalidate/org/eclipse/wst/wsdl/validation/internal/xml/DefaultXMLValidator.java
deleted file mode 100644
index ba8a0c1de..000000000
--- a/bundles/org.eclipse.wst.wsdl.validation/src/wsdlvalidate/org/eclipse/wst/wsdl/validation/internal/xml/DefaultXMLValidator.java
+++ /dev/null
@@ -1,561 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2004 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.wst.wsdl.validation.internal.xml;
-
-import java.io.BufferedReader;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.InputStreamReader;
-import java.io.Reader;
-import java.io.StringReader;
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.Hashtable;
-import java.util.List;
-
-import javax.xml.parsers.FactoryConfigurationError;
-import javax.xml.parsers.ParserConfigurationException;
-import javax.xml.parsers.SAXParserFactory;
-
-import org.apache.xerces.impl.XMLErrorReporter;
-import org.apache.xerces.jaxp.SAXParserFactoryImpl;
-import org.apache.xerces.parsers.SAXParser;
-import org.apache.xerces.parsers.StandardParserConfiguration;
-import org.apache.xerces.xni.XNIException;
-import org.apache.xerces.xni.parser.XMLInputSource;
-import org.eclipse.core.resources.IFile;
-import org.eclipse.wst.wsdl.validation.internal.ValidationMessageImpl;
-import org.eclipse.wst.wsdl.validation.internal.resolver.IURIResolutionResult;
-import org.eclipse.wst.wsdl.validation.internal.resolver.URIResolver;
-import org.xml.sax.Attributes;
-import org.xml.sax.InputSource;
-import org.xml.sax.SAXException;
-import org.xml.sax.SAXNotRecognizedException;
-import org.xml.sax.SAXNotSupportedException;
-import org.xml.sax.SAXParseException;
-import org.xml.sax.helpers.DefaultHandler;
-
-import com.ibm.wsdl.Constants;
-
-/**
- * The default implementation of IXMLValidator.
- */
-public class DefaultXMLValidator implements IXMLValidator
-{
- private final String _APACHE_FEATURE_CONTINUE_AFTER_FATAL_ERROR =
- "http://apache.org/xml/features/continue-after-fatal-error";
- private final String _APACHE_FEATURE_NAMESPACE_PREFIXES = "http://xml.org/sax/features/namespace-prefixes";
- private final String _APACHE_FEATURE_NAMESPACES = "http://xml.org/sax/features/namespaces";
- private final String _APACHE_FEATURE_VALIDATION = "http://xml.org/sax/features/validation";
- private final String _APACHE_FEATURE_VALIDATION_SCHEMA = "http://apache.org/xml/features/validation/schema";
- private final String _APACHE_PROPERTY_EXTERNAL_SCHEMALOCATION =
- "http://apache.org/xml/properties/schema/external-schemaLocation";
- private final String DEFINITIONS = "definitions";
-
- protected static final String IGNORE_ALWAYS = "IGNORE_ALWAYS";
- protected static final String PREMATURE_EOF = "PrematureEOF";
-
- protected Hashtable ingoredErrorKeyTable = new Hashtable();
-
- protected String uri;
- protected URIResolver uriResolver = null;
- protected List errors = new ArrayList();
- protected StringBuffer schemaLocationString = new StringBuffer();
- protected List ignoredNamespaceList = new ArrayList();
-
- protected InputStream inputStream = null;
-
- protected String currentErrorKey = null;
- protected Object[] currentMessageArguments = null;
-
- protected boolean isChildOfDoc = false;
-// protected String wsdlNamespace = null;
-
-
-
-
-/**
- * Constructor.
- */
- public DefaultXMLValidator()
- {
- super();
-
- ignoredNamespaceList.add(Constants.NS_URI_XSD_1999);
- ignoredNamespaceList.add(Constants.NS_URI_XSD_2000);
- ignoredNamespaceList.add(Constants.NS_URI_XSD_2001);
-
- ingoredErrorKeyTable.put(PREMATURE_EOF, IGNORE_ALWAYS);
- }
-
- /**
- * @see org.eclipse.validate.wsdl.xmlconformance.IXMLValidatorAction#setFile(IFile)
- */
- public void setFile(String uri)
- {
- this.uri = uri;
- }
-
- public void setURIResolver(URIResolver uriResolver)
- {
- this.uriResolver = uriResolver;
- }
-
- /**
- * @see org.eclipse.validate.wsdl.xmlconformance.IXMLValidatorAction#run()
- */
- public void run()
- {
- // Validate the XML file.
- try
- {
- Reader reader1 = null; // Used for the preparse.
- Reader reader2 = null; // Used for validation parse.
-
- InputSource validateInputSource;
-
-
- if (this.inputStream != null)
- {
-
-
- String string = createStringForInputStream(inputStream);
- reader1 = new StringReader(string);
- reader2 = new StringReader(string);
-
- validateInputSource = new InputSource(inputStream);
- validateInputSource.setCharacterStream(reader2);
- } else
- { validateInputSource = new InputSource(uri);
- }
-
- preparse(uri, reader1);
-
- SAXParser saxparser = createSAXParser();
- XMLConformanceDefaultHandler handler = new XMLConformanceDefaultHandler();
-
- saxparser.setErrorHandler(handler);
- saxparser.setEntityResolver(handler);
- saxparser.setContentHandler(handler);
-
- saxparser.parse(validateInputSource);
-// wsdlNamespace = handler.getWSDLNamespace();
- }
- catch (SAXParseException e)
- {
- addError(e.getMessage(), e.getLineNumber(), e.getColumnNumber(), uri);
- }
- catch (IOException e)
- {
- }
- catch (Exception e)
- {
- //System.out.println(e);
- }
- }
-
- /**
- * Create and configure a SAX parser.
- *
- * @return The new SAX parser.
- */
- protected SAXParser createSAXParser()
- {
- SAXParser saxParser = null;
- try
- {
- //SAXParserFactory parserfactory = new SAXParserFactoryImpl();
- try
- { MyStandardParserConfiguration configuration = new MyStandardParserConfiguration();
- saxParser = new org.apache.xerces.parsers.SAXParser(configuration);
- saxParser.setFeature(_APACHE_FEATURE_CONTINUE_AFTER_FATAL_ERROR, true);
- saxParser.setFeature(_APACHE_FEATURE_NAMESPACE_PREFIXES, true);
- saxParser.setFeature(_APACHE_FEATURE_NAMESPACES, true);
- saxParser.setFeature(_APACHE_FEATURE_VALIDATION, true);
- saxParser.setFeature(_APACHE_FEATURE_VALIDATION_SCHEMA, true);
- }
- catch (SAXNotRecognizedException e)
- {
- }
- catch (SAXNotSupportedException e)
- {
- }
- if (schemaLocationString.length() > 0)
- {
- saxParser.setProperty(_APACHE_PROPERTY_EXTERNAL_SCHEMALOCATION, schemaLocationString.toString());
- }
- }
- catch (FactoryConfigurationError e)
- {
- }
- catch (SAXNotRecognizedException e)
- {
- }
- catch (SAXNotSupportedException e)
- {
- }
-// catch (SAXException e)
-// {
-// }
- return saxParser;
- }
-
-
- final String createStringForInputStream(InputStream inputStream)
- {
- // Here we are reading the file and storing to a stringbuffer.
- StringBuffer fileString = new StringBuffer();
- try
- {
- InputStreamReader inputReader = new InputStreamReader(inputStream);
- BufferedReader reader = new BufferedReader(inputReader);
- char[] chars = new char[1024];
- int numberRead = reader.read(chars);
- while (numberRead != -1)
- {
- fileString.append(chars, 0, numberRead);
- numberRead = reader.read(chars);
- }
- }
- catch (Exception e)
- {
- //TODO: log error message
- //e.printStackTrace();
- }
- return fileString.toString();
- }
-
- /**
- * Preparse the file to find all of the namespaces that are defined in order
- * to specify the schemalocation.
- *
- * @param uri The uri of the file to parse.
- */
- protected void preparse(String uri, Reader characterStream)
- {
- javax.xml.parsers.SAXParser saxParser = null;
- try
- {
-
- InputSource inputSource;
-
- if (characterStream != null)
- {
- inputSource = new InputSource(uri);
- inputSource.setCharacterStream(characterStream);
- }
- else
- {
- inputSource = new InputSource(uri);
- }
-
- SAXParserFactory parserfactory = new SAXParserFactoryImpl();
-
- parserfactory.setFeature(_APACHE_FEATURE_NAMESPACE_PREFIXES, true);
- parserfactory.setFeature(_APACHE_FEATURE_NAMESPACES, true);
-
- saxParser = parserfactory.newSAXParser();
- SchemaStringHandler handler = new SchemaStringHandler(uri);
-
- saxParser.parse(inputSource, handler);
- }
- catch (FactoryConfigurationError e)
- {
- }
- catch (SAXNotRecognizedException e)
- {
- }
- catch (ParserConfigurationException e)
- {
- }
- catch (SAXNotSupportedException e)
- {
- }
- catch (SAXException e)
- {
- }
- catch (IOException e)
- {
- }
- }
-
- /**
- * @see org.eclipse.validate.wsdl.xmlconformance.IXMLValidatorAction#hasErrors()
- */
- public boolean hasErrors()
- {
- return !errors.isEmpty();
- }
-
- /**
- * @see org.eclipse.validate.wsdl.xmlconformance.IXMLValidatorAction#getErrorList()
- */
- public List getErrors()
- {
- return errors;
- }
-
- /**
- * Add an error message.
- *
- * @param error The error message to add.
- * @param line The line location of the error.
- * @param column The column location of the error.
- * @param uri The URI of the file containing the error.
- */
- protected void addError(String error, int line, int column, String uri)
- {
- errors.add(new ValidationMessageImpl(error, line, column, ValidationMessageImpl.SEV_ERROR, uri, currentErrorKey, currentMessageArguments));
- }
-
- /**
- * The handler for the SAX parser. This handler will obtain the WSDL
- * namespace, handle errors and resolve entities.
- */
- protected class XMLConformanceDefaultHandler extends DefaultHandler
- {
- /**
- * @see org.xml.sax.ErrorHandler#error(SAXParseException)
- */
- public void error(SAXParseException arg0) throws SAXException
- {
- String tempURI = arg0.getSystemId();
- if (inputStream!= null && arg0.getSystemId() == null)
- {
- //mh: In this case we are validating a stream so the URI may be null in this exception
- tempURI = uri;
- }
- addError(arg0.getMessage(), arg0.getLineNumber(), arg0.getColumnNumber(), tempURI);
- }
-
- /**
- * @see org.xml.sax.ErrorHandler#fatalError(SAXParseException)
- */
- public void fatalError(SAXParseException arg0) throws SAXException
- {
- addError(arg0.getMessage(), arg0.getLineNumber(), arg0.getColumnNumber(), arg0.getSystemId());
- }
-
- /**
- * @see org.xml.sax.ErrorHandler#warning(SAXParseException)
- */
- public void warning(SAXParseException arg0) throws SAXException
- {
- addError(arg0.getMessage(), arg0.getLineNumber(), arg0.getColumnNumber(), arg0.getSystemId());
- }
-
- /**
- * @see org.xml.sax.ContentHandler#endElement(java.lang.String, java.lang.String, java.lang.String)
- */
- public void endElement(String uri, String localName, String qName)
- throws SAXException {
- if(localName.equals("documentation") && (uri.equals(Constants.NS_URI_WSDL) || uri.equals(Constants.NS_URI_XSD_2001)|| uri.equals(Constants.NS_URI_XSD_1999) || uri.equals(Constants.NS_URI_XSD_2000)))
- {
- isChildOfDoc = false;
- }
- super.endElement(uri, localName, qName);
- }
- /**
- * @see org.xml.sax.ContentHandler#startElement(java.lang.String, java.lang.String, java.lang.String, org.xml.sax.Attributes)
- */
- public void startElement(String uri, String localName, String qName,
- Attributes atts) throws SAXException {
- if(localName.equals("documentation") && (uri.equals(Constants.NS_URI_WSDL) || uri.equals(Constants.NS_URI_XSD_2001)|| uri.equals(Constants.NS_URI_XSD_1999) || uri.equals(Constants.NS_URI_XSD_2000)))
- {
- isChildOfDoc = true;
- }
- super.startElement(uri, localName, qName, atts);
- }
-
- /**
- * @see org.xml.sax.EntityResolver#resolveEntity(java.lang.String,
- * java.lang.String)
- */
- public InputSource resolveEntity(String publicId, String systemId) throws SAXException
- {
- // If we're currently examining a subelement of the
- // WSDL or schema documentation element we don't want to resolve it
- // as anything is allowed as a child of documentation.
- if(isChildOfDoc)
- {
- return new InputSource();
- }
- if(publicId == null)
- {
- publicId = systemId;
- }
-
- IURIResolutionResult result = uriResolver.resolve(null, publicId, systemId);
- String uri = result.getPhysicalLocation();
- if (uri != null && !uri.equals(""))
- {
- try
- {
-// String entity = systemId;
-// if(publicId != null)
-// {
-// entity = publicId;
-// }
- URL entityURL = new URL(uri);
- InputSource is = new InputSource(result.getLogicalLocation());
- is.setByteStream(entityURL.openStream());
- if (is != null)
- {
- return is;
- }
- }
- catch(Exception e)
- {
- // Do nothing.
- }
- }
- // This try/catch block with the IOException is here to handle a difference
- // between different versions of the EntityResolver interface.
- try
- {
- InputSource is = super.resolveEntity(publicId, systemId);
- if(is == null)
- {
- throw new IOException();
- }
- return is;
- }
- catch(IOException e)
- {
- }
- return null;
- }
-
- }
-
- /**
- * @see org.eclipse.validate.wsdl.xmlconformance.IXMLValidator#setSchemaLocation(String,
- * String)
- */
- public void setSchemaLocation(String namespace, String location)
- {
- if (namespace != null && location != null && !namespace.equalsIgnoreCase("") && !location.equalsIgnoreCase(""))
- {
- schemaLocationString.append(" ").append(namespace).append(" ").append(formatURI(location));
- }
- }
-
-
- /**
- * @param inputStream - set the inputStream to validate
- */
- public void setInputStream(InputStream inputStream)
- {
- this.inputStream = inputStream;
- }
-
- /**
- * Remove space characters from a String and replace them with %20.
- *
- * @param uri -
- * the uri to format
- * @return the formatted string
- */
- protected String formatURI(String uri)
- {
- String space = "%20";
- StringBuffer newUri = new StringBuffer(uri);
- int newUriLength = newUri.length();
-
- // work backwards through the stringbuffer in case it grows to the
- // point
- // where the last space would be missed.
- for (int i = newUriLength - 1; i >= 0; i--)
- {
- if (newUri.charAt(i) == ' ')
- {
- newUri.replace(i, i + 1, space);
- }
- }
-
- return newUri.toString();
- }
-
- /**
- * A handler used in preparsing to get the schemaLocation string.
- */
- protected class SchemaStringHandler extends DefaultHandler
- {
- private final String XMLNS = "xmlns";
- private final String TARGETNAMESPACE = "targetNamespace";
- private String baselocation = null;
-
- public SchemaStringHandler(String baselocation)
- {
- this.baselocation = baselocation;
- }
- /**
- * @see org.xml.sax.ContentHandler#startElement(java.lang.String,
- * java.lang.String, java.lang.String, org.xml.sax.Attributes)
- */
- public void startElement(String uri, String localname, String arg2, Attributes attributes) throws SAXException
- {
- if (localname.equals(DEFINITIONS))
- {
- String targetNamespace = attributes.getValue(TARGETNAMESPACE);
- int numAtts = attributes.getLength();
- for (int i = 0; i < numAtts; i++)
- {
-
- String attname = attributes.getQName(i);
- if (attname.startsWith(XMLNS))
- {
- String namespace = attributes.getValue(i);
- if(!(namespace.equals(targetNamespace) || ignoredNamespaceList.contains(namespace)))
- {
- String resolvedURI = namespace;
- setSchemaLocation(namespace, resolvedURI);
- }
- }
- }
-
- }
- super.startElement(uri, localname, arg2, attributes);
-
- }
- }
-
-
- protected class MyStandardParserConfiguration extends StandardParserConfiguration
- {
- public MyStandardParserConfiguration()
- {
- }
-
- /* (non-Javadoc)
- * @see org.apache.xerces.parsers.DTDConfiguration#createErrorReporter()
- */
- protected XMLErrorReporter createErrorReporter()
- {
- return new XMLErrorReporter()
- {
- /* (non-Javadoc)
- * @see org.apache.xerces.impl.XMLErrorReporter#reportError(java.lang.String, java.lang.String, java.lang.Object[], short)
- */
- public void reportError(String domain, String key, Object[] arguments,
- short severity) throws XNIException
- {
- currentErrorKey = key;
- currentMessageArguments = arguments;
- super.reportError(domain, key, arguments, severity);
- }
- };
- }
- }
-
-
-}

Back to the top

e.update.core/src/org/eclipse/update/operations/IOperation.java update/org.eclipse.update.core/src/org/eclipse/update/operations/IOperationFactory.java update/org.eclipse.update.core/src/org/eclipse/update/operations/IOperationListener.java update/org.eclipse.update.core/src/org/eclipse/update/operations/IOperationValidator.java update/org.eclipse.update.core/src/org/eclipse/update/operations/IReplaceFeatureVersionOperation.java update/org.eclipse.update.core/src/org/eclipse/update/operations/IRevertConfigurationOperation.java update/org.eclipse.update.core/src/org/eclipse/update/operations/IToggleSiteOperation.java update/org.eclipse.update.core/src/org/eclipse/update/operations/IUnconfigFeatureOperation.java update/org.eclipse.update.core/src/org/eclipse/update/operations/IUninstallFeatureOperation.java update/org.eclipse.update.core/src/org/eclipse/update/operations/IUpdateModelChangedListener.java update/org.eclipse.update.core/src/org/eclipse/update/operations/OperationsManager.java update/org.eclipse.update.core/src/org/eclipse/update/operations/package.html update/org.eclipse.update.core/src/org/eclipse/update/search/BackLevelFilter.java update/org.eclipse.update.core/src/org/eclipse/update/search/BaseFilter.java update/org.eclipse.update.core/src/org/eclipse/update/search/EnvironmentFilter.java update/org.eclipse.update.core/src/org/eclipse/update/search/IQueryUpdateSiteAdapter.java update/org.eclipse.update.core/src/org/eclipse/update/search/IUpdateSearchCategory.java update/org.eclipse.update.core/src/org/eclipse/update/search/IUpdateSearchFilter.java update/org.eclipse.update.core/src/org/eclipse/update/search/IUpdateSearchQuery.java update/org.eclipse.update.core/src/org/eclipse/update/search/IUpdateSearchResultCollector.java update/org.eclipse.update.core/src/org/eclipse/update/search/IUpdateSearchSite.java update/org.eclipse.update.core/src/org/eclipse/update/search/IUpdateSiteAdapter.java update/org.eclipse.update.core/src/org/eclipse/update/search/UpdateSearchRequest.java update/org.eclipse.update.core/src/org/eclipse/update/search/UpdateSearchScope.java update/org.eclipse.update.core/src/org/eclipse/update/search/VersionedIdentifiersFilter.java update/org.eclipse.update.core/src/org/eclipse/update/search/package.html update/org.eclipse.update.core/src/org/eclipse/update/standalone/AddSiteCommand.java update/org.eclipse.update.core/src/org/eclipse/update/standalone/CmdLineArgs.java update/org.eclipse.update.core/src/org/eclipse/update/standalone/DisableCommand.java update/org.eclipse.update.core/src/org/eclipse/update/standalone/EnableCommand.java update/org.eclipse.update.core/src/org/eclipse/update/standalone/InstallCommand.java update/org.eclipse.update.core/src/org/eclipse/update/standalone/ListFeaturesCommand.java update/org.eclipse.update.core/src/org/eclipse/update/standalone/RemoveSiteCommand.java update/org.eclipse.update.core/src/org/eclipse/update/standalone/ScriptedCommand.java update/org.eclipse.update.core/src/org/eclipse/update/standalone/SearchCommand.java update/org.eclipse.update.core/src/org/eclipse/update/standalone/StandaloneUpdateApplication.java update/org.eclipse.update.core/src/org/eclipse/update/standalone/UninstallCommand.java update/org.eclipse.update.core/src/org/eclipse/update/standalone/UpdateCommand.java update/org.eclipse.update.core/src/org/eclipse/update/standalone/package.html update/org.eclipse.update.examples/.classpath update/org.eclipse.update.examples/.cvsignore update/org.eclipse.update.examples/.project update/org.eclipse.update.examples/Scrapbook2.jpage update/org.eclipse.update.examples/about.html update/org.eclipse.update.examples/build.properties update/org.eclipse.update.examples/plugin.properties update/org.eclipse.update.examples/plugin.xml update/org.eclipse.update.examples/site/features/com.reddot.reddot_1.0.0.jar update/org.eclipse.update.examples/site/features/com.reddot.reddot_2.0.0.jar update/org.eclipse.update.examples/site/info/images/redDot.jpg update/org.eclipse.update.examples/site/info/siteInfo.html update/org.eclipse.update.examples/site/plugins/com.reddot.reddot_1.0.0.jar update/org.eclipse.update.examples/site/plugins/com.reddot.reddot_2.0.0.jar update/org.eclipse.update.examples/site/site.xml update/org.eclipse.update.examples/src/org/eclipse/update/examples/buildzip/BuildZipConverter.java update/org.eclipse.update.examples/src/org/eclipse/update/examples/buildzip/BuildZipFeatureContentProvider.java update/org.eclipse.update.examples/src/org/eclipse/update/examples/buildzip/BuildZipFeatureFactory.java update/org.eclipse.update.examples/src/org/eclipse/update/examples/buildzip/BuildZipFeatureParser.java update/org.eclipse.update.examples/src/org/eclipse/update/examples/buildzip/BuildZipPluginParser.java update/org.eclipse.update.examples/src/org/eclipse/update/examples/buildzip/BuildZipSiteContentProvider.java update/org.eclipse.update.examples/src/org/eclipse/update/examples/buildzip/BuildZipSiteFactory.java update/org.eclipse.update.examples/src/org/eclipse/update/examples/buildzip/DefaultModelWriter.java update/org.eclipse.update.examples/src/org/eclipse/update/examples/buildzip/Test.java update/org.eclipse.update.examples/src/org/eclipse/update/examples/buildzip/java.page.jpage update/org.eclipse.update.examples/src/org/eclipse/update/examples/freeform/FreeFormSiteContentProvider.java update/org.eclipse.update.examples/src/org/eclipse/update/examples/freeform/FreeFormSiteFactory.java update/org.eclipse.update.scheduler/.classpath update/org.eclipse.update.scheduler/.cvsignore update/org.eclipse.update.scheduler/.project update/org.eclipse.update.scheduler/about.html update/org.eclipse.update.scheduler/build.properties update/org.eclipse.update.scheduler/plugin.properties update/org.eclipse.update.scheduler/plugin.xml update/org.eclipse.update.scheduler/src/org/eclipse/update/internal/scheduler/AutomaticUpdatesJob.java update/org.eclipse.update.scheduler/src/org/eclipse/update/internal/scheduler/SchedulerStartup.java update/org.eclipse.update.scheduler/src/org/eclipse/update/internal/scheduler/UpdateScheduler.java update/org.eclipse.update.scheduler/src/org/eclipse/update/internal/scheduler/UpdateSchedulerResources.properties update/org.eclipse.update.scheduler/src/org/eclipse/update/internal/scheduler/preferences/AutomaticUpdatesPreferencePage.java update/org.eclipse.update.tests.core/.classpath update/org.eclipse.update.tests.core/.cvsignore update/org.eclipse.update.tests.core/.project update/org.eclipse.update.tests.core/about.html update/org.eclipse.update.tests.core/build.properties update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data/features/feature3/feature.xml update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data/plugins/Pde_core.jar update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data/plugins/help.jar update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data/plugins/junit_3.7.jar update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data/plugins/org.eclipse.update.plugin1_1.1.1/plugin.xml update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data/plugins/org.eclipse.update.plugin1_1.1.1/src.jar update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/features/feature3/feature.xml update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/features/helpFeature.jar update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/features/org.eclipse.pde.feature_1.0.0.jar update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/info/img/top_titlsm.gif update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/info/img/wel_ml.jpg update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/info/siteInfo.html update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/plugins/Pde_core.jar update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/plugins/help.jar update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/plugins/junit_3.7.jar update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/plugins/org.eclipse.update.plugin1_1.1.1/plugin.xml update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/plugins/org.eclipse.update.plugin1_1.1.1/src.jar update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/site.xml update/org.eclipse.update.tests.core/data/FTPLikeSite/site.xml update/org.eclipse.update.tests.core/data/FeatureTypeExamples/site1/features/feature3/feature.xml update/org.eclipse.update.tests.core/data/FeatureTypeExamples/site1/site.xml update/org.eclipse.update.tests.core/data/FeatureTypeExamples/site2/features/feature3/features2.jarfile update/org.eclipse.update.tests.core/data/FeatureTypeExamples/site2/site.xml update/org.eclipse.update.tests.core/data/FeatureTypeExamples/site3/features/feature3/features2.jarfile update/org.eclipse.update.tests.core/data/FeatureTypeExamples/site3/site.xml update/org.eclipse.update.tests.core/data/Site with space/features space/helpFeature.jar update/org.eclipse.update.tests.core/data/Site with space/features space/space feature.jar update/org.eclipse.update.tests.core/data/Site with space/info/img/top_titlsm.gif update/org.eclipse.update.tests.core/data/Site with space/info/img/wel_ml.jpg update/org.eclipse.update.tests.core/data/Site with space/info/siteInfo.html update/org.eclipse.update.tests.core/data/Site with space/install/features space/feature3/feature.xml update/org.eclipse.update.tests.core/data/Site with space/plugins space/Pde_core.jar update/org.eclipse.update.tests.core/data/Site with space/plugins space/help.jar update/org.eclipse.update.tests.core/data/Site with space/plugins space/junit_3.7.jar update/org.eclipse.update.tests.core/data/Site with space/plugins space/org.eclipse.update.plugin1_1.1.1/plugin.xml update/org.eclipse.update.tests.core/data/Site with space/plugins space/org.eclipse.update.plugin1_1.1.1/src.jar update/org.eclipse.update.tests.core/data/Site with space/site.xml update/org.eclipse.update.tests.core/data/SiteTypeExamples/site1/features/feature3/features2.jarfile update/org.eclipse.update.tests.core/data/SiteTypeExamples/site1/site.xml update/org.eclipse.update.tests.core/data/SiteURLTest/data/artifacts/features/helpFeature.jar update/org.eclipse.update.tests.core/data/SiteURLTest/data/artifacts/features/org.eclipse.pde.feature_1.0.0.jar update/org.eclipse.update.tests.core/data/SiteURLTest/data/artifacts/plugins/Pde_core.jar update/org.eclipse.update.tests.core/data/SiteURLTest/data/artifacts/plugins/help.jar update/org.eclipse.update.tests.core/data/SiteURLTest/data/artifacts/plugins/junit_3.7.jar update/org.eclipse.update.tests.core/data/SiteURLTest/data/info/img/top_titlsm.gif update/org.eclipse.update.tests.core/data/SiteURLTest/data/info/img/wel_ml.jpg update/org.eclipse.update.tests.core/data/SiteURLTest/data/info/siteInfo.html update/org.eclipse.update.tests.core/data/SiteURLTest/data/site.xml update/org.eclipse.update.tests.core/data/dataEntrySiteTest/site1/file1.zip update/org.eclipse.update.tests.core/data/dataEntrySiteTest/site1/install/features/feature3/feature.xml update/org.eclipse.update.tests.core/data/dataEntrySiteTest/site1/site.xml update/org.eclipse.update.tests.core/data/dataEntrySiteTest/site2/features/features3.jar update/org.eclipse.update.tests.core/data/dataEntrySiteTest/site2/non data/another file.zip update/org.eclipse.update.tests.core/data/dataEntrySiteTest/site2/site.xml update/org.eclipse.update.tests.core/data/features/features2.jar update/org.eclipse.update.tests.core/data/features/org.eclipse.test.feature_1.0.0.jar update/org.eclipse.update.tests.core/data/features/org.eclipse.update.core.tests.feature1_1.0.4.jar update/org.eclipse.update.tests.core/data/features/org.eclipse_test_feature.jar update/org.eclipse.update.tests.core/data/mirrors/update-site1/.project update/org.eclipse.update.tests.core/data/mirrors/update-site1/.sitebuild/build.log update/org.eclipse.update.tests.core/data/mirrors/update-site1/.sitebuild/sitebuild.xml update/org.eclipse.update.tests.core/data/mirrors/update-site1/features/update.feature1_1.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site1/features/update.feature2_1.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site1/features/update.feature3_1.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site1/plugins/com.plugin1_1.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site1/plugins/com.plugin2_1.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site1/plugins/com.plugin3_1.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site1/plugins/com.plugin4_1.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site1/site.xml update/org.eclipse.update.tests.core/data/mirrors/update-site2/.project update/org.eclipse.update.tests.core/data/mirrors/update-site2/.sitebuild/build.log update/org.eclipse.update.tests.core/data/mirrors/update-site2/.sitebuild/sitebuild.xml update/org.eclipse.update.tests.core/data/mirrors/update-site2/features/update.feature1_1.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site2/features/update.feature2_1.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site2/plugins/com.plugin1_1.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site2/plugins/com.plugin2_1.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site2/site.xml update/org.eclipse.update.tests.core/data/mirrors/update-site3/.project update/org.eclipse.update.tests.core/data/mirrors/update-site3/.sitebuild/build.log update/org.eclipse.update.tests.core/data/mirrors/update-site3/.sitebuild/sitebuild.xml update/org.eclipse.update.tests.core/data/mirrors/update-site3/features/update.feature1b_2.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site3/features/update.feature2b_2.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site3/plugins/com.plugin1_1.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site3/plugins/com.plugin1a_1.0.1.jar update/org.eclipse.update.tests.core/data/mirrors/update-site3/plugins/com.plugin2_1.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site3/plugins/com.plugin2a_1.0.1.jar update/org.eclipse.update.tests.core/data/mirrors/update-site3/site.xml update/org.eclipse.update.tests.core/data/mirrors/update-site4/.project update/org.eclipse.update.tests.core/data/mirrors/update-site4/.sitebuild/build.log update/org.eclipse.update.tests.core/data/mirrors/update-site4/.sitebuild/sitebuild.xml update/org.eclipse.update.tests.core/data/mirrors/update-site4/features/update.feature1_1.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site4/features/update.feature1_1.0.1.jar update/org.eclipse.update.tests.core/data/mirrors/update-site4/features/update.feature1b_2.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site4/features/update.feature1c_3.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site4/plugins/com.plugin1_1.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site4/plugins/com.plugin1a_1.0.1.jar update/org.eclipse.update.tests.core/data/mirrors/update-site4/site.xml update/org.eclipse.update.tests.core/data/mirrors/update-site5/.project update/org.eclipse.update.tests.core/data/mirrors/update-site5/.sitebuild/build.log update/org.eclipse.update.tests.core/data/mirrors/update-site5/.sitebuild/sitebuild.xml update/org.eclipse.update.tests.core/data/mirrors/update-site5/features/update.feature1_1.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site5/features/update.feature1_1.0.1.jar update/org.eclipse.update.tests.core/data/mirrors/update-site5/features/update.feature1b_2.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site5/features/update.feature1c_3.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site5/features/update.feature2_1.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site5/features/update.feature2b_2.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site5/features/update.feature2c_3.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site5/plugins/com.plugin1_1.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site5/plugins/com.plugin1a_1.0.1.jar update/org.eclipse.update.tests.core/data/mirrors/update-site5/plugins/com.plugin2_1.0.0.jar update/org.eclipse.update.tests.core/data/mirrors/update-site5/plugins/com.plugin2a_1.0.1.jar update/org.eclipse.update.tests.core/data/mirrors/update-site5/site.xml update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest/features/org.eclipse.update.core.tests.childrenfeature_2.0.0.jar update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest/features/rootfeature.jar update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest/plugins/org.eclipse.update.core.tests.feature1.plugin1_3.5.6.jar update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest/plugins/org.eclipse.update.core.tests.feature1.plugin2_5.0.0.jar update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest/plugins/org.eclipse.update.core.tests.feature1.plugin2_5.0.1.jar update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest/site.xml update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest2/features/childrenfeature.jar update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest2/features/rootfeature.jar update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest2/plugins/org.eclipse.update.core.tests.feature1.plugin1_3.5.6.jar update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest2/plugins/org.eclipse.update.core.tests.feature1.plugin2_5.0.0.jar update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest2/plugins/org.eclipse.update.core.tests.feature1.plugin2_5.0.1.jar update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest2/site.xml update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest3/features/childrenfeature.jar update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest3/features/rootfeature.jar update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest3/plugins/org.eclipse.update.core.tests.feature1.plugin1_3.5.6.jar update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest3/plugins/org.eclipse.update.core.tests.feature1.plugin2_5.0.0.jar update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest3/plugins/org.eclipse.update.core.tests.feature1.plugin2_5.0.1.jar update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest3/site.xml update/org.eclipse.update.tests.core/data/parsertests/feature1.xml update/org.eclipse.update.tests.core/data/parsertests/feature1bis.xml update/org.eclipse.update.tests.core/data/parsertests/feature2.xml update/org.eclipse.update.tests.core/data/parsertests/feature3.xml update/org.eclipse.update.tests.core/data/parsertests/feature4.xml update/org.eclipse.update.tests.core/data/parsertests/reddot.xml update/org.eclipse.update.tests.core/data/parsertests/reddot1.xml update/org.eclipse.update.tests.core/data/parsertests/site.properties update/org.eclipse.update.tests.core/data/parsertests/site.xml update/org.eclipse.update.tests.core/data/parsertests/site10.xml update/org.eclipse.update.tests.core/data/parsertests/site2.xml update/org.eclipse.update.tests.core/data/parsertests/site3.xml update/org.eclipse.update.tests.core/data/parsertests/site4.xml update/org.eclipse.update.tests.core/data/parsertests/site7.xml update/org.eclipse.update.tests.core/data/parsertests/site8.xml update/org.eclipse.update.tests.core/data/parsertests/site9.xml update/org.eclipse.update.tests.core/data/parsertests/siteftp.xml update/org.eclipse.update.tests.core/data/plugins/org.eclipse.update.core.feature1.plugin1_1.1.1.jar update/org.eclipse.update.tests.core/data/plugins/org.eclipse.update.core.feature2.plugin2_2.2.2.jar update/org.eclipse.update.tests.core/data/plugins/org.eclipse.update.core.tests.dummy_7.9.8.jar update/org.eclipse.update.tests.core/data/plugins/org.eclipse.update.core.tests.feature1.plugin1_3.5.6.jar update/org.eclipse.update.tests.core/data/plugins/org.eclipse.update.core.tests.feature1.plugin2_5.0.0.jar update/org.eclipse.update.tests.core/data/plugins/org.eclipse.update.plugin1_1.1.1/plugin.xml update/org.eclipse.update.tests.core/data/plugins/org.eclipse.update.plugin1_1.1.1/src.jar update/org.eclipse.update.tests.core/data/reconciliationSites/site1/install/features/feature3/feature.xml update/org.eclipse.update.tests.core/data/reconciliationSites/site1/plugins/org.eclipse.update.plugin1_1.1.1/plugin.xml update/org.eclipse.update.tests.core/data/reconciliationSites/site1/plugins/org.eclipse.update.plugin1_1.1.1/src.jar update/org.eclipse.update.tests.core/data/reconciliationSites/site2/install/features/feature3/feature.xml update/org.eclipse.update.tests.core/data/reconciliationSites/site2/plugins/org.eclipse.update.core_2.0.0/plugin.xml update/org.eclipse.update.tests.core/data/reconciliationSites/site2/plugins/org.eclipse.update.core_2.0.0/src.jar update/org.eclipse.update.tests.core/data/resources.properties update/org.eclipse.update.tests.core/data/site.xml update/org.eclipse.update.tests.core/data/site2/site.xml update/org.eclipse.update.tests.core/data/siteTestLocalSite/plugins/bundleAndPluginManifests_1.0.3/META-INF/MANIFEST.MF update/org.eclipse.update.tests.core/data/siteTestLocalSite/plugins/bundleAndPluginManifests_1.0.3/plugin.xml update/org.eclipse.update.tests.core/data/siteTestLocalSite/plugins/bundleManifest_1.0.1/META-INF/MANIFEST.MF update/org.eclipse.update.tests.core/data/siteTestLocalSite/plugins/feature1_plugin2_5.0.0/plugin.xml update/org.eclipse.update.tests.core/data/siteTestLocalSite/plugins/feature1_plugin2_5.0.0/src.jar update/org.eclipse.update.tests.core/data/siteTestLocalSite/plugins/feature1_plugin2_5.0.1/plugin.xml update/org.eclipse.update.tests.core/data/siteTestLocalSite/plugins/feature1_plugin2_5.0.1/src.jar update/org.eclipse.update.tests.core/data/siteTestLocalSite/plugins/notBundleManifest_1.0.2/META-INF/MANIFEST.MF update/org.eclipse.update.tests.core/data/testAPI/features/feature3/feature.xml update/org.eclipse.update.tests.core/data/testAPI/plugins/org.eclipse.update.plugin1_1.1.1/plugin.xml update/org.eclipse.update.tests.core/data/testAPI/plugins/org.eclipse.update.plugin1_1.1.1/src.jar update/org.eclipse.update.tests.core/data/testAPI/site.xml update/org.eclipse.update.tests.core/data/validation/site2/.eclipseproduct update/org.eclipse.update.tests.core/data/validation/site3/.eclipseextension update/org.eclipse.update.tests.core/data/validation/site4/eclipse/.eclipseextension update/org.eclipse.update.tests.core/data/validation/site5/.eclipseUM update/org.eclipse.update.tests.core/data/validation/site6/.eclipseUM update/org.eclipse.update.tests.core/data/validation/site6/children/children/eclipse/.eclipseextension update/org.eclipse.update.tests.core/data/xmls/apitests/org.eclipse.test.feature_1.0.0/feature.xml update/org.eclipse.update.tests.core/data/xmls/apitests/org.eclipse_test_feature/feature.xml update/org.eclipse.update.tests.core/data/xmls/feature_1.0.0/feature.xml update/org.eclipse.update.tests.core/data/xmls/feature_1.0.0/feature1.gif update/org.eclipse.update.tests.core/data/xmls/site1/site.xml update/org.eclipse.update.tests.core/plugin.properties update/org.eclipse.update.tests.core/plugin.xml update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/AllTests.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/UpdateManagerTestCase.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/UpdateTestsPlugin.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/AllAPITests.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/DefaultFeature.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/MyURLEntry.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/TestDefaultExecutableFeatureAPI.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/TestDefaultPackageFeatureAPI.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/TestFeatureContentProvider_FileFilterAPI.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/TestLocalSiteAPI.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/TestNestedFeatureAPI.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/TestPluginContainerAPI.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/TestSiteAPI.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/TestSiteManagerAPI.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/TestUpdateManagerUtilsAPI.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/branding/AllBrandingTests.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/branding/BundleProviderTest.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/branding/ProductTest.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/configurations/AllConfigurationsTests.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/configurations/TestBackward.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/configurations/TestRevert.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/core/boot/AllPlatformConfigurationTests.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/core/boot/PlatformConfigurationTestCase.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/core/boot/TestPlatCfgAPI.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/core/boot/TestPlatCfgDefault.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/implementation/SiteFTP.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/implementation/SiteFTPFactory.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/mirror/AllMirrorTests.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/mirror/MirrorManagerTestCase.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/mirror/TestRemoteDoubleEmbeddedFeatureMirror.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/mirror/TestRemoteEmbeddedFeatureMirror.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/mirror/TestRemoteFeatureVersionMirror.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/model/AllModelTests.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/model/FeatureMain.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/model/SiteMain.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/model/feature.xml update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/model/site.xml update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/model/site_old_format.xml update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/model/site_with_type.xml update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/model/test.properties update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/nativeTests/TestLocalSystemInfo.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/nestedfeatures/AllNestedTests.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/nestedfeatures/TestInstall.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/parser/AllParserTests.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/parser/TestCategories.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/parser/TestFeatureParse.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/parser/TestSiteParse.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/reconciliation/AllReconciliationTests.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/reconciliation/TestSiteReconciliation.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularInstall/AllRegularInstallTests.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularInstall/MultipleTestLocalSite.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularInstall/TestDataEntryInstall.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularInstall/TestExecutableInstall.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularInstall/TestExecutablePackagedInstall.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularInstall/TestGetFeature.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularInstall/TestInstall.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularInstall/TestInstallURLSIteXML.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularInstall/TestLocalSite.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularInstall/TestSpaceInInstall.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularRemove/AllRegularRemoveTests.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularRemove/TestRemove.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/sitevalidation/AllSiteValidationTests.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/sitevalidation/TestSiteValidation.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/standalone/AllStandaloneTests.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/standalone/StandaloneManagerTestCase.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/standalone/TestBundlesInstall.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/standalone/TestFeatureDisable.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/standalone/TestFeatureEnable.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/standalone/TestFeatureInstall.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/standalone/TestFeatureUninstall.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/standalone/TestFeatureUpdate.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/types/AllTypesTests.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/types/TestFeatureType.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/types/TestSiteType.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/uivalues/AllCoreUITests.java update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/uivalues/TestUILabel.java update/org.eclipse.update.tests.core/test.xml update/org.eclipse.update.tests.core/test_with_mail.xml update/org.eclipse.update.tests.core/webserver/Site with space/features space/helpFeature.jar update/org.eclipse.update.tests.core/webserver/Site with space/features space/space feature.jar update/org.eclipse.update.tests.core/webserver/Site with space/info/img/top_titlsm.gif update/org.eclipse.update.tests.core/webserver/Site with space/info/img/wel_ml.jpg update/org.eclipse.update.tests.core/webserver/Site with space/info/siteInfo.html update/org.eclipse.update.tests.core/webserver/Site with space/install/features space/feature3/feature.xml update/org.eclipse.update.tests.core/webserver/Site with space/plugins space/Pde_core.jar update/org.eclipse.update.tests.core/webserver/Site with space/plugins space/help.jar update/org.eclipse.update.tests.core/webserver/Site with space/plugins space/junit_3.7.jar update/org.eclipse.update.tests.core/webserver/Site with space/site.xml update/org.eclipse.update.tests.core/webserver/UpdateManager/features/helpFeature.jar update/org.eclipse.update.tests.core/webserver/UpdateManager/features/org.eclipse.pde.feature_1.0.0.jar update/org.eclipse.update.tests.core/webserver/UpdateManager/info/img/top_titlsm.gif update/org.eclipse.update.tests.core/webserver/UpdateManager/info/img/wel_ml.jpg update/org.eclipse.update.tests.core/webserver/UpdateManager/info/siteInfo.html update/org.eclipse.update.tests.core/webserver/UpdateManager/plugins/Pde_core.jar update/org.eclipse.update.tests.core/webserver/UpdateManager/plugins/help.jar update/org.eclipse.update.tests.core/webserver/UpdateManager/plugins/junit_3.7.jar update/org.eclipse.update.tests.core/webserver/UpdateManager/site.xml update/org.eclipse.update.tests.core/webserver/UpdateManager2/features/features2.jar update/org.eclipse.update.tests.core/webserver/UpdateManager2/features/org.eclipse.test.feature_1.0.0.jar update/org.eclipse.update.tests.core/webserver/UpdateManager2/features/org.eclipse.update.core.tests.feature1_1.0.4.jar update/org.eclipse.update.tests.core/webserver/UpdateManager2/features/org.eclipse_test_feature.jar update/org.eclipse.update.tests.core/webserver/UpdateManager2/nestedFeatureSiteTest/features/org.eclipse.update.core.tests.childrenfeature_2.0.0.jar update/org.eclipse.update.tests.core/webserver/UpdateManager2/nestedFeatureSiteTest/features/rootfeature.jar update/org.eclipse.update.tests.core/webserver/UpdateManager2/nestedFeatureSiteTest/plugins/org.eclipse.update.core.tests.feature1.plugin1_3.5.6.jar update/org.eclipse.update.tests.core/webserver/UpdateManager2/nestedFeatureSiteTest/plugins/org.eclipse.update.core.tests.feature1.plugin2_5.0.0.jar update/org.eclipse.update.tests.core/webserver/UpdateManager2/nestedFeatureSiteTest/plugins/org.eclipse.update.core.tests.feature1.plugin2_5.0.1.jar update/org.eclipse.update.tests.core/webserver/UpdateManager2/nestedFeatureSiteTest/site.xml update/org.eclipse.update.tests.core/webserver/UpdateManager2/org.eclipse.update.core.feature2_1.0.0/org.eclipse.update.core.feature2_2.2.2.jar update/org.eclipse.update.tests.core/webserver/UpdateManager2/plugins/org.eclipse.update.core.feature1.plugin1_1.1.1.jar update/org.eclipse.update.tests.core/webserver/UpdateManager2/plugins/org.eclipse.update.core.feature2.plugin2_2.2.2.jar update/org.eclipse.update.tests.core/webserver/UpdateManager2/plugins/org.eclipse.update.core.tests.dummy_7.9.8.jar update/org.eclipse.update.tests.core/webserver/UpdateManager2/plugins/org.eclipse.update.core.tests.feature1.plugin1_3.5.6.jar update/org.eclipse.update.tests.core/webserver/UpdateManager2/plugins/org.eclipse.update.core.tests.feature1.plugin2_5.0.0.jar update/org.eclipse.update.tests.core/webserver/UpdateManager2/site.properties update/org.eclipse.update.tests.core/webserver/UpdateManager2/site.xml update/org.eclipse.update.tests.core/webserver/WEB-INF/web.xml update/org.eclipse.update.tests.core/webserver/bundleSite/features/com.example.bundle.feature_1.0.0.jar update/org.eclipse.update.tests.core/webserver/bundleSite/plugins/com.example.budle.fragment.ui_1.0.0.jar update/org.eclipse.update.tests.core/webserver/bundleSite/plugins/com.example.bundle.fragment_1.0.0.jar update/org.eclipse.update.tests.core/webserver/bundleSite/plugins/com.example.bundle.plugin.ui_2.0.0.jar update/org.eclipse.update.tests.core/webserver/bundleSite/plugins/com.example.bundle.plugin_1.0.0.jar update/org.eclipse.update.tests.core/webserver/bundleSite/site.xml update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.budle.fragment.ui/.classpath update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.budle.fragment.ui/.project update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.budle.fragment.ui/.template update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.budle.fragment.ui/META-INF/MANIFEST.MF update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.budle.fragment.ui/build.properties update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.budle.fragment.ui/fragment.xml update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.feature/.project update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.feature/build.properties update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.feature/feature.xml update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.fragment/.classpath update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.fragment/.project update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.fragment/.template update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.fragment/META-INF/MANIFEST.MF update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.fragment/build.properties update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.fragment/fragment.xml update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin.ui/.classpath update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin.ui/.project update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin.ui/.template update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin.ui/META-INF/MANIFEST.MF update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin.ui/bin/com/example/bundle/plugin/ui/UiPlugin.class update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin.ui/build.properties update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin.ui/plugin.xml update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin.ui/src/com/example/bundle/plugin/ui/UiPlugin.java update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin/.classpath update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin/.project update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin/.template update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin/META-INF/MANIFEST.MF update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin/bin/com/example/bundle/plugin/PluginPlugin.class update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin/build.properties update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin/plugin.xml update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin/src/com/example/bundle/plugin/PluginPlugin.java update/org.eclipse.update.ui.forms/.classpath update/org.eclipse.update.ui.forms/.cvsignore update/org.eclipse.update.ui.forms/.project update/org.eclipse.update.ui.forms/about.html update/org.eclipse.update.ui.forms/build.properties update/org.eclipse.update.ui.forms/plugin.properties update/org.eclipse.update.ui.forms/plugin.xml update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/AbstractForm.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/AbstractSectionForm.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/CustomWorkbook.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/ExpandableGroup.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/FormButton.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/FormEntry.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/FormLabel.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/FormSection.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/FormWidgetFactory.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/FormsPlugin.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/FormsPluginResources.properties update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/HTMLTableLayout.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/HyperlinkAdapter.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/HyperlinkHandler.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/HyperlinkSettings.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/IForm.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/IFormPage.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/IFormSelectionListener.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/IFormTextListener.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/IFormWorkbook.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/IHyperlinkListener.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/ILayoutExtension.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/NoTabsWorkbook.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/ScrollableSectionForm.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/SectionChangeManager.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/SectionForm.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/SelectableControl.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/SelectableFormLabel.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/TableData.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/TableLayoutTest.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/ToggleControl.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/WebForm.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/BulletParagraph.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/FormEngine.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/FormEngineLayout.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/HTTPAction.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/HyperlinkAction.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/HyperlinkSegment.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/IBulletParagraph.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/IHyperlinkSegment.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/IImageSegment.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/IObjectReference.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/IParagraph.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/IParagraphSegment.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/ITextModel.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/ITextSegment.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/ImageSegment.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/Locator.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/Paragraph.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/ParagraphSegment.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/TextModel.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/TextSegment.java update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/image1.gif update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/index.xml update/org.eclipse.update.ui.win32/.classpath update/org.eclipse.update.ui.win32/.cvsignore update/org.eclipse.update.ui.win32/.project update/org.eclipse.update.ui.win32/about.html update/org.eclipse.update.ui.win32/build.properties update/org.eclipse.update.ui.win32/icons/full/clcl16/backward_nav.gif update/org.eclipse.update.ui.win32/icons/full/clcl16/forward_nav.gif update/org.eclipse.update.ui.win32/icons/full/clcl16/go_nav.gif update/org.eclipse.update.ui.win32/icons/full/clcl16/hierarchicalLayout.gif update/org.eclipse.update.ui.win32/icons/full/clcl16/home_nav.gif update/org.eclipse.update.ui.win32/icons/full/clcl16/refresh_nav.gif update/org.eclipse.update.ui.win32/icons/full/clcl16/show_unconf.gif update/org.eclipse.update.ui.win32/icons/full/clcl16/stop_nav.gif update/org.eclipse.update.ui.win32/icons/full/cview16/browser.gif update/org.eclipse.update.ui.win32/icons/full/dlcl16/backward_nav.gif update/org.eclipse.update.ui.win32/icons/full/dlcl16/forward_nav.gif update/org.eclipse.update.ui.win32/icons/full/dlcl16/go_nav.gif update/org.eclipse.update.ui.win32/icons/full/dlcl16/hierarchicalLayout.gif update/org.eclipse.update.ui.win32/icons/full/dlcl16/home_nav.gif update/org.eclipse.update.ui.win32/icons/full/dlcl16/refresh_nav.gif update/org.eclipse.update.ui.win32/icons/full/dlcl16/show_unconf.gif update/org.eclipse.update.ui.win32/icons/full/dlcl16/stop_nav.gif update/org.eclipse.update.ui.win32/icons/full/elcl16/backward_nav.gif update/org.eclipse.update.ui.win32/icons/full/elcl16/collapseall.gif update/org.eclipse.update.ui.win32/icons/full/elcl16/forward_nav.gif update/org.eclipse.update.ui.win32/icons/full/elcl16/go_nav.gif update/org.eclipse.update.ui.win32/icons/full/elcl16/hierarchicalLayout.gif update/org.eclipse.update.ui.win32/icons/full/elcl16/home_nav.gif update/org.eclipse.update.ui.win32/icons/full/elcl16/refresh_nav.gif update/org.eclipse.update.ui.win32/icons/full/elcl16/show_unconf.gif update/org.eclipse.update.ui.win32/icons/full/elcl16/stop_nav.gif update/org.eclipse.update.ui.win32/icons/full/eview16/browser.gif update/org.eclipse.update.ui.win32/icons/full/forms/def_provider.jpg update/org.eclipse.update.ui.win32/icons/full/forms/form_banner.gif update/org.eclipse.update.ui.win32/icons/full/forms/form_banner.jpg update/org.eclipse.update.ui.win32/icons/full/forms/form_underline.jpg update/org.eclipse.update.ui.win32/icons/full/forms/form_underline2.jpg update/org.eclipse.update.ui.win32/icons/full/forms/topic.gif update/org.eclipse.update.ui.win32/icons/sample.gif update/org.eclipse.update.ui.win32/plugin.properties update/org.eclipse.update.ui.win32/plugin.xml update/org.eclipse.update.ui.win32/schema/welcomePages.exsd update/org.eclipse.update.ui.win32/schema/welcomeSections.exsd update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/ShowWelcomePageAction.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/WelcomePortal.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/WelcomePortalImages.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/WelcomePortalResources.properties update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/actions/TipsAndTricksContentProvider.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/actions/WelcomeContentProvider.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/HelpSection.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/IFormContentObserver.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/IFormContentProvider.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/IPortalSectionForm.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/PortalSection.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/SectionDescriptor.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/WelcomePortalEditor.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/WelcomePortalEditorInput.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/WelcomePortalEditorInputFactory.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/WelcomePortalForm.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/WelcomePortalPage.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/WelcomePortalPart.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/WelcomeTitleArea.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/webbrowser/BrowserControlSite.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/webbrowser/GlobalActionHandler.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/webbrowser/IEmbeddedWebBrowser.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/webbrowser/IWebBrowserListener.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/webbrowser/WebBrowser.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/webbrowser/WebBrowserEditor.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/webbrowser/WebBrowserEditorContributor.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/webbrowser/WebBrowserEditorInput.java update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/webbrowser/WebBrowserEditorInputFactory.java update/org.eclipse.update.ui/.classpath update/org.eclipse.update.ui/.cvsignore update/org.eclipse.update.ui/.project update/org.eclipse.update.ui/Graphics_update.html update/org.eclipse.update.ui/about.html update/org.eclipse.update.ui/build.properties update/org.eclipse.update.ui/icons/dlcl16/collapseall.gif update/org.eclipse.update.ui/icons/dlcl16/hierarchicalLayout.gif update/org.eclipse.update.ui/icons/dlcl16/show_unconf.gif update/org.eclipse.update.ui/icons/dtool16/config_wiz.gif update/org.eclipse.update.ui/icons/dtool16/install_wiz.gif update/org.eclipse.update.ui/icons/dtool16/uninstall_wiz.gif update/org.eclipse.update.ui/icons/dtool16/update_wiz.gif update/org.eclipse.update.ui/icons/elcl16/collapseall.gif update/org.eclipse.update.ui/icons/elcl16/hierarchicalLayout.gif update/org.eclipse.update.ui/icons/elcl16/show_unconf.gif update/org.eclipse.update.ui/icons/etool16/config_wiz.gif update/org.eclipse.update.ui/icons/etool16/install_wiz.gif update/org.eclipse.update.ui/icons/etool16/uninstall_wiz.gif update/org.eclipse.update.ui/icons/etool16/update_wiz.gif update/org.eclipse.update.ui/icons/eview16/configs.gif update/org.eclipse.update.ui/icons/eview16/preview.gif update/org.eclipse.update.ui/icons/forms/def_provider.jpg update/org.eclipse.update.ui/icons/forms/form_banner.gif update/org.eclipse.update.ui/icons/forms/form_banner.jpg update/org.eclipse.update.ui/icons/forms/form_underline.jpg update/org.eclipse.update.ui/icons/forms/topic.gif update/org.eclipse.update.ui/icons/obj16/app_obj.gif update/org.eclipse.update.ui/icons/obj16/bfolder_obj.gif update/org.eclipse.update.ui/icons/obj16/category_obj.gif update/org.eclipse.update.ui/icons/obj16/config_obj.gif update/org.eclipse.update.ui/icons/obj16/efix2_obj.gif update/org.eclipse.update.ui/icons/obj16/efix_obj.gif update/org.eclipse.update.ui/icons/obj16/error_st_obj.gif update/org.eclipse.update.ui/icons/obj16/esite_obj.gif update/org.eclipse.update.ui/icons/obj16/feature_obj.gif update/org.eclipse.update.ui/icons/obj16/history_obj.gif update/org.eclipse.update.ui/icons/obj16/lsite_obj.gif update/org.eclipse.update.ui/icons/obj16/notinstalled_feature_obj.gif update/org.eclipse.update.ui/icons/obj16/ok_st_obj.gif update/org.eclipse.update.ui/icons/obj16/psite_obj.gif update/org.eclipse.update.ui/icons/obj16/site_obj.gif update/org.eclipse.update.ui/icons/obj16/unconf_feature_obj.gif update/org.eclipse.update.ui/icons/obj16/updates_obj.gif update/org.eclipse.update.ui/icons/obj16/usearch_obj.gif update/org.eclipse.update.ui/icons/obj16/web_bkmrk_obj.gif update/org.eclipse.update.ui/icons/ovr16/add_stat.gif update/org.eclipse.update.ui/icons/ovr16/current_co.gif update/org.eclipse.update.ui/icons/ovr16/del_stat.gif update/org.eclipse.update.ui/icons/ovr16/error_co.gif update/org.eclipse.update.ui/icons/ovr16/installable_co.gif update/org.eclipse.update.ui/icons/ovr16/linked_co.gif update/org.eclipse.update.ui/icons/ovr16/mod_co.gif update/org.eclipse.update.ui/icons/ovr16/unconfigured_co.gif update/org.eclipse.update.ui/icons/ovr16/updated_co.gif update/org.eclipse.update.ui/icons/ovr16/warning_co.gif update/org.eclipse.update.ui/icons/wizban/config_wiz.gif update/org.eclipse.update.ui/icons/wizban/def_wizban.jpg update/org.eclipse.update.ui/icons/wizban/install_wiz.gif update/org.eclipse.update.ui/icons/wizban/uninstall_wiz.gif update/org.eclipse.update.ui/icons/wizban/update_wiz.gif update/org.eclipse.update.ui/plugin.properties update/org.eclipse.update.ui/plugin.xml update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/AddBookmarksAction.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/ConfigurationManagerWindow.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/RestartDialog.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/UpdateLabelProvider.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/UpdateUI.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/UpdateUIImages.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/UpdateUIPluginResources.properties update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/BookmarkFolder.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/BookmarkUtil.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/ConfiguredFeatureAdapter.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/ConfiguredSiteAdapter.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/DiscoveryFolder.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/FeatureAdapter.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/FeatureReferenceAdapter.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/IConfiguredFeatureAdapter.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/IConfiguredSiteAdapter.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/IConfiguredSiteContext.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/IFeatureAdapter.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/ISiteAdapter.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/MissingFeature.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/NamedModelObject.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/SimpleFeatureAdapter.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/SiteBookmark.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/SiteCategory.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/UIModelObject.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/UpdateModel.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/parts/AbstractOverlayIcon.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/parts/DefaultContentProvider.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/parts/ImageOverlayIcon.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/parts/OverlayIcon.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/parts/PixelConverter.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/parts/SWTUtil.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/parts/SharedLabelProvider.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/preferences/MainPreferencePage.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/preferences/UpdateSettingsPreferencePage.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/properties/ConfiguredSitePropertyPage.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/properties/FeatureCopyrightPropertyPage.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/properties/FeatureGeneralPropertyPage.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/properties/FeatureLicensePropertyPage.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/properties/FeatureStatusPropertyPage.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/properties/InstallConfigurationPropertyPage.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/security/Authentication.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/security/JarVerificationDialog.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/security/JarVerificationPage.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/security/JarVerificationService.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/security/UpdateManagerAuthenticator.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/security/UserValidationDialog.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/ConfigurationPreview.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/ConfigurationView.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/FeatureStateAction.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/FindUpdatesAction.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/IPreviewTask.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/InstallOptionalFeatureAction.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/InstallationHistoryAction.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/NewExtensionLocationAction.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/ReplaceVersionAction.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/RevertConfigurationAction.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/ShowActivitiesAction.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/SiteStateAction.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/UninstallFeatureAction.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/ActivitiesTableViewer.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/BannerPage.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/DuplicateConflictsDialog.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/EditSiteDialog.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/FeatureSorter.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/IDynamicPage.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/ISearchProvider.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/InstallWizard.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/LicensePage.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/LocalSiteSelector.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/ModeSelectionPage.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/NewUpdateSiteDialog.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/NewWebSiteDialog.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/OptionalFeaturesPage.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/ReplaceFeatureVersionWizard.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/ReplaceFeatureVersionWizardPage.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/ResizableInstallWizardDialog.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/RevertConfigurationWizard.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/RevertConfigurationWizardPage.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/ReviewPage.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/SearchRunner.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/ShowActivitiesDialog.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/SitePage.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/TableLayoutComposite.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/TargetPage.java update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/UIProblemHandler.java update/org.eclipse.update.ui/src/org/eclipse/update/ui/UpdateManagerUI.java update/org.eclipse.update.ui/src_webapp/org/eclipse/update/internal/ui/servlets/InstallServlet.java update/org.eclipse.update.ui/src_webapp/org/eclipse/update/internal/ui/servlets/ServletsUtil.java update/org.eclipse.update.ui/webapp/WEB-INF/.cvsignore update/org.eclipse.update.ui/webapp/WEB-INF/lib/.cvsignore update/org.eclipse.update.ui/webapp/WEB-INF/web.xml update/org.eclipse.update.ui/webapp/images/backward_nav.gif update/org.eclipse.update.ui/webapp/images/form_banner.jpg update/org.eclipse.update.ui/webapp/images/form_underline.jpg update/org.eclipse.update/.classpath update/org.eclipse.update/.cvsignore update/org.eclipse.update/.vcm_meta update/org.eclipse.update/about.html update/org.eclipse.update/build.properties update/org.eclipse.update/icons/full/ctool16/new.gif update/org.eclipse.update/icons/full/ctool16/update.gif update/org.eclipse.update/icons/full/wizban/new.gif update/org.eclipse.update/icons/full/wizban/revert.gif update/org.eclipse.update/icons/full/wizban/update.gif update/org.eclipse.update/plugin.properties update/org.eclipse.update/plugin.xml update/org.eclipse.update/plugin.xml.off update/org.eclipse.update/src/org/eclipse/update/internal/core/ISessionDefiner.java update/org.eclipse.update/src/org/eclipse/update/internal/core/IUMLock.java update/org.eclipse.update/src/org/eclipse/update/internal/core/UMLock.java update/org.eclipse.update/src/org/eclipse/update/internal/core/UMSessionDefinerReferenceUpdate.java update/org.eclipse.update/src/org/eclipse/update/internal/core/UMSessionManager.java update/org.eclipse.update/src/org/eclipse/update/internal/core/UMSessionManagerEntry.java update/org.eclipse.update/src/org/eclipse/update/internal/core/UMSessionManagerMessage.java update/org.eclipse.update/src/org/eclipse/update/internal/core/UMSessionManagerOperation.java update/org.eclipse.update/src/org/eclipse/update/internal/core/UMSessionManagerParcel.java update/org.eclipse.update/src/org/eclipse/update/internal/core/UMSessionManagerSession.java update/org.eclipse.update/src/org/eclipse/update/internal/core/URLHandler.java update/org.eclipse.update/src/org/eclipse/update/internal/core/UpdateManager.java update/org.eclipse.update/src/org/eclipse/update/internal/core/UpdateManagerException.java update/org.eclipse.update/src/org/eclipse/update/internal/core/UpdateManagerPlugin.java update/org.eclipse.update/src/org/eclipse/update/internal/core/UpdateManagerStrings.java update/org.eclipse.update/src/org/eclipse/update/internal/core/UpdateManagerURLComparator.java update/org.eclipse.update/src/org/eclipse/update/internal/core/updatemanagerstrings.properties update/org.eclipse.update/src/org/eclipse/update/internal/ui/AuthorizationDatabase.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/Installation.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/JarVerificationDialog.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/JarVerificationResult.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/JarVerificationService.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/JarVerifier.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/KeyStores.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/Main.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMApplication.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMApplicationUserInterface.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMApplicationUserInterfaceProperties.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMApplicationWindow.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMDialog.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMDialogAction.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMPreferencePageSettings.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizard.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardPageComplete.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardPageInstallable.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardPageInstalling.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardPageLaunchHistory.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardPageLaunchHistoryComplete.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardPageLocations.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardPageURLComplete.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardPageURLInstall.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardPageURLInstallable.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardPageURLInstalling.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardPersistentProperties.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardProductComponentNew.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardProductComponentRevert.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardProductComponentURLInstall.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardProductComponentUpdate.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardTreeItem.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardTreeItemComparator.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardURLNamePairComparator.java update/org.eclipse.update/src/org/eclipse/update/internal/ui/UserValidationDialog.java
Diffstat
-rw-r--r--ant/org.eclipse.ant.tests.core/.classpath9
-rw-r--r--ant/org.eclipse.ant.tests.core/.cvsignore3
-rw-r--r--ant/org.eclipse.ant.tests.core/.externalToolBuilders/Ant Test Support Lib Builder.launch11
-rw-r--r--ant/org.eclipse.ant.tests.core/.project27
-rw-r--r--ant/org.eclipse.ant.tests.core/.settings/org.eclipse.pde.core.prefs3
-rw-r--r--ant/org.eclipse.ant.tests.core/about.html30
-rw-r--r--ant/org.eclipse.ant.tests.core/build.properties26
-rw-r--r--ant/org.eclipse.ant.tests.core/buildfiles/buildAntTestsSupportJAR.xml42
-rw-r--r--ant/org.eclipse.ant.tests.core/lib/.cvsignore1
-rw-r--r--ant/org.eclipse.ant.tests.core/plugin.properties13
-rw-r--r--ant/org.eclipse.ant.tests.core/plugin.xml79
-rw-r--r--ant/org.eclipse.ant.tests.core/test plugin/org/eclipse/ant/tests/core/testplugin/AntFileRunner.java78
-rw-r--r--ant/org.eclipse.ant.tests.core/test plugin/org/eclipse/ant/tests/core/testplugin/AntTestChecker.java229
-rw-r--r--ant/org.eclipse.ant.tests.core/test plugin/org/eclipse/ant/tests/core/testplugin/AntTestPlugin.java59
-rw-r--r--ant/org.eclipse.ant.tests.core/test plugin/org/eclipse/ant/tests/core/testplugin/AntTestPropertyValueProvider.java24
-rw-r--r--ant/org.eclipse.ant.tests.core/test plugin/org/eclipse/ant/tests/core/testplugin/ProjectHelper.java109
-rw-r--r--ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/inputHandlers/AntTestInputHandler.java36
-rw-r--r--ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/tasks/AntTestTask.java35
-rw-r--r--ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/tasks/AntTestTask2.java35
-rw-r--r--ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/testloggers/TestBuildListener.java64
-rw-r--r--ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/testloggers/TestBuildLogger.java172
-rw-r--r--ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/types/AntTestPath.java34
-rw-r--r--ant/org.eclipse.ant.tests.core/test.xml50
-rw-r--r--ant/org.eclipse.ant.tests.core/testbuildfiles/Bug32551.xml15
-rw-r--r--ant/org.eclipse.ant.tests.core/testbuildfiles/Bug34663.xml8
-rw-r--r--ant/org.eclipse.ant.tests.core/testbuildfiles/Bug42926.xml12
-rw-r--r--ant/org.eclipse.ant.tests.core/testbuildfiles/ClasspathOrdering.xml6
-rw-r--r--ant/org.eclipse.ant.tests.core/testbuildfiles/CustomTask.xml13
-rw-r--r--ant/org.eclipse.ant.tests.core/testbuildfiles/CustomType.xml16
-rw-r--r--ant/org.eclipse.ant.tests.core/testbuildfiles/ExtensionPointTask.xml5
-rw-r--r--ant/org.eclipse.ant.tests.core/testbuildfiles/ExtensionPointType.xml12
-rw-r--r--ant/org.eclipse.ant.tests.core/testbuildfiles/NoDefault.xml6
-rw-r--r--ant/org.eclipse.ant.tests.core/testbuildfiles/TestForEcho.xml11
-rw-r--r--ant/org.eclipse.ant.tests.core/testbuildfiles/build.xml14
-rw-r--r--ant/org.eclipse.ant.tests.core/testbuildfiles/echoing.xml14
-rw-r--r--ant/org.eclipse.ant.tests.core/testbuildfiles/failingTarget.xml9
-rw-r--r--ant/org.eclipse.ant.tests.core/testbuildfiles/input.xml7
-rw-r--r--ant/org.eclipse.ant.tests.core/testbuildfiles/javac.xml33
-rw-r--r--ant/org.eclipse.ant.tests.core/testlib/classpathOrdering1.jarbin663 -> 0 bytes
-rw-r--r--ant/org.eclipse.ant.tests.core/testlib/classpathOrdering2.jarbin664 -> 0 bytes
-rw-r--r--ant/org.eclipse.ant.tests.core/testlib/taskFolder/org/eclipse/ant/tests/core/support/tasks/AntTestTask2.classbin894 -> 0 bytes
-rw-r--r--ant/org.eclipse.ant.tests.core/testresources/AntTestTask.java34
-rw-r--r--ant/org.eclipse.ant.tests.core/testresources/taskdefs.properties1
-rw-r--r--ant/org.eclipse.ant.tests.core/testresources/test.properties12
-rw-r--r--ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/AbstractAntTest.java231
-rw-r--r--ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/AutomatedSuite.java95
-rw-r--r--ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/ProjectCreationDecorator.java50
-rw-r--r--ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/FrameworkTests.java222
-rw-r--r--ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/OptionTests.java605
-rw-r--r--ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/ProjectTests.java78
-rw-r--r--ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/TargetTests.java108
-rw-r--r--ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/TaskTests.java143
-rw-r--r--ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/TypeTests.java80
-rw-r--r--ant/org.eclipse.ant.tests.ui/.classpath11
-rw-r--r--ant/org.eclipse.ant.tests.ui/.cvsignore2
-rw-r--r--ant/org.eclipse.ant.tests.ui/.externalToolBuilders/Build Test Support JAR.launch10
-rw-r--r--ant/org.eclipse.ant.tests.ui/.project27
-rw-r--r--ant/org.eclipse.ant.tests.ui/.settings/org.eclipse.pde.core.prefs3
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/dtd/dumper.java147
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/AntEditorContentOutlineTests.java207
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/CodeCompletionTest.java748
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/TaskDescriptionProviderTest.java65
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/formatter/FormattingPreferencesTest.java63
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/formatter/XmlDocumentFormatterTest.java99
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/formatter/XmlFormatterTest.java53
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/formatter/XmlTagFormatterTest.java391
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/support/TestEditor.java31
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/support/TestLocationProvider.java36
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/support/TestProblemRequestor.java39
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/support/TestTextCompletionProcessor.java167
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant Tests/org/eclipse/ant/tests/ui/AbstractAntUIBuildTest.java91
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant Tests/org/eclipse/ant/tests/ui/BuildTests.java171
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant Tests/org/eclipse/ant/tests/ui/separateVM/SeparateVMTests.java151
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Ext Dir Test Example/.project11
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Ext Dir Test Example/build.xml15
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Ext Dir Test Example/readme.txt4
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/.classpath6
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/.project17
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/bin.log2
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/bin/main.classbin403 -> 0 bytes
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/build.xml40
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/src/main.classbin731 -> 0 bytes
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/src/main.java13
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/.project11
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Buildfile Error/build.xml44
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Custom Build filename/customBuild.xml39
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Missing default target/build.xml27
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Missing project element/build.xml27
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Missing project name/build.xml27
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Similar Dependencies/build.xml15
-rw-r--r--ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Simple Dependency/build.xml9
-rw-r--r--ant/org.eclipse.ant.tests.ui/External Tools/org/eclipse/ant/tests/ui/externaltools/MigrationTests.java227
-rw-r--r--ant/org.eclipse.ant.tests.ui/about.html30
-rw-r--r--ant/org.eclipse.ant.tests.ui/build.properties27
-rw-r--r--ant/org.eclipse.ant.tests.ui/buildfiles/buildAntTestsSupportJAR.xml42
-rw-r--r--ant/org.eclipse.ant.tests.ui/icons/ant.gifbin216 -> 0 bytes
-rw-r--r--ant/org.eclipse.ant.tests.ui/lib/.cvsignore1
-rw-r--r--ant/org.eclipse.ant.tests.ui/plugin.properties13
-rw-r--r--ant/org.eclipse.ant.tests.ui/plugin.xml85
-rw-r--r--ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/AbstractAntUITest.java344
-rw-r--r--ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/AntUITestPlugin.java63
-rw-r--r--ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/AntUITests.java53
-rw-r--r--ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/ConsoleLineTracker.java112
-rw-r--r--ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/DebugElementKindEventWaiter.java36
-rw-r--r--ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/DebugEventWaiter.java170
-rw-r--r--ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/ProjectCreationDecorator.java111
-rw-r--r--ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/ProjectHelper.java138
-rw-r--r--ant/org.eclipse.ant.tests.ui/test support/org/eclipse/ant/tests/ui/support/tasks/AntTestTask.java33
-rw-r--r--ant/org.eclipse.ant.tests.ui/test support/org/eclipse/ant/tests/ui/support/tasks/AntTestTask2.java55
-rw-r--r--ant/org.eclipse.ant.tests.ui/test support/org/eclipse/ant/tests/ui/support/tasks/NestElementTask.java52
-rw-r--r--ant/org.eclipse.ant.tests.ui/test support/org/eclipse/ant/tests/ui/support/types/AntTestPath.java32
-rw-r--r--ant/org.eclipse.ant.tests.ui/test.xml50
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/antUITestsSupport.jarbin3224 -> 0 bytes
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/bad.xml14
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/badproject.xml4
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/build.Cp1251.xml10
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/build.UTF8.xml9
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/build.xml14
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/buildtest1.properties2
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/buildtest1.xml21
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/buildtest2.xml5
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/customBoolean.xml5
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/dependencytest.xml38
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/echoing.xml14
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/echoingSepVM.xml19
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/empty.xml0
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/extensionPointSepVM.xml14
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/extensionPointTaskSepVM.xml5
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/extensionPointTypeSepVM.xml12
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/formatTest_source01.xml14
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/formatTest_target01.xml21
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/formatTest_target02.xml21
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/formatTest_target03.xml21
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/javac.xml7
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/macrodef.xml18
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/mixed.xml1
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/nestedElementAttributes.xml8
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/outline_select_test_build.xml20
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/projectOnly.xml4
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/refid.xml13
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/russianbuild.xml8
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/taskdef.xml10
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/test1.xml10
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/test2.xml9
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/test3.xml4
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/test4.xml1
-rw-r--r--ant/org.eclipse.ant.tests.ui/testbuildfiles/test5.xml6
-rw-r--r--platform/org.eclipse.platform/css/whatsnew/swt.properties5
-rw-r--r--platform/org.eclipse.platform/css/whatsnew/whatsnew.css53
-rw-r--r--platform/org.eclipse.platform/introContent.xml9
-rw-r--r--platform/org.eclipse.sdk/.project11
-rw-r--r--platform/org.eclipse.sdk/about.html30
-rw-r--r--platform/org.eclipse.sdk/about.ini31
-rw-r--r--platform/org.eclipse.sdk/about.mappings6
-rw-r--r--platform/org.eclipse.sdk/about.properties14
-rw-r--r--platform/org.eclipse.sdk/build.properties8
-rw-r--r--platform/org.eclipse.sdk/eclipse32.gifbin1750 -> 0 bytes
-rw-r--r--platform/org.eclipse.sdk/plugin.properties21
-rw-r--r--platform/org.eclipse.sdk/plugin.xml156
-rw-r--r--update/org.eclipse.update.configurator/.classpath7
-rw-r--r--update/org.eclipse.update.configurator/.cvsignore2
-rw-r--r--update/org.eclipse.update.configurator/.options5
-rw-r--r--update/org.eclipse.update.configurator/.project32
-rw-r--r--update/org.eclipse.update.configurator/about.html30
-rw-r--r--update/org.eclipse.update.configurator/build.properties9
-rw-r--r--update/org.eclipse.update.configurator/config.ini60
-rw-r--r--update/org.eclipse.update.configurator/plugin.properties14
-rw-r--r--update/org.eclipse.update.configurator/plugin.xml30
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/configurator/ConfiguratorUtils.java80
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/configurator/IPlatformConfiguration.java583
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/configurator/IPlatformConfigurationFactory.java41
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/configurator/package.html22
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/BootDescriptor.java44
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/BundleManifest.java130
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/Configuration.java163
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/ConfigurationActivator.java483
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/ConfigurationParser.java362
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/FeatureEntry.java354
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/FeatureParser.java135
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/FullFeatureParser.java149
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/IConfigurationConstants.java64
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/Messages.java69
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/PlatformConfiguration.java1169
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/PlatformConfigurationFactory.java34
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/PluginEntry.java157
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/PluginParser.java117
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/ProductProvider.java46
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/SiteEntry.java744
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/SitePolicy.java59
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/Utils.java259
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/VersionedIdentifier.java153
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/branding/AboutInfo.java253
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/branding/IBundleGroupConstants.java49
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/branding/IProductConstants.java77
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/branding/IniFileReader.java378
-rw-r--r--update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/messages.properties90
-rw-r--r--update/org.eclipse.update.core.linux/.classpath7
-rw-r--r--update/org.eclipse.update.core.linux/.cvsignore1
-rw-r--r--update/org.eclipse.update.core.linux/.project33
-rw-r--r--update/org.eclipse.update.core.linux/about.html30
-rw-r--r--update/org.eclipse.update.core.linux/build.properties17
-rw-r--r--update/org.eclipse.update.core.linux/fragment.xml16
-rw-r--r--update/org.eclipse.update.core.linux/os/linux/x86/libupdate.sobin5993 -> 0 bytes
-rw-r--r--update/org.eclipse.update.core.linux/src/build.xml70
-rw-r--r--update/org.eclipse.update.core.linux/src/update.c162
-rw-r--r--update/org.eclipse.update.core.linux/src/update.h76
-rw-r--r--update/org.eclipse.update.core.win32/.project22
-rw-r--r--update/org.eclipse.update.core.win32/about.html30
-rw-r--r--update/org.eclipse.update.core.win32/build.properties17
-rw-r--r--update/org.eclipse.update.core.win32/fragment.xml16
-rw-r--r--update/org.eclipse.update.core.win32/os/win32/x86/update.dllbin54784 -> 0 bytes
-rw-r--r--update/org.eclipse.update.core.win32/src/build.xml74
-rw-r--r--update/org.eclipse.update.core.win32/src/update.cpp487
-rw-r--r--update/org.eclipse.update.core.win32/src/update.h79
-rw-r--r--update/org.eclipse.update.core/.classpath7
-rw-r--r--update/org.eclipse.update.core/.cvsignore1
-rw-r--r--update/org.eclipse.update.core/.options9
-rw-r--r--update/org.eclipse.update.core/.project31
-rw-r--r--update/org.eclipse.update.core/Scrapbook.jpage431
-rw-r--r--update/org.eclipse.update.core/about.html30
-rw-r--r--update/org.eclipse.update.core/build.properties19
-rw-r--r--update/org.eclipse.update.core/plugin.properties16
-rw-r--r--update/org.eclipse.update.core/plugin.xml86
-rw-r--r--update/org.eclipse.update.core/preferences.ini8
-rw-r--r--update/org.eclipse.update.core/schema/featureTypes.exsd119
-rw-r--r--update/org.eclipse.update.core/schema/installHandlers.exsd110
-rw-r--r--update/org.eclipse.update.core/schema/siteTypes.exsd116
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/configuration/IActivity.java259
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/configuration/IConfiguredSite.java372
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/configuration/IConfiguredSiteChangedListener.java83
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/configuration/IInstallConfiguration.java234
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/configuration/IInstallConfigurationChangedListener.java53
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/configuration/IInstallDeltaHandler.java55
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/configuration/ILocalSite.java269
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/configuration/ILocalSiteChangedListener.java52
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/configuration/ILocalSystemInfoListener.java53
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/configuration/IProblemHandler.java44
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/configuration/ISessionDelta.java149
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/configuration/IVolume.java104
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/configuration/LocalSystemInfo.java432
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/configuration/package.html25
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/ArchiveReference.java55
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/BaseFeatureFactory.java135
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/BaseInstallHandler.java251
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/BaseSiteFactory.java148
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/Category.java53
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/ContentReference.java334
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/Feature.java1128
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/FeatureContentProvider.java588
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/FeatureReference.java288
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/IArchiveReference.java53
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/ICategory.java64
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/IContentConsumer.java57
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/IFeature.java479
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/IFeatureContentConsumer.java165
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/IFeatureContentProvider.java268
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/IFeatureFactory.java71
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/IFeatureReference.java120
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/IImport.java94
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/IIncludedFeatureReference.java128
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/IInstallHandler.java244
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/IInstallHandlerEntry.java76
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/INonPluginEntry.java68
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/IPlatformEnvironment.java102
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/IPluginEntry.java86
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/ISite.java328
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/ISiteContentProvider.java78
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/ISiteFactory.java56
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/ISiteFactoryExtension.java59
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/ISiteFeatureReference.java50
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/IURLEntry.java66
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/IUpdateConstants.java83
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/IVerificationListener.java79
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/IVerificationResult.java161
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/IVerifier.java75
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/Import.java88
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/IncludedFeatureReference.java143
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/InstallHandlerEntry.java42
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/InstallMonitor.java273
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/JarContentReference.java366
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/JarEntryContentReference.java117
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/NonPluginEntry.java40
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/PluginEntry.java94
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/Site.java527
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/SiteContentProvider.java88
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/SiteFeatureReference.java94
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/SiteFeatureReferenceModel.java114
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/SiteManager.java314
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/URLEntry.java57
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/Utilities.java334
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/Verifier.java62
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/VersionedIdentifier.java122
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/model/ArchiveReferenceModel.java118
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/model/CategoryModel.java224
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/model/ContentEntryModel.java196
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/model/DefaultFeatureParser.java1203
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/model/DefaultSiteParser.java723
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/model/FeatureModel.java942
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/model/FeatureModelFactory.java156
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/model/FeatureReferenceModel.java422
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/model/ImportModel.java278
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/model/IncludedFeatureReferenceModel.java158
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/model/InstallAbortedException.java35
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/model/InstallHandlerEntryModel.java142
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/model/InvalidSiteTypeException.java50
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/model/ModelObject.java382
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/model/NonPluginEntryModel.java63
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/model/PluginEntryModel.java163
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/model/SiteModel.java367
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/model/SiteModelFactory.java151
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/model/URLEntryModel.java180
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/model/package.html23
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/core/package.html25
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/Assert.java166
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/BaseSiteLocalFactory.java55
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/ConfigurationActivity.java82
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/ConfigurationPolicy.java512
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/ConfiguredSite.java1104
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/ConnectionThreadManager.java197
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/ContentConsumer.java24
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/DefaultInstallHandler.java147
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/DeltaInstallHandler.java166
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/ErrorRecoveryLog.java550
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/FeatureContentConsumer.java26
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/FeatureDownloadException.java36
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/FeatureExecutableContentConsumer.java180
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/FeatureExecutableContentProvider.java273
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/FeatureExecutableFactory.java116
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/FeaturePackagedContentProvider.java273
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/FeaturePackagedFactory.java77
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/FeaturePlugin.java46
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/FeatureTypeFactory.java86
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/FileFragment.java30
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/FileResponse.java56
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/FragmentEntry.java71
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/HttpResponse.java163
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/ISiteContentConsumer.java66
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/IStatusCodes.java64
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/IWritable.java27
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/InstallConfiguration.java865
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/InstallHandlerProxy.java503
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/InstallLogParser.java228
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/InstallRegistry.java180
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/InternalSiteManager.java359
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/ListenersList.java164
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/NonPluginEntryContentConsumer.java55
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/OtherResponse.java62
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/PatchedFeature.java101
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/PluginEntryContentConsumer.java55
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/Policy.java93
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/Response.java69
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/SiteContentConsumer.java45
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/SiteFile.java431
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/SiteFileContentConsumer.java296
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/SiteFileContentProvider.java72
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/SiteFileFactory.java387
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/SiteFileNonPluginContentConsumer.java75
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/SiteFilePackedPluginContentConsumer.java134
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/SiteFilePluginContentConsumer.java181
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/SiteLocal.java363
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/SiteReconciler.java462
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/SiteStatusAnalyzer.java357
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/SiteTypeFactory.java88
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/SiteURLContentProvider.java77
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/SiteURLFactory.java89
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/TargetFeature.java52
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/URLEncoder.java138
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/URLKey.java76
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/UpdateCore.java319
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/UpdateManagerLogWriter.java291
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/UpdateManagerUtils.java952
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/UpdatePreferencesInitializer.java61
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/Volume.java70
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/core/messages.properties328
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/mirror/MirrorCommand.java228
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/mirror/MirrorSite.java749
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/mirror/MirrorSiteFactory.java224
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/model/BundleManifest.java111
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/model/ConfigurationActivityModel.java115
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/model/ConfigurationPolicyModel.java277
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/model/ConfiguredSiteModel.java177
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/model/DefaultPluginParser.java104
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/model/InstallConfigurationModel.java296
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/model/InstallConfigurationParser.java193
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/model/SiteLocalModel.java279
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/model/SiteLocalParser.java128
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/operations/BatchInstallOperation.java108
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/operations/ConfigOperation.java79
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/operations/DuplicateConflictsValidator.java223
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/operations/FeatureHierarchyElement.java445
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/operations/FeatureOperation.java69
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/operations/FeatureStatus.java57
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/operations/InstallOperation.java151
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/operations/JobRoot.java101
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/operations/Operation.java31
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/operations/OperationFactory.java77
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/operations/OperationValidator.java1282
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/operations/PatchCleaner.java64
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/operations/ReplaceFeatureVersionOperation.java100
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/operations/RevertConfigurationOperation.java54
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/operations/ToggleSiteOperation.java58
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/operations/UnconfigOperation.java82
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/operations/UninstallOperation.java80
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/operations/UpdateUtils.java605
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/search/BaseSearchCategory.java30
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/search/OptionalFeatureSearchCategory.java98
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/search/QueryUpdateSiteAdapter.java28
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/search/SiteSearchCategory.java93
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/search/UpdatePolicy.java238
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/search/UpdateSiteAdapter.java45
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/search/UpdatesSearchCategory.java528
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/security/CertificatePair.java73
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/security/JarVerificationResult.java327
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/security/JarVerifier.java430
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/security/KeyStores.java211
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/internal/security/KeystoreHandle.java62
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/operations/IBatchOperation.java30
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/operations/IConfigFeatureOperation.java24
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/operations/IFeatureOperation.java48
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/operations/IInstallFeatureOperation.java31
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/operations/IOperation.java47
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/operations/IOperationFactory.java109
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/operations/IOperationListener.java38
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/operations/IOperationValidator.java77
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/operations/IReplaceFeatureVersionOperation.java24
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/operations/IRevertConfigurationOperation.java24
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/operations/IToggleSiteOperation.java24
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/operations/IUnconfigFeatureOperation.java25
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/operations/IUninstallFeatureOperation.java26
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/operations/IUpdateModelChangedListener.java45
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/operations/OperationsManager.java240
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/operations/package.html22
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/search/BackLevelFilter.java52
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/search/BaseFilter.java35
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/search/EnvironmentFilter.java35
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/search/IQueryUpdateSiteAdapter.java35
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/search/IUpdateSearchCategory.java46
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/search/IUpdateSearchFilter.java41
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/search/IUpdateSearchQuery.java53
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/search/IUpdateSearchResultCollector.java36
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/search/IUpdateSearchSite.java37
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/search/IUpdateSiteAdapter.java40
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/search/UpdateSearchRequest.java346
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/search/UpdateSearchScope.java127
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/search/VersionedIdentifiersFilter.java63
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/search/package.html21
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/standalone/AddSiteCommand.java86
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/standalone/CmdLineArgs.java151
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/standalone/DisableCommand.java136
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/standalone/EnableCommand.java137
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/standalone/InstallCommand.java210
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/standalone/ListFeaturesCommand.java89
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/standalone/RemoveSiteCommand.java87
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/standalone/ScriptedCommand.java109
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/standalone/SearchCommand.java91
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/standalone/StandaloneUpdateApplication.java69
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/standalone/UninstallCommand.java139
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/standalone/UpdateCommand.java218
-rw-r--r--update/org.eclipse.update.core/src/org/eclipse/update/standalone/package.html23
-rw-r--r--update/org.eclipse.update.examples/.classpath10
-rw-r--r--update/org.eclipse.update.examples/.cvsignore1
-rw-r--r--update/org.eclipse.update.examples/.project33
-rw-r--r--update/org.eclipse.update.examples/Scrapbook2.jpage111
-rw-r--r--update/org.eclipse.update.examples/about.html42
-rw-r--r--update/org.eclipse.update.examples/build.properties3
-rw-r--r--update/org.eclipse.update.examples/plugin.properties3
-rw-r--r--update/org.eclipse.update.examples/plugin.xml43
-rw-r--r--update/org.eclipse.update.examples/site/features/com.reddot.reddot_1.0.0.jarbin10284 -> 0 bytes
-rw-r--r--update/org.eclipse.update.examples/site/features/com.reddot.reddot_2.0.0.jarbin16134 -> 0 bytes
-rw-r--r--update/org.eclipse.update.examples/site/info/images/redDot.jpgbin1859 -> 0 bytes
-rw-r--r--update/org.eclipse.update.examples/site/info/siteInfo.html33
-rw-r--r--update/org.eclipse.update.examples/site/plugins/com.reddot.reddot_1.0.0.jarbin3149 -> 0 bytes
-rw-r--r--update/org.eclipse.update.examples/site/plugins/com.reddot.reddot_2.0.0.jarbin3152 -> 0 bytes
-rw-r--r--update/org.eclipse.update.examples/site/site.xml19
-rw-r--r--update/org.eclipse.update.examples/src/org/eclipse/update/examples/buildzip/BuildZipConverter.java157
-rw-r--r--update/org.eclipse.update.examples/src/org/eclipse/update/examples/buildzip/BuildZipFeatureContentProvider.java256
-rw-r--r--update/org.eclipse.update.examples/src/org/eclipse/update/examples/buildzip/BuildZipFeatureFactory.java63
-rw-r--r--update/org.eclipse.update.examples/src/org/eclipse/update/examples/buildzip/BuildZipFeatureParser.java203
-rw-r--r--update/org.eclipse.update.examples/src/org/eclipse/update/examples/buildzip/BuildZipPluginParser.java85
-rw-r--r--update/org.eclipse.update.examples/src/org/eclipse/update/examples/buildzip/BuildZipSiteContentProvider.java31
-rw-r--r--update/org.eclipse.update.examples/src/org/eclipse/update/examples/buildzip/BuildZipSiteFactory.java85
-rw-r--r--update/org.eclipse.update.examples/src/org/eclipse/update/examples/buildzip/DefaultModelWriter.java228
-rw-r--r--update/org.eclipse.update.examples/src/org/eclipse/update/examples/buildzip/Test.java55
-rw-r--r--update/org.eclipse.update.examples/src/org/eclipse/update/examples/buildzip/java.page.jpage43
-rw-r--r--update/org.eclipse.update.examples/src/org/eclipse/update/examples/freeform/FreeFormSiteContentProvider.java34
-rw-r--r--update/org.eclipse.update.examples/src/org/eclipse/update/examples/freeform/FreeFormSiteFactory.java69
-rw-r--r--update/org.eclipse.update.scheduler/.classpath7
-rw-r--r--update/org.eclipse.update.scheduler/.cvsignore1
-rw-r--r--update/org.eclipse.update.scheduler/.project39
-rw-r--r--update/org.eclipse.update.scheduler/about.html30
-rw-r--r--update/org.eclipse.update.scheduler/build.properties6
-rw-r--r--update/org.eclipse.update.scheduler/plugin.properties16
-rw-r--r--update/org.eclipse.update.scheduler/plugin.xml43
-rw-r--r--update/org.eclipse.update.scheduler/src/org/eclipse/update/internal/scheduler/AutomaticUpdatesJob.java188
-rw-r--r--update/org.eclipse.update.scheduler/src/org/eclipse/update/internal/scheduler/SchedulerStartup.java225
-rw-r--r--update/org.eclipse.update.scheduler/src/org/eclipse/update/internal/scheduler/UpdateScheduler.java187
-rw-r--r--update/org.eclipse.update.scheduler/src/org/eclipse/update/internal/scheduler/UpdateSchedulerResources.properties48
-rw-r--r--update/org.eclipse.update.scheduler/src/org/eclipse/update/internal/scheduler/preferences/AutomaticUpdatesPreferencePage.java229
-rw-r--r--update/org.eclipse.update.tests.core/.classpath7
-rw-r--r--update/org.eclipse.update.tests.core/.cvsignore1
-rw-r--r--update/org.eclipse.update.tests.core/.project38
-rw-r--r--update/org.eclipse.update.tests.core/about.html30
-rw-r--r--update/org.eclipse.update.tests.core/build.properties12
-rw-r--r--update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data/features/feature3/feature.xml12
-rw-r--r--update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data/plugins/Pde_core.jarbin65389 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data/plugins/help.jarbin364483 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data/plugins/junit_3.7.jarbin258684 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data/plugins/org.eclipse.update.plugin1_1.1.1/plugin.xml8
-rw-r--r--update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data/plugins/org.eclipse.update.plugin1_1.1.1/src.jarbin627 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/features/feature3/feature.xml12
-rw-r--r--update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/features/helpFeature.jarbin62392 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/features/org.eclipse.pde.feature_1.0.0.jarbin60984 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/info/img/top_titlsm.gifbin3083 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/info/img/wel_ml.jpgbin11159 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/info/siteInfo.html63
-rw-r--r--update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/plugins/Pde_core.jarbin65389 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/plugins/help.jarbin364483 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/plugins/junit_3.7.jarbin258684 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/plugins/org.eclipse.update.plugin1_1.1.1/plugin.xml8
-rw-r--r--update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/plugins/org.eclipse.update.plugin1_1.1.1/src.jarbin627 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/ExecutableFeaturePackagedSite/data2/site.xml22
-rw-r--r--update/org.eclipse.update.tests.core/data/FTPLikeSite/site.xml4
-rw-r--r--update/org.eclipse.update.tests.core/data/FeatureTypeExamples/site1/features/feature3/feature.xml12
-rw-r--r--update/org.eclipse.update.tests.core/data/FeatureTypeExamples/site1/site.xml4
-rw-r--r--update/org.eclipse.update.tests.core/data/FeatureTypeExamples/site2/features/feature3/features2.jarfilebin1401 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/FeatureTypeExamples/site2/site.xml4
-rw-r--r--update/org.eclipse.update.tests.core/data/FeatureTypeExamples/site3/features/feature3/features2.jarfilebin1401 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/FeatureTypeExamples/site3/site.xml4
-rw-r--r--update/org.eclipse.update.tests.core/data/Site with space/features space/helpFeature.jarbin62392 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/Site with space/features space/space feature.jarbin61296 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/Site with space/info/img/top_titlsm.gifbin3083 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/Site with space/info/img/wel_ml.jpgbin11159 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/Site with space/info/siteInfo.html63
-rw-r--r--update/org.eclipse.update.tests.core/data/Site with space/install/features space/feature3/feature.xml12
-rw-r--r--update/org.eclipse.update.tests.core/data/Site with space/plugins space/Pde_core.jarbin65389 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/Site with space/plugins space/help.jarbin364483 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/Site with space/plugins space/junit_3.7.jarbin258684 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/Site with space/plugins space/org.eclipse.update.plugin1_1.1.1/plugin.xml8
-rw-r--r--update/org.eclipse.update.tests.core/data/Site with space/plugins space/org.eclipse.update.plugin1_1.1.1/src.jarbin627 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/Site with space/site.xml22
-rw-r--r--update/org.eclipse.update.tests.core/data/SiteTypeExamples/site1/features/feature3/features2.jarfilebin1401 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/SiteTypeExamples/site1/site.xml4
-rw-r--r--update/org.eclipse.update.tests.core/data/SiteURLTest/data/artifacts/features/helpFeature.jarbin62404 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/SiteURLTest/data/artifacts/features/org.eclipse.pde.feature_1.0.0.jarbin60998 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/SiteURLTest/data/artifacts/plugins/Pde_core.jarbin65389 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/SiteURLTest/data/artifacts/plugins/help.jarbin364483 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/SiteURLTest/data/artifacts/plugins/junit_3.7.jarbin258684 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/SiteURLTest/data/info/img/top_titlsm.gifbin3083 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/SiteURLTest/data/info/img/wel_ml.jpgbin11159 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/SiteURLTest/data/info/siteInfo.html63
-rw-r--r--update/org.eclipse.update.tests.core/data/SiteURLTest/data/site.xml18
-rw-r--r--update/org.eclipse.update.tests.core/data/dataEntrySiteTest/site1/file1.zipbin163 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/dataEntrySiteTest/site1/install/features/feature3/feature.xml5
-rw-r--r--update/org.eclipse.update.tests.core/data/dataEntrySiteTest/site1/site.xml7
-rw-r--r--update/org.eclipse.update.tests.core/data/dataEntrySiteTest/site2/features/features3.jarbin986 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/dataEntrySiteTest/site2/non data/another file.zipbin163 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/dataEntrySiteTest/site2/site.xml7
-rw-r--r--update/org.eclipse.update.tests.core/data/features/features2.jarbin1478 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/features/org.eclipse.test.feature_1.0.0.jarbin909 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/features/org.eclipse.update.core.tests.feature1_1.0.4.jarbin960 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/features/org.eclipse_test_feature.jarbin928 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site1/.project17
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site1/.sitebuild/build.log318
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site1/.sitebuild/sitebuild.xml11
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site1/features/update.feature1_1.0.0.jarbin660 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site1/features/update.feature2_1.0.0.jarbin661 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site1/features/update.feature3_1.0.0.jarbin667 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site1/plugins/com.plugin1_1.0.0.jarbin953 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site1/plugins/com.plugin2_1.0.0.jarbin1341 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site1/plugins/com.plugin3_1.0.0.jarbin1730 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site1/plugins/com.plugin4_1.0.0.jarbin2118 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site1/site.xml27
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site2/.project17
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site2/.sitebuild/build.log203
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site2/.sitebuild/sitebuild.xml10
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site2/features/update.feature1_1.0.0.jarbin659 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site2/features/update.feature2_1.0.0.jarbin661 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site2/plugins/com.plugin1_1.0.0.jarbin953 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site2/plugins/com.plugin2_1.0.0.jarbin1341 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site2/site.xml5
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site3/.project17
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site3/.sitebuild/build.log318
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site3/.sitebuild/sitebuild.xml10
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site3/features/update.feature1b_2.0.0.jarbin672 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site3/features/update.feature2b_2.0.0.jarbin672 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site3/plugins/com.plugin1_1.0.0.jarbin953 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site3/plugins/com.plugin1a_1.0.1.jarbin1344 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site3/plugins/com.plugin2_1.0.0.jarbin2123 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site3/plugins/com.plugin2a_1.0.1.jarbin1736 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site3/site.xml19
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site4/.project17
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site4/.sitebuild/build.log791
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site4/.sitebuild/sitebuild.xml9
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site4/features/update.feature1_1.0.0.jarbin660 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site4/features/update.feature1_1.0.1.jarbin505 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site4/features/update.feature1b_2.0.0.jarbin672 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site4/features/update.feature1c_3.0.0.jarbin614 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site4/plugins/com.plugin1_1.0.0.jarbin953 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site4/plugins/com.plugin1a_1.0.1.jarbin1344 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site4/site.xml11
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site5/.project17
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site5/.sitebuild/build.log791
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site5/.sitebuild/sitebuild.xml10
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site5/features/update.feature1_1.0.0.jarbin660 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site5/features/update.feature1_1.0.1.jarbin505 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site5/features/update.feature1b_2.0.0.jarbin672 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site5/features/update.feature1c_3.0.0.jarbin614 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site5/features/update.feature2_1.0.0.jarbin661 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site5/features/update.feature2b_2.0.0.jarbin672 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site5/features/update.feature2c_3.0.0.jarbin614 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site5/plugins/com.plugin1_1.0.0.jarbin954 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site5/plugins/com.plugin1a_1.0.1.jarbin1346 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site5/plugins/com.plugin2_1.0.0.jarbin2127 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site5/plugins/com.plugin2a_1.0.1.jarbin2128 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/mirrors/update-site5/site.xml19
-rw-r--r--update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest/features/org.eclipse.update.core.tests.childrenfeature_2.0.0.jarbin770 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest/features/rootfeature.jarbin756 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest/plugins/org.eclipse.update.core.tests.feature1.plugin1_3.5.6.jarbin985 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest/plugins/org.eclipse.update.core.tests.feature1.plugin2_5.0.0.jarbin986 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest/plugins/org.eclipse.update.core.tests.feature1.plugin2_5.0.1.jarbin985 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest/site.xml4
-rw-r--r--update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest2/features/childrenfeature.jarbin778 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest2/features/rootfeature.jarbin773 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest2/plugins/org.eclipse.update.core.tests.feature1.plugin1_3.5.6.jarbin985 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest2/plugins/org.eclipse.update.core.tests.feature1.plugin2_5.0.0.jarbin986 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest2/plugins/org.eclipse.update.core.tests.feature1.plugin2_5.0.1.jarbin985 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest2/site.xml7
-rw-r--r--update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest3/features/childrenfeature.jarbin826 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest3/features/rootfeature.jarbin797 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest3/plugins/org.eclipse.update.core.tests.feature1.plugin1_3.5.6.jarbin985 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest3/plugins/org.eclipse.update.core.tests.feature1.plugin2_5.0.0.jarbin986 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest3/plugins/org.eclipse.update.core.tests.feature1.plugin2_5.0.1.jarbin985 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/nestedFeatureSiteTest3/site.xml6
-rw-r--r--update/org.eclipse.update.tests.core/data/parsertests/feature1.xml25
-rw-r--r--update/org.eclipse.update.tests.core/data/parsertests/feature1bis.xml25
-rw-r--r--update/org.eclipse.update.tests.core/data/parsertests/feature2.xml24
-rw-r--r--update/org.eclipse.update.tests.core/data/parsertests/feature3.xml25
-rw-r--r--update/org.eclipse.update.tests.core/data/parsertests/feature4.xml26
-rw-r--r--update/org.eclipse.update.tests.core/data/parsertests/reddot.xml19
-rw-r--r--update/org.eclipse.update.tests.core/data/parsertests/reddot1.xml18
-rw-r--r--update/org.eclipse.update.tests.core/data/parsertests/site.properties12
-rw-r--r--update/org.eclipse.update.tests.core/data/parsertests/site.xml40
-rw-r--r--update/org.eclipse.update.tests.core/data/parsertests/site10.xml12
-rw-r--r--update/org.eclipse.update.tests.core/data/parsertests/site2.xml4
-rw-r--r--update/org.eclipse.update.tests.core/data/parsertests/site3.xml6
-rw-r--r--update/org.eclipse.update.tests.core/data/parsertests/site4.xml20
-rw-r--r--update/org.eclipse.update.tests.core/data/parsertests/site7.xml42
-rw-r--r--update/org.eclipse.update.tests.core/data/parsertests/site8.xml41
-rw-r--r--update/org.eclipse.update.tests.core/data/parsertests/site9.xml40
-rw-r--r--update/org.eclipse.update.tests.core/data/parsertests/siteftp.xml4
-rw-r--r--update/org.eclipse.update.tests.core/data/plugins/org.eclipse.update.core.feature1.plugin1_1.1.1.jarbin460 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/plugins/org.eclipse.update.core.feature2.plugin2_2.2.2.jarbin460 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/plugins/org.eclipse.update.core.tests.dummy_7.9.8.jarbin5931 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/plugins/org.eclipse.update.core.tests.feature1.plugin1_3.5.6.jarbin973 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/plugins/org.eclipse.update.core.tests.feature1.plugin2_5.0.0.jarbin974 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/plugins/org.eclipse.update.plugin1_1.1.1/plugin.xml8
-rw-r--r--update/org.eclipse.update.tests.core/data/plugins/org.eclipse.update.plugin1_1.1.1/src.jarbin627 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/reconciliationSites/site1/install/features/feature3/feature.xml12
-rw-r--r--update/org.eclipse.update.tests.core/data/reconciliationSites/site1/plugins/org.eclipse.update.plugin1_1.1.1/plugin.xml8
-rw-r--r--update/org.eclipse.update.tests.core/data/reconciliationSites/site1/plugins/org.eclipse.update.plugin1_1.1.1/src.jarbin627 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/reconciliationSites/site2/install/features/feature3/feature.xml12
-rw-r--r--update/org.eclipse.update.tests.core/data/reconciliationSites/site2/plugins/org.eclipse.update.core_2.0.0/plugin.xml8
-rw-r--r--update/org.eclipse.update.tests.core/data/reconciliationSites/site2/plugins/org.eclipse.update.core_2.0.0/src.jarbin627 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/resources.properties13
-rw-r--r--update/org.eclipse.update.tests.core/data/site.xml19
-rw-r--r--update/org.eclipse.update.tests.core/data/site2/site.xml6
-rw-r--r--update/org.eclipse.update.tests.core/data/siteTestLocalSite/plugins/bundleAndPluginManifests_1.0.3/META-INF/MANIFEST.MF11
-rw-r--r--update/org.eclipse.update.tests.core/data/siteTestLocalSite/plugins/bundleAndPluginManifests_1.0.3/plugin.xml3
-rw-r--r--update/org.eclipse.update.tests.core/data/siteTestLocalSite/plugins/bundleManifest_1.0.1/META-INF/MANIFEST.MF11
-rw-r--r--update/org.eclipse.update.tests.core/data/siteTestLocalSite/plugins/feature1_plugin2_5.0.0/plugin.xml8
-rw-r--r--update/org.eclipse.update.tests.core/data/siteTestLocalSite/plugins/feature1_plugin2_5.0.0/src.jarbin627 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/siteTestLocalSite/plugins/feature1_plugin2_5.0.1/plugin.xml8
-rw-r--r--update/org.eclipse.update.tests.core/data/siteTestLocalSite/plugins/feature1_plugin2_5.0.1/src.jarbin627 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/siteTestLocalSite/plugins/notBundleManifest_1.0.2/META-INF/MANIFEST.MF8
-rw-r--r--update/org.eclipse.update.tests.core/data/testAPI/features/feature3/feature.xml12
-rw-r--r--update/org.eclipse.update.tests.core/data/testAPI/plugins/org.eclipse.update.plugin1_1.1.1/plugin.xml8
-rw-r--r--update/org.eclipse.update.tests.core/data/testAPI/plugins/org.eclipse.update.plugin1_1.1.1/src.jarbin627 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/testAPI/site.xml19
-rw-r--r--update/org.eclipse.update.tests.core/data/validation/site2/.eclipseproduct3
-rw-r--r--update/org.eclipse.update.tests.core/data/validation/site3/.eclipseextension1
-rw-r--r--update/org.eclipse.update.tests.core/data/validation/site4/eclipse/.eclipseextension1
-rw-r--r--update/org.eclipse.update.tests.core/data/validation/site5/.eclipseUM3
-rw-r--r--update/org.eclipse.update.tests.core/data/validation/site6/.eclipseUM1
-rw-r--r--update/org.eclipse.update.tests.core/data/validation/site6/children/children/eclipse/.eclipseextension1
-rw-r--r--update/org.eclipse.update.tests.core/data/xmls/apitests/org.eclipse.test.feature_1.0.0/feature.xml13
-rw-r--r--update/org.eclipse.update.tests.core/data/xmls/apitests/org.eclipse_test_feature/feature.xml13
-rw-r--r--update/org.eclipse.update.tests.core/data/xmls/feature_1.0.0/feature.xml13
-rw-r--r--update/org.eclipse.update.tests.core/data/xmls/feature_1.0.0/feature1.gifbin121 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/data/xmls/site1/site.xml22
-rw-r--r--update/org.eclipse.update.tests.core/plugin.properties13
-rw-r--r--update/org.eclipse.update.tests.core/plugin.xml41
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/AllTests.java55
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/UpdateManagerTestCase.java163
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/UpdateTestsPlugin.java88
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/AllAPITests.java46
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/DefaultFeature.java173
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/MyURLEntry.java31
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/TestDefaultExecutableFeatureAPI.java184
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/TestDefaultPackageFeatureAPI.java175
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/TestFeatureContentProvider_FileFilterAPI.java85
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/TestLocalSiteAPI.java117
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/TestNestedFeatureAPI.java153
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/TestPluginContainerAPI.java77
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/TestSiteAPI.java39
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/TestSiteManagerAPI.java76
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/api/TestUpdateManagerUtilsAPI.java229
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/branding/AllBrandingTests.java40
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/branding/BundleProviderTest.java50
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/branding/ProductTest.java41
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/configurations/AllConfigurationsTests.java30
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/configurations/TestBackward.java65
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/configurations/TestRevert.java127
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/core/boot/AllPlatformConfigurationTests.java38
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/core/boot/PlatformConfigurationTestCase.java78
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/core/boot/TestPlatCfgAPI.java209
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/core/boot/TestPlatCfgDefault.java33
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/implementation/SiteFTP.java266
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/implementation/SiteFTPFactory.java64
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/mirror/AllMirrorTests.java40
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/mirror/MirrorManagerTestCase.java464
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/mirror/TestRemoteDoubleEmbeddedFeatureMirror.java215
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/mirror/TestRemoteEmbeddedFeatureMirror.java189
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/mirror/TestRemoteFeatureVersionMirror.java110
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/model/AllModelTests.java40
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/model/FeatureMain.java183
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/model/SiteMain.java158
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/model/feature.xml42
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/model/site.xml35
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/model/site_old_format.xml30
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/model/site_with_type.xml5
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/model/test.properties14
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/nativeTests/TestLocalSystemInfo.java68
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/nestedfeatures/AllNestedTests.java32
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/nestedfeatures/TestInstall.java301
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/parser/AllParserTests.java35
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/parser/TestCategories.java62
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/parser/TestFeatureParse.java132
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/parser/TestSiteParse.java288
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/reconciliation/AllReconciliationTests.java40
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/reconciliation/TestSiteReconciliation.java169
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularInstall/AllRegularInstallTests.java41
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularInstall/MultipleTestLocalSite.java33
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularInstall/TestDataEntryInstall.java100
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularInstall/TestExecutableInstall.java72
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularInstall/TestExecutablePackagedInstall.java147
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularInstall/TestGetFeature.java49
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularInstall/TestInstall.java313
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularInstall/TestInstallURLSIteXML.java332
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularInstall/TestLocalSite.java422
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularInstall/TestSpaceInInstall.java141
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularRemove/AllRegularRemoveTests.java29
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/regularRemove/TestRemove.java91
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/sitevalidation/AllSiteValidationTests.java30
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/sitevalidation/TestSiteValidation.java163
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/standalone/AllStandaloneTests.java43
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/standalone/StandaloneManagerTestCase.java327
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/standalone/TestBundlesInstall.java127
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/standalone/TestFeatureDisable.java103
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/standalone/TestFeatureEnable.java109
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/standalone/TestFeatureInstall.java134
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/standalone/TestFeatureUninstall.java123
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/standalone/TestFeatureUpdate.java138
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/types/AllTypesTests.java34
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/types/TestFeatureType.java155
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/types/TestSiteType.java80
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/uivalues/AllCoreUITests.java33
-rw-r--r--update/org.eclipse.update.tests.core/src/org/eclipse/update/tests/uivalues/TestUILabel.java87
-rw-r--r--update/org.eclipse.update.tests.core/test.xml49
-rw-r--r--update/org.eclipse.update.tests.core/test_with_mail.xml76
-rw-r--r--update/org.eclipse.update.tests.core/webserver/Site with space/features space/helpFeature.jarbin62378 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/Site with space/features space/space feature.jarbin61259 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/Site with space/info/img/top_titlsm.gifbin3083 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/Site with space/info/img/wel_ml.jpgbin11159 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/Site with space/info/siteInfo.html63
-rw-r--r--update/org.eclipse.update.tests.core/webserver/Site with space/install/features space/feature3/feature.xml11
-rw-r--r--update/org.eclipse.update.tests.core/webserver/Site with space/plugins space/Pde_core.jarbin65389 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/Site with space/plugins space/help.jarbin364483 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/Site with space/plugins space/junit_3.7.jarbin258684 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/Site with space/site.xml20
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager/features/helpFeature.jarbin62376 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager/features/org.eclipse.pde.feature_1.0.0.jarbin60935 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager/info/img/top_titlsm.gifbin3083 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager/info/img/wel_ml.jpgbin11159 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager/info/siteInfo.html63
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager/plugins/Pde_core.jarbin65389 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager/plugins/help.jarbin364483 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager/plugins/junit_3.7.jarbin258684 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager/site.xml18
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager2/features/features2.jarbin1430 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager2/features/org.eclipse.test.feature_1.0.0.jarbin832 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager2/features/org.eclipse.update.core.tests.feature1_1.0.4.jarbin888 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager2/features/org.eclipse_test_feature.jarbin40806 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager2/nestedFeatureSiteTest/features/org.eclipse.update.core.tests.childrenfeature_2.0.0.jarbin749 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager2/nestedFeatureSiteTest/features/rootfeature.jarbin732 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager2/nestedFeatureSiteTest/plugins/org.eclipse.update.core.tests.feature1.plugin1_3.5.6.jarbin985 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager2/nestedFeatureSiteTest/plugins/org.eclipse.update.core.tests.feature1.plugin2_5.0.0.jarbin986 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager2/nestedFeatureSiteTest/plugins/org.eclipse.update.core.tests.feature1.plugin2_5.0.1.jarbin985 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager2/nestedFeatureSiteTest/site.xml4
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager2/org.eclipse.update.core.feature2_1.0.0/org.eclipse.update.core.feature2_2.2.2.jarbin1392 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager2/plugins/org.eclipse.update.core.feature1.plugin1_1.1.1.jarbin460 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager2/plugins/org.eclipse.update.core.feature2.plugin2_2.2.2.jarbin460 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager2/plugins/org.eclipse.update.core.tests.dummy_7.9.8.jarbin180132 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager2/plugins/org.eclipse.update.core.tests.feature1.plugin1_3.5.6.jarbin47228 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager2/plugins/org.eclipse.update.core.tests.feature1.plugin2_5.0.0.jarbin47229 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager2/site.properties12
-rw-r--r--update/org.eclipse.update.tests.core/webserver/UpdateManager2/site.xml24
-rw-r--r--update/org.eclipse.update.tests.core/webserver/WEB-INF/web.xml10
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSite/features/com.example.bundle.feature_1.0.0.jarbin717 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSite/plugins/com.example.budle.fragment.ui_1.0.0.jarbin1699 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSite/plugins/com.example.bundle.fragment_1.0.0.jarbin805 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSite/plugins/com.example.bundle.plugin.ui_2.0.0.jarbin1755 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSite/plugins/com.example.bundle.plugin_1.0.0.jarbin1705 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSite/site.xml7
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.budle.fragment.ui/.classpath7
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.budle.fragment.ui/.project32
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.budle.fragment.ui/.template4
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.budle.fragment.ui/META-INF/MANIFEST.MF8
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.budle.fragment.ui/build.properties5
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.budle.fragment.ui/fragment.xml18
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.feature/.project17
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.feature/build.properties1
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.feature/feature.xml45
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.fragment/.classpath7
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.fragment/.project31
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.fragment/.template4
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.fragment/META-INF/MANIFEST.MF8
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.fragment/build.properties5
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.fragment/fragment.xml17
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin.ui/.classpath7
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin.ui/.project31
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin.ui/.template4
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin.ui/META-INF/MANIFEST.MF12
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin.ui/bin/com/example/bundle/plugin/ui/UiPlugin.classbin1530 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin.ui/build.properties5
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin.ui/plugin.xml22
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin.ui/src/com/example/bundle/plugin/ui/UiPlugin.java69
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin/.classpath7
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin/.project30
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin/.template4
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin/META-INF/MANIFEST.MF11
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin/bin/com/example/bundle/plugin/PluginPlugin.classbin1538 -> 0 bytes
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin/build.properties5
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin/plugin.xml21
-rw-r--r--update/org.eclipse.update.tests.core/webserver/bundleSitesrc/com.example.bundle.plugin/src/com/example/bundle/plugin/PluginPlugin.java69
-rw-r--r--update/org.eclipse.update.ui.forms/.classpath7
-rw-r--r--update/org.eclipse.update.ui.forms/.cvsignore1
-rw-r--r--update/org.eclipse.update.ui.forms/.project32
-rw-r--r--update/org.eclipse.update.ui.forms/about.html30
-rw-r--r--update/org.eclipse.update.ui.forms/build.properties6
-rw-r--r--update/org.eclipse.update.ui.forms/plugin.properties17
-rw-r--r--update/org.eclipse.update.ui.forms/plugin.xml22
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/AbstractForm.java233
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/AbstractSectionForm.java217
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/CustomWorkbook.java143
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/ExpandableGroup.java211
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/FormButton.java81
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/FormEntry.java103
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/FormLabel.java238
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/FormSection.java531
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/FormWidgetFactory.java435
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/FormsPlugin.java134
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/FormsPluginResources.properties13
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/HTMLTableLayout.java678
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/HyperlinkAdapter.java21
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/HyperlinkHandler.java224
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/HyperlinkSettings.java115
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/IForm.java37
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/IFormPage.java25
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/IFormSelectionListener.java15
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/IFormTextListener.java16
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/IFormWorkbook.java27
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/IHyperlinkListener.java20
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/ILayoutExtension.java28
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/NoTabsWorkbook.java108
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/ScrollableSectionForm.java113
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/SectionChangeManager.java44
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/SectionForm.java166
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/SelectableControl.java100
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/SelectableFormLabel.java149
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/TableData.java60
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/TableLayoutTest.java243
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/ToggleControl.java169
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/WebForm.java237
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/BulletParagraph.java103
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/FormEngine.java560
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/FormEngineLayout.java111
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/HTTPAction.java30
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/HyperlinkAction.java51
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/HyperlinkSegment.java100
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/IBulletParagraph.java25
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/IHyperlinkSegment.java29
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/IImageSegment.java27
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/IObjectReference.java19
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/IParagraph.java29
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/IParagraphSegment.java25
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/ITextModel.java24
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/ITextSegment.java28
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/ImageSegment.java99
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/Locator.java34
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/Paragraph.java159
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/ParagraphSegment.java19
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/TextModel.java457
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/engine/TextSegment.java368
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/image1.gifbin2300 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.forms/src/org/eclipse/update/ui/forms/internal/index.xml22
-rw-r--r--update/org.eclipse.update.ui.win32/.classpath12
-rw-r--r--update/org.eclipse.update.ui.win32/.cvsignore1
-rw-r--r--update/org.eclipse.update.ui.win32/.project34
-rw-r--r--update/org.eclipse.update.ui.win32/about.html30
-rw-r--r--update/org.eclipse.update.ui.win32/build.properties7
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/clcl16/backward_nav.gifbin108 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/clcl16/forward_nav.gifbin138 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/clcl16/go_nav.gifbin162 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/clcl16/hierarchicalLayout.gifbin106 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/clcl16/home_nav.gifbin221 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/clcl16/refresh_nav.gifbin182 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/clcl16/show_unconf.gifbin267 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/clcl16/stop_nav.gifbin163 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/cview16/browser.gifbin364 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/dlcl16/backward_nav.gifbin81 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/dlcl16/forward_nav.gifbin80 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/dlcl16/go_nav.gifbin98 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/dlcl16/hierarchicalLayout.gifbin75 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/dlcl16/home_nav.gifbin101 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/dlcl16/refresh_nav.gifbin104 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/dlcl16/show_unconf.gifbin108 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/dlcl16/stop_nav.gifbin91 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/elcl16/backward_nav.gifbin104 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/elcl16/collapseall.gifbin871 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/elcl16/forward_nav.gifbin107 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/elcl16/go_nav.gifbin131 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/elcl16/hierarchicalLayout.gifbin103 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/elcl16/home_nav.gifbin160 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/elcl16/refresh_nav.gifbin144 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/elcl16/show_unconf.gifbin199 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/elcl16/stop_nav.gifbin120 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/eview16/browser.gifbin170 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/forms/def_provider.jpgbin15642 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/forms/form_banner.gifbin5600 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/forms/form_banner.jpgbin4985 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/forms/form_underline.jpgbin3989 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/forms/form_underline2.jpgbin989 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/full/forms/topic.gifbin154 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/icons/sample.gifbin983 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui.win32/plugin.properties3
-rw-r--r--update/org.eclipse.update.ui.win32/plugin.xml192
-rw-r--r--update/org.eclipse.update.ui.win32/schema/welcomePages.exsd135
-rw-r--r--update/org.eclipse.update.ui.win32/schema/welcomeSections.exsd166
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/ShowWelcomePageAction.java76
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/WelcomePortal.java182
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/WelcomePortalImages.java243
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/WelcomePortalResources.properties29
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/actions/TipsAndTricksContentProvider.java64
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/actions/WelcomeContentProvider.java97
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/HelpSection.java84
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/IFormContentObserver.java17
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/IFormContentProvider.java18
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/IPortalSectionForm.java22
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/PortalSection.java289
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/SectionDescriptor.java34
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/WelcomePortalEditor.java87
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/WelcomePortalEditorInput.java58
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/WelcomePortalEditorInputFactory.java21
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/WelcomePortalForm.java85
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/WelcomePortalPage.java73
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/WelcomePortalPart.java183
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/portal/WelcomeTitleArea.java45
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/webbrowser/BrowserControlSite.java119
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/webbrowser/GlobalActionHandler.java154
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/webbrowser/IEmbeddedWebBrowser.java16
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/webbrowser/IWebBrowserListener.java18
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/webbrowser/WebBrowser.java467
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/webbrowser/WebBrowserEditor.java297
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/webbrowser/WebBrowserEditorContributor.java109
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/webbrowser/WebBrowserEditorInput.java67
-rw-r--r--update/org.eclipse.update.ui.win32/src/org/eclipse/welcome/internal/webbrowser/WebBrowserEditorInputFactory.java23
-rw-r--r--update/org.eclipse.update.ui/.classpath7
-rw-r--r--update/org.eclipse.update.ui/.cvsignore1
-rw-r--r--update/org.eclipse.update.ui/.project36
-rw-r--r--update/org.eclipse.update.ui/Graphics_update.html955
-rw-r--r--update/org.eclipse.update.ui/about.html30
-rw-r--r--update/org.eclipse.update.ui/build.properties10
-rw-r--r--update/org.eclipse.update.ui/icons/dlcl16/collapseall.gifbin155 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/dlcl16/hierarchicalLayout.gifbin101 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/dlcl16/show_unconf.gifbin376 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/dtool16/config_wiz.gifbin232 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/dtool16/install_wiz.gifbin348 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/dtool16/uninstall_wiz.gifbin367 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/dtool16/update_wiz.gifbin369 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/elcl16/collapseall.gifbin157 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/elcl16/hierarchicalLayout.gifbin101 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/elcl16/show_unconf.gifbin591 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/etool16/config_wiz.gifbin352 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/etool16/install_wiz.gifbin377 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/etool16/uninstall_wiz.gifbin604 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/etool16/update_wiz.gifbin600 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/eview16/configs.gifbin368 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/eview16/preview.gifbin648 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/forms/def_provider.jpgbin25721 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/forms/form_banner.gifbin5600 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/forms/form_banner.jpgbin4985 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/forms/form_underline.jpgbin3989 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/forms/topic.gifbin162 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/obj16/app_obj.gifbin591 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/obj16/bfolder_obj.gifbin377 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/obj16/category_obj.gifbin572 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/obj16/config_obj.gifbin368 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/obj16/efix2_obj.gifbin597 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/obj16/efix_obj.gifbin609 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/obj16/error_st_obj.gifbin339 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/obj16/esite_obj.gifbin319 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/obj16/feature_obj.gifbin585 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/obj16/history_obj.gifbin578 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/obj16/lsite_obj.gifbin348 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/obj16/notinstalled_feature_obj.gifbin237 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/obj16/ok_st_obj.gifbin343 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/obj16/psite_obj.gifbin333 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/obj16/site_obj.gifbin353 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/obj16/unconf_feature_obj.gifbin596 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/obj16/updates_obj.gifbin332 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/obj16/usearch_obj.gifbin586 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/obj16/web_bkmrk_obj.gifbin578 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/ovr16/add_stat.gifbin186 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/ovr16/current_co.gifbin79 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/ovr16/del_stat.gifbin184 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/ovr16/error_co.gifbin82 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/ovr16/installable_co.gifbin169 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/ovr16/linked_co.gifbin85 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/ovr16/mod_co.gifbin187 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/ovr16/unconfigured_co.gifbin112 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/ovr16/updated_co.gifbin105 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/ovr16/warning_co.gifbin173 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/wizban/config_wiz.gifbin3388 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/wizban/def_wizban.jpgbin33456 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/wizban/install_wiz.gifbin3550 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/wizban/uninstall_wiz.gifbin3719 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/icons/wizban/update_wiz.gifbin3744 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/plugin.properties52
-rw-r--r--update/org.eclipse.update.ui/plugin.xml73
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/AddBookmarksAction.java34
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/ConfigurationManagerWindow.java182
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/RestartDialog.java83
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/UpdateLabelProvider.java48
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/UpdateUI.java392
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/UpdateUIImages.java120
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/UpdateUIPluginResources.properties407
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/BookmarkFolder.java57
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/BookmarkUtil.java247
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/ConfiguredFeatureAdapter.java116
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/ConfiguredSiteAdapter.java51
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/DiscoveryFolder.java103
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/FeatureAdapter.java58
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/FeatureReferenceAdapter.java105
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/IConfiguredFeatureAdapter.java21
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/IConfiguredSiteAdapter.java19
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/IConfiguredSiteContext.java22
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/IFeatureAdapter.java31
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/ISiteAdapter.java25
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/MissingFeature.java456
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/NamedModelObject.java94
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/SimpleFeatureAdapter.java67
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/SiteBookmark.java252
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/SiteCategory.java177
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/UIModelObject.java57
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/model/UpdateModel.java121
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/parts/AbstractOverlayIcon.java115
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/parts/DefaultContentProvider.java22
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/parts/ImageOverlayIcon.java34
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/parts/OverlayIcon.java117
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/parts/PixelConverter.java45
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/parts/SWTUtil.java111
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/parts/SharedLabelProvider.java201
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/preferences/MainPreferencePage.java339
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/preferences/UpdateSettingsPreferencePage.java116
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/properties/ConfiguredSitePropertyPage.java53
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/properties/FeatureCopyrightPropertyPage.java82
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/properties/FeatureGeneralPropertyPage.java131
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/properties/FeatureLicensePropertyPage.java69
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/properties/FeatureStatusPropertyPage.java149
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/properties/InstallConfigurationPropertyPage.java41
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/security/Authentication.java36
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/security/JarVerificationDialog.java124
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/security/JarVerificationPage.java323
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/security/JarVerificationService.java143
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/security/UpdateManagerAuthenticator.java52
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/security/UserValidationDialog.java162
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/ConfigurationPreview.java180
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/ConfigurationView.java1125
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/FeatureStateAction.java94
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/FindUpdatesAction.java79
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/IPreviewTask.java22
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/InstallOptionalFeatureAction.java95
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/InstallationHistoryAction.java245
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/NewExtensionLocationAction.java114
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/ReplaceVersionAction.java62
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/RevertConfigurationAction.java44
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/ShowActivitiesAction.java32
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/SiteStateAction.java81
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/views/UninstallFeatureAction.java95
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/ActivitiesTableViewer.java148
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/BannerPage.java76
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/DuplicateConflictsDialog.java123
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/EditSiteDialog.java42
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/FeatureSorter.java92
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/IDynamicPage.java22
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/ISearchProvider.java20
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/InstallWizard.java386
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/LicensePage.java175
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/LocalSiteSelector.java212
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/ModeSelectionPage.java107
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/NewUpdateSiteDialog.java130
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/NewWebSiteDialog.java35
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/OptionalFeaturesPage.java324
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/ReplaceFeatureVersionWizard.java26
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/ReplaceFeatureVersionWizardPage.java167
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/ResizableInstallWizardDialog.java66
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/RevertConfigurationWizard.java39
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/RevertConfigurationWizardPage.java263
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/ReviewPage.java841
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/SearchRunner.java110
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/ShowActivitiesDialog.java195
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/SitePage.java585
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/TableLayoutComposite.java173
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/TargetPage.java538
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/internal/ui/wizards/UIProblemHandler.java29
-rw-r--r--update/org.eclipse.update.ui/src/org/eclipse/update/ui/UpdateManagerUI.java49
-rw-r--r--update/org.eclipse.update.ui/src_webapp/org/eclipse/update/internal/ui/servlets/InstallServlet.java207
-rw-r--r--update/org.eclipse.update.ui/src_webapp/org/eclipse/update/internal/ui/servlets/ServletsUtil.java151
-rw-r--r--update/org.eclipse.update.ui/webapp/WEB-INF/.cvsignore1
-rw-r--r--update/org.eclipse.update.ui/webapp/WEB-INF/lib/.cvsignore1
-rw-r--r--update/org.eclipse.update.ui/webapp/WEB-INF/web.xml20
-rw-r--r--update/org.eclipse.update.ui/webapp/images/backward_nav.gifbin104 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/webapp/images/form_banner.jpgbin4985 -> 0 bytes
-rw-r--r--update/org.eclipse.update.ui/webapp/images/form_underline.jpgbin3989 -> 0 bytes
-rw-r--r--update/org.eclipse.update/.classpath15
-rw-r--r--update/org.eclipse.update/.cvsignore1
-rw-r--r--update/org.eclipse.update/.vcm_meta7
-rw-r--r--update/org.eclipse.update/about.html30
-rw-r--r--update/org.eclipse.update/build.properties2
-rw-r--r--update/org.eclipse.update/icons/full/ctool16/new.gifbin918 -> 0 bytes
-rw-r--r--update/org.eclipse.update/icons/full/ctool16/update.gifbin895 -> 0 bytes
-rw-r--r--update/org.eclipse.update/icons/full/wizban/new.gifbin2667 -> 0 bytes
-rw-r--r--update/org.eclipse.update/icons/full/wizban/revert.gifbin2703 -> 0 bytes
-rw-r--r--update/org.eclipse.update/icons/full/wizban/update.gifbin2712 -> 0 bytes
-rw-r--r--update/org.eclipse.update/plugin.properties3
-rw-r--r--update/org.eclipse.update/plugin.xml52
-rw-r--r--update/org.eclipse.update/plugin.xml.off62
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/core/ISessionDefiner.java16
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/core/IUMLock.java23
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/core/UMLock.java97
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/core/UMSessionDefinerReferenceUpdate.java216
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/core/UMSessionManager.java351
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/core/UMSessionManagerEntry.java171
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/core/UMSessionManagerMessage.java79
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/core/UMSessionManagerOperation.java1189
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/core/UMSessionManagerParcel.java327
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/core/UMSessionManagerSession.java207
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/core/URLHandler.java76
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/core/UpdateManager.java640
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/core/UpdateManagerException.java17
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/core/UpdateManagerPlugin.java135
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/core/UpdateManagerStrings.java54
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/core/UpdateManagerURLComparator.java37
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/core/updatemanagerstrings.properties112
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/AuthorizationDatabase.java108
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/Installation.java221
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/JarVerificationDialog.java180
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/JarVerificationResult.java38
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/JarVerificationService.java167
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/JarVerifier.java360
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/KeyStores.java107
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/Main.java181
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMApplication.java45
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMApplicationUserInterface.java253
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMApplicationUserInterfaceProperties.java87
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMApplicationWindow.java316
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMDialog.java740
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMDialogAction.java43
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMPreferencePageSettings.java147
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizard.java120
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardPageComplete.java106
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardPageInstallable.java1333
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardPageInstalling.java245
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardPageLaunchHistory.java251
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardPageLaunchHistoryComplete.java94
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardPageLocations.java526
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardPageURLComplete.java96
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardPageURLInstall.java367
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardPageURLInstallable.java396
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardPageURLInstalling.java275
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardPersistentProperties.java141
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardProductComponentNew.java58
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardProductComponentRevert.java48
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardProductComponentURLInstall.java71
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardProductComponentUpdate.java46
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardTreeItem.java109
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardTreeItemComparator.java58
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UMWizardURLNamePairComparator.java55
-rw-r--r--update/org.eclipse.update/src/org/eclipse/update/internal/ui/UserValidationDialog.java135
1199 files changed, 65 insertions, 111690 deletions
diff --git a/ant/org.eclipse.ant.tests.core/.classpath b/ant/org.eclipse.ant.tests.core/.classpath
deleted file mode 100644
index 0b19bafe8..000000000
--- a/ant/org.eclipse.ant.tests.core/.classpath
+++ /dev/null
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
- <classpathentry kind="src" path="test plugin"/>
- <classpathentry kind="src" path="tests"/>
- <classpathentry output="test_support_bin" kind="src" path="test support"/>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/ant/org.eclipse.ant.tests.core/.cvsignore b/ant/org.eclipse.ant.tests.core/.cvsignore
deleted file mode 100644
index 0b484958e..000000000
--- a/ant/org.eclipse.ant.tests.core/.cvsignore
+++ /dev/null
@@ -1,3 +0,0 @@
-bin
-lib
-test_support_bin
diff --git a/ant/org.eclipse.ant.tests.core/.externalToolBuilders/Ant Test Support Lib Builder.launch b/ant/org.eclipse.ant.tests.core/.externalToolBuilders/Ant Test Support Lib Builder.launch
deleted file mode 100644
index 324b0d4af..000000000
--- a/ant/org.eclipse.ant.tests.core/.externalToolBuilders/Ant Test Support Lib Builder.launch
+++ /dev/null
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<launchConfiguration type="org.eclipse.ant.AntBuilderLaunchConfigurationType">
-<booleanAttribute key="org.eclipse.debug.ui.ATTR_LAUNCH_IN_BACKGROUND" value="false"/>
-<booleanAttribute key="org.eclipse.jdt.launching.DEFAULT_CLASSPATH" value="true"/>
-<stringAttribute key="org.eclipse.ui.externaltools.ATTR_BUILD_SCOPE" value="${working_set:&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;&#10;&lt;launchConfigurationWorkingSet factoryID=&quot;org.eclipse.ui.internal.WorkingSetFactory&quot; name=&quot;workingSet&quot; editPageId=&quot;org.eclipse.ui.resourceWorkingSetPage&quot;&gt;&#10;&lt;item factoryID=&quot;org.eclipse.ui.internal.model.ResourceFactory&quot; path=&quot;/org.eclipse.ant.tests.core/test support/org&quot; type=&quot;2&quot;/&gt;&#10;&lt;item factoryID=&quot;org.eclipse.ui.internal.model.ResourceFactory&quot; path=&quot;/org.eclipse.ant.tests.core/buildfiles/buildAntTestsSupportJAR.xml&quot; type=&quot;1&quot;/&gt;&#10;&lt;/launchConfigurationWorkingSet&gt;&#10;}"/>
-<stringAttribute key="org.eclipse.ui.externaltools.ATTR_RUN_BUILD_KINDS" value="full,incremental,auto,"/>
-<stringAttribute key="org.eclipse.debug.core.ATTR_REFRESH_SCOPE" value="${working_set:&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;&#10;&lt;launchConfigurationWorkingSet factoryID=&quot;org.eclipse.ui.internal.WorkingSetFactory&quot; name=&quot;workingSet&quot;&gt;&#10;&lt;item factoryID=&quot;org.eclipse.ui.internal.model.ResourceFactory&quot; path=&quot;/org.eclipse.ant.tests.core&quot; type=&quot;4&quot;/&gt;&#10;&lt;/launchConfigurationWorkingSet&gt;&#10;}"/>
-<stringAttribute key="org.eclipse.ui.externaltools.ATTR_LOCATION" value="${workspace_loc:/org.eclipse.ant.tests.core/buildfiles/buildAntTestsSupportJAR.xml}"/>
-<booleanAttribute key="org.eclipse.debug.ui.ATTR_RUN_IN_BACKGROUND" value="false"/>
-<stringAttribute key="org.eclipse.jdt.launching.CLASSPATH_PROVIDER" value="org.eclipse.ant.ui.AntClasspathProvider"/>
-</launchConfiguration>
diff --git a/ant/org.eclipse.ant.tests.core/.project b/ant/org.eclipse.ant.tests.core/.project
deleted file mode 100644
index 694351010..000000000
--- a/ant/org.eclipse.ant.tests.core/.project
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.ant.tests.core</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.jdt.core.javabuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.ui.externaltools.ExternalToolBuilder</name>
- <arguments>
- <dictionary>
- <key>LaunchConfigHandle</key>
- <value>Ant Test Support Lib Builder.launch</value>
- </dictionary>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.eclipse.jdt.core.javanature</nature>
- <nature>org.eclipse.pde.PluginNature</nature>
- </natures>
-</projectDescription>
diff --git a/ant/org.eclipse.ant.tests.core/.settings/org.eclipse.pde.core.prefs b/ant/org.eclipse.ant.tests.core/.settings/org.eclipse.pde.core.prefs
deleted file mode 100644
index f01a37434..000000000
--- a/ant/org.eclipse.ant.tests.core/.settings/org.eclipse.pde.core.prefs
+++ /dev/null
@@ -1,3 +0,0 @@
-#Thu May 27 14:48:43 PDT 2004
-eclipse.preferences.version=1
-selfhosting.binExcludes=/org.eclipse.ant.tests.core/test_support_bin
diff --git a/ant/org.eclipse.ant.tests.core/about.html b/ant/org.eclipse.ant.tests.core/about.html
deleted file mode 100644
index d57b43281..000000000
--- a/ant/org.eclipse.ant.tests.core/about.html
+++ /dev/null
@@ -1,30 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<title>About</title>
-<meta http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<p>16th October, 2002</p>
-<h3>License</h3>
-<p>Eclipse.org makes available all content in this plug-in (&quot;Content&quot;). Unless otherwise indicated below, the Content is provided to you under the terms and conditions of the
-Common Public License Version 1.0 (&quot;CPL&quot;). A copy of the CPL is available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>.
-For purposes of the CPL, &quot;Program&quot; will mean the Content.</p>
-
-<h3>Contributions</h3>
-
-<p>If this Content is licensed to you under the terms and conditions of the CPL, any Contributions, as defined in the CPL, uploaded, submitted, or otherwise
-made available to Eclipse.org, members of Eclipse.org and/or the host of Eclipse.org web site, by you that relate to such
-Content are provided under the terms and conditions of the CPL and can be made available to others under the terms of the CPL.</p>
-
-<p>If this Content is licensed to you under license terms and conditions other than the CPL (&quot;Other License&quot;), any modifications, enhancements and/or
-other code and/or documentation (&quot;Modifications&quot;) uploaded, submitted, or otherwise made available to Eclipse.org, members of Eclipse.org and/or the
-host of Eclipse.org, by you that relate to such Content are provided under terms and conditions of the Other License and can be made available
-to others under the terms of the Other License. In addition, with regard to Modifications for which you are the copyright holder, you are also
-providing the Modifications under the terms and conditions of the CPL and such Modifications can be made available to others under the terms of
-the CPL.</p>
-
-</body>
-</html> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.core/build.properties b/ant/org.eclipse.ant.tests.core/build.properties
deleted file mode 100644
index a6804c35b..000000000
--- a/ant/org.eclipse.ant.tests.core/build.properties
+++ /dev/null
@@ -1,26 +0,0 @@
-###############################################################################
-# Copyright (c) 2000, 2003 IBM Corporation and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Common Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/cpl-v10.html
-#
-# Contributors:
-# IBM Corporation - initial API and implementation
-###############################################################################
-bin.includes = plugin.xml,\
- plugin.properties,\
- test.xml,\
- about.html,\
- testbuildfiles/,\
- testresources/,\
- testlib/,\
- lib/,\
- lib/*.jar,\
- *.jar
-
-source.anttestscore.jar = test plugin/,\
- tests/,\
- buildfiles/
-source.lib/antTestsSupport.jar = test support/
-jars.compile.order=anttestscore.jar,lib/antTestsSupport.jar
diff --git a/ant/org.eclipse.ant.tests.core/buildfiles/buildAntTestsSupportJAR.xml b/ant/org.eclipse.ant.tests.core/buildfiles/buildAntTestsSupportJAR.xml
deleted file mode 100644
index 5c6262864..000000000
--- a/ant/org.eclipse.ant.tests.core/buildfiles/buildAntTestsSupportJAR.xml
+++ /dev/null
@@ -1,42 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project name="build tests support jar" default="build" basedir="..">
-
- <property name="bootclasspath" value=""/>
-
- <target name="build" description="Removes all build artifacts, recreates the support jar, and refreshes this plugin's resources" depends="clean, lib/antTestsSupport.jar"/>
-
- <target name="init" depends="properties">
- <property name="version.suffix" value="_3.0.0"/>
- <property name="ant_version.suffix" value="_1.6.1"/>
- <property name="temp.folder" value="${basedir}/temp.folder"/>
- <property name="plugin.destination" value="${basedir}"/>
- <property name="build.result.folder" value="${basedir}"/>
- </target>
-
- <target name="properties" if="eclipse.running">
- <property name="build.compiler" value="org.eclipse.jdt.core.JDTCompilerAdapter"/>
- </target>
-
- <target name="lib/antTestsSupport.jar" depends="init" description= "Builds the support JAR">
- <property name="destdir" value="${temp.folder}/lib/antTestsSupport.jar.bin"/>
- <delete dir="${temp.folder}/lib/antTestsSupport.jar.bin"/>
- <mkdir dir="${temp.folder}/lib/antTestsSupport.jar.bin"/>
- <!-- compile the source code -->
- <javac target="1.1" destdir="${temp.folder}/lib/antTestsSupport.jar.bin" failonerror="false" verbose="false" debug="on" includeAntRuntime="yes" bootclasspath="${bootclasspath}"
- classpath="${basedir}/../org.eclipse.core.runtime/bin;
- ${eclipse.home}/plugins/org.eclipse.core.runtime${version.suffix}/runtime.jar;
- ${basedir}/bin;
- ${eclipse.home}/plugins/org.eclipse.ant.core${version.suffix}/antsupport.jar;
- ${basedir}/../org.eclipse.ant.core/bin">
- <src path="test support/"/>
- </javac>
- <mkdir dir="${build.result.folder}/lib"/>
- <jar jarfile="${build.result.folder}/lib/antTestsSupport.jar" basedir="${temp.folder}/lib/antTestsSupport.jar.bin"/>
- <delete dir="${temp.folder}"/>
- </target>
-
- <target name="clean" depends="init">
- <delete file="${build.result.folder}/lib/antTestsSupport.jar"/>
- <delete dir="${temp.folder}"/>
- </target>
-</project>
diff --git a/ant/org.eclipse.ant.tests.core/lib/.cvsignore b/ant/org.eclipse.ant.tests.core/lib/.cvsignore
deleted file mode 100644
index 3740b607e..000000000
--- a/ant/org.eclipse.ant.tests.core/lib/.cvsignore
+++ /dev/null
@@ -1 +0,0 @@
-antTestsSupport.jar
diff --git a/ant/org.eclipse.ant.tests.core/plugin.properties b/ant/org.eclipse.ant.tests.core/plugin.properties
deleted file mode 100644
index a81529451..000000000
--- a/ant/org.eclipse.ant.tests.core/plugin.properties
+++ /dev/null
@@ -1,13 +0,0 @@
-###############################################################################
-# Copyright (c) 2000, 2003 IBM Corporation and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Common Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/cpl-v10.html
-#
-# Contributors:
-# IBM Corporation - initial API and implementation
-###############################################################################
-
-pluginName=Ant Core Test Plugin
-providerName=Eclipse.org
diff --git a/ant/org.eclipse.ant.tests.core/plugin.xml b/ant/org.eclipse.ant.tests.core/plugin.xml
deleted file mode 100644
index deab74728..000000000
--- a/ant/org.eclipse.ant.tests.core/plugin.xml
+++ /dev/null
@@ -1,79 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.0"?>
-<plugin
- id="org.eclipse.ant.tests.core"
- name="%pluginName"
- version="3.0.0"
- provider-name="%providerName"
- class="org.eclipse.ant.tests.core.testplugin.AntTestPlugin">
-
- <runtime>
- <library name="anttestscore.jar">
- <export name="*"/>
- </library>
- </runtime>
- <requires>
- <import plugin="org.eclipse.ui.ide" optional="true"/>
- <import plugin="org.eclipse.ui.views" optional="true"/>
- <import plugin="org.eclipse.jface.text" optional="true"/>
- <import plugin="org.eclipse.ui.workbench.texteditor" optional="true"/>
- <import plugin="org.eclipse.ui.editors" optional="true"/>
- <import plugin="org.apache.ant"/>
- <import plugin="org.junit"/>
- <import plugin="org.eclipse.core.resources"/>
- <import plugin="org.eclipse.jdt.core"/>
- <import plugin="org.eclipse.ui"/>
- <import plugin="org.eclipse.ant.core"/>
- <import plugin="org.eclipse.update.core"/>
- <import plugin="org.eclipse.core.runtime"/>
- </requires>
-
-
- <extension
- point="org.eclipse.ant.core.extraClasspathEntries">
- <extraClasspathEntry
- library="lib/antTestsSupport.jar">
- </extraClasspathEntry>
- </extension>
-
- <extension point="org.eclipse.ant.core.antTasks">
- <antTask
- name="coolTask"
- class="org.eclipse.ant.tests.core.support.tasks.AntTestTask"
- library="lib/antTestsSupport.jar"
- headless="false">
- </antTask>
- </extension>
-
- <extension point="org.eclipse.ant.core.antTypes">
- <antType
- name="coolType"
- class="org.eclipse.ant.tests.core.support.types.AntTestPath"
- library="lib/antTestsSupport.jar"
- headless="false">
- </antType>
- </extension>
-
- <extension
- point="org.eclipse.ant.core.antProperties">
- <antProperty
- name="property.testing"
- value="true">
- </antProperty>
- <antProperty
- name="property.testing2"
- value="hey"
- class= "org.eclipse.does.not.exist">
- </antProperty>
- <antProperty
- name="property.testing3"
- class= "org.eclipse.ant.tests.core.testplugin.AntTestPropertyValueProvider">
- </antProperty>
- <antProperty
- name="property.headless"
- value="headless"
- headless= "false">
- </antProperty>
- </extension>
-
-</plugin>
diff --git a/ant/org.eclipse.ant.tests.core/test plugin/org/eclipse/ant/tests/core/testplugin/AntFileRunner.java b/ant/org.eclipse.ant.tests.core/test plugin/org/eclipse/ant/tests/core/testplugin/AntFileRunner.java
deleted file mode 100644
index 64e82167f..000000000
--- a/ant/org.eclipse.ant.tests.core/test plugin/org/eclipse/ant/tests/core/testplugin/AntFileRunner.java
+++ /dev/null
@@ -1,78 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.core.testplugin;
-
-
-import org.eclipse.ant.core.AntRunner;
-import org.eclipse.ant.tests.core.AbstractAntTest;
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.runtime.CoreException;
-
-/**
- * Responsible for running test ant build files.
- */
-public class AntFileRunner {
-
- private static final String BASE_DIR_PREFIX = "-Dbasedir="; //$NON-NLS-1$
-
- public void run(IFile buildFile, String[] targets, String[] args, String baseDir, boolean captureOutput) throws CoreException {
-
- AntRunner runner = new AntRunner();
-
- String[] runnerArgs = args;
-
- if (baseDir.length() > 0) {
- // Ant requires the working directory to be specified
- // as one of the arguments, so it needs to be appended.
- int length = 1;
- if (args != null) {
- length = args.length + 1;
- }
-
- runnerArgs = new String[length];
- if (args != null) {
- System.arraycopy(args, 0, runnerArgs, 0, args.length);
- }
- runnerArgs[length - 1] = BASE_DIR_PREFIX + baseDir;
- }
- runner.setArguments(runnerArgs);
-
- if (buildFile != null) {
- runner.setBuildFileLocation(buildFile.getLocation().toFile().toString());
- }
- if (targets != null && targets.length > 0) {
- runner.setExecutionTargets(targets);
- }
- if (captureOutput) {
- runner.addBuildLogger(AbstractAntTest.ANT_TEST_BUILD_LOGGER);
- }
-
- runner.run(null);
- }
-
- public void run(String[] args, String baseDir) throws Exception {
-
- AntRunner runner = new AntRunner();
-
- String[] runnerArgs = args;
-
- if (baseDir.length() > 0) {
- // Ant requires the working directory to be specified
- // as one of the arguments, so it needs to be appended.
- runnerArgs = new String[args.length + 1];
- System.arraycopy(args, 0, runnerArgs, 0, args.length);
- runnerArgs[args.length] = BASE_DIR_PREFIX + baseDir;
- }
- runner.setArguments(runnerArgs);
-
- runner.run(args);
- }
-}
diff --git a/ant/org.eclipse.ant.tests.core/test plugin/org/eclipse/ant/tests/core/testplugin/AntTestChecker.java b/ant/org.eclipse.ant.tests.core/test plugin/org/eclipse/ant/tests/core/testplugin/AntTestChecker.java
deleted file mode 100644
index ccc58161b..000000000
--- a/ant/org.eclipse.ant.tests.core/test plugin/org/eclipse/ant/tests/core/testplugin/AntTestChecker.java
+++ /dev/null
@@ -1,229 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.core.testplugin;
-
-
-import java.util.ArrayList;
-import java.util.Hashtable;
-import java.util.List;
-
-public class AntTestChecker {
-
- private static AntTestChecker deflt= null;
-
- private int taskStartedCount;
-
- private int taskFinishedCount;
-
- private int targetsStartedCount;
-
- private int targetsFinishedCount;
-
- private int buildsStartedCount;
-
- private int buildsFinishedCount;
-
- private List messages= new ArrayList();
-
- private List targets= new ArrayList();
-
- private List tasks= new ArrayList();
-
- private List projects= new ArrayList();
-
- private Hashtable userProperties;
-
- private List nameOfListeners= new ArrayList();
-
- private AntTestChecker() {
- }
-
- /**
- * Returns the singleton AntTestChecker
- */
- public static AntTestChecker getDefault() {
- if (deflt == null) {
- deflt= new AntTestChecker();
- }
- return deflt;
- }
-
- /**
- * Resets the singleton AntTestChecker
- */
- public static void reset() {
- if (deflt != null) {
- deflt.resetState();
- }
- }
- /**
- * @see org.apache.tools.ant.BuildListener#buildFinished(org.apache.tools.ant.BuildEvent)
- */
- public void buildFinished() {
- buildsFinishedCount++;
- }
-
-
- public void buildStarted(String projectName) {
- buildsStartedCount++;
- projects.add(projectName);
- }
-
-
- public void messageLogged(String message) {
- messages.add(message);
- }
-
- /**
- * @see org.apache.tools.ant.BuildListener#targetFinished(org.apache.tools.ant.BuildEvent)
- */
- public void targetFinished() {
- targetsFinishedCount++;
- }
-
- /**
- * @see org.apache.tools.ant.BuildListener#targetStarted(org.apache.tools.ant.BuildEvent)
- */
- public void targetStarted(String targetName) {
- targetsStartedCount++;
- targets.add(targetName);
- }
-
- /**
- * @see org.apache.tools.ant.BuildListener#taskFinished(org.apache.tools.ant.BuildEvent)
- */
- public void taskFinished() {
- taskFinishedCount++;
- }
-
- /**
- * @see org.apache.tools.ant.BuildListener#taskStarted(org.apache.tools.ant.BuildEvent)
- */
- public void taskStarted(String taskName) {
- taskStartedCount++;
- tasks.add(taskName);
- }
-
- /**
- * Returns the buildsFinishedCount.
- * @return int
- */
- public int getBuildsFinishedCount() {
- return buildsFinishedCount;
- }
-
- /**
- * Returns the buildsStartedCount.
- * @return int
- */
- public int getBuildsStartedCount() {
- return buildsStartedCount;
- }
-
- /**
- * Returns the messagesLoggedCount.
- * @return int
- */
- public int getMessagesLoggedCount() {
- return messages.size();
- }
-
- /**
- * Returns the targetsFinishedCount.
- * @return int
- */
- public int getTargetsFinishedCount() {
- return targetsFinishedCount;
- }
-
- /**
- * Returns the targetsStartedCount.
- * @return int
- */
- public int getTargetsStartedCount() {
- return targetsStartedCount;
- }
-
- /**
- * Returns the taskFinishedCount.
- * @return int
- */
- public int getTaskFinishedCount() {
- return taskFinishedCount;
- }
-
- /**
- * Returns the taskStartedCount.
- * @return int
- */
- public int getTaskStartedCount() {
- return taskStartedCount;
- }
-
- protected void resetState() {
- taskStartedCount= 0;
- taskFinishedCount= 0;
- targetsStartedCount= 0;
- targetsFinishedCount= 0;
- buildsStartedCount= 0;
- buildsFinishedCount= 0;
- messages= new ArrayList();
- tasks= new ArrayList();
- targets= new ArrayList();
- projects= new ArrayList();
- userProperties= null;
- nameOfListeners= new ArrayList();
- }
-
- /**
- * Return the message n from the last:
- * e.g. getLoggedMessage(0) returns the most recent message
- *
- * @param n message index
- * @return the nth last message
- */
- public String getLoggedMessage(int n) {
- n = messages.size() - (n + 1);
- if ((n < 0) || (n >= messages.size())) {
- return null;
- }
- return (String) messages.get(n);
- }
-
- public String getLastMessageLogged() {
- return getLoggedMessage(0);
- }
-
- public void setUserProperties(Hashtable userProperties) {
- this.userProperties= userProperties;
- }
-
- public String getUserProperty(String name) {
- return (String)userProperties.get(name);
- }
-
- public List getMessages() {
- return messages;
- }
-
- public List getListeners() {
- return nameOfListeners;
- }
-
- public String getLastListener() {
- return (String)nameOfListeners.get(nameOfListeners.size() - 1);
- }
-
-
- public void addNameOfListener(String nameOfListener) {
- this.nameOfListeners.add(nameOfListener);
- }
-}
diff --git a/ant/org.eclipse.ant.tests.core/test plugin/org/eclipse/ant/tests/core/testplugin/AntTestPlugin.java b/ant/org.eclipse.ant.tests.core/test plugin/org/eclipse/ant/tests/core/testplugin/AntTestPlugin.java
deleted file mode 100644
index a62aa7240..000000000
--- a/ant/org.eclipse.ant.tests.core/test plugin/org/eclipse/ant/tests/core/testplugin/AntTestPlugin.java
+++ /dev/null
@@ -1,59 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.core.testplugin;
-
-
-import java.io.File;
-import java.io.IOException;
-import java.net.URL;
-
-import org.eclipse.core.resources.*;
-import org.eclipse.core.runtime.*;
-import org.eclipse.ui.plugin.AbstractUIPlugin;
-import org.osgi.framework.Bundle;
-
-
-public class AntTestPlugin extends AbstractUIPlugin {
-
- private static AntTestPlugin deflt;
-
- public AntTestPlugin() {
- super();
- deflt= this;
- }
-
- public static AntTestPlugin getDefault() {
- return deflt;
- }
-
- public static IWorkspace getWorkspace() {
- return ResourcesPlugin.getWorkspace();
- }
-
- public static void enableAutobuild(boolean enable) throws CoreException {
- // disable auto build
- IWorkspace workspace= AntTestPlugin.getWorkspace();
- IWorkspaceDescription desc= workspace.getDescription();
- desc.setAutoBuilding(enable);
- workspace.setDescription(desc);
- }
-
- public File getFileInPlugin(IPath path) {
- try {
- Bundle bundle = getDefault().getBundle();
- URL installURL= new URL(bundle.getEntry("/"), path.toString());
- URL localURL= Platform.asLocalURL(installURL);
- return new File(localURL.getFile());
- } catch (IOException e) {
- return null;
- }
- }
-}
diff --git a/ant/org.eclipse.ant.tests.core/test plugin/org/eclipse/ant/tests/core/testplugin/AntTestPropertyValueProvider.java b/ant/org.eclipse.ant.tests.core/test plugin/org/eclipse/ant/tests/core/testplugin/AntTestPropertyValueProvider.java
deleted file mode 100644
index 7d9ac88c6..000000000
--- a/ant/org.eclipse.ant.tests.core/test plugin/org/eclipse/ant/tests/core/testplugin/AntTestPropertyValueProvider.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.core.testplugin;
-
-import org.eclipse.ant.core.IAntPropertyValueProvider;
-
-public class AntTestPropertyValueProvider implements IAntPropertyValueProvider {
-
- /* (non-Javadoc)
- * @see org.eclipse.ant.core.IAntPropertyValueProvider#getAntPropertyValue(java.lang.String)
- */
- public String getAntPropertyValue(String antPropertyName) {
- return "AntTestPropertyValueProvider";
- }
-
-}
diff --git a/ant/org.eclipse.ant.tests.core/test plugin/org/eclipse/ant/tests/core/testplugin/ProjectHelper.java b/ant/org.eclipse.ant.tests.core/test plugin/org/eclipse/ant/tests/core/testplugin/ProjectHelper.java
deleted file mode 100644
index fecbbef91..000000000
--- a/ant/org.eclipse.ant.tests.core/test plugin/org/eclipse/ant/tests/core/testplugin/ProjectHelper.java
+++ /dev/null
@@ -1,109 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.core.testplugin;
-
-
-import java.io.File;
-import java.io.IOException;
-import java.lang.reflect.InvocationTargetException;
-import java.util.*;
-
-import org.eclipse.core.resources.*;
-import org.eclipse.core.runtime.*;
-import org.eclipse.ui.dialogs.IOverwriteQuery;
-import org.eclipse.ui.wizards.datatransfer.*;
-
-/**
- * Helper methods to set up an IProject.
- */
-public class ProjectHelper {
-
- public static final IPath TEST_BUILDFILES_DIR= new Path("testbuildfiles");
- public static final IPath TEST_RESOURCES_DIR= new Path("testresources");
- public static final IPath TEST_LIB_DIR= new Path("testlib");
-
- /**
- * Creates a IProject.
- */
- public static IProject createProject(String projectName) throws CoreException {
- IWorkspaceRoot root= ResourcesPlugin.getWorkspace().getRoot();
- IProject project= root.getProject(projectName);
- if (!project.exists()) {
- project.create(null);
- } else {
- project.refreshLocal(IResource.DEPTH_INFINITE, null);
- }
-
- if (!project.isOpen()) {
- project.open(null);
- }
-
- return project;
- }
-
- /**
- * Removes an IProject.
- */
- public static void delete(IProject project) throws CoreException {
- project.delete(true, true, null);
- }
-
-
- /**
- * Adds a folder to an IProject.
- */
- public static IFolder addFolder(IProject project, String containerName) throws CoreException {
-
- IFolder folder= project.getFolder(containerName);
- if (!folder.exists()) {
- folder.create(false, true, null);
- }
-
- return folder;
-
- }
-
- public static void importFilesFromDirectory(File rootDir, IPath destPath, IProgressMonitor monitor) throws InvocationTargetException, IOException {
- IImportStructureProvider structureProvider = FileSystemStructureProvider.INSTANCE;
- List files = new ArrayList(100);
- addFiles(rootDir, files);
- try {
- ImportOperation op= new ImportOperation(destPath, rootDir, structureProvider, new ImportOverwriteQuery(), files);
- op.setCreateContainerStructure(false);
- op.run(monitor);
- } catch (InterruptedException e) {
- // should not happen
- }
- }
-
- private static void addFiles(File dir, List collection) throws IOException {
- File[] files = dir.listFiles();
- List subDirs = new ArrayList(2);
- for (int i = 0; i < files.length; i++) {
- if (files[i].isFile()) {
- collection.add(files[i]);
- } else if (files[i].isDirectory()) {
- subDirs.add(files[i]);
- }
- }
- Iterator iter = subDirs.iterator();
- while (iter.hasNext()) {
- File subDir = (File)iter.next();
- addFiles(subDir, collection);
- }
- }
-
- private static class ImportOverwriteQuery implements IOverwriteQuery {
- public String queryOverwrite(String file) {
- return ALL;
- }
- }
-} \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/inputHandlers/AntTestInputHandler.java b/ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/inputHandlers/AntTestInputHandler.java
deleted file mode 100644
index 9c1336f6f..000000000
--- a/ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/inputHandlers/AntTestInputHandler.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.core.support.inputHandlers;
-
-
-import org.apache.tools.ant.BuildException;
-import org.apache.tools.ant.input.DefaultInputHandler;
-import org.apache.tools.ant.input.InputRequest;
-
-/**
- * A test input handler when using Ant within Eclipse.
- * This is the class that will respond to <input> requests from
- * within an Ant build file.
- * If the build is occurring in Ant 1.6.0 and the -noinput option has been specified
- * this input handler will fail.
- */
-public class AntTestInputHandler extends DefaultInputHandler {
-
- /* (non-Javadoc)
- * @see org.apache.tools.ant.input.InputHandler#handleInput(org.apache.tools.ant.input.InputRequest)
- */
- public void handleInput(InputRequest request) throws BuildException {
- if (System.getProperty("eclipse.ant.noInput") != null) { //$NON-NLS-1$
- throw new BuildException("Unable to respond to input request likely as a result of specifying the -noinput command");
- }
- request.setInput("testing handling input requests");
- }
-}
diff --git a/ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/tasks/AntTestTask.java b/ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/tasks/AntTestTask.java
deleted file mode 100644
index c73c83695..000000000
--- a/ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/tasks/AntTestTask.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.core.support.tasks;
-
-
-
-import org.apache.tools.ant.BuildException;
-import org.apache.tools.ant.Task;
-import org.apache.tools.ant.taskdefs.Echo;
-
-
-public class AntTestTask extends Task {
-
- public AntTestTask() {
- super();
- }
-
- /**
- * @see org.apache.tools.ant.Task#execute()
- */
- public void execute() throws BuildException {
- Echo echo= new Echo();
- echo.setProject(getProject());
- echo.setMessage("Testing Ant in Eclipse with a custom task");
- echo.execute();
- }
-}
diff --git a/ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/tasks/AntTestTask2.java b/ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/tasks/AntTestTask2.java
deleted file mode 100644
index 59dddc71b..000000000
--- a/ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/tasks/AntTestTask2.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.core.support.tasks;
-
-
-
-import org.apache.tools.ant.BuildException;
-import org.apache.tools.ant.Task;
-import org.apache.tools.ant.taskdefs.Echo;
-
-
-public class AntTestTask2 extends Task {
-
- public AntTestTask2() {
- super();
- }
-
- /**
- * @see org.apache.tools.ant.Task#execute()
- */
- public void execute() throws BuildException {
- Echo echo= new Echo();
- echo.setProject(getProject());
- echo.setMessage("Testing Ant in Eclipse with a custom task");
- echo.execute();
- }
-}
diff --git a/ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/testloggers/TestBuildListener.java b/ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/testloggers/TestBuildListener.java
deleted file mode 100644
index 30d4ddf11..000000000
--- a/ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/testloggers/TestBuildListener.java
+++ /dev/null
@@ -1,64 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.core.support.testloggers;
-
-
-import org.apache.tools.ant.BuildEvent;
-import org.apache.tools.ant.BuildListener;
-import org.eclipse.ant.tests.core.testplugin.AntTestChecker;
-
-
-public class TestBuildListener implements BuildListener {
-
- /**
- * @see org.apache.tools.ant.BuildListener#buildFinished(org.apache.tools.ant.BuildEvent)
- */
- public void buildFinished(BuildEvent event) {
- }
-
- /**
- * @see org.apache.tools.ant.BuildListener#buildStarted(org.apache.tools.ant.BuildEvent)
- */
- public void buildStarted(BuildEvent event) {
- AntTestChecker.getDefault().addNameOfListener(this.getClass().getName());
- }
-
- /**
- * @see org.apache.tools.ant.BuildListener#messageLogged(org.apache.tools.ant.BuildEvent)
- */
- public void messageLogged(BuildEvent event) {
- }
-
- /**
- * @see org.apache.tools.ant.BuildListener#targetFinished(org.apache.tools.ant.BuildEvent)
- */
- public void targetFinished(BuildEvent event) {
- }
-
- /**
- * @see org.apache.tools.ant.BuildListener#targetStarted(org.apache.tools.ant.BuildEvent)
- */
- public void targetStarted(BuildEvent event) {
- }
-
- /**
- * @see org.apache.tools.ant.BuildListener#taskFinished(org.apache.tools.ant.BuildEvent)
- */
- public void taskFinished(BuildEvent event) {
- }
-
- /**
- * @see org.apache.tools.ant.BuildListener#taskStarted(org.apache.tools.ant.BuildEvent)
- */
- public void taskStarted(BuildEvent event) {
- }
-
-}
diff --git a/ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/testloggers/TestBuildLogger.java b/ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/testloggers/TestBuildLogger.java
deleted file mode 100644
index 4edc76632..000000000
--- a/ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/testloggers/TestBuildLogger.java
+++ /dev/null
@@ -1,172 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.core.support.testloggers;
-
-
-import java.io.PrintStream;
-
-import org.apache.tools.ant.*;
-import org.eclipse.ant.core.AntSecurityException;
-import org.eclipse.ant.tests.core.testplugin.AntTestChecker;
-import org.eclipse.core.runtime.OperationCanceledException;
-
-public class TestBuildLogger implements BuildLogger {
-
- private int messageOutputLevel =Project.MSG_INFO;
- private PrintStream fErr= null;
- private PrintStream fOut= null;
-
- /**
- * An exception that has already been logged.
- */
- private Throwable fHandledException= null;
-
-
- public TestBuildLogger() {
- }
-
- /**
- * @see org.apache.tools.ant.BuildLogger#setMessageOutputLevel(int)
- */
- public void setMessageOutputLevel(int level) {
- messageOutputLevel= level;
- }
-
- protected int getMessageOutputLevel() {
- return messageOutputLevel;
- }
-
- /**
- * @see org.apache.tools.ant.BuildLogger#setEmacsMode(boolean)
- */
- public void setEmacsMode(boolean emacsMode) {
- }
-
- /**
- * @see org.apache.tools.ant.BuildListener#buildStarted(org.apache.tools.ant.BuildEvent)
- */
- public void buildStarted(BuildEvent event) {
- AntTestChecker.getDefault().buildStarted(event.getProject().getName());
- AntTestChecker.getDefault().setUserProperties(event.getProject().getProperties());
- }
-
- /**
- * @see org.apache.tools.ant.BuildListener#buildFinished(org.apache.tools.ant.BuildEvent)
- */
- public void buildFinished(BuildEvent event) {
- handleException(event);
- fHandledException= null;
- AntTestChecker.getDefault().buildFinished();
- }
-
- /**
- * @see org.apache.tools.ant.BuildListener#targetStarted(org.apache.tools.ant.BuildEvent)
- */
- public void targetStarted(BuildEvent event) {
- AntTestChecker.getDefault().targetStarted(event.getTarget().getName());
- }
-
- /**
- * @see org.apache.tools.ant.BuildListener#targetFinished(org.apache.tools.ant.BuildEvent)
- */
- public void targetFinished(BuildEvent event) {
- handleException(event);
- AntTestChecker.getDefault().targetFinished();
- }
-
- /**
- * @see org.apache.tools.ant.BuildListener#taskStarted(org.apache.tools.ant.BuildEvent)
- */
- public void taskStarted(BuildEvent event) {
- AntTestChecker.getDefault().taskStarted(event.getTask().getTaskName());
- }
-
- /**
- * @see org.apache.tools.ant.BuildListener#taskFinished(org.apache.tools.ant.BuildEvent)
- */
- public void taskFinished(BuildEvent event) {
- handleException(event);
- AntTestChecker.getDefault().targetFinished();
- }
-
- /**
- * @see BuildListener#messageLogged(BuildEvent)
- */
- public void messageLogged(BuildEvent event) {
- if (event.getPriority() > getMessageOutputLevel()) {
- return;
- }
- logMessage(event.getMessage(), event.getPriority());
- AntTestChecker.getDefault().messageLogged(event.getMessage());
- }
-
- protected PrintStream getErrorPrintStream() {
- return fErr;
- }
-
- protected PrintStream getOutputPrintStream() {
- return fOut;
- }
-
- /**
- * @see org.apache.tools.ant.BuildLogger#setErrorPrintStream(java.io.PrintStream)
- */
- public void setErrorPrintStream(PrintStream err) {
- //this build logger logs to "null" unless
- //the user has explicitly set a logfile to use
- if (err == System.err) {
- fErr= null;
- } else {
- fErr= err;
- }
- }
-
- /**
- * @see org.apache.tools.ant.BuildLogger#setOutputPrintStream(java.io.PrintStream)
- */
- public void setOutputPrintStream(PrintStream output) {
- //this build logger logs to "null" unless
- //the user has explicitly set a logfile to use
- if (output == System.out) {
- fOut= null;
- } else {
- fOut= output;
- }
- }
-
- protected void logMessage(String message, int priority) {
- if (priority > getMessageOutputLevel()) {
- return;
- }
-
- if (priority == Project.MSG_ERR) {
- if (getErrorPrintStream() != null && getErrorPrintStream() != System.err) {
- //user has designated to log to a logfile
- getErrorPrintStream().println(message);
- }
- } else {
- if (getOutputPrintStream() != null && getOutputPrintStream() != System.out) {
- //user has designated to log to a logfile
- getOutputPrintStream().println(message);
- }
- }
- }
-
- protected void handleException(BuildEvent event) {
- Throwable exception = event.getException();
- if (exception == null || exception == fHandledException
- || exception instanceof OperationCanceledException
- || exception instanceof AntSecurityException) {
- return;
- }
- fHandledException= exception;
- }
-}
diff --git a/ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/types/AntTestPath.java b/ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/types/AntTestPath.java
deleted file mode 100644
index 408ac4a94..000000000
--- a/ant/org.eclipse.ant.tests.core/test support/org/eclipse/ant/tests/core/support/types/AntTestPath.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.core.support.types;
-
-
-
-import org.apache.tools.ant.Project;
-import org.apache.tools.ant.types.Path;
-
-public class AntTestPath extends Path {
-
- String message;
-
- public AntTestPath(Project project) {
- super(project);
- }
-
- public void setMessage(String message) {
- this.message= message;
- }
-
- public String getMessage() {
- return message;
- }
-
-}
diff --git a/ant/org.eclipse.ant.tests.core/test.xml b/ant/org.eclipse.ant.tests.core/test.xml
deleted file mode 100644
index 0eb1e4f29..000000000
--- a/ant/org.eclipse.ant.tests.core/test.xml
+++ /dev/null
@@ -1,50 +0,0 @@
-<?xml version="1.0"?>
-
-<project name="testsuite" default="run" basedir=".">
- <!-- sets the properties eclipse-home, and library-file -->
- <!-- The property ${eclipse-home} should be passed into this script -->
- <!-- Set a meaningful default value for when it is not. -->
- <property name="eclipse-home" value="${basedir}\..\.."/>
-<property name="plugin-name" value="org.eclipse.ant.tests.core"/>
- <property name="library-file"
- value="${eclipse-home}/plugins/org.eclipse.test/library.xml"/>
-
- <!-- This target holds all initialization code that needs to be done for -->
- <!-- all tests that are to be run. Initialization for individual tests -->
- <!-- should be done within the body of the suite target. -->
- <target name="init">
- <tstamp/>
- <delete>
- <fileset dir="${eclipse-home}" includes="org*.xml"/>
- </delete>
- </target>
-
- <!-- This target defines the tests that need to be run. -->
- <target name="suite">
- <property name="jdt-folder"
- value="${eclipse-home}/jdt_folder"/>
- <delete dir="${jdt-folder}" quiet="true"/>
- <ant target="core-test" antfile="${library-file}" dir="${eclipse-home}">
- <property name="data-dir" value="${jdt-folder}"/>
- <property name="plugin-name" value="${plugin-name}"/>
- <property name="classname"
- value="org.eclipse.ant.tests.core.AutomatedSuite"/>
- </ant>
- </target>
-
- <!-- This target holds code to cleanup the testing environment after -->
- <!-- after all of the tests have been run. You can use this target to -->
- <!-- delete temporary files that have been created. -->
- <target name="cleanup">
- </target>
-
- <!-- This target runs the test suite. Any actions that need to happen -->
- <!-- after all the tests have been run should go here. -->
- <target name="run" depends="init,suite,cleanup">
- <ant target="collect" antfile="${library-file}" dir="${eclipse-home}">
- <property name="includes" value="org*.xml"/>
- <property name="output-file" value="${plugin-name}.xml"/>
- </ant>
- </target>
-
-</project>
diff --git a/ant/org.eclipse.ant.tests.core/testbuildfiles/Bug32551.xml b/ant/org.eclipse.ant.tests.core/testbuildfiles/Bug32551.xml
deleted file mode 100644
index e5439971c..000000000
--- a/ant/org.eclipse.ant.tests.core/testbuildfiles/Bug32551.xml
+++ /dev/null
@@ -1,15 +0,0 @@
-<project name="bug" default="all">
- <path id="myclasspath">
- <fileset dir="..\lib">
- <include name="antTestsSupport.jar" />
- </fileset>
- </path>
-
- <taskdef name="hello" classname="org.eclipse.ant.tests.core.support.tasks.AntTestTask">
- <classpath refid="myclasspath" />
- </taskdef>
-
- <target name="all">
- <hello />
- </target>
- </project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.core/testbuildfiles/Bug34663.xml b/ant/org.eclipse.ant.tests.core/testbuildfiles/Bug34663.xml
deleted file mode 100644
index 4ba03f146..000000000
--- a/ant/org.eclipse.ant.tests.core/testbuildfiles/Bug34663.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-<project name="34663.xml" default="echoP">
-
-<taskdef file="${ROOTDIR}/taskdefs.properties" />
-
- <target name="echoP">
- <echoProperties/>
- </target>
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.core/testbuildfiles/Bug42926.xml b/ant/org.eclipse.ant.tests.core/testbuildfiles/Bug42926.xml
deleted file mode 100644
index 3bb86a294..000000000
--- a/ant/org.eclipse.ant.tests.core/testbuildfiles/Bug42926.xml
+++ /dev/null
@@ -1,12 +0,0 @@
-<project default="all">
- <path id="someclasspath">
- <fileset dir="${ant.home}/lib" includes="sometask.jar"/>
- </path>
-
- <taskdef name="sometask" classname="com.foo.SomeTask"
-classpathref="someclasspath"/>
-
- <target name="all">
- <echo>Hello ${ant.home}</echo>
- </target>
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.core/testbuildfiles/ClasspathOrdering.xml b/ant/org.eclipse.ant.tests.core/testbuildfiles/ClasspathOrdering.xml
deleted file mode 100644
index c99b65e1e..000000000
--- a/ant/org.eclipse.ant.tests.core/testbuildfiles/ClasspathOrdering.xml
+++ /dev/null
@@ -1,6 +0,0 @@
-<project name="ClasspathOrdering" default="ordered" basedir="..">
-
- <target name="ordered">
- <java classname= "ClasspathOrdering"/>
- </target>
-</project>
diff --git a/ant/org.eclipse.ant.tests.core/testbuildfiles/CustomTask.xml b/ant/org.eclipse.ant.tests.core/testbuildfiles/CustomTask.xml
deleted file mode 100644
index 53525c8b0..000000000
--- a/ant/org.eclipse.ant.tests.core/testbuildfiles/CustomTask.xml
+++ /dev/null
@@ -1,13 +0,0 @@
-<project name="Custom Task" default="Custom Task" basedir=".">
- <target name="init">
- <tstamp/>
- </target>
-
- <target name="Custom Task" description= "Test adding a custom task" depends="init">
- <AntTestTask/>
- </target>
-
- <target name="Custom Task from Entry" description= "Test adding a custom task">
- <AntTestTask2/>
- </target>
-</project>
diff --git a/ant/org.eclipse.ant.tests.core/testbuildfiles/CustomType.xml b/ant/org.eclipse.ant.tests.core/testbuildfiles/CustomType.xml
deleted file mode 100644
index 1ae1ef5c3..000000000
--- a/ant/org.eclipse.ant.tests.core/testbuildfiles/CustomType.xml
+++ /dev/null
@@ -1,16 +0,0 @@
-<project name="Custom Type" default="Custom Type" basedir=".">
-
- <anttestpath id="compile.classpath">
- <fileset dir="lib">
- <include name="**/*.jar"/>
- </fileset>
- </anttestpath>
-
- <target name="init">
- <tstamp/>
- </target>
-
- <target name="Custom Type" description= "Test adding a custom type" depends="init">
- <echo message="Test adding a custom type"/>
- </target>
-</project>
diff --git a/ant/org.eclipse.ant.tests.core/testbuildfiles/ExtensionPointTask.xml b/ant/org.eclipse.ant.tests.core/testbuildfiles/ExtensionPointTask.xml
deleted file mode 100644
index 10a31408d..000000000
--- a/ant/org.eclipse.ant.tests.core/testbuildfiles/ExtensionPointTask.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-<project name="Extension Point Task" default="Extension Point Task" basedir=".">
- <target name="Extension Point Task" description= "Ensure that an extension point defined task is present">
- <coolTask/>
- </target>
-</project>
diff --git a/ant/org.eclipse.ant.tests.core/testbuildfiles/ExtensionPointType.xml b/ant/org.eclipse.ant.tests.core/testbuildfiles/ExtensionPointType.xml
deleted file mode 100644
index abaaaec76..000000000
--- a/ant/org.eclipse.ant.tests.core/testbuildfiles/ExtensionPointType.xml
+++ /dev/null
@@ -1,12 +0,0 @@
-<project name="Extension Point Type" default="Extension Point Type" basedir=".">
-
- <coolType id="compile.classpath">
- <fileset dir="lib">
- <include name="**/*.jar"/>
- </fileset>
- </coolType>
-
- <target name="Extension Point Type" description= "Ensure that an extension point defined type is present">
- <echo message="Ensure that an extension point defined type is present"/>
- </target>
-</project>
diff --git a/ant/org.eclipse.ant.tests.core/testbuildfiles/NoDefault.xml b/ant/org.eclipse.ant.tests.core/testbuildfiles/NoDefault.xml
deleted file mode 100644
index 305d7e909..000000000
--- a/ant/org.eclipse.ant.tests.core/testbuildfiles/NoDefault.xml
+++ /dev/null
@@ -1,6 +0,0 @@
-<project name= "Testing" default="build">
-
- <target name= "test">
- <echo message="testing"/>
- </target>
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.core/testbuildfiles/TestForEcho.xml b/ant/org.eclipse.ant.tests.core/testbuildfiles/TestForEcho.xml
deleted file mode 100644
index 2213e5e5b..000000000
--- a/ant/org.eclipse.ant.tests.core/testbuildfiles/TestForEcho.xml
+++ /dev/null
@@ -1,11 +0,0 @@
-<project name="Echo Test" default="Test for Echo" basedir=".">
- <target name="init">
- <tstamp/>
- </target>
-
- <target name="Test for Echo" description= "Calls other echos" depends="init">
- <ant antfile="buildfiles/echoing.xml" dir="../../AntTests" target="echo1"/>
- <ant antfile="buildfiles/echoing.xml" dir="../../AntTests" target="echo2"/>
- <ant antfile="buildfiles/echoing.xml" dir="../../AntTests" target="echo3"/>
- </target>
-</project>
diff --git a/ant/org.eclipse.ant.tests.core/testbuildfiles/build.xml b/ant/org.eclipse.ant.tests.core/testbuildfiles/build.xml
deleted file mode 100644
index 7638a536c..000000000
--- a/ant/org.eclipse.ant.tests.core/testbuildfiles/build.xml
+++ /dev/null
@@ -1,14 +0,0 @@
-<project name="Eching" default="echo1" basedir="..">
-
- <target name="echo1">
- <echo message="echo1"/>
- </target>
-
- <target name="echo2">
- <echo message="echo2"/>
- </target>
-
- <target name="echo3" description= "An echo3!">
- <echo message="echo3"/>
- </target>
-</project>
diff --git a/ant/org.eclipse.ant.tests.core/testbuildfiles/echoing.xml b/ant/org.eclipse.ant.tests.core/testbuildfiles/echoing.xml
deleted file mode 100644
index 5cdd64da7..000000000
--- a/ant/org.eclipse.ant.tests.core/testbuildfiles/echoing.xml
+++ /dev/null
@@ -1,14 +0,0 @@
-<project name="Echoing" default="echo1" basedir="..">
-
- <target name="echo1">
- <echo message="echo1"/>
- </target>
-
- <target name="echo2">
- <echo message="echo2"/>
- </target>
-
- <target name="echo3" description= "An echo3!">
- <echo message="echo3"/>
- </target>
-</project>
diff --git a/ant/org.eclipse.ant.tests.core/testbuildfiles/failingTarget.xml b/ant/org.eclipse.ant.tests.core/testbuildfiles/failingTarget.xml
deleted file mode 100644
index 04418e08a..000000000
--- a/ant/org.eclipse.ant.tests.core/testbuildfiles/failingTarget.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-<project default="all">
- <target name="all" depends="fails, echos"/>
- <target name="fails">
- <jar jarfile="jar16.jar" basedir="doesNotExist"/>
- </target>
- <target name="echos">
- <echo>Still echo on failure</echo>
- </target>
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.core/testbuildfiles/input.xml b/ant/org.eclipse.ant.tests.core/testbuildfiles/input.xml
deleted file mode 100644
index 8d70ab5f4..000000000
--- a/ant/org.eclipse.ant.tests.core/testbuildfiles/input.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-<project name="input testing" default= "input test">
- <target name="input test">
- <input message="Enter for echo" addproperty= "inputTest">
- </input>
- <echo message="${inputTest}"/>
- </target>
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.core/testbuildfiles/javac.xml b/ant/org.eclipse.ant.tests.core/testbuildfiles/javac.xml
deleted file mode 100644
index 42f022581..000000000
--- a/ant/org.eclipse.ant.tests.core/testbuildfiles/javac.xml
+++ /dev/null
@@ -1,33 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project name="org.eclipse.ant.core" default="build" basedir="..">
-
-
- <target name="init" depends="properties">
- <property name="plugin" value="AntTests"/>
- <property name="temp.folder" value="${basedir}/temp.folder"/>
- <property name="plugin.destination" value="${basedir}"/>
- <property name="build.result.folder" value="${basedir}"/>
- </target>
-
- <target name="properties" if="use.eclipse.JDTCompiler">
- <property name="build.compiler" value="org.eclipse.jdt.core.JDTCompilerAdapter"/>
- </target>
-
- <target name="build" depends="init">
- <property name="destdir" value="${temp.folder}/javac.bin"/>
- <delete dir="${temp.folder}/javac.bin"/>
- <mkdir dir="${temp.folder}/javac.bin"/>
- <!-- compile the source code -->
- <javac destdir="${temp.folder}/javac.bin" failonerror="false" verbose="false" debug="on" includeAntRuntime="yes">
- <src path="resources"/>
- </javac>
- </target>
-
- <target name="clean" depends="init">
- <delete dir="${temp.folder}"/>
- </target>
-
- <target name="refresh" depends="init" if="eclipse.running">
- <eclipse.refreshLocal resource="${plugin}" depth="infinite"/>
- </target>
-</project>
diff --git a/ant/org.eclipse.ant.tests.core/testlib/classpathOrdering1.jar b/ant/org.eclipse.ant.tests.core/testlib/classpathOrdering1.jar
deleted file mode 100644
index b10cb7f6f..000000000
--- a/ant/org.eclipse.ant.tests.core/testlib/classpathOrdering1.jar
+++ /dev/null
Binary files differ
diff --git a/ant/org.eclipse.ant.tests.core/testlib/classpathOrdering2.jar b/ant/org.eclipse.ant.tests.core/testlib/classpathOrdering2.jar
deleted file mode 100644
index 6816741ca..000000000
--- a/ant/org.eclipse.ant.tests.core/testlib/classpathOrdering2.jar
+++ /dev/null
Binary files differ
diff --git a/ant/org.eclipse.ant.tests.core/testlib/taskFolder/org/eclipse/ant/tests/core/support/tasks/AntTestTask2.class b/ant/org.eclipse.ant.tests.core/testlib/taskFolder/org/eclipse/ant/tests/core/support/tasks/AntTestTask2.class
deleted file mode 100644
index 6a37eb55f..000000000
--- a/ant/org.eclipse.ant.tests.core/testlib/taskFolder/org/eclipse/ant/tests/core/support/tasks/AntTestTask2.class
+++ /dev/null
Binary files differ
diff --git a/ant/org.eclipse.ant.tests.core/testresources/AntTestTask.java b/ant/org.eclipse.ant.tests.core/testresources/AntTestTask.java
deleted file mode 100644
index bc4f60232..000000000
--- a/ant/org.eclipse.ant.tests.core/testresources/AntTestTask.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-
-
-import org.apache.tools.ant.BuildException;
-import org.apache.tools.ant.Task;
-import org.apache.tools.ant.taskdefs.Echo;
-
-
-public class AntTestTask extends Task {
-
- public AntTestTask() {
- super();
- }
-
- /**
- * @see org.apache.tools.ant.Task#execute()
- */
- public void execute() throws BuildException {
- Echo echo= new Echo();
- echo.setProject(getProject());
- echo.setMessage("Testing Ant in Eclipse with a custom task");
- echo.execute();
- }
-}
diff --git a/ant/org.eclipse.ant.tests.core/testresources/taskdefs.properties b/ant/org.eclipse.ant.tests.core/testresources/taskdefs.properties
deleted file mode 100644
index 52049fff1..000000000
--- a/ant/org.eclipse.ant.tests.core/testresources/taskdefs.properties
+++ /dev/null
@@ -1 +0,0 @@
-echoProperties=org.apache.tools.ant.taskdefs.optional.EchoProperties \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.core/testresources/test.properties b/ant/org.eclipse.ant.tests.core/testresources/test.properties
deleted file mode 100644
index 7eacd3a26..000000000
--- a/ant/org.eclipse.ant.tests.core/testresources/test.properties
+++ /dev/null
@@ -1,12 +0,0 @@
-###############################################################################
-# Copyright (c) 2000, 2003 IBM Corporation and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Common Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/cpl-v10.html
-#
-# Contributors:
-# IBM Corporation - initial API and implementation
-###############################################################################
-AntTests=testing from properties file
-eclipse.is.cool=Yep
diff --git a/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/AbstractAntTest.java b/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/AbstractAntTest.java
deleted file mode 100644
index 3aa3fced7..000000000
--- a/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/AbstractAntTest.java
+++ /dev/null
@@ -1,231 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.core;
-
-
-import java.util.List;
-
-import junit.framework.TestCase;
-
-import org.eclipse.ant.core.AntCorePlugin;
-import org.eclipse.ant.core.AntCorePreferences;
-import org.eclipse.ant.core.AntRunner;
-import org.eclipse.ant.core.IAntClasspathEntry;
-import org.eclipse.ant.core.Property;
-import org.eclipse.ant.core.TargetInfo;
-import org.eclipse.ant.core.Task;
-import org.eclipse.ant.core.Type;
-import org.eclipse.ant.tests.core.testplugin.AntFileRunner;
-import org.eclipse.ant.tests.core.testplugin.AntTestChecker;
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.Path;
-
-
-
-/**
- * Tests for Ant core
- */
-public abstract class AbstractAntTest extends TestCase {
-
- protected static final String BUILD_SUCCESSFUL= "BUILD SUCCESSFUL";
- public static final String ANT_TEST_BUILD_LOGGER = "org.eclipse.ant.tests.core.support.testloggers.TestBuildLogger"; //$NON-NLS-1$
- public static final String ANT_TEST_BUILD_LISTENER= "org.eclipse.ant.tests.core.support.testloggers.TestBuildListener";
-
- /**
- * Returns the 'AntTests' project.
- *
- * @return the test project
- */
- protected IProject getProject() {
- return ResourcesPlugin.getWorkspace().getRoot().getProject("AntTests");
- }
-
- public static IProject project;
-
-
- public AbstractAntTest(String name) {
- super(name);
- }
-
- protected IFile getBuildFile(String buildFileName) {
- IFile file = getProject().getFolder("buildfiles").getFile(buildFileName);
- assertTrue("Could not find build file named: " + buildFileName, file.exists());
- return file;
- }
-
- protected IFolder getWorkingDirectory(String workingDirectoryName) {
- IFolder folder = getProject().getFolder(workingDirectoryName);
- assertTrue("Could not find the working directory named: " + workingDirectoryName, folder.exists());
- return folder;
- }
-
- protected IFile checkFileExists(String fileName) throws CoreException {
- getProject().refreshLocal(IResource.DEPTH_INFINITE, null);
- IFile file = getProject().getFolder("buildfiles").getFile(fileName);
- assertTrue("Could not find file named: " + fileName, file.exists());
- return file;
- }
-
- public void run(String buildFileName) throws CoreException {
- run(buildFileName, null, true);
- }
-
- public void run(String buildFileName, String[] args) throws CoreException {
- run(buildFileName, args, true);
- }
-
- public void run(String buildFileName, String[] args, boolean retrieveTargets) throws CoreException {
- run(buildFileName, args, retrieveTargets, "");
- }
-
- public void run(String buildFileName, String[] args, boolean retrieveTargets, String workingDir) throws CoreException {
- AntTestChecker.reset();
- IFile buildFile= null;
- if (buildFileName != null) {
- buildFile= getBuildFile(buildFileName);
- }
- AntFileRunner runner= new AntFileRunner();
- String[] targets= null;
- if (retrieveTargets) {
- targets= getTargetNames(buildFileName);
- }
- if (workingDir.length() > 0) {
- workingDir= getWorkingDirectory(workingDir).getLocation().toFile().getAbsolutePath();
- }
- runner.run(buildFile, targets, args, workingDir, true);
- assertTrue("Build starts did not equal build finishes", AntTestChecker.getDefault().getBuildsStartedCount() == AntTestChecker.getDefault().getBuildsFinishedCount());
- }
-
- protected TargetInfo[] getTargets(String buildFileName) throws CoreException {
- IFile buildFile= getBuildFile(buildFileName);
-
- AntRunner runner = new AntRunner();
- runner.setBuildFileLocation(buildFile.getLocation().toFile().getAbsolutePath());
- return runner.getAvailableTargets();
- }
-
- protected String[] getTargetNames(String buildFileName) throws CoreException {
- TargetInfo[] infos= getTargets(buildFileName);
- String[] names= new String[infos.length];
- for (int i = 0; i < infos.length; i++) {
- TargetInfo info = infos[i];
- names[i]= info.getName();
- }
- return names;
- }
-
- protected String[] getTargetDescriptions(String buildFileName) throws CoreException {
- TargetInfo[] infos= getTargets(buildFileName);
- String[] descriptions= new String[infos.length];
- for (int i = 0; i < infos.length; i++) {
- TargetInfo info = infos[i];
- descriptions[i]= info.getDescription();
- }
- return descriptions;
- }
-
- /**
- * Returns the name of the project containing the given target in the given build file or
- * <code>null</code> if no project name can be found.
- */
- protected String getProjectName(String buildFileName, String targetName) throws CoreException {
- TargetInfo info= getTarget(buildFileName, targetName);
- if (info != null) {
- return info.getProject().getName();
- }
- return null;
- }
-
- /**
- * Returns the dependencies of the target with the given name in the given build file or <code>null</code>
- * if no such target can be found.
- */
- protected String[] getDependencies(String buildFileName, String targetName) throws CoreException {
- TargetInfo info= getTarget(buildFileName, targetName);
- if (info != null) {
- return info.getDependencies();
- }
- return null;
- }
-
- /**
- * Returns the target with the given name in the given build file or <code>null</code>
- * if no such target can be found.
- */
- protected TargetInfo getTarget(String buildFileName, String targetName) throws CoreException {
- TargetInfo[] infos= getTargets(buildFileName);
- for (int i= 0, numTargets= infos.length; i < numTargets; i++) {
- if (infos[i].getName().equals(targetName)) {
- return infos[i];
- }
- }
- return null;
- }
-
- /**
- * Return the log message n from the last:
- * e.g. getLoggedMessage(0) returns the most recent message
- *
- * @param n message index
- * @return the nth last message
- */
- protected String getLoggedMessage(int n) {
- return AntTestChecker.getDefault().getLoggedMessage(n);
- }
-
- protected String getLastMessageLogged() {
- return getLoggedMessage(0);
- }
-
- protected void assertSuccessful() {
- List messages= AntTestChecker.getDefault().getMessages();
- String success= (String)messages.get(messages.size() - 1);
- assertTrue("Build was not flagged as successful: " + success, BUILD_SUCCESSFUL.equals(success));
- }
-
- protected String getPropertyFileName() {
- return getProject().getFolder("resources").getFile("test.properties").getLocation().toFile().getAbsolutePath();
- }
-
- protected void restorePreferenceDefaults() {
- AntCorePreferences prefs= AntCorePlugin.getPlugin().getPreferences();
- IAntClasspathEntry toolsEntry= prefs.getToolsJarEntry();
- IAntClasspathEntry[] additionalEntries;
- if (toolsEntry == null) {
- additionalEntries= new IAntClasspathEntry[]{};
- } else {
- additionalEntries= new IAntClasspathEntry[] {toolsEntry};
- }
- prefs.setAdditionalClasspathEntries(additionalEntries);
- prefs.setAntHomeClasspathEntries(prefs.getDefaultAntHomeEntries());
- prefs.setCustomTasks(new Task[]{});
- prefs.setCustomTypes(new Type[]{});
- prefs.setCustomPropertyFiles(new String[]{});
- prefs.setCustomProperties(new Property[]{});
- prefs.setAntHome(prefs.getDefaultAntHome());
- }
-
- protected String getAntHome() {
- AntCorePreferences prefs= AntCorePlugin.getPlugin().getPreferences();
- IAntClasspathEntry[] entries= prefs.getAntHomeClasspathEntries();
- IAntClasspathEntry antjar= entries[0];
- IPath antHomePath= new Path(antjar.getEntryURL().getFile());
- antHomePath= antHomePath.removeLastSegments(1);
- return antHomePath.toFile().getAbsolutePath();
- }
-}
-
diff --git a/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/AutomatedSuite.java b/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/AutomatedSuite.java
deleted file mode 100644
index 379babaf5..000000000
--- a/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/AutomatedSuite.java
+++ /dev/null
@@ -1,95 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.core;
-
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-import org.eclipse.ant.tests.core.tests.*;
-
-/**
- * Test all areas of Ant.
- *
- * To run this test suite:
- * <ol>
- * <li>Create a new JUnit plugin test launch configuration</li>
- * <li>Set the Test class to "org.eclipse.ant.tests.core.AutomatedSuite"</li>
- * <li>Set the Project to "org.eclipse.ant.tests.core"</li>
- * <li>Run the launch configuration. Output from the tests will be displayed in a JUnit view</li>
- * </ol>
- */
-public class AutomatedSuite extends TestSuite {
-
- /**
- * Flag that indicates test are in progress
- */
- protected boolean testing = true;
-
- /**
- * Returns the suite. This is required to
- * use the JUnit Launcher.
- */
- public static Test suite() {
- return new AutomatedSuite();
- }
-
- /**
- * Construct the test suite.
- */
- public AutomatedSuite() {
- addTest(new TestSuite(ProjectCreationDecorator.class));
- addTest(new TestSuite(FrameworkTests.class));
- addTest(new TestSuite(TargetTests.class));
- addTest(new TestSuite(ProjectTests.class));
- addTest(new TestSuite(OptionTests.class));
- addTest(new TestSuite(TaskTests.class));
- addTest(new TestSuite(TypeTests.class));
- }
-
- /**
- * Runs the tests and collects their result in a TestResult without blocking.
- * the UI thread. Not normally needed but nice to have to check on the state of
- * environment during a test run.
- */
-// public void run(final TestResult result) {
-// final Display display = Display.getCurrent();
-// Thread thread = null;
-// try {
-// Runnable r = new Runnable() {
-// public void run() {
-// for (Enumeration e= tests(); e.hasMoreElements(); ) {
-// if (result.shouldStop() )
-// break;
-// Test test= (Test)e.nextElement();
-// runTest(test, result);
-// }
-// testing = false;
-// display.wake();
-// }
-// };
-// thread = new Thread(r);
-// thread.start();
-// } catch (Exception e) {
-// e.printStackTrace();
-// }
-//
-// while (testing) {
-// try {
-// if (!display.readAndDispatch())
-// display.sleep();
-// } catch (Throwable e) {
-// e.printStackTrace();
-// }
-// }
-// }
-}
-
diff --git a/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/ProjectCreationDecorator.java b/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/ProjectCreationDecorator.java
deleted file mode 100644
index 8d5d64e0e..000000000
--- a/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/ProjectCreationDecorator.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.core;
-
-
-import java.io.File;
-
-import org.eclipse.ant.tests.core.testplugin.AntTestPlugin;
-import org.eclipse.ant.tests.core.testplugin.ProjectHelper;
-import org.eclipse.core.resources.*;
-
-/**
- * Test to close the workbench, since debug tests do not run in the UI
- * thread.
- */
-public class ProjectCreationDecorator extends AbstractAntTest {
-
- public ProjectCreationDecorator(String name) {
- super(name);
- }
-
- public void testProjectCreation() throws Exception {
- // delete any pre-existing project
- IProject pro = ResourcesPlugin.getWorkspace().getRoot().getProject("AntTests");
- if (pro.exists()) {
- pro.delete(true, true, null);
- }
- // create project and import buildfiles and support files
- project = ProjectHelper.createProject("AntTests");
- IFolder folder = ProjectHelper.addFolder(project, "buildfiles");
- File root = AntTestPlugin.getDefault().getFileInPlugin(ProjectHelper.TEST_BUILDFILES_DIR);
- ProjectHelper.importFilesFromDirectory(root, folder.getFullPath(), null);
-
- folder = ProjectHelper.addFolder(project, "resources");
- root = AntTestPlugin.getDefault().getFileInPlugin(ProjectHelper.TEST_RESOURCES_DIR);
- ProjectHelper.importFilesFromDirectory(root, folder.getFullPath(), null);
-
- folder = ProjectHelper.addFolder(project, "lib");
- root = AntTestPlugin.getDefault().getFileInPlugin(ProjectHelper.TEST_LIB_DIR);
- ProjectHelper.importFilesFromDirectory(root, folder.getFullPath(), null);
- }
-}
diff --git a/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/FrameworkTests.java b/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/FrameworkTests.java
deleted file mode 100644
index 44bd7a4c9..000000000
--- a/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/FrameworkTests.java
+++ /dev/null
@@ -1,222 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.core.tests;
-
-
-import java.io.File;
-import java.net.MalformedURLException;
-import java.net.URL;
-
-import org.eclipse.ant.core.AntCorePlugin;
-import org.eclipse.ant.core.AntCorePreferences;
-import org.eclipse.ant.core.IAntClasspathEntry;
-import org.eclipse.ant.core.Property;
-import org.eclipse.ant.internal.core.AntClasspathEntry;
-import org.eclipse.ant.tests.core.AbstractAntTest;
-import org.eclipse.ant.tests.core.testplugin.AntTestChecker;
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.runtime.CoreException;
-
-public class FrameworkTests extends AbstractAntTest {
-
- public FrameworkTests(String name) {
- super(name);
- }
-
- /**
- * Ensures that the deprecated means of setting the classpath still works correctly
- * Do not fix deprecations unless the deprecated methods are being removed.
- * @throws MalformedURLException
- * @throws CoreException
- */
- public void testClasspathOrderingDeprecated() throws MalformedURLException, CoreException {
- AntCorePreferences prefs =AntCorePlugin.getPlugin().getPreferences();
-
- String path= getProject().getFolder("lib").getFile("classpathOrdering1.jar").getLocation().toFile().getAbsolutePath();
- URL url= new URL("file:" + path);
-
- path= getProject().getFolder("lib").getFile("classpathOrdering2.jar").getLocation().toFile().getAbsolutePath();
- URL url2= new URL("file:" + path);
-
- URL urls[] = prefs.getCustomURLs();
- URL newUrls[] = new URL[urls.length + 2];
- System.arraycopy(urls, 0, newUrls, 0, urls.length);
- newUrls[urls.length] = url;
- newUrls[urls.length + 1] = url2;
- prefs.setCustomURLs(newUrls);
-
- prefs.updatePluginPreferences();
-
- run("ClasspathOrdering.xml");
- String msg= (String)AntTestChecker.getDefault().getMessages().get(1);
- assertTrue("Message incorrect: " + msg, msg.equals("classpathOrdering1"));
- assertSuccessful();
-
- restorePreferenceDefaults();
-
- urls = prefs.getCustomURLs();
- newUrls = new URL[urls.length + 2];
- System.arraycopy(urls, 0, newUrls, 0, urls.length);
- newUrls[urls.length] = url2;
- newUrls[urls.length + 1] = url;
- prefs.setCustomURLs(newUrls);
-
- prefs.updatePluginPreferences();
-
- run("ClasspathOrdering.xml");
- msg= (String)AntTestChecker.getDefault().getMessages().get(1);
- assertTrue("Message incorrect: " + msg, msg.equals("classpathOrdering2"));
- assertSuccessful();
- restorePreferenceDefaults();
- }
-
- public void testClasspathOrdering() throws CoreException {
- AntCorePreferences prefs =AntCorePlugin.getPlugin().getPreferences();
-
- String path= getProject().getFolder("lib").getFile("classpathOrdering1.jar").getLocation().toFile().getAbsolutePath();
- IAntClasspathEntry entry= new AntClasspathEntry(path);
-
- path= getProject().getFolder("lib").getFile("classpathOrdering2.jar").getLocation().toFile().getAbsolutePath();
- IAntClasspathEntry entry2= new AntClasspathEntry(path);
-
- IAntClasspathEntry entries[] = prefs.getAdditionalClasspathEntries();
- IAntClasspathEntry newEntries[] = new IAntClasspathEntry[entries.length + 2];
- System.arraycopy(entries, 0, newEntries, 0, entries.length);
- newEntries[entries.length] = entry;
- newEntries[entries.length + 1] = entry2;
- prefs.setAdditionalClasspathEntries(newEntries);
-
- prefs.updatePluginPreferences();
-
- run("ClasspathOrdering.xml");
- String msg= (String)AntTestChecker.getDefault().getMessages().get(1);
- assertTrue("Message incorrect: " + msg, msg.equals("classpathOrdering1"));
- assertSuccessful();
-
- restorePreferenceDefaults();
-
- entries = prefs.getAdditionalClasspathEntries();
- newEntries = new IAntClasspathEntry[entries.length + 2];
- System.arraycopy(entries, 0, newEntries, 0, entries.length);
- newEntries[entries.length] = entry2;
- newEntries[entries.length + 1] = entry;
- prefs.setAdditionalClasspathEntries(newEntries);
-
- prefs.updatePluginPreferences();
-
- run("ClasspathOrdering.xml");
- msg= (String)AntTestChecker.getDefault().getMessages().get(1);
- assertTrue("Message incorrect: " + msg, msg.equals("classpathOrdering2"));
- assertSuccessful();
- restorePreferenceDefaults();
- }
-
- public void testNoDefaultTarget() {
- try {
- run("NoDefault.xml", new String[]{"test"}, false);
- } catch (CoreException e) {
- String msg= e.getMessage();
- assertTrue("Message incorrect: " + msg, msg.equals("Default target 'build' does not exist in this project"));
- return;
- }
- assertTrue("Build files with no default targets should not be accepted", false);
- }
-
- /**
- * Ensures that tasks like javac work when includeAntRuntime is specified
- * bug 20857.
- * This test will just return if the tests are conducted on a JRE (no tools.jar).
- */
- public void testIncludeAntRuntime() throws CoreException {
- IAntClasspathEntry toolsEntry= AntCorePlugin.getPlugin().getPreferences().getToolsJarEntry();
- if (toolsEntry == null) {
- //running on a JRE where tools.jar could not be found
- return;
- }
- run("javac.xml", new String[]{"build","refresh"}, false); //standard compiler
- assertSuccessful();
- IFile classFile= getProject().getFolder("temp.folder").getFolder("javac.bin").getFile("AntTestTask.class");
- assertTrue("Class file was not generated", classFile.exists());
- run("javac.xml", new String[]{"-Duse.eclipse.compiler=true", "clean", "build", "refresh"}, false); //JDTCompiler
- assertSuccessful();
- classFile= getProject().getFolder("temp.folder").getFolder("javac.bin").getFile("AntTestTask.class");
- assertTrue("Class file was not generated", classFile.exists());
- }
-
- /**
- * Tests the properties added using a global property file
- */
- public void testGlobalPropertyFile() throws CoreException {
-
- AntCorePreferences prefs =AntCorePlugin.getPlugin().getPreferences();
-
- String path= getPropertyFileName();
- prefs.setCustomPropertyFiles(new String[]{path});
-
- run("TestForEcho.xml", new String[]{});
- assertSuccessful();
- assertTrue("eclipse.is.cool should have been set as Yep", "Yep".equals(AntTestChecker.getDefault().getUserProperty("eclipse.is.cool")));
- assertTrue("AntTests should have a value of testing", "testing from properties file".equals(AntTestChecker.getDefault().getUserProperty("AntTests")));
- assertNull("my.name was not set and should be null", AntTestChecker.getDefault().getUserProperty("my.name"));
-
- restorePreferenceDefaults();
- }
-
- /**
- * Tests the properties added using a global property
- */
- public void testGlobalProperty() throws CoreException {
-
- AntCorePreferences prefs =AntCorePlugin.getPlugin().getPreferences();
- prefs.setCustomProperties(new Property[]{new Property("eclipse.is.cool", "Yep"), new Property("JUnitTest", "true")});
-
- run("TestForEcho.xml", new String[]{});
- assertSuccessful();
- assertTrue("eclipse.is.cool should have been set as Yep", "Yep".equals(AntTestChecker.getDefault().getUserProperty("eclipse.is.cool")));
- assertTrue("JUnitTests should have a value of true", "true".equals(AntTestChecker.getDefault().getUserProperty("JUnitTest")));
- assertNull("my.name was not set and should be null", AntTestChecker.getDefault().getUserProperty("my.name"));
-
- restorePreferenceDefaults();
- }
-
- public void testGlobalPropertyFileWithMinusDTakingPrecedence() throws CoreException {
- AntCorePreferences prefs =AntCorePlugin.getPlugin().getPreferences();
-
- String path= getPropertyFileName();
- prefs.setCustomPropertyFiles(new String[]{path});
-
- run("echoing.xml", new String[]{"-DAntTests=testing", "-Declipse.is.cool=true"}, false);
- assertSuccessful();
- assertTrue("eclipse.is.cool should have been set as true", "true".equals(AntTestChecker.getDefault().getUserProperty("eclipse.is.cool")));
- assertTrue("AntTests should have a value of testing", "testing".equals(AntTestChecker.getDefault().getUserProperty("AntTests")));
- assertNull("my.name was not set and should be null", AntTestChecker.getDefault().getUserProperty("my.name"));
- restorePreferenceDefaults();
- }
-
- /**
- * Tests that the default ANT_HOME is set and that it can be changed
- */
- public void testSettingAntHome() throws CoreException {
- try {
- AntCorePreferences prefs= AntCorePlugin.getPlugin().getPreferences();
- run("echoing.xml");
- assertTrue("ANT_HOME not set correctly", prefs.getDefaultAntHome().equals(System.getProperty("ant.home")));
- File antLibDir= new File(prefs.getDefaultAntHome(), "lib"); //$NON-NLS-1$
- assertTrue("ant.library.dir not set correctly", antLibDir.getAbsolutePath().equals(System.getProperty("ant.library.dir")));
- prefs.setAntHome("");
- run("echoing.xml");
- assertTrue("ANT_HOME not set correctly", null == System.getProperty("ant.home"));
- assertTrue("ant.library.dir not set correctly", null == System.getProperty("ant.library.dir"));
- } finally {
- restorePreferenceDefaults();
- }
- }
-}
diff --git a/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/OptionTests.java b/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/OptionTests.java
deleted file mode 100644
index 886155ca1..000000000
--- a/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/OptionTests.java
+++ /dev/null
@@ -1,605 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.core.tests;
-
-
-import java.io.BufferedInputStream;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.InputStreamReader;
-import java.util.List;
-
-import org.eclipse.ant.core.AntCorePlugin;
-import org.eclipse.ant.tests.core.AbstractAntTest;
-import org.eclipse.ant.tests.core.testplugin.AntTestChecker;
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.runtime.CoreException;
-
-public class OptionTests extends AbstractAntTest {
-
- protected static final String UNKNOWN_ARG= "Unknown argument: ";
- protected static final String START_OF_HELP= "ant [options] [target [target2 [target3] ...]]";
- protected static final String VERSION= "Apache Ant version 1.6.1 compiled on February 12 2004";
- protected static final String PLUGIN_VERSION= "org.apache.ant_1.6.1";
-
- public OptionTests(String name) {
- super(name);
- }
-
- /**
- * Tests the "-help" option
- */
- public void testHelp() throws CoreException {
- run("TestForEcho.xml", new String[]{"-help"});
- assertTrue("One message should have been logged", AntTestChecker.getDefault().getMessagesLoggedCount() == 1);
- assertTrue("Help is incorrect", getLastMessageLogged() != null && getLastMessageLogged().startsWith(START_OF_HELP));
- }
-
- /**
- * Tests the "-h" option (help)
- */
- public void testMinusH() throws CoreException {
- run("TestForEcho.xml", new String[]{"-h"});
- assertTrue("One message should have been logged, was " + AntTestChecker.getDefault().getMessagesLoggedCount(), AntTestChecker.getDefault().getMessagesLoggedCount() == 1);
- assertTrue("Help is incorrect", getLastMessageLogged() != null && getLastMessageLogged().startsWith(START_OF_HELP));
- }
-
- /**
- * Tests the "-version" option
- */
- public void testVersion() throws CoreException {
- run("TestForEcho.xml", new String[]{"-version"});
- assertTrue("One message should have been logged", AntTestChecker.getDefault().getMessagesLoggedCount() == 1);
- assertTrue("Version is incorrect", VERSION.equals(getLastMessageLogged()));
- }
-
- /**
- * Tests the "-projecthelp" option
- */
- public void testProjecthelp() throws CoreException {
- run("TestForEcho.xml", new String[]{"-projecthelp"});
- assertTrue("5 messages should have been logged; was " + AntTestChecker.getDefault().getMessagesLoggedCount(), AntTestChecker.getDefault().getMessagesLoggedCount() == 5);
- assertTrue("Project help is incorrect", getLastMessageLogged().startsWith("Subtargets:"));
- }
-
- /**
- * Tests the "-p" option (project help)
- */
- public void testMinusP() throws CoreException {
- run("TestForEcho.xml", new String[]{"-p"});
- assertTrue("5 messages should have been logged; was " + AntTestChecker.getDefault().getMessagesLoggedCount(), AntTestChecker.getDefault().getMessagesLoggedCount() == 5);
- assertTrue("Project help is incorrect", getLastMessageLogged().startsWith("Subtargets:"));
- }
-
- /**
- * Tests the "-projecthelp" option when it will not show (quite mode)
- */
- public void testProjecthelpQuiet() throws CoreException {
- run("TestForEcho.xml", new String[]{"-projecthelp", "-q"});
- assertTrue("no messages should have been logged; was " + AntTestChecker.getDefault().getMessagesLoggedCount(), AntTestChecker.getDefault().getMessagesLoggedCount() == 0);
- }
-
- /**
- * Tests the "-listener" option with a listener that is not an instance of BuildListener
- */
- public void testListenerBad() {
- try {
- run("TestForEcho.xml", new String[]{"-listener", "java.lang.String"});
- } catch (CoreException ce) {
- String msg= ce.getMessage();
- assertTrue("Message incorrect!: " + msg, msg.equals("java.lang.String which was specified to be a build listener is not an instance of org.apache.tools.ant.BuildListener."));
- return;
- }
- assertTrue("A core exception should have occurred wrappering a class cast exception", false);
- }
-
- /**
- * Tests passing an unrecognized argument
- */
- public void testUnknownArg() throws CoreException {
- run("TestForEcho.xml", new String[]{"-listenr"});
- assertTrue("Unrecognized option message should have been logged before successful build",
- (AntTestChecker.getDefault().getMessagesLoggedCount() == 6)
- && (getLoggedMessage(5).startsWith(UNKNOWN_ARG))
- && (getLastMessageLogged().startsWith(BUILD_SUCCESSFUL)));
- }
-
- /**
- * Tests specifying the -logfile with no arg
- */
- public void testLogFileWithNoArg() {
- try {
- run("TestForEcho.xml", new String[]{"-logfile"});
- } catch (CoreException ce) {
- return;
- }
- assertTrue("You must specify a log file when using the -log argument", false);
- }
-
- /**
- * Tests specifying the -logfile
- */
- public void testLogFile() throws CoreException, IOException {
- run("TestForEcho.xml", new String[]{"-logfile", "TestLogFile.txt"});
- IFile file= checkFileExists("TestLogFile.txt");
- InputStream stream =file.getContents();
-
- InputStreamReader in= null;
- try {
- in= new InputStreamReader(new BufferedInputStream(stream));
- StringBuffer buffer= new StringBuffer();
- char[] readBuffer= new char[2048];
- int n= in.read(readBuffer);
- while (n > 0) {
- buffer.append(readBuffer, 0, n);
- n= in.read(readBuffer);
- }
- assertTrue("File should have started with Buildfile", buffer.toString().startsWith("Buildfile"));
- } finally {
- in.close();
- stream.close();
- }
-
- }
-
- /**
- * Tests specifying the -logger with no arg
- */
- public void testLoggerWithNoArg() {
- try {
- run("TestForEcho.xml", new String[]{"-logger"});
- } catch (CoreException ce) {
- return;
- }
- assertTrue("You must specify a classname when using the -logger argument", false);
- }
-
- /**
- * Tests the "-logger" option with a logger that is not an instance of BuildLogger
- */
- public void testLoggerBad() {
- try {
- run("TestForEcho.xml", new String[]{"-logger", "java.lang.String"});
- } catch (CoreException ce) {
- return;
- }
- assertTrue("A core exception should have occurred wrappering a class cast exception", false);
- }
-
- /**
- * Tests the "-logger" option with two loggers specified...only one is allowed
- */
- public void testTwoLoggers() {
- try {
- run("TestForEcho.xml", new String[]{"-logger", "java.lang.String", "-q", "-logger", "java.lang.String"});
- } catch (CoreException ce) {
- return;
- }
- assertTrue("As only one logger can be specified", false);
- }
-
- /**
- * Tests specifying the -listener with no arg
- */
- public void testListenerWithNoArg() {
- try {
- run("TestForEcho.xml", new String[]{"-listener"});
- } catch (CoreException ce) {
- return;
- }
- assertTrue("You must specify a listeners when using the -listener argument ", false);
- }
-
- /**
- * Tests specifying the -listener with a class that will not be found
- */
- public void testListenerClassNotFound() {
- try {
- run("TestForEcho.xml", new String[]{"-listener", "TestBuildListener"});
- } catch (CoreException e) {
- String message= e.getStatus().getException().getMessage();
- assertTrue("Should be ClassNotFoundException", "java.lang.ClassNotFoundException: TestBuildListener".equals(message));
- return;
- }
- assertTrue("A CoreException should have occurred as the listener class will not be found", false);
-
- }
- /**
- * Tests specifying the -listener option
- */
- public void testListener() throws CoreException {
- run("TestForEcho.xml", new String[]{"-listener", ANT_TEST_BUILD_LISTENER});
- assertSuccessful();
- assertTrue("A listener should have been added named: " + ANT_TEST_BUILD_LISTENER, ANT_TEST_BUILD_LISTENER.equals(AntTestChecker.getDefault().getLastListener()));
- }
-
- /**
- * Tests specifying the -listener option multiple times...which is allowed
- */
- public void testListenerMultiple() throws CoreException {
- run("TestForEcho.xml", new String[]{"-listener", ANT_TEST_BUILD_LISTENER, "-listener", ANT_TEST_BUILD_LISTENER});
- assertSuccessful();
- assertTrue("A listener should have been added named: " + ANT_TEST_BUILD_LISTENER, ANT_TEST_BUILD_LISTENER.equals(AntTestChecker.getDefault().getLastListener()));
- assertTrue("Two listeners should have been added", AntTestChecker.getDefault().getListeners().size() == 2);
- }
-
- /**
- * Tests specifying the -listener option multiple times, with one missing the arg
- */
- public void testListenerMultipleWithBad() {
- try {
- run("TestForEcho.xml", new String[]{"-listener", ANT_TEST_BUILD_LISTENER, "-q", "-listener", "-verbose"});
- } catch(CoreException e) {
- //You must specify a listener for all -listener arguments
- return;
- }
- assertTrue("You must specify a listener for all -listener arguments ", false);
- }
-
- /**
- * Tests specifying the -buildfile with no arg
- */
- public void testBuildFileWithNoArg() {
- try {
- run("TestForEcho.xml", new String[]{"-buildfile"});
- } catch (CoreException ce) {
- //You must specify a buildfile when using the -buildfile argument
- return;
- }
- assertTrue("You must specify a buildfile when using the -buildfile argument", false);
- }
-
- /**
- * Tests specifying the -buildfile
- */
- public void testBuildFile() throws CoreException {
- String buildFileName= getProject().getFolder("buildfiles").getFile("echoing.xml").getLocation().toFile().getAbsolutePath();
- run("TestForEcho.xml", new String[]{"-buildfile", buildFileName}, false, "buildfiles");
-
- assertTrue("Should have been 1 tasks, was: " + AntTestChecker.getDefault().getTaskStartedCount(), AntTestChecker.getDefault().getTaskStartedCount() == 1);
- }
-
- /**
- * Tests specifying a target at the command line that does not exist.
- */
- public void testSpecifyBadTargetAsArg() {
- try {
- run("TestForEcho.xml", new String[]{"echo2"}, false);
- } catch (CoreException ce) {
- return;
- }
- assertTrue("A core exception should have occurred as the target does not exist", false);
- }
-
- /**
- * Tests specifying a target at the command line
- */
- public void testSpecifyTargetAsArg() throws CoreException {
- run("echoing.xml", new String[]{"echo3"}, false);
- assertTrue("3 messages should have been logged; was " + AntTestChecker.getDefault().getMessagesLoggedCount(), AntTestChecker.getDefault().getMessagesLoggedCount() == 3);
- assertSuccessful();
- }
-
- /**
- * Tests specifying a target at the command line with other options
- */
- public void testSpecifyTargetAsArgWithOtherOptions() throws CoreException {
- run("echoing.xml", new String[]{"-logfile", "TestLogFile.txt", "echo3"}, false);
- assertTrue("4 messages should have been logged; was " + AntTestChecker.getDefault().getMessagesLoggedCount(), AntTestChecker.getDefault().getMessagesLoggedCount() == 4);
- List messages= AntTestChecker.getDefault().getMessages();
- //ensure that echo3 target executed and only that target
- assertTrue("echo3 target not executed", messages.get(2).equals("echo3"));
- assertSuccessful();
- }
-
- /**
- * Tests specifying targets at the command line with other options
- */
- public void testSpecifyTargetsAsArgWithOtherOptions() throws CoreException {
- run("echoing.xml", new String[]{"-logfile", "TestLogFile.txt", "echo2", "echo3"}, false);
- assertTrue("5 messages should have been logged; was " + AntTestChecker.getDefault().getMessagesLoggedCount(), AntTestChecker.getDefault().getMessagesLoggedCount() == 5);
- List messages= AntTestChecker.getDefault().getMessages();
- //ensure that echo2 target executed
- assertTrue("echo2 target not executed", messages.get(2).equals("echo2"));
- assertSuccessful();
- }
-
- /**
- * Tests specifying a target at the command line and quiet reporting
- */
- public void testSpecifyTargetAsArgAndQuiet() throws CoreException {
- run("echoing.xml", new String[]{"-logfile", "TestLogFile.txt", "echo3", "-quiet"}, false);
- assertTrue("2 messages should have been logged; was " + AntTestChecker.getDefault().getMessagesLoggedCount(), AntTestChecker.getDefault().getMessagesLoggedCount() == 2);
- }
-
- /**
- * Tests properties using "-D"
- */
- public void testMinusD() throws CoreException {
- run("echoing.xml", new String[]{"-DAntTests=testing", "-Declipse.is.cool=true"}, false);
- assertSuccessful();
- assertTrue("eclipse.is.cool should have been set as true", "true".equals(AntTestChecker.getDefault().getUserProperty("eclipse.is.cool")));
- assertTrue("AntTests should have a value of testing", "testing".equals(AntTestChecker.getDefault().getUserProperty("AntTests")));
- assertNull("my.name was not set and should be null", AntTestChecker.getDefault().getUserProperty("my.name"));
-
- }
-
- /**
- * Tests properties using "-D" and "-d" to specify debug
- */
- public void testMinusDMinusd() throws CoreException {
- run("echoing.xml", new String[]{"-d", "-DAntTests=testing", "-Declipse.is.cool=true"}, false);
- assertSuccessful();
- assertTrue("eclipse.is.cool should have been set as true", "true".equals(AntTestChecker.getDefault().getUserProperty("eclipse.is.cool")));
- assertTrue("AntTests should have a value of testing", "testing".equals(AntTestChecker.getDefault().getUserProperty("AntTests")));
- assertNull("my.name was not set and should be null", AntTestChecker.getDefault().getUserProperty("my.name"));
-
- }
-
- public void testMinusDAndGlobalProperties() throws CoreException {
- run("echoing.xml", new String[]{"-DAntTests=testing", "-Declipse.is.cool=true"}, false);
- assertSuccessful();
- assertTrue("eclipse.running should have been set as true", "true".equals(AntTestChecker.getDefault().getUserProperty("eclipse.running")));
- assertNotNull("eclipse.home should have been set", AntTestChecker.getDefault().getUserProperty("eclipse.home"));
- }
-
- /**
- * Tests specifying a property such as "-D=emptyStringIsMyName
- * Bug 37007
- */
- public void testMinusDEmpty() throws CoreException {
- run("echoing.xml", new String[]{"-D=emptyStringIsMyName", "-Declipse.is.cool=true"}, false);
- assertSuccessful();
- assertTrue("eclipse.is.cool should have been set as true", "true".equals(AntTestChecker.getDefault().getUserProperty("eclipse.is.cool")));
- assertTrue("\"\" should have a value of emptyStringIsMyName", "emptyStringIsMyName".equals(AntTestChecker.getDefault().getUserProperty("")));
- assertNull("my.name was not set and should be null", AntTestChecker.getDefault().getUserProperty("my.name"));
- }
-
- /**
- * Tests specifying properties that contain spaces
- * Bug 37094
- */
- public void testMinusDWithSpaces() throws CoreException {
- run("echoing.xml", new String[]{"-DAntTests= testing", "-Declipse.is.cool= true"}, false);
- assertSuccessful();
- assertTrue("eclipse.is.cool should have been set as true", "true".equals(AntTestChecker.getDefault().getUserProperty("eclipse.is.cool")));
- assertTrue("AntTests should have a value of testing", "testing".equals(AntTestChecker.getDefault().getUserProperty("AntTests")));
- assertNull("my.name was not set and should be null", AntTestChecker.getDefault().getUserProperty("my.name"));
- }
-
- /**
- * Tests specifying properties when the user has incorrectly specified "-Debug"
- * Bug 40935
- */
- public void testPropertiesWithMinusDebug() throws CoreException {
- run("echoing.xml", new String[]{"-Debug", "-DAntTests= testing", "-Declipse.is.cool= true"}, false);
- assertTrue("\"-Debug\" should be flagged as an unknown argument", "Unknown argument: -Debug".equals(AntTestChecker.getDefault().getMessages().get(0)));
- assertSuccessful();
- assertTrue("eclipse.is.cool should have been set as true", "true".equals(AntTestChecker.getDefault().getUserProperty("eclipse.is.cool")));
- assertTrue("AntTests should have a value of testing", "testing".equals(AntTestChecker.getDefault().getUserProperty("AntTests")));
- assertNull("my.name was not set and should be null", AntTestChecker.getDefault().getUserProperty("my.name"));
- }
-
- /**
- * Tests when the user has incorrectly specified "-Debug"
- * Bug 40935
- */
- public void testMinusDebug() throws CoreException {
- run("echoing.xml", new String[]{"-Debug"});
- assertTrue("\"-Debug\" should be flagged as an unknown argument", "Unknown argument: -Debug".equals(AntTestChecker.getDefault().getMessages().get(0)));
- assertSuccessful();
- }
-
- public void testPropertyFileWithNoArg() {
- try {
- run("TestForEcho.xml", new String[]{"-propertyfile"});
- } catch (CoreException ce) {
- String msg= (String)AntTestChecker.getDefault().getMessages().get(0);
- assertTrue("Message incorrect!: " + msg, msg.equals("You must specify a property filename when using the -propertyfile argument"));
- return;
- }
- assertTrue("You must specify a property filename when using the -propertyfile argument", false);
- }
-
- /**
- * A build should succeed when a property file is not found.
- * The error is reported and the build continues.
- */
- public void testPropertyFileFileNotFound() throws CoreException {
-
- run("TestForEcho.xml", new String[]{"-propertyfile", "qq.txt"});
- assertSuccessful();
- String msg= (String)AntTestChecker.getDefault().getMessages().get(0);
- assertTrue("Message incorrect!: " + msg, msg.startsWith("Could not load property file qq.txt:"));
- }
-
- public void testPropertyFile() throws CoreException {
- run("TestForEcho.xml", new String[]{"-propertyfile", getPropertyFileName()});
- assertSuccessful();
- assertTrue("eclipse.is.cool should have been set as Yep", "Yep".equals(AntTestChecker.getDefault().getUserProperty("eclipse.is.cool")));
- assertTrue("AntTests should have a value of testing", "testing from properties file".equals(AntTestChecker.getDefault().getUserProperty("AntTests")));
- assertNull("my.name was not set and should be null", AntTestChecker.getDefault().getUserProperty("my.name"));
- }
-
- public void testPropertyFileWithMinusDTakingPrecedence() throws CoreException {
- run("echoing.xml", new String[]{"-propertyfile", getPropertyFileName(), "-DAntTests=testing", "-Declipse.is.cool=true"}, false);
- assertSuccessful();
- assertTrue("eclipse.is.cool should have been set as true", "true".equals(AntTestChecker.getDefault().getUserProperty("eclipse.is.cool")));
- assertTrue("AntTests should have a value of testing", "testing".equals(AntTestChecker.getDefault().getUserProperty("AntTests")));
- assertNull("my.name was not set and should be null", AntTestChecker.getDefault().getUserProperty("my.name"));
- }
-
- public void testInputHandlerWithNoArg() {
- try {
- run("TestForEcho.xml", new String[]{"-inputhandler"});
- } catch (CoreException ce) {
- String msg= ce.getMessage();
- assertTrue("Message incorrect!: " + msg, msg.equals("You must specify a classname when using the -inputhandler argument"));
- return;
- }
- assertTrue("You must specify a classname when using the -inputhandler argument", false);
- }
-
- /**
- * Tests the "-inputhandler" option with two handlers specified...only one is allowed
- */
- public void testInputHandlerMultiple() {
- try {
- run("TestForEcho.xml", new String[]{"-inputhandler", "org.apache.tools.ant.input.DefaultInputHandler", "-q", "-inputhandler", "org.apache.tools.ant.input.DefaultInputHandler"});
- } catch (CoreException ce) {
- String msg= ce.getMessage();
- assertTrue("Message incorrect!: " + msg, msg.equals("Only one input handler class may be specified."));
- return;
- }
- assertTrue("As only one input handler can be specified", false);
- }
-
- /**
- * Tests the "-inputhandler" option with a input handler that is not an instance of InputHandler
- */
- public void testInputHandlerBad() {
- try {
- run("TestForEcho.xml", new String[]{"-inputhandler", "java.lang.StringBuffer"});
- } catch (CoreException ce) {
- String msg= ce.getMessage();
- assertTrue("Message incorrect!: " + msg, msg.equals("The specified input handler class java.lang.StringBuffer does not implement the org.apache.tools.ant.input.InputHandler interface"));
- return;
- }
- assertTrue("Incorrect inputhandler", false);
- }
-
- /**
- * Tests the "-inputhandler" option with a input handler that is not a defined class
- */
- public void testInputHandlerBad2() {
- try {
- run("TestForEcho.xml", new String[]{"-inputhandler", "ja.lang.StringBuffer"});
- } catch (CoreException ce) {
- String msg= ce.getMessage();
- assertTrue("Message incorrect!: " + msg, msg.startsWith("Unable to instantiate specified input handler class ja.lang.StringBuffer"));
- return;
- }
- assertTrue("Incorrect inputhandler", false);
- }
-
- /**
- * Tests the "-inputhandler" option with a test input handler
- */
- public void testInputHandler() throws CoreException {
-
- run("input.xml", new String[]{"-inputhandler", "org.eclipse.ant.tests.core.support.inputHandlers.AntTestInputHandler"});
- assertSuccessful();
- String msg= (String)AntTestChecker.getDefault().getMessages().get(1);
- assertTrue("Message incorrect: " + msg, msg.equals("testing handling input requests"));
-
- }
-
- /**
- * Tests the "-inputhandler" option with a test input handler and the -noinput option
- */
- public void testInputHandlerWithMinusNoInput() {
- try {
- run("input.xml", new String[]{"-inputhandler", "org.eclipse.ant.tests.core.support.inputHandlers.AntTestInputHandler", "-noinput"});
- } catch (CoreException ce) {
- assertTrue("Message incorrect: " + ce.getMessage(), ce.getMessage().endsWith("Unable to respond to input request likely as a result of specifying the -noinput command"));
- return;
- }
-
- assertTrue("Build should have failed", false);
- }
-
- /**
- * Tests the -noinput option with the default input handler
- */
- public void testMinusNoInput() {
- try {
- run("input.xml", new String[]{"-noinput"});
- } catch (CoreException ce) {
- assertTrue("Message incorrect: " + ce.getMessage(), ce.getMessage().endsWith("Failed to read input from Console."));
- return;
- }
-
- assertTrue("Build should have failed", false);
- }
-
- /**
- * Tests the "-diagnostics" option with no ANT_HOME set
- * bug 25693
- */
- public void testDiagnosticsWithNoAntHome() throws CoreException {
- try {
- AntCorePlugin.getPlugin().getPreferences().setAntHome(null);
- run("input.xml", new String[]{"-diagnostics"});
-
- String msg= (String)AntTestChecker.getDefault().getMessages().get(0);
- assertTrue("Message incorrect: " + msg, msg.equals("------- Ant diagnostics report -------"));
- } finally {
- restorePreferenceDefaults();
- }
- }
-
- /**
- * Tests the "-diagnostics" option with ANT_HOME set
- * bug 25693
- */
- public void testDiagnostics() throws CoreException {
-
- try {
- run("input.xml", new String[]{"-diagnostics"});
- } finally {
- restorePreferenceDefaults();
- }
-
- String msg= (String)AntTestChecker.getDefault().getMessages().get(12);
- //msg depends on whether self hosting testing or build testing
- assertTrue("Message incorrect: " + msg, msg.endsWith("org.apache.ant") || msg.endsWith(PLUGIN_VERSION));
- }
-
- /**
- * Tests the "-quiet" still reports build successful
- * bug 34488
- */
- public void testMinusQuiet() throws CoreException {
- run("TestForEcho.xml", new String[]{"-quiet"});
- assertSuccessful();
- }
-
- /**
- * Tests the "-keep-going" option
- */
- public void testMinusKeepGoing() {
- try {
- run("failingTarget.xml", new String[]{"-keep-going"}, false);
- } catch (CoreException be) {
- assertTrue("4 messages should have been logged; was " + AntTestChecker.getDefault().getMessagesLoggedCount(), AntTestChecker.getDefault().getMessagesLoggedCount() == 4);
- assertTrue("Incorrect message:" + AntTestChecker.getDefault().getLoggedMessage(1), "Still echo on failure".equals(AntTestChecker.getDefault().getLoggedMessage(1)));
- return;
- }
-
- assertTrue("The build should have failed", false);
- }
-
- /**
- * Tests the "-k" option
- */
- public void testMinusK() {
- try {
- run("failingTarget.xml", new String[]{"-keep-going"}, false);
- } catch (CoreException be) {
- assertTrue("4 messages should have been logged; was " + AntTestChecker.getDefault().getMessagesLoggedCount(), AntTestChecker.getDefault().getMessagesLoggedCount() == 4);
- assertTrue("Incorrect message:" + AntTestChecker.getDefault().getLoggedMessage(1), "Still echo on failure".equals(AntTestChecker.getDefault().getLoggedMessage(1)));
- return;
- }
-
- assertTrue("The build should have failed", false);
- }
-
-} \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/ProjectTests.java b/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/ProjectTests.java
deleted file mode 100644
index b477eb454..000000000
--- a/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/ProjectTests.java
+++ /dev/null
@@ -1,78 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.core.tests;
-
-
-import org.eclipse.ant.core.AntCorePlugin;
-import org.eclipse.ant.tests.core.AbstractAntTest;
-import org.eclipse.ant.tests.core.testplugin.AntTestChecker;
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.runtime.CoreException;
-
-
-public class ProjectTests extends AbstractAntTest {
-
- public ProjectTests(String name) {
- super(name);
- }
-
- /**
- * Tests that the three properties that should always be set are correct
- */
- public void testBasePropertiesSet() throws CoreException {
- String buildFileName="TestForEcho.xml";
- run(buildFileName);
- IFile buildFile= getBuildFile(buildFileName);
- String fullName= buildFile.getLocation().toFile().getAbsolutePath();
- assertTrue("eclipse.running should have been set as true", "true".equals(AntTestChecker.getDefault().getUserProperty("eclipse.running")));
- assertTrue("ant.file should have been set as the build file name", fullName.equals(AntTestChecker.getDefault().getUserProperty("ant.file")));
- assertNotNull("ant.java.version should have been set", AntTestChecker.getDefault().getUserProperty("ant.java.version"));
- assertNotNull("ant.version should have been set", AntTestChecker.getDefault().getUserProperty("ant.version"));
- assertNotNull("eclipse.home should have been set", AntTestChecker.getDefault().getUserProperty("eclipse.home"));
- }
-
- public void testValue() throws CoreException {
- String buildFileName="TestForEcho.xml";
- run(buildFileName);
- assertTrue("property.testing should have been set as true", "true".equals(AntTestChecker.getDefault().getUserProperty("property.testing")));
- }
-
- public void testValueWithClass() throws CoreException {
-
- String buildFileName="TestForEcho.xml";
- run(buildFileName);
- assertTrue("property.testing2 should have been set as hey", "hey".equals(AntTestChecker.getDefault().getUserProperty("property.testing2")));
- }
-
- public void testClass() throws CoreException {
- String buildFileName="TestForEcho.xml";
- run(buildFileName);
- assertTrue("property.testing3 should have been set as AntTestPropertyProvider", "AntTestPropertyValueProvider".equals(AntTestChecker.getDefault().getUserProperty("property.testing3")));
- }
-
- public void testHeadless() throws CoreException {
- try {
- AntCorePlugin.getPlugin().setRunningHeadless(true);
- String buildFileName="TestForEcho.xml";
- run(buildFileName);
- assertNull("property.headless should not have been set as AntTestPropertyProvider", AntTestChecker.getDefault().getUserProperty("property.headless"));
- } finally {
- AntCorePlugin.getPlugin().setRunningHeadless(false);
- }
- }
-
- public void testNotHeadless() throws CoreException {
- String buildFileName="TestForEcho.xml";
- run(buildFileName);
- assertTrue("property.headless should have been set as AntTestPropertyProvider", "headless".equals(AntTestChecker.getDefault().getUserProperty("property.headless")));
- }
-}
-
diff --git a/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/TargetTests.java b/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/TargetTests.java
deleted file mode 100644
index 20df72b55..000000000
--- a/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/TargetTests.java
+++ /dev/null
@@ -1,108 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.core.tests;
-
-
-import java.io.File;
-
-import org.eclipse.ant.core.TargetInfo;
-import org.eclipse.ant.tests.core.AbstractAntTest;
-import org.eclipse.ant.tests.core.testplugin.AntTestChecker;
-import org.eclipse.core.runtime.CoreException;
-
-
-public class TargetTests extends AbstractAntTest {
-
- public TargetTests(String name) {
- super(name);
- }
-
- /**
- * Ensures that a default target is found
- */
- public void testDefaultTarget() throws CoreException {
- TargetInfo[] targets= getTargets("TestForEcho.xml");
- assertTrue("Should be two targets in TestForEcho.xml", targets.length == 2);
- assertTrue("Test for Echo should be the default target", targets[1].isDefault());
- }
-
- /**
- * Ensures that targets are found in a build file with data types
- */
- public void testGetTargetsWithDataTypes() throws CoreException {
- TargetInfo[] targets= getTargets("Bug32551.xml");
- assertTrue("Should be one targets in Bug32551.xml", targets.length == 1);
- }
-
- /**
- * Ensures that targets are found in a buildfile with a fileset based on ant_home
- * (that ant_home is set at parse time)
- * Bug 42926.
- */
- public void testGetTargetsWithAntHome() {
- System.getProperties().remove("ant.home");
- try {
- getTargets("Bug42926.xml");
- } catch (CoreException ce) {
- //classpathref was successful but the task is not defined
- ce.getMessage().equals("file:c:/runtime-test-workspace/AntTests/buildfiles/Bug42926.xml:7: taskdef class com.foo.SomeTask cannot be found");
- }
- }
-
- /**
- * Ensures that target names are retrieved properly
- */
- public void testTargetNames() throws CoreException {
- String[] targetNames= getTargetNames("TestForEcho.xml");
- assertTrue("Should be two targets in TestForEcho.xml", targetNames.length == 2);
- assertTrue("First name should be init", targetNames[0].equals("init"));
- assertTrue("Second name should be Test for Echo", targetNames[1].equals("Test for Echo"));
- }
-
- /**
- * Ensures that target descriptions are retrieved properly
- */
- public void testTargetDescription() throws CoreException {
- String[] targetDescriptions= getTargetDescriptions("TestForEcho.xml");
- assertTrue("Should be two targets in TestForEcho.xml", targetDescriptions.length == 2);
- assertNull("First description should be null", targetDescriptions[0]);
- assertTrue("Second description should be Calls other targets", targetDescriptions[1].equals("Calls other echos"));
- }
-
- /**
- * Ensures that target projects are retrieved properly
- */
- public void testTargetProject() throws CoreException {
- String targetProject= getProjectName("TestForEcho.xml", "Test for Echo");
- assertTrue("Project name should be Echo Test", "Echo Test".equals(targetProject));
- }
-
- /**
- * Ensures that target dependencies are retrieved properly
- */
- public void testTargetDependencies() throws CoreException {
- String[] dependencies= getDependencies("TestForEcho.xml", "Test for Echo");
- assertNotNull("Dependencies should not be null", dependencies);
- assertTrue("Should be one dependency in Test for Echo", dependencies.length == 1);
- assertTrue("First dependency should be init", "init".equals(dependencies[0]));
- }
-
- /**
- * Runs an Ant build and ensure that the build file location is logged
- */
- public void testRunScript() throws CoreException {
- run("TestForEcho.xml");
- String message= (String)AntTestChecker.getDefault().getMessages().get(0);
- assertTrue("Build file location should be logged as the first message", message != null && message.endsWith("AntTests" + File.separator + "buildfiles" + File.separator + "TestForEcho.xml"));
- assertSuccessful();
- }
-}
-
diff --git a/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/TaskTests.java b/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/TaskTests.java
deleted file mode 100644
index 0749cfc1a..000000000
--- a/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/TaskTests.java
+++ /dev/null
@@ -1,143 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.core.tests;
-
-import java.io.File;
-import java.net.URL;
-
-import org.eclipse.ant.core.AntCorePlugin;
-import org.eclipse.ant.core.AntCorePreferences;
-import org.eclipse.ant.core.IAntClasspathEntry;
-import org.eclipse.ant.core.Property;
-import org.eclipse.ant.core.Task;
-import org.eclipse.ant.internal.core.AntClasspathEntry;
-import org.eclipse.ant.tests.core.AbstractAntTest;
-import org.eclipse.ant.tests.core.testplugin.AntTestChecker;
-import org.eclipse.core.runtime.CoreException;
-
-public class TaskTests extends AbstractAntTest {
-
-
- public TaskTests(String name) {
- super(name);
- }
-
- /**
- * Testing the old deprecated API
- * @throws CoreException
- */
- public void testAddTaskSettingLibrary() throws CoreException {
- AntCorePreferences prefs =AntCorePlugin.getPlugin().getPreferences();
- URL[] urls= prefs.getExtraClasspathURLs();
- Task newTask= new Task();
- newTask.setLibrary(urls[0]);
- newTask.setTaskName("AntTestTask");
- newTask.setClassName("org.eclipse.ant.tests.core.support.tasks.AntTestTask");
- prefs.setCustomTasks(new Task[]{newTask});
-
- prefs.updatePluginPreferences();
-
- run("CustomTask.xml", new String[0], false);
- String msg= (String)AntTestChecker.getDefault().getMessages().get(1);
- assertTrue("Message incorrect: " + msg, msg.equals("Testing Ant in Eclipse with a custom task"));
- assertSuccessful();
- }
-
- public void testAddTaskSettingLibraryEntry() throws CoreException {
- AntCorePreferences prefs =AntCorePlugin.getPlugin().getPreferences();
- URL[] urls= prefs.getExtraClasspathURLs();
- Task newTask= new Task();
- newTask.setLibraryEntry(new AntClasspathEntry(urls[0]));
- newTask.setTaskName("AntTestTask2");
- newTask.setClassName("org.eclipse.ant.tests.core.support.tasks.AntTestTask");
- prefs.setCustomTasks(new Task[]{newTask});
-
- prefs.updatePluginPreferences();
-
- run("CustomTask.xml", new String[] {"Custom Task from Entry"}, false);
- String msg= (String)AntTestChecker.getDefault().getMessages().get(1);
- assertTrue("Message incorrect: " + msg, msg.equals("Testing Ant in Eclipse with a custom task"));
- assertSuccessful();
- }
-
- public void testRemoveTask() {
- AntCorePreferences prefs =AntCorePlugin.getPlugin().getPreferences();
- prefs.setCustomTasks(new Task[]{});
- try {
- run("CustomTask.xml");
- } catch (CoreException ce) {
- assertTrue("Exception from undefined task is incorrect", ce.getMessage().endsWith("as this is not an Ant bug."));
- return;
- } finally {
- restorePreferenceDefaults();
- }
- assertTrue("Build should have failed as task no longer defined", false);
- }
-
- public void testAddTaskFromFolder() throws CoreException {
- try {
- AntCorePreferences prefs =AntCorePlugin.getPlugin().getPreferences();
- Task newTask= new Task();
- String path= getProject().getFolder("lib").getFile("taskFolder").getLocation().toFile().getAbsolutePath();
- IAntClasspathEntry entry= new AntClasspathEntry(path + File.separatorChar);
- IAntClasspathEntry entries[] = prefs.getAdditionalClasspathEntries();
- IAntClasspathEntry newEntries[] = new IAntClasspathEntry[entries.length + 1];
- System.arraycopy(entries, 0, newEntries, 0, entries.length);
- newEntries[entries.length] = entry;
- prefs.setAdditionalClasspathEntries(newEntries);
-
- newTask.setLibraryEntry(entry);
- newTask.setTaskName("AntTestTask");
- newTask.setClassName("org.eclipse.ant.tests.core.support.tasks.AntTestTask2");
- prefs.setCustomTasks(new Task[]{newTask});
-
- prefs.updatePluginPreferences();
-
- run("CustomTask.xml", new String[0], false);
- String msg= (String)AntTestChecker.getDefault().getMessages().get(1);
- assertTrue("Message incorrect: " + msg, msg.equals("Testing Ant in Eclipse with a custom task"));
- assertSuccessful();
- } finally {
- restorePreferenceDefaults();
- }
- }
-
- public void testTasksDefinedInPropertyFile() throws CoreException {
- try {
- AntCorePreferences prefs =AntCorePlugin.getPlugin().getPreferences();
- Property newProp= new Property("ROOTDIR", "..//resources");
- prefs.setCustomProperties(new Property[]{newProp});
- run("Bug34663.xml");
- } finally {
- restorePreferenceDefaults();
- }
- }
-
- public void testTaskDefinedInExtensionPoint() throws CoreException {
- run("ExtensionPointTask.xml");
- String msg= (String)AntTestChecker.getDefault().getMessages().get(1);
- assertTrue("Message incorrect: " + msg, msg.equals("Testing Ant in Eclipse with a custom task"));
- assertSuccessful();
- }
-
- public void testTaskDefinedInExtensionPointHeadless() {
- AntCorePlugin.getPlugin().setRunningHeadless(true);
- try {
- run("ExtensionPointTask.xml");
- } catch (CoreException ce) {
- assertTrue("Exception from undefined task is incorrect", ce.getMessage().endsWith("as this is not an Ant bug."));
- return;
- } finally {
- AntCorePlugin.getPlugin().setRunningHeadless(false);
- }
- assertTrue("Build should have failed as task was not defined to run in headless", false);
- }
-}
diff --git a/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/TypeTests.java b/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/TypeTests.java
deleted file mode 100644
index 3c2102c59..000000000
--- a/ant/org.eclipse.ant.tests.core/tests/org/eclipse/ant/tests/core/tests/TypeTests.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.core.tests;
-
-
-import java.net.URL;
-
-import org.eclipse.ant.core.AntCorePlugin;
-import org.eclipse.ant.core.AntCorePreferences;
-import org.eclipse.ant.core.Type;
-import org.eclipse.ant.internal.core.AntClasspathEntry;
-import org.eclipse.ant.tests.core.AbstractAntTest;
-import org.eclipse.ant.tests.core.testplugin.AntTestChecker;
-import org.eclipse.core.runtime.CoreException;
-
-public class TypeTests extends AbstractAntTest {
-
- public TypeTests(String name) {
- super(name);
- }
-
- public void testAddType() throws CoreException {
- AntCorePreferences prefs =AntCorePlugin.getPlugin().getPreferences();
- URL[] urls= prefs.getExtraClasspathURLs();
- Type newType= new Type();
- newType.setLibraryEntry(new AntClasspathEntry(urls[0]));
- newType.setTypeName("anttestpath");
- newType.setClassName("org.eclipse.ant.tests.core.support.types.AntTestPath");
- prefs.setCustomTypes(new Type[]{newType});
-
- run("CustomType.xml");
- String msg= (String)AntTestChecker.getDefault().getMessages().get(1);
- assertTrue("Message incorrect: " + msg, msg.equals("Test adding a custom type"));
- assertSuccessful();
- }
-
- public void testRemoveType() {
- AntCorePreferences prefs =AntCorePlugin.getPlugin().getPreferences();
- prefs.setCustomTypes(new Type[]{});
- try {
- run("CustomType.xml");
- } catch (CoreException ce) {
- assertTrue("Exception from undefined type is incorrect: "+ ce.getMessage(), ce.getMessage().endsWith("as this is not an Ant bug."));
- return;
- } finally {
- restorePreferenceDefaults();
- }
- assertTrue("Build should have failed as type no longer defined", false);
-
- }
-
- public void testTypeDefinedInExtensionPoint() throws CoreException {
- run("ExtensionPointType.xml");
- String msg= (String)AntTestChecker.getDefault().getMessages().get(1);
- assertTrue("Message incorrect: " + msg, msg.equals("Ensure that an extension point defined type is present"));
- assertSuccessful();
- }
-
- public void testTypeDefinedInExtensionPointHeadless() {
- AntCorePlugin.getPlugin().setRunningHeadless(true);
- try {
- run("ExtensionPointType.xml");
- } catch (CoreException ce) {
- assertTrue("Exception from undefined type is incorrect: " + ce.getMessage(), ce.getMessage().endsWith("as this is not an Ant bug."));
- return;
- } finally {
- AntCorePlugin.getPlugin().setRunningHeadless(false);
- }
- assertTrue("Build should have failed as type was not defined to run in headless", false);
- }
-
-}
diff --git a/ant/org.eclipse.ant.tests.ui/.classpath b/ant/org.eclipse.ant.tests.ui/.classpath
deleted file mode 100644
index 5e3b04c8a..000000000
--- a/ant/org.eclipse.ant.tests.ui/.classpath
+++ /dev/null
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
- <classpathentry kind="src" path="Ant Editor Tests"/>
- <classpathentry kind="src" path="test plugin"/>
- <classpathentry kind="src" path="Ant Tests"/>
- <classpathentry kind="src" path="External Tools"/>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry output="test_support_bin" kind="src" path="test support"/>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/ant/org.eclipse.ant.tests.ui/.cvsignore b/ant/org.eclipse.ant.tests.ui/.cvsignore
deleted file mode 100644
index 4e3b0f0c0..000000000
--- a/ant/org.eclipse.ant.tests.ui/.cvsignore
+++ /dev/null
@@ -1,2 +0,0 @@
-bin
-test_support_bin
diff --git a/ant/org.eclipse.ant.tests.ui/.externalToolBuilders/Build Test Support JAR.launch b/ant/org.eclipse.ant.tests.ui/.externalToolBuilders/Build Test Support JAR.launch
deleted file mode 100644
index 40b635ef3..000000000
--- a/ant/org.eclipse.ant.tests.ui/.externalToolBuilders/Build Test Support JAR.launch
+++ /dev/null
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<launchConfiguration type="org.eclipse.ant.AntBuilderLaunchConfigurationType">
-<booleanAttribute key="org.eclipse.debug.ui.ATTR_LAUNCH_IN_BACKGROUND" value="false"/>
-<booleanAttribute key="org.eclipse.jdt.launching.DEFAULT_CLASSPATH" value="true"/>
-<stringAttribute key="org.eclipse.ui.externaltools.ATTR_BUILD_SCOPE" value="${working_set:&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;&#10;&lt;launchConfigurationWorkingSet factoryID=&quot;org.eclipse.ui.internal.WorkingSetFactory&quot; name=&quot;workingSet&quot; editPageId=&quot;org.eclipse.ui.resourceWorkingSetPage&quot;&gt;&#10;&lt;item factoryID=&quot;org.eclipse.ui.internal.model.ResourceFactory&quot; path=&quot;/org.eclipse.ant.tests.ui/buildfiles/buildAntTestsSupportJAR.xml&quot; type=&quot;1&quot;/&gt;&#10;&lt;item factoryID=&quot;org.eclipse.ui.internal.model.ResourceFactory&quot; path=&quot;/org.eclipse.ant.tests.ui/test support&quot; type=&quot;2&quot;/&gt;&#10;&lt;/launchConfigurationWorkingSet&gt;&#10;}"/>
-<stringAttribute key="org.eclipse.ui.externaltools.ATTR_RUN_BUILD_KINDS" value="full,incremental,auto,"/>
-<stringAttribute key="org.eclipse.debug.core.ATTR_REFRESH_SCOPE" value="${working_set:&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;&#10;&lt;launchConfigurationWorkingSet factoryID=&quot;org.eclipse.ui.internal.WorkingSetFactory&quot; name=&quot;workingSet&quot; editPageId=&quot;org.eclipse.ui.resourceWorkingSetPage&quot;&gt;&#10;&lt;item factoryID=&quot;org.eclipse.ui.internal.model.ResourceFactory&quot; path=&quot;/org.eclipse.ant.tests.ui&quot; type=&quot;4&quot;/&gt;&#10;&lt;/launchConfigurationWorkingSet&gt;&#10;}"/>
-<stringAttribute key="org.eclipse.ui.externaltools.ATTR_LOCATION" value="${workspace_loc:/org.eclipse.ant.tests.ui/buildfiles/buildAntTestsSupportJAR.xml}"/>
-<stringAttribute key="org.eclipse.jdt.launching.CLASSPATH_PROVIDER" value="org.eclipse.ant.ui.AntClasspathProvider"/>
-</launchConfiguration>
diff --git a/ant/org.eclipse.ant.tests.ui/.project b/ant/org.eclipse.ant.tests.ui/.project
deleted file mode 100644
index 7ac853057..000000000
--- a/ant/org.eclipse.ant.tests.ui/.project
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.ant.tests.ui</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.jdt.core.javabuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.ui.externaltools.ExternalToolBuilder</name>
- <arguments>
- <dictionary>
- <key>LaunchConfigHandle</key>
- <value>Build Test Support JAR.launch</value>
- </dictionary>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.eclipse.jdt.core.javanature</nature>
- <nature>org.eclipse.pde.PluginNature</nature>
- </natures>
-</projectDescription>
diff --git a/ant/org.eclipse.ant.tests.ui/.settings/org.eclipse.pde.core.prefs b/ant/org.eclipse.ant.tests.ui/.settings/org.eclipse.pde.core.prefs
deleted file mode 100644
index 0f654cf39..000000000
--- a/ant/org.eclipse.ant.tests.ui/.settings/org.eclipse.pde.core.prefs
+++ /dev/null
@@ -1,3 +0,0 @@
-#Thu May 27 14:48:38 PDT 2004
-eclipse.preferences.version=1
-selfhosting.binExcludes=/org.eclipse.ant.tests.ui/test_support_bin
diff --git a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/dtd/dumper.java b/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/dtd/dumper.java
deleted file mode 100644
index ecdc48680..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/dtd/dumper.java
+++ /dev/null
@@ -1,147 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2002, 2003 Object Factory Inc.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * Object Factory Inc. - Initial implementation
- *******************************************************************************/
-
-package org.eclipse.ant.tests.ui.dtd;
-
-import java.io.IOException;
-import java.util.Arrays;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.LinkedList;
-import java.util.Map;
-
-import org.eclipse.ant.internal.ui.dtd.IDfm;
-import org.eclipse.ant.internal.ui.dtd.IElement;
-import org.eclipse.ant.internal.ui.dtd.IModel;
-import org.eclipse.ant.internal.ui.dtd.ISchema;
-import org.eclipse.ant.internal.ui.dtd.ParseError;
-import org.eclipse.ant.internal.ui.dtd.Parser;
-
-/**
- * This class is intended to be used from the command line (hence the
- * uncapitalized class name).
- * @author Bob Foster
- */
-public class dumper {
-
- public static int main(String[] args) {
-
- if (args.length <= 0) {
- System.out.println("Usage: java DTDMerger URL");
- return 0;
- }
- String document = args[0];
-
- Parser parser = new Parser();
-
- ISchema schema;
- try {
- schema = parser.parse(document);
- } catch (ParseError e) {
- System.out.println(e.getMessage());
- e.printStackTrace();
- return 1;
- } catch (IOException e) {
- e.printStackTrace();
- return 1;
- }
- System.out.println("DTD successfully parsed");
- dumpSchema(schema);
- return 0;
- }
-
- /**
- * Write schema contents to standard output.
- */
- private static void dumpSchema(ISchema schema) {
- IElement[] elements = schema.getElements();
- System.out.println(""+elements.length+" elements defined");
- for (int i = 0; i < elements.length; i++) {
- IElement element = elements[i];
- IModel model = element.getContentModel();
- System.out.println("ELEMENT "+element.getName()
- +'"'+model.stringRep()+'"');
- dumpDfm(element.getDfm());
- }
- }
-
- /**
- * Dump dfm as a series of states.
- * <pre>
- * S0 a=>S1 b=>S2
- * S1 c=>S2
- * S2* d=>S2
- * </pre>
- * Where * indicates accepting state.
- * @param dfm to dump
- */
- private static void dumpDfm(IDfm dfm) {
- HashMap map = new HashMap();
- dumpDfm(dfm, map, 0);
- LinkedList list = new LinkedList();
- Iterator it = map.entrySet().iterator();
- while (it.hasNext()) {
- Map.Entry entry = (Map.Entry) it.next();
- list.add(new State((IDfm)entry.getKey(), (Integer)entry.getValue()));
- }
- State[] states = (State[]) list.toArray(new State[list.size()]);
- Arrays.sort(states);
- for (int i = 0; i < states.length; i++) {
- print(states[i], map);
- }
- }
-
- private static void print(State state, HashMap map) {
- System.out.print(" S"+state.n.intValue()
- +(state.dfm.isAccepting() ? "* " : " "));
- String[] accepts = state.dfm.getAccepts();
- for (int i = 0; i < accepts.length; i++) {
- String accept = accepts[i];
- IDfm next = state.dfm.advance(accept);
- int n = ((Integer)map.get(next)).intValue();
- System.out.print(" "+accept+"=>S"+n);
- }
- System.out.println();
- }
-
- private static int dumpDfm(IDfm dfm, HashMap map, int num) {
- if (!map.containsKey(dfm)) {
- map.put(dfm, new Integer(num++));
- String[] accepts = dfm.getAccepts();
- for (int i = 0; i < accepts.length; i++) {
- IDfm next = dfm.advance(accepts[i]);
- num = dumpDfm(next, map, num);
- }
- }
- return num;
- }
-
- private static class State implements Comparable {
- public IDfm dfm;
- public Integer n;
- public State(IDfm dfm, Integer n) {
- this.dfm = dfm;
- this.n = n;
- }
- /**
- * @see java.lang.Comparable#compareTo(java.lang.Object)
- */
- public int compareTo(Object o) {
- State other = (State) o;
- return n.intValue() < other.n.intValue()
- ? -1
- : (n.intValue() == other.n.intValue()
- ? 0
- : 1);
- }
-
- }
-}
diff --git a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/AntEditorContentOutlineTests.java b/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/AntEditorContentOutlineTests.java
deleted file mode 100644
index 9da14d3a8..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/AntEditorContentOutlineTests.java
+++ /dev/null
@@ -1,207 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2002, 2003 GEBIT Gesellschaft fuer EDV-Beratung
- * und Informatik-Technologien mbH,
- * Berlin, Duesseldorf, Frankfurt (Germany) and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * GEBIT Gesellschaft fuer EDV-Beratung und Informatik-Technologien mbH - initial implementation
- * IBM Corporation - additional tests
- *******************************************************************************/
-
-package org.eclipse.ant.tests.ui.editor;
-
-import java.util.List;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-import org.eclipse.ant.internal.ui.editor.outline.AntModel;
-import org.eclipse.ant.internal.ui.editor.model.AntElementNode;
-import org.eclipse.ant.tests.ui.testplugin.AbstractAntUITest;
-import org.eclipse.jface.text.BadLocationException;
-
-/**
- * Tests the correct creation of the outline for an xml file.
- *
- */
-public class AntEditorContentOutlineTests extends AbstractAntUITest {
-
- public AntEditorContentOutlineTests(String name) {
- super(name);
- }
-
- /**
- * Tests the creation of the AntElementNode, that includes parsing a file
- * and determining the correct location of the tags.
- */
- public void testCreationOfOutlineTree() throws BadLocationException {
- AntModel model= getAntModel("buildtest1.xml");
-
- AntElementNode[] roots = model.getRootElements();
- assertNotNull(roots);
- AntElementNode rootProject= roots[0];
-
- assertNotNull(rootProject);
-
- // Get the content as string
- String wholeDocumentString = getCurrentDocument().get();
-
- // <project>
- assertEquals(2, getStartingRow(rootProject));
- assertEquals(2, getStartingColumn(rootProject));
- int offset = wholeDocumentString.indexOf("project");
- assertEquals(offset, rootProject.getOffset());
-
- List children = rootProject.getChildNodes();
-
- // <property name="propD">
- AntElementNode element = (AntElementNode)children.get(0);
- assertEquals(3, getStartingRow(element));
- assertEquals(3, getStartingColumn(element)); // with tab in file
- assertEquals(3, getEndingRow(element));
- assertEquals(39, getEndingColumn(element)); // with tab in file
-
- offset = wholeDocumentString.indexOf("property");
- assertEquals(offset, element.getOffset());
- int length = "<property name=\"propD\" value=\"valD\" />".length();
- assertEquals(length- 1, element.getLength()); //we do not include the first '<'
-
- // <property file="buildtest1.properties">
- element = (AntElementNode)children.get(1);
- assertEquals(4, getStartingRow(element));
- assertEquals(6, getStartingColumn(element)); // no tab
- assertEquals(4, getEndingRow(element));
- assertEquals(45, getEndingColumn(element));
-
- // <property name="propV">
- element = (AntElementNode)children.get(2);
- assertEquals(5, getStartingRow(element));
- assertEquals(6, getStartingColumn(element));
- assertEquals(5, getEndingRow(element));
- assertEquals(42, getEndingColumn(element));
-
- // <target name="main">
- element = (AntElementNode)children.get(3);
- assertEquals(6, getStartingRow(element));
- assertEquals(6, getStartingColumn(element));
- assertEquals(9, getEndingRow(element));
- assertEquals(13, getEndingColumn(element));
-
- // <property name="property_in_target">
- element = (AntElementNode)element.getChildNodes().get(0);
- assertEquals(7, getStartingRow(element));
- assertEquals(10, getStartingColumn(element));
- assertEquals(7, getEndingRow(element));
- assertEquals(57, getEndingColumn(element));
- offset = wholeDocumentString.indexOf("property name=\"property_in_target\"");
- assertEquals(offset, element.getOffset());
-
- assertEquals(21, getEndingRow(rootProject));
- assertEquals(10, getEndingColumn(rootProject));
- }
-
- private int getColumn(int offset, int line) throws BadLocationException {
- return offset - getCurrentDocument().getLineOffset(line - 1) + 1;
- }
-
- private int getStartingRow(AntElementNode element) throws BadLocationException {
- return getCurrentDocument().getLineOfOffset(element.getOffset()) + 1;
- }
-
- private int getEndingRow(AntElementNode element) throws BadLocationException {
- return getCurrentDocument().getLineOfOffset(element.getOffset() + element.getLength() - 1) + 1;
- }
-
- private int getStartingColumn(AntElementNode element) throws BadLocationException {
- return getColumn(element.getOffset(), getStartingRow(element));
- }
-
- private int getEndingColumn(AntElementNode element) throws BadLocationException {
- return getColumn(element.getOffset() + element.getLength() - 1, getEndingRow(element));
- }
-
- /**
- * Tests the creation of the AntElementNode, that includes parsing a non-valid
- * file.
- */
- public void testParsingOfNonValidFile() throws BadLocationException {
- AntModel model= getAntModel("buildtest2.xml");
-
- AntElementNode[] roots = model.getRootElements();
- assertNotNull(roots);
- AntElementNode root= roots[0];
- assertNotNull(root);
-
- List children = root.getChildNodes();
-
- // <target name="main">
- AntElementNode element = (AntElementNode)children.get(2);
- assertEquals(5, getStartingRow(element));
- assertEquals(3, getStartingColumn(element)); // with tab in file
- assertEquals(5, getEndingRow(element));
- //main has no ending column as the element is not closed
- int offset = getCurrentDocument().get().indexOf("target name=\"main\"");
- assertEquals(offset, element.getOffset());
- }
-
-
- /**
- * Tests whether the outline can handle a build file with only the <project></project> tags.
- */
- public void testWithProjectOnlyBuildFile() {
- AntModel model= getAntModel("projectOnly.xml");
- AntElementNode[] roots = model.getRootElements();
- assertNotNull(roots);
- AntElementNode root= roots[0];
- assertNotNull(root);
- }
-
- /**
- * Tests whether the outline can handle an empty build file.
- */
- public void testWithEmptyBuildFile() {
- AntModel model= getAntModel("empty.xml");
- AntElementNode[] roots = model.getRootElements();
- assertNotNull(roots);
- assertTrue(roots.length == 0);
- }
-
- /**
- * Some testing of getting the right location of tags.
- */
- public void testAdvancedTaskLocation() throws BadLocationException {
- AntModel model= getAntModel("outline_select_test_build.xml");
-
- AntElementNode[] roots = model.getRootElements();
- assertNotNull(roots);
- AntElementNode rootProject= roots[0];
- // Get the content as string
- String wholeDocumentString = getCurrentDocument().get();
-
- // <project>
- assertNotNull(rootProject);
- assertEquals(2, getStartingRow(rootProject));
- assertEquals(2, getStartingColumn(rootProject));
- int offset = wholeDocumentString.indexOf("project");
-
- assertEquals(offset, rootProject.getOffset());
-
- // <target name="properties">
- AntElementNode element = (AntElementNode)rootProject.getChildNodes().get(1);
- assertNotNull(element);
- assertEquals("properties", element.getLabel());
- assertEquals(16, getStartingRow(element));
- assertEquals(3, getStartingColumn(element));
- offset = wholeDocumentString.indexOf("target name=\"properties\"");
-
- assertEquals(offset, element.getOffset());
- }
-
- public static Test suite() {
- return new TestSuite(AntEditorContentOutlineTests.class);
- }
-} \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/CodeCompletionTest.java b/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/CodeCompletionTest.java
deleted file mode 100644
index e0bc4e38e..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/CodeCompletionTest.java
+++ /dev/null
@@ -1,748 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2002, 2004 GEBIT Gesellschaft fuer EDV-Beratung
- * und Informatik-Technologien mbH,
- * Berlin, Duesseldorf, Frankfurt (Germany) and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * GEBIT Gesellschaft fuer EDV-Beratung und Informatik-Technologien mbH - initial implementation
- * IBM Corporation - additional tests
- *******************************************************************************/
-
-package org.eclipse.ant.tests.ui.editor;
-
-import java.io.File;
-import java.io.FileNotFoundException;
-
-import javax.xml.parsers.DocumentBuilder;
-import javax.xml.parsers.DocumentBuilderFactory;
-import javax.xml.parsers.ParserConfigurationException;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-import org.eclipse.ant.tests.ui.editor.support.TestTextCompletionProcessor;
-import org.eclipse.ant.tests.ui.testplugin.AbstractAntUITest;
-import org.eclipse.jface.text.BadLocationException;
-import org.eclipse.jface.text.contentassist.ICompletionProposal;
-import org.w3c.dom.Attr;
-import org.w3c.dom.Comment;
-import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-
-/**
- * Tests everything about code completion and code assistance.
- *
- */
-public class CodeCompletionTest extends AbstractAntUITest {
-
- /**
- * Constructor for CodeCompletionTest.
- * @param name
- */
- public CodeCompletionTest(String name) {
- super(name);
- }
-
- public static Test suite() {
- return new TestSuite(CodeCompletionTest.class);
- }
-
- /**
- * Tests the code completion for attributes of tasks.
- */
- public void testAttributeProposals() {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor();
-
- ICompletionProposal[] proposals = processor.getAttributeProposals("contains", "ca");
- assertEquals(1, proposals.length);
- assertEquals("casesensitive - (true | false | on | off | yes | no)", proposals[0].getDisplayString());
-
- proposals = processor.getAttributeProposals("move", "");
- assertEquals(16, proposals.length);
- ICompletionProposal proposal = proposals[0];
- String displayString = proposal.getDisplayString();
- assertTrue(displayString.equals("id")
- || displayString.equals("taskname")
- || displayString.equals("description")
- || displayString.equals("file")
- || displayString.equals("preservelastmodified - (true | false | on | off | yes | no)")
- || displayString.equals("tofile")
- || displayString.equals("todir")
- || displayString.equals("overwrite - (true | false | on | off | yes | no)")
- || displayString.equals("filtering - (true | false | on | off | yes | no)")
- || displayString.equals("flatten - (true | false | on | off | yes | no)")
- || displayString.equals("includeemptydirs")
- || displayString.equals("failonerror - (true | false | on | off | yes | no)")
- || displayString.equals("verbose - (true | false | on | off | yes | no)")
- || displayString.equals("encoding")
- || displayString.equals("outputencoding")
- || displayString.equals("enablemultiplemapping - (true | false | on | off | yes | no)"));
-
- proposals = processor.getAttributeProposals("move", "to");
- assertEquals(2, proposals.length);
-
- proposals = processor.getAttributeProposals("reference", "idl");
- assertEquals(0, proposals.length);
-
- proposals = processor.getAttributeProposals("reference", "id");
- assertEquals(1, proposals.length);
- assertEquals("id", proposals[0].getDisplayString());
-
- proposals = processor.getAttributeProposals("reference", "i");
- //id includesfile includes
- assertEquals(3, proposals.length);
- displayString= proposals[0].getDisplayString();
- assertTrue(displayString.equals("id")
- || displayString.equals("includeFile")
- || displayString.equals("includes"));
-
- proposals = processor.getAttributeProposals("project", "de");
- assertEquals(1, proposals.length);
- }
-
- /**
- * Test the code completion for properties, including unquoted (bug 40871)
- */
- public void testPropertyProposals() throws BadLocationException {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("buildtest1.xml"));
-
- int lineNumber= 7;
- int columnNumber= 17;
- int lineOffset= getCurrentDocument().getLineOffset(lineNumber);
- processor.setLineNumber(lineNumber);
- processor.setColumnNumber(columnNumber);
- processor.setCursorPosition(lineOffset + columnNumber);
- ICompletionProposal[] proposals = processor.getPropertyProposals(getCurrentDocument(), "", lineOffset + columnNumber);
- assertTrue(proposals.length >= 1);
- assertContains("prop1", proposals);
-
- lineNumber= 18;
- columnNumber= 25;
- lineOffset= getCurrentDocument().getLineOffset(lineNumber);
- processor.setLineNumber(lineNumber);
- processor.setColumnNumber(columnNumber);
- processor.setCursorPosition(lineOffset + columnNumber);
- proposals = processor.getPropertyProposals(getCurrentDocument(), "", lineOffset + columnNumber);
- assertTrue(proposals.length >= 1);
- assertContains("prop2", proposals);
- }
-
- /**
- * Test the code completion for "system" properties
- */
- public void testSystemPropertyProposals() throws BadLocationException {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("buildtest1.xml"));
-
- int lineNumber= 18;
- int columnNumber= 25;
- int lineOffset= getCurrentDocument().getLineOffset(lineNumber);
- processor.setLineNumber(lineNumber);
- processor.setColumnNumber(columnNumber);
- processor.setCursorPosition(lineOffset + columnNumber);
- ICompletionProposal[] proposals = processor.getPropertyProposals(getCurrentDocument(), "", lineOffset + columnNumber);
- assertTrue(proposals.length >= 1);
- assertContains("java.home", proposals);
- }
-
- /**
- * Test the code completion for the depend attribute of a target.
- */
- public void testTargetDependProposals() throws BadLocationException {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("buildtest1.xml"));
- //simple depends
- int lineNumber= 10;
- int columnNumber= 34;
- int lineOffset= getCurrentDocument().getLineOffset(lineNumber);
- processor.setLineNumber(lineNumber);
- processor.setColumnNumber(columnNumber);
- processor.setCursorPosition(lineOffset + columnNumber);
- ICompletionProposal[] proposals = processor.getTargetAttributeValueProposals(getCurrentDocument(), getCurrentDocument().get(0, lineOffset + columnNumber), "", "depends");
- assertTrue(proposals.length == 7);
- assertContains("pretest", proposals);
- assertContains("testMoreDepends", proposals);
- //comma separated depends
- lineNumber= 17;
- columnNumber= 53;
- lineOffset= getCurrentDocument().getLineOffset(lineNumber);
- processor.setLineNumber(lineNumber);
- processor.setColumnNumber(columnNumber);
- processor.setCursorPosition(lineOffset + columnNumber);
- proposals = processor.getTargetAttributeValueProposals(getCurrentDocument(), getCurrentDocument().get(0, lineOffset + columnNumber), "", "depends");
- assertTrue(proposals.length == 6);
- assertContains("main", proposals);
- assertDoesNotContain("pretest", proposals);
-
- }
-
- /**
- * Test the code completion for the if attribute of a target.
- */
- public void testTargetIfProposals() throws BadLocationException {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("buildtest1.xml"));
-
- int lineNumber= 15;
- int columnNumber= 31;
- int lineOffset= getCurrentDocument().getLineOffset(lineNumber);
- processor.setLineNumber(lineNumber);
- processor.setColumnNumber(columnNumber);
- processor.setCursorPosition(lineOffset + columnNumber);
- ICompletionProposal[] proposals = processor.getTargetAttributeValueProposals(getCurrentDocument(), getCurrentDocument().get(0, lineOffset + columnNumber), "", "if");
- assertTrue(proposals.length >= 1);
- assertContains("prop1", proposals);
- }
-
- /**
- * Test the code completion for the unless attribute of a target.
- */
- public void testTargetUnlessProposals() throws BadLocationException {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("buildtest1.xml"));
-
- int lineNumber= 16;
- int columnNumber= 43;
- int lineOffset= getCurrentDocument().getLineOffset(lineNumber);
- processor.setLineNumber(lineNumber);
- processor.setColumnNumber(columnNumber);
- processor.setCursorPosition(lineOffset + columnNumber);
- ICompletionProposal[] proposals = processor.getTargetAttributeValueProposals(getCurrentDocument(), getCurrentDocument().get(0, lineOffset + columnNumber), "prop", "unless");
- assertTrue(proposals.length >= 1);
- assertContains("prop1", proposals);
-
- }
-
- /**
- * Asserts that <code>displayString</code> is in one of the
- * completion proposals.
- */
- private void assertContains(String displayString, ICompletionProposal[] proposalArray) {
- boolean found = false;
- for (int i = 0; i < proposalArray.length; i++) {
- ICompletionProposal proposal = proposalArray[i];
- String proposalDisplayString = proposal.getDisplayString();
- if(displayString.equals(proposalDisplayString)) {
- found = true;
- break;
- }
- }
- assertEquals(true, found);
- }
-
- /**
- * Asserts that <code>displayString</code> is not in one of the
- * completion proposals.
- */
- private void assertDoesNotContain(String displayString, ICompletionProposal[] proposalArray) {
- boolean found = false;
- for (int i = 0; i < proposalArray.length; i++) {
- ICompletionProposal proposal = proposalArray[i];
- String proposalDisplayString = proposal.getDisplayString();
- if(displayString.equals(proposalDisplayString)) {
- found = true;
- break;
- }
- }
- assertEquals(false, found);
- }
-
- /**
- * Tests the property proposals for the case that they are defined in
- * a dependent targets.
- */
- public void testPropertyProposalDefinedInDependantTargets() throws FileNotFoundException {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("dependencytest.xml"));
-
- File file= getBuildFile("dependencytest.xml");
- processor.setEditedFile(file);
- String documentText = getFileContentAsString(file);
-
- processor.setLineNumber(35);
- processor.setColumnNumber(41);
- int cursorPosition = documentText.lastIndexOf("${");
- assertTrue(cursorPosition != -1);
- ICompletionProposal[] proposals = processor.getPropertyProposals(new org.eclipse.jface.text.Document(documentText), "", cursorPosition+2);
- assertContains("init_prop", proposals);
- assertContains("main_prop", proposals);
- assertContains("prop_prop", proposals);
- assertContains("do_not_compile", proposals);
- assertContains("adit_prop", proposals);
- assertContains("compile_prop", proposals);
- }
-
- /**
- * Tests the code completion for tasks that have been defined in the buildfile
- */
- public void testCustomTaskProposals() {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("taskdef.xml"));
-
- ICompletionProposal[] proposals = processor.getTaskProposals(getCurrentDocument(), "target", "min");
- assertEquals(1, proposals.length);
- ICompletionProposal proposal = proposals[0];
- assertEquals("mine", proposal.getDisplayString());
- }
-
- /**
- * Tests the code completion for tasks that have been defined via the task extension point
- */
- public void testExtensionPointTaskProposals() {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("taskdef.xml"));
-
- ICompletionProposal[] proposals = processor.getTaskProposals(getCurrentDocument(), "target", "cool");
- assertEquals(4, proposals.length);
- assertContains("coolUITask", proposals);
- }
-
- /**
- * Tests the code completion for tasks that have been defined via macrodef in the buildfile
- */
- public void testMacrodefProposals() {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("macrodef.xml"));
-
- ICompletionProposal[] proposals = processor.getTaskProposals(getCurrentDocument(), "target", "eclipsema");
- assertEquals(1, proposals.length);
- ICompletionProposal proposal = proposals[0];
- assertEquals("eclipseMacro", proposal.getDisplayString());
-
- }
-
- /**
- * Tests the code completion for nested element attributes
- */
- public void testMacrodefNestedElementAttributeProposals() throws BadLocationException {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("macrodef.xml"));
- int lineNumber= 5;
- int columnNumber= 11;
- int lineOffset= getCurrentDocument().getLineOffset(lineNumber);
- processor.setLineNumber(lineNumber);
- processor.setColumnNumber(columnNumber);
- processor.setCursorPosition(lineOffset + columnNumber);
- ICompletionProposal[] proposals = processor.getProposalsFromDocument(getCurrentDocument(), "");
- assertTrue(proposals.length == 4);
- assertContains("description", proposals);
- assertContains("name", proposals);
- }
-
- /**
- * Tests the code completion for tasks that have been defined via macrodef in the buildfile
- */
- public void testMacrodefAttributeProposals() throws BadLocationException {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("macrodef.xml"));
- int lineNumber= 12;
- int columnNumber= 16;
- int lineOffset= getCurrentDocument().getLineOffset(lineNumber);
- processor.setLineNumber(lineNumber);
- processor.setColumnNumber(columnNumber);
- processor.setCursorPosition(lineOffset + columnNumber);
- ICompletionProposal[] proposals = processor.getProposalsFromDocument(getCurrentDocument(), "");
- assertTrue(proposals.length == 2);
- assertContains("v", proposals);
- assertContains("eclipse", proposals);
- assertTrue("Additional proposal information not correct", proposals[1].getAdditionalProposalInfo().startsWith("Testing Eclipse"));
- }
-
- /**
- * Tests the code completion for elements that have been defined via macrodef in the buildfile
- */
- public void testMacrodefElementProposals() throws BadLocationException {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("macrodef.xml"));
- int lineNumber= 13;
- int columnNumber= 3;
- int lineOffset= getCurrentDocument().getLineOffset(lineNumber);
- processor.setLineNumber(lineNumber);
- processor.setColumnNumber(columnNumber);
- processor.setCursorPosition(lineOffset + columnNumber);
- ICompletionProposal[] proposals = processor.getProposalsFromDocument(getCurrentDocument(), "");
- assertTrue(proposals.length == 1);
- assertTrue("Proposal not correct", proposals[0].getDisplayString().equals("some-tasks"));
- assertTrue("Additional proposal information not correct", proposals[0].getAdditionalProposalInfo().endsWith("Not required"));
- }
-
- /**
- * Tests the code completion for tasks having parent tasks.
- */
- public void testTaskProposals() {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("buildtest1.xml"));
-
-
- ICompletionProposal[] proposals = processor.getTaskProposals(" <", "rename", "");
- assertEquals(0, proposals.length);
-
- proposals = processor.getTaskProposals(" <cl", "property", "cl");
- assertEquals(1, proposals.length);
- ICompletionProposal proposal = proposals[0];
- assertEquals("classpath", proposal.getDisplayString());
-
- proposals = processor.getTaskProposals(" <pr", "property", "");
- assertEquals(1, proposals.length);
- proposal = proposals[0];
- assertEquals("classpath", proposal.getDisplayString());
-
- // "<project><target><mk"
- proposals = processor.getTaskProposals("<project><target><mk", "target", "mk");
- assertEquals(1, proposals.length);
- proposal = proposals[0];
- assertEquals("mkdir", proposal.getDisplayString());
-
- }
-
- /**
- * Test for bug 40951
- */
- public void testMixedElements() {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("mixed.xml"));
- //String string = "<project><target><sql driver=\"\" password=\"\" url=\"\" userid=\"\"></sql><concat></concat>";
- ICompletionProposal[] proposals = processor.getTaskProposals(getCurrentDocument(), processor.getParentName(getCurrentDocument(), 0, 62), "t");
- assertEquals(1, proposals.length);
- ICompletionProposal proposal = proposals[0];
- assertEquals("transaction", proposal.getDisplayString());
-
- proposals = processor.getTaskProposals(getCurrentDocument(), processor.getParentName(getCurrentDocument(), 0, 76), "");
- //filelist fileset filterchain footer header path
- assertEquals(6, proposals.length);
- proposal = proposals[0];
- assertEquals("filelist", proposal.getDisplayString());
- }
-
- /**
- * Tests the algorithm for finding a child as used by the processor.
- */
- public void testFindChildElement() throws ParserConfigurationException {
-
- // Create the test data
- DocumentBuilder docBuilder = DocumentBuilderFactory.newInstance().newDocumentBuilder();
- Document doc = docBuilder.newDocument();
- Element parentElement = doc.createElement("parent");
- Attr attribute = doc.createAttribute("att1");
- parentElement.setAttributeNode(attribute);
- Comment comment = doc.createComment("lakjjflsakdfj");
- parentElement.appendChild(comment);
- Element childElement = doc.createElement("child");
- parentElement.appendChild(childElement);
- childElement = doc.createElement("secondchild");
- parentElement.appendChild(childElement);
-
- // Create the processor
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor();
-
- // Test it!
- childElement = processor.findChildElementNamedOf(parentElement, "jkl");
- assertNull(childElement);
- childElement = processor.findChildElementNamedOf(parentElement, "secondchild");
- assertNotNull(childElement);
- assertEquals("secondchild", childElement.getTagName());
- }
-
- /**
- * Tests that the processor correctly determines the attribute proposal mode
- */
- public void testDeterminingAttributeProposalMode() {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor();
- int mode = processor.determineProposalMode("<project><property ta", 21, "ta");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_ATTRIBUTE_PROPOSAL, mode);
- mode = processor.determineProposalMode("<project><property ", 19, "");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_ATTRIBUTE_PROPOSAL, mode);
- mode = processor.determineProposalMode("<project><property ", 21, "");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_ATTRIBUTE_PROPOSAL, mode);
- mode = processor.determineProposalMode("<property id=\"hu\" ", 18, "");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_ATTRIBUTE_PROPOSAL, mode);
- mode = processor.determineProposalMode("<property id=\"hu\" \r\n ", 21, "");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_ATTRIBUTE_PROPOSAL, mode);
- mode = processor.determineProposalMode("<property\n", 10, "");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_ATTRIBUTE_PROPOSAL, mode);
- }
-
- /**
- * Tests that the processor correctly determines the attribute value proposal mode
- */
- public void testDeterminingAttributeValueProposalMode() {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor();
- int mode = processor.determineProposalMode("<project><property take=\"", 25, "");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_ATTRIBUTE_VALUE_PROPOSAL, mode);
- mode = processor.determineProposalMode("<property id=\"hu\" ", 14, "");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_ATTRIBUTE_VALUE_PROPOSAL, mode);
- mode = processor.determineProposalMode("<property id=\"hu\" \r\n ", 16, "hu");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_ATTRIBUTE_VALUE_PROPOSAL, mode);
- mode = processor.determineProposalMode("<property \n\t\tid=\"hu\" \r\n ", 19, "hu");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_ATTRIBUTE_VALUE_PROPOSAL, mode);
- }
-
- /**
- * Tests how the processor determines the proposal mode.
- */
- public void testDeterminingPropertyProposalMode() {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor();
- int mode =processor.determineProposalMode("<project><target name=\"$\"", 24, "");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_PROPERTY_PROPOSAL, mode);
- mode = processor.determineProposalMode("<project><target name=\"${\"", 25, "");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_PROPERTY_PROPOSAL, mode);
- mode = processor.determineProposalMode("<project><target name=\"${ja.bl\"", 30, "ja.bl");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_PROPERTY_PROPOSAL, mode);
-
- mode = processor.determineProposalMode("<project><target><echo>${", 25, "");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_PROPERTY_PROPOSAL, mode);
- }
-
- /**
- * Tests how the processor determines the proposal mode.
- */
- public void testDeterminingTaskProposalMode() {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor();
-
- int mode = processor.determineProposalMode("<project><prop", 14, "prop");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_TASK_PROPOSAL, mode);
- mode = processor.determineProposalMode("<project> hjk", 13, "");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_TASK_PROPOSAL, mode);
- mode = processor.determineProposalMode("<project> hjk<", 14, "");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_TASK_PROPOSAL, mode); // allow this case though it is not valid with Ant
- mode = processor.determineProposalMode("<project>", 9, "");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_TASK_PROPOSAL, mode);
- mode = processor.determineProposalMode("<project> ", 10, "");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_TASK_PROPOSAL, mode);
- mode = processor.determineProposalMode("<project></", 11, "");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_TASK_PROPOSAL_CLOSING, mode);
- mode = processor.determineProposalMode("<project>< </project>", 10, "");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_TASK_PROPOSAL, mode);
- mode = processor.determineProposalMode("<project default=\"hey\"><target name=\"hey\">a</target></project>", 44, "a");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_TASK_PROPOSAL, mode);
- mode = processor.determineProposalMode("<project default=\"hey\"><target name=\"hey\"></target></project>", 43, "");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_TASK_PROPOSAL, mode);
- mode = processor.determineProposalMode("<project default=\"hey\"><target name=\"hey\"><a</target></project>", 45, "<a");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_TASK_PROPOSAL, mode);
- mode = processor.determineProposalMode("<target name=\"main\"><zip><size></size></zip></", 46, "");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_TASK_PROPOSAL_CLOSING, mode);
- mode = processor.determineProposalMode("", 0, "");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_BUILDFILE, mode);
- mode= processor.determineProposalMode("<project default=\"hey\"><target name=\"hey\"><javac>a</javac></target></project>", 51, "a");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_TASK_PROPOSAL, mode);
- mode = processor.determineProposalMode("<project> hjk", 13, "");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_TASK_PROPOSAL, mode);
- }
-
- /**
- * Tests how the processor determines the proposal mode.
- */
- public void testDeterminingTaskClosingProposalMode() {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor();
-
- int mode = processor.determineProposalMode("<target name=\"main\"><zip><size></size></zip></", 46, "");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_TASK_PROPOSAL_CLOSING, mode);
- }
-
- /**
- * Tests how the prefix will be determined.
- */
- public void testDeterminingPrefix() {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor();
-
- // cursor after ${
- String prefix = processor.getPrefixFromDocument("<project><target name=\"${}\"", 25);
- assertEquals("", prefix);
-
- // cursor after $
- prefix = processor.getPrefixFromDocument("<project><target name=\"${\"", 24);
- assertEquals("", prefix);
-
- // cursor after ${ja.
- prefix = processor.getPrefixFromDocument("<project><target name=\"${ja.\"", 28);
- assertEquals("ja.", prefix);
-
- // cursor after <
- prefix = processor.getPrefixFromDocument("<project><", 10);
- assertEquals("", prefix);
-
- prefix = processor.getPrefixFromDocument("<project name= \"test\"><tar", 26);
- assertEquals("tar", prefix);
-
- prefix = processor.getPrefixFromDocument("pro", 3);
- assertEquals("pro", prefix);
- }
-
- /**
- * Tests how the processor determines the proposal mode.
- */
- public void testDeterminingNoneProposalMode() {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor();
-
- int mode = processor.determineProposalMode("<project><prop bla", 18, "bla");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_NONE, mode);
- mode= processor.determineProposalMode("<project default=\"hey\"><target name=", 37, "name=");
- assertEquals(TestTextCompletionProcessor.TEST_PROPOSAL_MODE_NONE, mode);
- }
-
- /**
- * Tests the code completion for tasks in an empty build file (no parent).
- */
- public void testTaskProposalsForEmptyBuildFile() {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("empty.xml"));
-
- ICompletionProposal[] proposals = processor.getBuildFileProposals("", "");
- assertEquals(1, proposals.length);
- assertEquals("project", proposals[0].getDisplayString());
-
- proposals = processor.getBuildFileProposals(" jl", "jl");
- assertEquals(0, proposals.length);
-
- proposals = processor.getBuildFileProposals(" \n<project></project>", "");
- assertEquals(1, proposals.length);
- }
-
- /**
- * Tests the code completion for refids (Bug 49830)
- */
- public void testRefidProposals() throws BadLocationException {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("refid.xml"));
-
- int lineNumber= 9;
- int columnNumber= 16;
- int lineOffset= getCurrentDocument().getLineOffset(lineNumber);
- processor.setLineNumber(lineNumber);
- processor.setColumnNumber(columnNumber);
- processor.setCursorPosition(lineOffset + columnNumber);
- ICompletionProposal[] proposals = processor.getProposalsFromDocument(getCurrentDocument(), "");
- //for sure should have project.class.path and project.class.path2
- assertTrue(proposals.length >= 2);
- assertContains("project.class.path", proposals);
- assertDoesNotContain("project.class.path2", proposals);
- }
-
- /**
- * Tests the code completion for custom task that has a boolean attribute
- */
- public void testCustomBooleanProposals() throws BadLocationException {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("customBoolean.xml"));
-
- int lineNumber= 2;
- int columnNumber= 44;
- int lineOffset= getCurrentDocument().getLineOffset(lineNumber);
- processor.setLineNumber(lineNumber);
- processor.setColumnNumber(columnNumber);
- processor.setCursorPosition(lineOffset + columnNumber);
- ICompletionProposal[] proposals = processor.getProposalsFromDocument(getCurrentDocument(), "");
- //true false yes no on off
- assertTrue(proposals.length == 6);
- assertContains("true", proposals);
- assertContains("no", proposals);
- }
-
- /**
- * Tests the code completion for custom task that has an enumerated attribute
- */
- public void testCustomEnumeratedProposals() throws BadLocationException {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("extensionPointTaskSepVM.xml"));
- int lineNumber= 2;
- int columnNumber= 24;
- int lineOffset= getCurrentDocument().getLineOffset(lineNumber);
- processor.setLineNumber(lineNumber);
- processor.setColumnNumber(columnNumber);
- processor.setCursorPosition(lineOffset + columnNumber);
- ICompletionProposal[] proposals = processor.getProposalsFromDocument(getCurrentDocument(), "c");
- assertEquals("Incorrect number of proposals", 2, proposals.length);
- assertContains("cool", proposals);
- assertContains("chillin", proposals);
- assertDoesNotContain("awesome", proposals);
- }
-
- /**
- * Tests the code completion for custom task that have a reference attribute
- */
- public void testCustomReferenceProposals() throws BadLocationException {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("extensionPointTaskSepVM.xml"));
- int lineNumber= 2;
- int columnNumber= 41;
- int lineOffset= getCurrentDocument().getLineOffset(lineNumber);
- processor.setLineNumber(lineNumber);
- processor.setColumnNumber(columnNumber);
- processor.setCursorPosition(lineOffset + columnNumber);
- ICompletionProposal[] proposals = processor.getProposalsFromDocument(getCurrentDocument(), "e");
- assertEquals("Incorrect number of proposals", 1, proposals.length);
- //the reference to the project by name
- assertContains("Extension Point Task", proposals);
- }
-
- /**
- * Tests the code completion for nested element attributes of custom tasks
- */
- public void testNestedElementAttributeProposals() throws BadLocationException {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("nestedElementAttributes.xml"));
- int lineNumber= 4;
- int columnNumber= 18;
- int lineOffset= getCurrentDocument().getLineOffset(lineNumber);
- processor.setLineNumber(lineNumber);
- processor.setColumnNumber(columnNumber);
- processor.setCursorPosition(lineOffset + columnNumber);
- ICompletionProposal[] proposals = processor.getProposalsFromDocument(getCurrentDocument(), "");
- assertTrue(proposals.length == 1);
- assertContains("works", proposals);
- }
-
- /**
- * Tests the code completion for nested element attribute values of custom tasks
- */
- public void testNestedElementAttributeValueProposals() throws BadLocationException {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("nestedElementAttributes.xml"));
- int lineNumber= 4;
- int columnNumber= 25;
- int lineOffset= getCurrentDocument().getLineOffset(lineNumber);
- processor.setLineNumber(lineNumber);
- processor.setColumnNumber(columnNumber);
- processor.setCursorPosition(lineOffset + columnNumber);
- ICompletionProposal[] proposals = processor.getProposalsFromDocument(getCurrentDocument(), "");
- assertTrue(proposals.length == 6); //the boolean proposals
- assertContains("true", proposals);
- }
-
- /**
- * Tests the code completion when a parse error occurs in the project definition
- * bug 63151
- */
- public void testBadProjectProposals() throws BadLocationException {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("badproject.xml"));
- int lineNumber= 0;
- int columnNumber= 10;
- int lineOffset= getCurrentDocument().getLineOffset(lineNumber);
- processor.setLineNumber(lineNumber);
- processor.setColumnNumber(columnNumber);
- processor.setCursorPosition(lineOffset + columnNumber);
- ICompletionProposal[] proposals = processor.getProposalsFromDocument(getCurrentDocument(), "n");
- assertTrue(proposals.length == 1);
- assertContains("name", proposals);
- }
-
- /**
- * Tests the code completion for attribute value proposals both with and without leading whitespace
- */
- public void testAttributeValueProposals() throws BadLocationException {
- TestTextCompletionProcessor processor = new TestTextCompletionProcessor(getAntModel("javac.xml"));
- int lineNumber= 2;
- int columnNumber= 29;
- int lineOffset= getCurrentDocument().getLineOffset(lineNumber);
- processor.setLineNumber(lineNumber);
- processor.setColumnNumber(columnNumber);
- processor.setCursorPosition(lineOffset + columnNumber);
- ICompletionProposal[] proposals = processor.getProposalsFromDocument(getCurrentDocument(), "");
- assertTrue(proposals.length == 6); //boolean proposals
- assertContains("false", proposals);
-
- lineNumber= 3;
- columnNumber= 19;
- lineOffset= getCurrentDocument().getLineOffset(lineNumber);
- processor.setLineNumber(lineNumber);
- processor.setColumnNumber(columnNumber);
- processor.setCursorPosition(lineOffset + columnNumber);
- proposals = processor.getProposalsFromDocument(getCurrentDocument(), "");
- assertTrue(proposals.length == 6); //boolean proposals
- assertContains("true", proposals);
-
- lineNumber= 4;
- columnNumber= 22;
- lineOffset= getCurrentDocument().getLineOffset(lineNumber);
- processor.setLineNumber(lineNumber);
- processor.setColumnNumber(columnNumber);
- processor.setCursorPosition(lineOffset + columnNumber);
- proposals = processor.getProposalsFromDocument(getCurrentDocument(), "");
- assertTrue(proposals.length == 6); //boolean proposals
- assertContains("no", proposals);
- }
-} \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/TaskDescriptionProviderTest.java b/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/TaskDescriptionProviderTest.java
deleted file mode 100644
index 521ecdde4..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/TaskDescriptionProviderTest.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2002, 2003 GEBIT Gesellschaft fuer EDV-Beratung
- * und Informatik-Technologien mbH,
- * Berlin, Duesseldorf, Frankfurt (Germany).
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * GEBIT Gesellschaft fuer EDV-Beratung und Informatik-Technologien mbH - initial implementation
- *******************************************************************************/
-
-package org.eclipse.ant.tests.ui.editor;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-import org.eclipse.ant.tests.ui.testplugin.AbstractAntUITest;
-import org.eclipse.ant.internal.ui.editor.TaskDescriptionProvider;
-
-/**
- * Tests the tasks description provider.
- *
- */
-public class TaskDescriptionProviderTest extends AbstractAntUITest {
-
- public TaskDescriptionProviderTest(String name) {
- super(name);
- }
-
- /**
- * Tests getting the description of a task.
- */
- public void testGettingTaskDescription() {
- TaskDescriptionProvider provider = TaskDescriptionProvider.getDefault();
- String description = provider.getDescriptionForTask("apply");
- assertNotNull(description);
- assertTrue(description.length() > 0);
- }
-
- /**
- * Tests getting the description of an attribute.
- */
- public void testGettingAttribute() {
- TaskDescriptionProvider provider = TaskDescriptionProvider.getDefault();
- String description = provider.getDescriptionForTaskAttribute("apply", "executable");
- assertNotNull(description);
- assertTrue(description.length() > 0);
- }
-
- /**
- * Tests getting the required value of an attribute.
- */
- public void testGettingRequired() {
- TaskDescriptionProvider provider = TaskDescriptionProvider.getDefault();
- String required = provider.getRequiredAttributeForTaskAttribute("apply", "executable");
- assertNotNull(required);
- assertEquals("yes", required);
- }
-
- public static Test suite() {
- return new TestSuite(TaskDescriptionProviderTest.class);
- }
-}
diff --git a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/formatter/FormattingPreferencesTest.java b/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/formatter/FormattingPreferencesTest.java
deleted file mode 100644
index 8295cfcff..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/formatter/FormattingPreferencesTest.java
+++ /dev/null
@@ -1,63 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 John-Mason P. Shackelford and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * John-Mason P. Shackelford - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.ui.editor.formatter;
-
-import org.eclipse.ant.internal.ui.editor.formatter.FormattingPreferences;
-import org.eclipse.ant.tests.ui.testplugin.AbstractAntUITest;
-
-public class FormattingPreferencesTest extends AbstractAntUITest {
-
- /**
- * @param name
- */
- public FormattingPreferencesTest(String name) {
- super(name);
- }
-
- public final void testGetCanonicalIndent() {
-
- FormattingPreferences prefs;
-
- // test spaces
- prefs = new FormattingPreferences(){
- public int getTabWidth() {
- return 3;
- }
- public boolean useSpacesInsteadOfTabs() {
- return true;
- }
- };
- assertEquals(" ",prefs.getCanonicalIndent());
-
- // ensure the value is not hard coded
- prefs = new FormattingPreferences(){
- public int getTabWidth() {
- return 7;
- }
- public boolean useSpacesInsteadOfTabs() {
- return true;
- }
- };
- assertEquals(" ",prefs.getCanonicalIndent());
-
- // use tab character
- prefs = new FormattingPreferences(){
- public int getTabWidth() {
- return 7;
- }
- public boolean useSpacesInsteadOfTabs() {
- return false;
- }
- };
- assertEquals("\t",prefs.getCanonicalIndent());
- }
-
-}
diff --git a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/formatter/XmlDocumentFormatterTest.java b/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/formatter/XmlDocumentFormatterTest.java
deleted file mode 100644
index 7852dd5d8..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/formatter/XmlDocumentFormatterTest.java
+++ /dev/null
@@ -1,99 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 John-Mason P. Shackelford and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * John-Mason P. Shackelford - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.ui.editor.formatter;
-
-import org.eclipse.ant.internal.ui.editor.formatter.FormattingPreferences;
-import org.eclipse.ant.internal.ui.editor.formatter.XmlDocumentFormatter;
-import org.eclipse.ant.tests.ui.testplugin.AbstractAntUITest;
-
-/**
- *
- */
-public class XmlDocumentFormatterTest extends AbstractAntUITest {
-
- /**
- * @param name
- */
- public XmlDocumentFormatterTest(String name) {
- super(name);
- }
-
- /**
- * General Test
- */
- public final void testGeneralFormat() throws Exception {
- FormattingPreferences prefs = new FormattingPreferences(){
- public int getTabWidth() {
- return 3;
- }
- public boolean stripBlankLines() {
- return false;
- }
- public boolean useSpacesInsteadOfTabs() {
- return true;
- }
- };
- simpleTest("formatTest_source01.xml","formatTest_target01.xml",prefs);
- }
-
- /**
- * Insure that tab width is not hard coded
- */
- public final void testTabWidth() throws Exception {
- FormattingPreferences prefs = new FormattingPreferences(){
- public int getTabWidth() {
- return 7;
- }
- public boolean stripBlankLines() {
- return false;
- }
- public boolean useSpacesInsteadOfTabs() {
- return true;
- }
- };
- simpleTest("formatTest_source01.xml","formatTest_target02.xml",prefs);
- }
-
-
- /**
- * Test with tab characters instead of spaces.
- */
- public final void testTabsInsteadOfSpaces() throws Exception {
- FormattingPreferences prefs = new FormattingPreferences(){
- public int getTabWidth() {
- return 3;
- }
- public boolean stripBlankLines() {
- return false;
- }
- public boolean useSpacesInsteadOfTabs() {
- return false;
- }
- };
- simpleTest("formatTest_source01.xml","formatTest_target03.xml",prefs);
- }
-
-
- /**
- * @param sourceFileName - file to format
- * @param targetFileName - the source file after a properly executed format
- * @param prefs - given the included preference instructions
- * @throws Exception
- */
- private void simpleTest(String sourceFileName, String targetFileName, FormattingPreferences prefs) throws Exception {
-
- XmlDocumentFormatter xmlFormatter = new XmlDocumentFormatter();
- String result = xmlFormatter.format(getFileContentAsString(getBuildFile(sourceFileName)),prefs);
- String expectedResult = getFileContentAsString(getBuildFile(targetFileName));
-
- assertEquals(expectedResult, result);
- }
-}
diff --git a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/formatter/XmlFormatterTest.java b/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/formatter/XmlFormatterTest.java
deleted file mode 100644
index 10e97f9d8..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/formatter/XmlFormatterTest.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 John-Mason P. Shackelford and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * John-Mason P. Shackelford - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.ui.editor.formatter;
-
-import junit.framework.TestCase;
-
-import org.eclipse.ant.internal.ui.editor.formatter.FormattingPreferences;
-import org.eclipse.ant.internal.ui.editor.formatter.XmlFormatter;
-import org.eclipse.ant.internal.ui.model.AntUIPlugin;
-import org.eclipse.ant.internal.ui.preferences.AntEditorPreferenceConstants;
-import org.eclipse.core.runtime.Preferences;
-
-/**
- *
- */
-public class XmlFormatterTest extends TestCase {
-
- public final void testFormatUsingPreferenceStore() {
- Preferences prefs = AntUIPlugin.getDefault().getPluginPreferences();
- prefs.setValue(AntEditorPreferenceConstants.FORMATTER_WRAP_LONG, true);
- prefs.setValue(AntEditorPreferenceConstants.FORMATTER_MAX_LINE_LENGTH, 40);
- prefs.setValue(AntEditorPreferenceConstants.FORMATTER_ALIGN, false);
- prefs.setValue(AntEditorPreferenceConstants.FORMATTER_TAB_CHAR, true);
- prefs.setValue(AntEditorPreferenceConstants.FORMATTER_TAB_SIZE, 4);
- String xmlDoc = "<project default=\"go\"><target name=\"go\" description=\"Demonstrate the wrapping of long tags.\"><echo>hi</echo></target></project>";
- String formattedDoc = XmlFormatter.format(xmlDoc);
- String expected = "<project default=\"go\">\n\t<target name=\"go\"\n\t description=\"Demonstrate the wrapping of long tags.\">\n\t\t<echo>hi</echo>\n\t</target>\n</project>";
- assertEquals(expected, formattedDoc);
- }
-
- public final void testFormatWithPreferenceParameter() {
- FormattingPreferences prefs = new FormattingPreferences() {
- public boolean wrapLongTags() { return true;}
- public int getMaximumLineWidth() { return 40;}
- public boolean alignElementCloseChar() { return false;}
- public boolean useSpacesInsteadOfTabs() { return true;}
- public int getTabWidth() { return 6;}
- };
- String xmlDoc = "<project default=\"go\"><target name=\"go\" description=\"Demonstrate the wrapping of long tags.\"><echo>hi</echo></target></project>";
- String formattedDoc = XmlFormatter.format(xmlDoc, prefs);
- String expected = "<project default=\"go\">\n <target name=\"go\"\n description=\"Demonstrate the wrapping of long tags.\">\n <echo>hi</echo>\n </target>\n</project>";
- assertEquals(expected, formattedDoc);
- }
-
-}
diff --git a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/formatter/XmlTagFormatterTest.java b/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/formatter/XmlTagFormatterTest.java
deleted file mode 100644
index 6fffb4a4f..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/formatter/XmlTagFormatterTest.java
+++ /dev/null
@@ -1,391 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 John-Mason P. Shackelford and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * John-Mason P. Shackelford - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.ui.editor.formatter;
-
-import java.util.List;
-
-import org.eclipse.ant.internal.ui.editor.formatter.XmlTagFormatter;
-import org.eclipse.ant.internal.ui.editor.formatter.FormattingPreferences;
-import org.eclipse.ant.tests.ui.testplugin.AbstractAntUITest;
-
-/**
- *
- */
-public class XmlTagFormatterTest extends AbstractAntUITest {
-
- // TODO This test is too low level and too tightly coupled to internals.
-
- /* ---------------- Test Fixture ---------------- */
- // In case anyone wonders why many people recommend against testing
- // privates, I produce this example...
- private static class InnerClassFactory extends XmlTagFormatter {
-
- public static class ParseException extends
- XmlTagFormatter.ParseException {
-
- public ParseException(String message) {
- super(message);
- }
- }
-
- public static class Tag extends XmlTagFormatter.Tag {
- }
-
- public static class TagFormatter extends XmlTagFormatter.TagFormatter {
-
- public boolean lineRequiresWrap(String line, int lineWidth,
- int tabWidth) {
- return super.lineRequiresWrap(line, lineWidth, tabWidth);
- }
-
- public int tabExpandedLineWidth(String line, int tabWidth) {
- return super.tabExpandedLineWidth(line, tabWidth);
- }
-
- public String wrapTag(Tag tag, FormattingPreferences prefs,
- String indent) {
- return super.wrapTag(tag, prefs, indent);
- }
- }
-
- public static class TagParser extends XmlTagFormatter.TagParser {
-
- public String getElementName(String tagText)
- throws XmlTagFormatter.ParseException {
- return super.getElementName(tagText);
- }
-
- public List getAttibutes(String elementText)
- throws XmlTagFormatter.ParseException {
- return super.getAttibutes(elementText);
- }
- }
-
- public static Tag createTag() {
- return new Tag();
- }
-
- public static TagFormatter createTagFormatter() {
- return new TagFormatter();
- }
-
- public static TagParser createTagParser() {
- return new TagParser();
- }
-
- public static void validateAttributePair(Object attributePair, String attribute, String value) {
- XmlTagFormatter.AttributePair pair = (XmlTagFormatter.AttributePair) attributePair;
- assertEquals(attribute, pair.getAttribute());
- assertEquals(value, pair.getValue());
- }
- }
-
- /**
- * @param name
- */
- public XmlTagFormatterTest(String name) {
- super(name);
- }
-
- private FormattingPreferences getPreferences(final boolean wrapLongTags,
- final boolean alignCloseChar, final int maxLineWidth) {
-
- return new FormattingPreferences() {
-
- public boolean alignElementCloseChar() {
- return alignCloseChar;
- }
-
- public boolean wrapLongTags() {
- return wrapLongTags;
- }
-
- public int getMaximumLineWidth() {
- return maxLineWidth;
- }
- };
- }
-
- /**
- *
- */
- private void simpleTest(String source, String target,
- FormattingPreferences prefs, String indent) throws Exception {
-
- String result = XmlTagFormatter.format(source, prefs, indent);
- assertEquals(target, result);
- }
-
- /* ---------------- Test Methods ---------------- */
-
- public void testParserGetElementName() throws Exception {
-
- InnerClassFactory.TagParser tagParser = InnerClassFactory
- .createTagParser();
-
- String elementFixture1 = "<myElement attribute1=\"value1\" attribute2=\"value2\" />"; //$NON-NLS-1$
- assertEquals("myElement", tagParser.getElementName(elementFixture1)); //$NON-NLS-1$
-
- String elementFixture2 = "<myElement\t\nattribute1=\"value1\" attribute2=\"value2\" />"; //$NON-NLS-1$
- assertEquals("myElement", tagParser.getElementName(elementFixture2)); //$NON-NLS-1$
-
- assertEquals("x", tagParser.getElementName("<x/>")); //$NON-NLS-1$ //$NON-NLS-2$
- assertEquals("x", tagParser.getElementName("<x>")); //$NON-NLS-1$ //$NON-NLS-2$
- assertEquals("x:y", tagParser.getElementName("<x:y/>")); //$NON-NLS-1$ //$NON-NLS-2$
- assertEquals("x:y", tagParser.getElementName("<x:y abc/>")); //$NON-NLS-1$ //$NON-NLS-2$
-
- Exception e1 = null;
- try {
- tagParser.getElementName("<>"); //$NON-NLS-1$
- } catch (Exception e) {
- e1 = e;
- }
- assertNotNull(e1);
- assertTrue(e1.getClass().isAssignableFrom(
- InnerClassFactory.ParseException.class));
-
- Exception e2 = null;
- try {
- tagParser.getElementName("<>"); //$NON-NLS-1$
- } catch (Exception e) {
- e2 = e;
- }
- assertNotNull(e2);
- assertTrue(e2.getClass().isAssignableFrom(
- InnerClassFactory.ParseException.class));
-
- }
-
- public void testParserGetAttributes() throws Exception {
- InnerClassFactory.TagParser tagParser = InnerClassFactory
- .createTagParser();
-
- List attributePairs;
-
- // test normal situation
- attributePairs = tagParser
- .getAttibutes("<myElement attribute1=\"value1\" attribute2=\"value2\" />"); //$NON-NLS-1$
-
- assertEquals(2, attributePairs.size());
- InnerClassFactory.validateAttributePair(attributePairs.get(0),
- "attribute1", "value1"); //$NON-NLS-1$ //$NON-NLS-2$
- InnerClassFactory.validateAttributePair(attributePairs.get(1),
- "attribute2", "value2"); //$NON-NLS-1$ //$NON-NLS-2$
-
-
- // test with extra whitespace and funny quotes
- attributePairs = tagParser
- .getAttibutes("<myElement \nattribute1 = 'value1\"'\nattribute2\t=\"value2'\" />"); //$NON-NLS-1$
-
- assertEquals(2, attributePairs.size());
- InnerClassFactory.validateAttributePair(attributePairs.get(0),
- "attribute1", "value1\""); //$NON-NLS-1$ //$NON-NLS-2$
- InnerClassFactory.validateAttributePair(attributePairs.get(1),
- "attribute2", "value2'"); //$NON-NLS-1$ //$NON-NLS-2$
-
-// TODO attributes which contain whitespace should throw a parse error
-//
-// // test parse errors - whitespace in attribute name
-// Exception e1 = null;
-// try {
-// attributePairs = tagParser
-// .getAttibutes("<myElement at tribute1 = \"value1\" attribute2=\"value2\" />");
-// } catch (Exception e) {
-// e1 = e;
-// }
-// assertNotNull(e1);
-// assertTrue(e1.getClass().isAssignableFrom(
-// InnerClassFactory.ParseException.class));
-
-
- // test parse errors - equals in the wrong place
- Exception e2 = null;
- try {
- attributePairs = tagParser
- .getAttibutes("<myElement attribute1=\"value1\" = attribute2=\"value2\" />"); //$NON-NLS-1$
- } catch (Exception e) {
- e2 = e;
- }
- assertNotNull(e2);
- assertTrue(e2.getClass().isAssignableFrom(
- InnerClassFactory.ParseException.class));
-
-
- // test parse errors - quotes in the wrong place
- Exception e3 = null;
- try {
- attributePairs = tagParser
- .getAttibutes("<myElement attribute1=\"\"value1\" attribute2=\"value2\" />"); //$NON-NLS-1$
- } catch (Exception e) {
- e3 = e;
- }
- assertNotNull(e3);
- assertTrue(e3.getClass().isAssignableFrom(
- InnerClassFactory.ParseException.class));
-
-
- }
-
- /**
- *
- */
- public void testFormat01() throws Exception {
- String indent = "\t"; //$NON-NLS-1$
- String source = "<target name=\"myTargetName\" depends=\"a,b,c,d,e,f,g\" description=\"This is a very long element which ought to be wrapped.\">"; //$NON-NLS-1$
- String target = "<target name=\"myTargetName\"\n" //$NON-NLS-1$
- + indent
- + " depends=\"a,b,c,d,e,f,g\"\n" //$NON-NLS-1$
- + indent
- + " description=\"This is a very long element which ought to be wrapped.\">"; //$NON-NLS-1$
-
- simpleTest(source, target, getPreferences(true, false, 60), indent);
- }
-
- /**
- *
- */
- public void testFormat02() throws Exception {
- String indent = "\t"; //$NON-NLS-1$
- String source = "<target name=\"myTargetName\" depends=\"a,b,c,d,e,f,g\" description=\"This is a very long element which ought to be wrapped.\">"; //$NON-NLS-1$
- String target = "<target name=\"myTargetName\"\n" //$NON-NLS-1$
- + indent
- + " depends=\"a,b,c,d,e,f,g\"\n" //$NON-NLS-1$
- + indent
- + " description=\"This is a very long element which ought to be wrapped.\"\n" //$NON-NLS-1$
- + indent + ">"; //$NON-NLS-1$
-
- simpleTest(source, target, getPreferences(true, true, 60), indent);
- }
-
- /**
- *
- */
- public void testLineRequiresWrap() throws Exception {
-
- InnerClassFactory.TagFormatter tagFormatter = InnerClassFactory
- .createTagFormatter();
-
- boolean shouldWrap = tagFormatter
- .lineRequiresWrap(
- "\t\t <myElement attribute1=\"value1\" attribute2=\"value2\" />", //$NON-NLS-1$
- 70, 8);
- boolean shouldNotWrap = tagFormatter
- .lineRequiresWrap(
- "\t\t <myElement attribute1=\"value1\" attribute2=\"value2\" />", //$NON-NLS-1$
- 70, 8);
- assertTrue(shouldWrap);
- assertTrue(!shouldNotWrap);
-
- }
-
- /**
- *
- */
- public void testTabExpandedLineWidth() throws Exception {
-
- InnerClassFactory.TagFormatter tagFormatter = InnerClassFactory
- .createTagFormatter();
-
- assertEquals(20, tagFormatter.tabExpandedLineWidth("\t 1234567890", 8)); //$NON-NLS-1$
- assertEquals(10, tagFormatter.tabExpandedLineWidth("1234567890", 8)); //$NON-NLS-1$
- assertEquals(19, tagFormatter
- .tabExpandedLineWidth("\t1\t2 34567890", 3)); //$NON-NLS-1$
- }
-
- public void testTabToStringAndMinimumLength() throws Exception {
- InnerClassFactory.Tag tag = InnerClassFactory.createTag();
-
- tag.setElementName("myElement"); //$NON-NLS-1$
- tag.setClosed(false);
- assertEquals("<myElement>", tag.toString()); //$NON-NLS-1$
- assertEquals(tag.toString().length(), tag.minimumLength());
-
- tag.setClosed(true);
- assertEquals("<myElement />", tag.toString()); //$NON-NLS-1$
- assertEquals(tag.toString().length(), tag.minimumLength());
-
- tag.addAttribute("attribute1", "value1"); //$NON-NLS-1$ //$NON-NLS-2$
- tag.addAttribute("attribute2", "value2"); //$NON-NLS-1$ //$NON-NLS-2$
- assertEquals(
- "<myElement attribute1=\"value1\" attribute2=\"value2\" />", //$NON-NLS-1$
- tag.toString());
- assertEquals(tag.toString().length(), tag.minimumLength());
-
- tag.setClosed(false);
- assertEquals("<myElement attribute1=\"value1\" attribute2=\"value2\">", //$NON-NLS-1$
- tag.toString());
- assertEquals(tag.toString().length(), tag.minimumLength());
- }
-
- /**
- *
- */
- public void testWrapTag() throws Exception {
-
- InnerClassFactory.Tag tag = InnerClassFactory.createTag();
-
- InnerClassFactory.TagFormatter tagFormatter = InnerClassFactory
- .createTagFormatter();
-
- FormattingPreferences dontAlignCloseChar = new FormattingPreferences() {
-
- public boolean alignElementCloseChar() {
- return false;
- }
- };
- FormattingPreferences doAlignCloseChar = new FormattingPreferences() {
-
- public boolean alignElementCloseChar() {
- return true;
- }
- };
-
- tag.setElementName("myElement"); //$NON-NLS-1$
- tag.addAttribute("attribute1", "value1"); //$NON-NLS-1$ //$NON-NLS-2$
- tag.addAttribute("attribute2", "value2"); //$NON-NLS-1$ //$NON-NLS-2$
-
- tag.setClosed(true);
-
- assertEquals("<myElement attribute1=\"value1\"\n" //$NON-NLS-1$
- + "\t\t attribute2=\"value2\" />", tagFormatter //$NON-NLS-1$
- .wrapTag(tag, dontAlignCloseChar, "\t\t ")); //$NON-NLS-1$
-
- assertEquals("<myElement attribute1=\"value1\"\n" //$NON-NLS-1$
- + "\t\t attribute2=\"value2\"\n\t\t />", //$NON-NLS-1$
- tagFormatter.wrapTag(tag, doAlignCloseChar, "\t\t ")); //$NON-NLS-1$
-
- tag.setClosed(false);
-
- assertEquals("<myElement attribute1=\"value1\"\n" //$NON-NLS-1$
- + "\t\t attribute2=\"value2\">", tagFormatter //$NON-NLS-1$
- .wrapTag(tag, dontAlignCloseChar, "\t\t ")); //$NON-NLS-1$
-
- assertEquals("<myElement attribute1=\"value1\"\n" //$NON-NLS-1$
- + "\t\t attribute2=\"value2\"\n\t\t >", //$NON-NLS-1$
- tagFormatter.wrapTag(tag, doAlignCloseChar, "\t\t ")); //$NON-NLS-1$
-
- }
-
- public void testBug63558() throws Exception {
-
- // Ordinarily the double space after the element name would be repaired
- // but if the formatter is working correctly these examples will be
- // considered malformed and will be passed through untouched.
-
- String source1 = "<echo file=\"foo\">\n&lt;html>&lt;body>&lt;pre>" //$NON-NLS-1$
- + "${compilelog}&lt;/pre>&lt;/body>&lt;/html>"; //$NON-NLS-1$
- FormattingPreferences prefs = getPreferences(true, false, 60); //$NON-NLS-1$
- simpleTest(source1, source1, prefs, "\t");
-
- String source2 = "<echo file=\"foo\"/bar/baz></echo>"; //$NON-NLS-1$
- simpleTest(source2, source2, prefs, "\t");
- }
-}
diff --git a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/support/TestEditor.java b/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/support/TestEditor.java
deleted file mode 100644
index 5aa6c93c1..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/support/TestEditor.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.ant.tests.ui.editor.support;
-
-import org.eclipse.ant.internal.ui.editor.AntEditor;
-
-public class TestEditor extends AntEditor {
-
- TestEditor() {
- }
-
- public void initializeEditor() {
- }
- /**
- * Returns '10'.
- * @see org.eclipse.ui.texteditor.AbstractTextEditor#getCursorPosition()
- */
- protected String getCursorPosition() {
- return "10";
- }
-
-} \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/support/TestLocationProvider.java b/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/support/TestLocationProvider.java
deleted file mode 100644
index de85de334..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/support/TestLocationProvider.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.ant.tests.ui.editor.support;
-
-import java.io.File;
-
-import org.eclipse.ant.internal.ui.editor.outline.LocationProvider;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.Path;
-
-
-public class TestLocationProvider extends LocationProvider {
-
- private File buildFile;
-
- public TestLocationProvider(File buildFile) {
- super(null);
- this.buildFile= buildFile;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.ant.internal.ui.editor.outline.ILocationProvider#getLocation()
- */
- public IPath getLocation() {
- return new Path(buildFile.getAbsolutePath());
- }
-} \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/support/TestProblemRequestor.java b/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/support/TestProblemRequestor.java
deleted file mode 100644
index 12378d0ca..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/support/TestProblemRequestor.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.ant.tests.ui.editor.support;
-
-import org.eclipse.ant.internal.ui.editor.outline.IProblem;
-import org.eclipse.ant.internal.ui.editor.outline.IProblemRequestor;
-
-public class TestProblemRequestor implements IProblemRequestor {
-
- /* (non-Javadoc)
- * @see org.eclipse.ant.internal.ui.editor.outline.IProblemRequestor#acceptProblem(org.eclipse.ant.internal.ui.editor.outline.IProblem)
- */
- public void acceptProblem(IProblem problem) {
-
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.ant.internal.ui.editor.outline.IProblemRequestor#beginReporting()
- */
- public void beginReporting() {
-
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.ant.internal.ui.editor.outline.IProblemRequestor#endReporting()
- */
- public void endReporting() {
-
- }
-}
diff --git a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/support/TestTextCompletionProcessor.java b/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/support/TestTextCompletionProcessor.java
deleted file mode 100644
index fd651cb92..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant Editor Tests/org/eclipse/ant/tests/ui/editor/support/TestTextCompletionProcessor.java
+++ /dev/null
@@ -1,167 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.ant.tests.ui.editor.support;
-
-import java.io.File;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Collection;
-
-import junit.framework.Assert;
-
-import org.eclipse.ant.internal.ui.editor.AntEditorCompletionProcessor;
-import org.eclipse.ant.internal.ui.editor.outline.AntModel;
-import org.eclipse.jface.text.Document;
-import org.eclipse.jface.text.IDocument;
-import org.eclipse.jface.text.contentassist.ICompletionProposal;
-import org.w3c.dom.Element;
-
-public class TestTextCompletionProcessor extends AntEditorCompletionProcessor {
-
- public final static int TEST_PROPOSAL_MODE_NONE = AntEditorCompletionProcessor.PROPOSAL_MODE_NONE;
- public final static int TEST_PROPOSAL_MODE_BUILDFILE = AntEditorCompletionProcessor.PROPOSAL_MODE_BUILDFILE;
- public final static int TEST_PROPOSAL_MODE_TASK_PROPOSAL = AntEditorCompletionProcessor.PROPOSAL_MODE_TASK_PROPOSAL;
- public final static int TEST_PROPOSAL_MODE_PROPERTY_PROPOSAL = AntEditorCompletionProcessor.PROPOSAL_MODE_PROPERTY_PROPOSAL;
- public final static int TEST_PROPOSAL_MODE_ATTRIBUTE_PROPOSAL = AntEditorCompletionProcessor.PROPOSAL_MODE_ATTRIBUTE_PROPOSAL;
- public final static int TEST_PROPOSAL_MODE_TASK_PROPOSAL_CLOSING = AntEditorCompletionProcessor.PROPOSAL_MODE_TASK_PROPOSAL_CLOSING;
- public final static int TEST_PROPOSAL_MODE_ATTRIBUTE_VALUE_PROPOSAL = AntEditorCompletionProcessor.PROPOSAL_MODE_ATTRIBUTE_VALUE_PROPOSAL;
-
- private File editedFile;
-
- public TestTextCompletionProcessor(AntModel model) {
- super(model);
- }
-
- public TestTextCompletionProcessor() {
- super(null);
- }
-
- public ICompletionProposal[] getAttributeProposals(String taskName, String prefix) {
- if (cursorPosition == -1) {
- cursorPosition= taskName.length();
- }
- return super.getAttributeProposals(taskName, prefix);
- }
-
- public Element findChildElementNamedOf(Element anElement, String childElementName) {
- return super.findChildElementNamedOf(anElement, childElementName);
- }
-
- public ICompletionProposal[] getTaskProposals(String text, String parentName, String prefix) {
- cursorPosition= Math.max(0, text.length() - 1);
- return super.getTaskProposals(new Document(text), parentName, prefix);
- }
-
- public ICompletionProposal[] getTaskProposals(IDocument document, String parentName, String aPrefix) {
- cursorPosition= Math.max(0, document.getLength() - 1);
- return super.getTaskProposals(document, parentName, aPrefix);
- }
-
- //TODO add template proposal testing
- protected Collection getTemplateProposals(IDocument document, String prefix) {
- return new ArrayList();
- }
-
- public int determineProposalMode(String text, int theCursorPosition, String prefix) {
- return super.determineProposalMode(new Document(text), theCursorPosition, prefix);
- }
-
- public String getParentName(String text, int aLineNumber, int aColumnNumber) {
- return super.getParentName(new Document(text), aLineNumber, aColumnNumber);
- }
-
- public String getParentName(IDocument doc, int aLineNumber, int aColumnNumber) {
- return super.getParentName(doc, aLineNumber, aColumnNumber);
- }
-
- public String getPrefixFromDocument(String aDocumentText, int anOffset) {
- String prefix= super.getPrefixFromDocument(aDocumentText, anOffset);
- currentPrefix= null;
- return prefix;
- }
-
- public ICompletionProposal[] getPropertyProposals(IDocument document, String prefix, int cursorPos) {
- return super.getPropertyProposals(document, prefix, cursorPos);
- }
-
- /**
- * Returns the edited File that org.eclipse.ant.internal.ui.editor.AntEditorCompletionProcessor sets or a temporary
- * file, which only serves as a dummy.
- * @see org.eclipse.ant.internal.ui.editor.AntEditorCompletionProcessor#getEditedFile()
- */
- public File getEditedFile() {
- if (editedFile != null){
- return editedFile;
- }
- File tempFile = null;
- try {
- tempFile = File.createTempFile("test", null);
- } catch (IOException e) {
- Assert.fail(e.getMessage());
- }
- tempFile.deleteOnExit();
- return tempFile;
- }
-
- public void setLineNumber(int aLineNumber) {
- lineNumber = aLineNumber;
- }
-
- public void setColumnNumber(int aColumnNumber) {
- columnNumber = aColumnNumber;
- }
-
- public void setCursorPosition(int cursorPosition) {
- this.cursorPosition = cursorPosition;
- }
-
- public void setEditedFile(File aFile) {
- editedFile= aFile;
- }
- /* (non-Javadoc)
- * @see org.eclipse.ant.internal.ui.editor.AntEditorCompletionProcessor#getTargetAttributeValueProposals(org.eclipse.jface.text.IDocument, java.lang.String, java.lang.String, java.lang.String)
- */
- public ICompletionProposal[] getTargetAttributeValueProposals(IDocument document, String textToSearch, String prefix, String attributeName) {
- return super.getTargetAttributeValueProposals(document, textToSearch, prefix, attributeName);
- }
- /**
- * Since the testing occurs without necessarily having an associated viewer, return
- * a dummy value.
- */
- protected char getPreviousChar() {
- return '?';
- }
-
- /**
- * Returns whether the specified task name is known.
- */
- protected boolean isKnownElement(String elementName) {
- if (antModel != null) {
- return super.isKnownElement(elementName);
- }
- return dtd.getElement(elementName) != null ;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.ant.internal.ui.editor.AntEditorCompletionProcessor#getProposalsFromDocument(org.eclipse.jface.text.IDocument, java.lang.String)
- */
- public ICompletionProposal[] getProposalsFromDocument(IDocument document, String prefix) {
- return super.getProposalsFromDocument(document, prefix);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.ant.internal.ui.editor.AntEditorCompletionProcessor#getBuildFileProposals(org.eclipse.jface.text.IDocument, java.lang.String)
- */
- public ICompletionProposal[] getBuildFileProposals(String text, String prefix) {
- return super.getBuildFileProposals(new Document(text), prefix);
- }
-} \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/Ant Tests/org/eclipse/ant/tests/ui/AbstractAntUIBuildTest.java b/ant/org.eclipse.ant.tests.ui/Ant Tests/org/eclipse/ant/tests/ui/AbstractAntUIBuildTest.java
deleted file mode 100644
index cb1f2449b..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant Tests/org/eclipse/ant/tests/ui/AbstractAntUIBuildTest.java
+++ /dev/null
@@ -1,91 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.ant.tests.ui;
-
-import junit.framework.TestResult;
-
-import org.eclipse.ant.tests.ui.testplugin.AbstractAntUITest;
-import org.eclipse.ant.tests.ui.testplugin.ConsoleLineTracker;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.debug.ui.console.IConsoleHyperlink;
-import org.eclipse.swt.widgets.Display;
-
-
-public abstract class AbstractAntUIBuildTest extends AbstractAntUITest {
-
- /**
- * Flag that indicates test are in progress
- */
- protected boolean testing = true;
-
- public AbstractAntUIBuildTest(String name) {
- super(name);
- }
-
- /**
- * Runs the test and collects the result in a TestResult without blocking
- * the UI thread.
- */
- public void run(final TestResult result) {
- final Display display = Display.getCurrent();
- Thread thread = null;
- try {
- Runnable r = new Runnable() {
- public void run() {
- AbstractAntUIBuildTest.super.run(result);
- testing = false;
- display.wake();
- }
- };
- thread = new Thread(r);
- thread.start();
- } catch (Exception e) {
- e.printStackTrace();
- }
-
- while (testing) {
- try {
- if (!display.readAndDispatch())
- display.sleep();
- } catch (Throwable e) {
- e.printStackTrace();
- }
- }
- }
-
- /**
- * Launches the Ant build with the buildfile name (no extension).
- * Waits for all of the lines to be appended to the console.
- *
- * @param mainTypeName the program to launch
- * @return thread in which the first suspend event occurred
- */
- protected void launch(String buildFileName) throws CoreException {
- super.launch(buildFileName);
- ConsoleLineTracker.waitForConsole();
- }
-
- protected void activateLink(final IConsoleHyperlink link) {
- Display.getDefault().asyncExec(new Runnable() {
- public void run() {
- link.linkActivated();
- }
- });
- }
- /* (non-Javadoc)
- * @see org.eclipse.ant.tests.ui.testplugin.AbstractAntUITest#launch(java.lang.String, java.lang.String)
- */
- protected void launch(String buildFileName, String arguments) throws CoreException {
- super.launch(buildFileName, arguments);
- ConsoleLineTracker.waitForConsole();
- }
-}
diff --git a/ant/org.eclipse.ant.tests.ui/Ant Tests/org/eclipse/ant/tests/ui/BuildTests.java b/ant/org.eclipse.ant.tests.ui/Ant Tests/org/eclipse/ant/tests/ui/BuildTests.java
deleted file mode 100644
index a94563ff0..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant Tests/org/eclipse/ant/tests/ui/BuildTests.java
+++ /dev/null
@@ -1,171 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.ant.tests.ui;
-
-import org.eclipse.ant.internal.ui.model.AntUIPlugin;
-import org.eclipse.ant.internal.ui.model.IAntUIPreferenceConstants;
-import org.eclipse.ant.tests.ui.testplugin.ConsoleLineTracker;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.debug.ui.console.IConsoleHyperlink;
-import org.eclipse.jface.text.BadLocationException;
-import org.eclipse.swt.graphics.Color;
-
-
-public class BuildTests extends AbstractAntUIBuildTest {
-
- public BuildTests(String name) {
- super(name);
- }
-
- /**
- * Tests launching Ant and getting messages
- * logged to the console.
- */
- public void testOutput() throws CoreException {
- launch("echoing");
- assertTrue("Incorrect number of messages logged for build. Should be 8. Was " + ConsoleLineTracker.getNumberOfMessages(), ConsoleLineTracker.getNumberOfMessages() == 8);
- String message= ConsoleLineTracker.getMessage(6);
- assertTrue("Incorrect last message. Should start with Total time:. Message: " + message, message.startsWith("Total time:"));
- }
-
- /**
- * Tests launching Ant and getting the build failed message
- * logged to the console with associated link.
- * Bug 42333 and 44565
- */
- public void testBuildFailedMessage() throws CoreException {
- launch("bad");
- assertTrue("Incorrect number of messages logged for build. Should be 7. Was " + ConsoleLineTracker.getNumberOfMessages(), ConsoleLineTracker.getNumberOfMessages() == 7);
- String message= ConsoleLineTracker.getMessage(4);
- assertTrue("Incorrect last message. Should start with Build Failed:. Message: " + message, message.startsWith("BUILD FAILED:"));
- int offset= -1;
- try {
- offset= ConsoleLineTracker.getDocument().getLineOffset(4) + 30; //link to buildfile that failed
- } catch (BadLocationException e) {
- assertTrue("failed getting offset of line", false);
- }
- IConsoleHyperlink link= getHyperlink(offset, ConsoleLineTracker.getDocument());
- assertNotNull("No hyperlink found at offset " + offset, link);
- }
-
- /**
- * Tests launching Ant and that the
- * correct links are in the console doc
- */
- public void testLinks() throws CoreException {
- launch("build");
- int offset= 25; //buildfile link
- IConsoleHyperlink link= getHyperlink(offset, ConsoleLineTracker.getDocument());
- assertNotNull("No hyperlink found at offset " + offset, link);
- activateLink(link);
-
- try {
- offset= ConsoleLineTracker.getDocument().getLineOffset(4) + 10; //echo link
- } catch (BadLocationException e) {
- assertTrue("failed getting offset of line", false);
- }
- link= getHyperlink(offset, ConsoleLineTracker.getDocument());
- assertNotNull("No hyperlink found at offset " + offset, link);
- activateLink(link);
- }
-
- /**
- * Tests launching Ant and that the
- * correct colors are in the console doc
- */
- public void testColor() throws BadLocationException, CoreException {
- launch("echoing");
- int offset= 15; //buildfile
- Color color= getColorAtOffset(offset, ConsoleLineTracker.getDocument());
- assertNotNull("No color found at " + offset, color);
- assertEquals(AntUIPlugin.getPreferenceColor(IAntUIPreferenceConstants.CONSOLE_INFO_COLOR), color);
- try {
- offset= ConsoleLineTracker.getDocument().getLineOffset(4) + 10; //echo
- } catch (BadLocationException e) {
- assertTrue("failed getting offset of line", false);
- }
- color= getColorAtOffset(offset, ConsoleLineTracker.getDocument());
- assertNotNull("No color found at " + offset, color);
- assertEquals(AntUIPlugin.getPreferenceColor(IAntUIPreferenceConstants.CONSOLE_WARNING_COLOR), color);
- }
-
- /**
- * Tests launching Ant and getting the build failed message
- * logged to the console.
- * Bug 42333.
- */
-// public void testBuildFailedMessageDebug() throws CoreException {
-// launchInDebug("bad");
-// assertTrue("Incorrect number of messages logged for build. Should be 35. Was " + ConsoleLineTracker.getNumberOfMessages(), ConsoleLineTracker.getNumberOfMessages() == 35);
-// String message= ConsoleLineTracker.getMessage(33);
-// assertTrue("Incorrect last message. Should start with Build Failed:. Message: " + message, message.startsWith("BUILD FAILED:"));
-// }
-//
-// /**
-// * Tests launching Ant and that the
-// * correct links are in the console doc
-// */
-// public void testLinksDebug() throws CoreException {
-// launchInDebug("echoing");
-// int offset= 0;
-// try {
-// offset= ConsoleLineTracker.getDocument().getLineOffset(2) + 15; //buildfile line 3
-// } catch (BadLocationException e) {
-// assertTrue("failed getting offset of line", false);
-// }
-// IConsoleHyperlink link= getHyperlink(offset, ConsoleLineTracker.getDocument());
-// assertNotNull("No hyperlink found at offset " + offset, link);
-//
-// try {
-// offset= ConsoleLineTracker.getDocument().getLineOffset(33) + 10; //echo link
-// } catch (BadLocationException e) {
-// assertTrue("failed getting offset of line", false);
-// }
-// link= getHyperlink(offset, ConsoleLineTracker.getDocument());
-// assertNotNull("No hyperlink found at offset " + offset, link);
-// }
-//
-// /**
-// * Tests launching Ant and that the
-// * correct colors are in the console doc
-// */
-// public void testColorDebug() throws BadLocationException, CoreException {
-// launchInDebug("echoing");
-// int offset= 0;
-// try {
-// offset= ConsoleLineTracker.getDocument().getLineOffset(2) + 15; //buildfile line 3
-// } catch (BadLocationException e) {
-// assertTrue("failed getting offset of line", false);
-// }
-// Color color= getColorAtOffset(offset, ConsoleLineTracker.getDocument());
-// assertNotNull("No color found at " + offset, color);
-// assertEquals(AntUIPlugin.getPreferenceColor(IAntUIPreferenceConstants.CONSOLE_INFO_COLOR), color);
-//
-// try {
-// offset= ConsoleLineTracker.getDocument().getLineOffset(4) + 3; //debug info
-// } catch (BadLocationException e) {
-// assertTrue("failed getting offset of line", false);
-// }
-// color= getColorAtOffset(offset, ConsoleLineTracker.getDocument());
-// assertNotNull("No color found at " + offset, color);
-// assertEquals(AntUIPlugin.getPreferenceColor(IAntUIPreferenceConstants.CONSOLE_DEBUG_COLOR), color);
-//
-// try {
-// offset= ConsoleLineTracker.getDocument().getLineOffset(33) + 10; //echo line 33
-// } catch (BadLocationException e) {
-// assertTrue("failed getting offset of line", false);
-// }
-// color= getColorAtOffset(offset, ConsoleLineTracker.getDocument());
-// assertNotNull("No color found at " + offset, color);
-// assertEquals(AntUIPlugin.getPreferenceColor(IAntUIPreferenceConstants.CONSOLE_WARNING_COLOR), color);
-// }
-} \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/Ant Tests/org/eclipse/ant/tests/ui/separateVM/SeparateVMTests.java b/ant/org.eclipse.ant.tests.ui/Ant Tests/org/eclipse/ant/tests/ui/separateVM/SeparateVMTests.java
deleted file mode 100644
index 7c9cfef8f..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant Tests/org/eclipse/ant/tests/ui/separateVM/SeparateVMTests.java
+++ /dev/null
@@ -1,151 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.ant.tests.ui.separateVM;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-import org.eclipse.ant.internal.ui.launchConfigurations.IAntLaunchConfigurationConstants;
-import org.eclipse.ant.internal.ui.model.AntUIPlugin;
-import org.eclipse.ant.internal.ui.model.IAntUIPreferenceConstants;
-import org.eclipse.ant.tests.ui.AbstractAntUIBuildTest;
-import org.eclipse.ant.tests.ui.testplugin.ConsoleLineTracker;
-import org.eclipse.ant.tests.ui.testplugin.ProjectHelper;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.debug.core.ILaunchConfiguration;
-import org.eclipse.debug.core.ILaunchConfigurationWorkingCopy;
-import org.eclipse.debug.ui.console.IConsoleHyperlink;
-import org.eclipse.jdt.launching.IJavaLaunchConfigurationConstants;
-import org.eclipse.jface.text.BadLocationException;
-import org.eclipse.swt.graphics.Color;
-
-public class SeparateVMTests extends AbstractAntUIBuildTest {
-
- public SeparateVMTests(String name) {
- super(name);
- }
-
- public static Test suite() {
- return new TestSuite(SeparateVMTests.class);
- }
-
- /**
- * Tests launching Ant in a separate vm and getting messages
- * logged to the console.
- */
- public void testBuild() throws CoreException {
- launch("echoingSepVM");
- assertTrue("Incorrect number of messages logged for build. Should be 6. Was " + ConsoleLineTracker.getNumberOfMessages(), ConsoleLineTracker.getNumberOfMessages() == 6);
- assertTrue("Incorrect last message. Should start with Total time:. Message: " + ConsoleLineTracker.getMessage(4), ConsoleLineTracker.getMessage(4).startsWith("Total time:"));
- }
-
- /**
- * Tests launching Ant in a separate vm and having an extra classpath entry designated to be availble.
- */
- public void testExtraClasspathEntries() throws CoreException {
- launch("extensionPointSepVM");
- assertTrue("Incorrect number of messages logged for build. Should be 8. Was " + ConsoleLineTracker.getNumberOfMessages(), ConsoleLineTracker.getNumberOfMessages() == 8);
- assertTrue("Incorrect last message. Should start with Total time:. Message: " + ConsoleLineTracker.getMessage(6), ConsoleLineTracker.getMessage(6).startsWith("Total time:"));
- }
-
- /**
- * Tests launching Ant in a separate vm and having an extra classpath entry designated to be available.
- */
- public void testProperties() throws CoreException {
- launch("extensionPointSepVM");
- assertTrue("Incorrect number of messages logged for build. Should be 8. Was " + ConsoleLineTracker.getNumberOfMessages(), ConsoleLineTracker.getNumberOfMessages() == 8);
- assertTrue("Incorrect last message. Should start with [echo] ${property.ui.testing. Message: " + ConsoleLineTracker.getMessage(3), ConsoleLineTracker.getMessage(3).trim().startsWith("[echo] ${property.ui.testing"));
- assertTrue("Incorrect last message. Should start with [echo] hey. Message: " + ConsoleLineTracker.getMessage(4), ConsoleLineTracker.getMessage(4).trim().startsWith("[echo] hey"));
- }
-
- /**
- * Tests launching Ant in a separate vm and having an extra classpath entry designated to be available.
- */
- public void testExtensionPointTask() throws CoreException {
- launch("extensionPointTaskSepVM");
- assertTrue("Incorrect number of messages logged for build. Should be 6. Was " + ConsoleLineTracker.getNumberOfMessages(), ConsoleLineTracker.getNumberOfMessages() == 6);
- assertTrue("Incorrect message. Should start with [null] Testing Ant in Eclipse with a custom task2. Message: " + ConsoleLineTracker.getMessage(2), ConsoleLineTracker.getMessage(2).trim().startsWith("[null] Testing Ant in Eclipse with a custom task2"));
- }
-
- /**
- * Tests launching Ant in a separate vm and having an extra classpath entry designated to be available.
- */
- public void testExtensionPointType() throws CoreException {
- launch("extensionPointTypeSepVM");
- assertTrue("Incorrect number of messages logged for build. Should be 6. Was " + ConsoleLineTracker.getNumberOfMessages(), ConsoleLineTracker.getNumberOfMessages() == 6);
- assertTrue("Incorrect message. Should start with [echo] Ensure that an extension point defined type. Message: " + ConsoleLineTracker.getMessage(2), ConsoleLineTracker.getMessage(2).trim().startsWith("[echo] Ensure that an extension point defined type"));
- }
-
- /**
- * Tests launching Ant in a separate vm and that the
- * correct links are in the console doc
- */
- public void testLinks() throws CoreException {
- launch("echoingSepVM");
- int offset= 15; //buildfile link
- IConsoleHyperlink link= getHyperlink(offset, ConsoleLineTracker.getDocument());
- assertNotNull("No hyperlink found at offset " + offset, link);
- try {
- offset= ConsoleLineTracker.getDocument().getLineOffset(2) + 10; //echo link
- } catch (BadLocationException e) {
- assertTrue("failed getting offset of line", false);
- }
- link= getHyperlink(offset, ConsoleLineTracker.getDocument());
- assertNotNull("No hyperlink found at offset " + offset, link);
- }
-
- /**
- * Tests launching Ant in a separate vm and that the
- * correct colors are in the console doc
- */
- public void testColor() throws BadLocationException, CoreException {
- launch("echoingSepVM");
- int offset= 15; //buildfile
- Color color= getColorAtOffset(offset, ConsoleLineTracker.getDocument());
- assertNotNull("No color found at " + offset, color);
- assertEquals(color, AntUIPlugin.getPreferenceColor(IAntUIPreferenceConstants.CONSOLE_INFO_COLOR));
- try {
- offset= ConsoleLineTracker.getDocument().getLineOffset(2) + 10; //echo link
- } catch (BadLocationException e) {
- assertTrue("failed getting offset of line", false);
- }
- color= getColorAtOffset(offset, ConsoleLineTracker.getDocument());
- assertNotNull("No color found at " + offset, color);
- assertEquals(color, AntUIPlugin.getPreferenceColor(IAntUIPreferenceConstants.CONSOLE_WARNING_COLOR));
- }
-
- /**
- * Tests launching Ant in a separate vm and that the
- * correct working directory is set
- */
- public void testWorkingDirectory() throws CoreException {
- ILaunchConfiguration config = getLaunchConfiguration("echoingSepVM");
- assertNotNull("Could not locate launch configuration for " + "echoingSepVM", config);
- ILaunchConfigurationWorkingCopy copy= config.getWorkingCopy();
- copy.setAttribute(IJavaLaunchConfigurationConstants.ATTR_WORKING_DIRECTORY, getJavaProject().getProject().getLocation().toOSString());
- copy.setAttribute(IAntLaunchConfigurationConstants.ATTR_ANT_TARGETS, "Bug42984");
- launchAndTerminate(copy, 20000);
- ConsoleLineTracker.waitForConsole();
- assertTrue("Incorrect number of messages logged for build. Should be 6. Was " + ConsoleLineTracker.getNumberOfMessages(), ConsoleLineTracker.getNumberOfMessages() == 6);
- assertTrue("Incorrect last message. Should end with " + ProjectHelper.PROJECT_NAME + ". Message: " + ConsoleLineTracker.getMessage(2), ConsoleLineTracker.getMessage(2).endsWith(ProjectHelper.PROJECT_NAME));
- }
-
- /**
- * Tests launching Ant in a separate vm and getting messages
- * logged to the console for project help.
- */
- public void testProjectHelp() throws CoreException {
- launch("echoingSepVM", "-p");
- assertTrue("Incorrect number of messages logged for build. Should be 14. Was " + ConsoleLineTracker.getNumberOfMessages(), ConsoleLineTracker.getNumberOfMessages() == 14);
- assertTrue("Incorrect last message. Should start with echo2:. Message: " + ConsoleLineTracker.getMessage(12), ConsoleLineTracker.getMessage(12).trim().startsWith("echo2"));
- }
-} \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Ext Dir Test Example/.project b/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Ext Dir Test Example/.project
deleted file mode 100644
index 7faea7143..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Ext Dir Test Example/.project
+++ /dev/null
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>AntView ExtDir Test</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- </buildSpec>
- <natures>
- </natures>
-</projectDescription>
diff --git a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Ext Dir Test Example/build.xml b/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Ext Dir Test Example/build.xml
deleted file mode 100644
index a733ad3a5..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Ext Dir Test Example/build.xml
+++ /dev/null
@@ -1,15 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project name="External Dir Test" basedir="." default="test-one">
- <target name="init">
- <echo message="Init"/>
- </target>
- <target name="test-one" depends="init,test-two">
- <echo message="One - multiple dependents"/>
- </target>
- <target name="test-two" depends="init,test-three">
- <echo message="Two - similar dependencies"/>
- </target>
- <target name="test-three">
- <echo message="Three - simple"/>
- </target>
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Ext Dir Test Example/readme.txt b/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Ext Dir Test Example/readme.txt
deleted file mode 100644
index d43b15a1e..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Ext Dir Test Example/readme.txt
+++ /dev/null
@@ -1,4 +0,0 @@
-
-Create a new simple project with project directory outside ECLIPSE_HOME
-
-import this directory. \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/.classpath b/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/.classpath
deleted file mode 100644
index 24fb4882c..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/.classpath
+++ /dev/null
@@ -1,6 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
- <classpathentry kind="src" path=""/>
- <classpathentry kind="var" path="JRE_LIB" rootpath="JRE_SRCROOT" sourcepath="JRE_SRC"/>
- <classpathentry kind="output" path=""/>
-</classpath>
diff --git a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/.project b/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/.project
deleted file mode 100644
index 4ad8ae913..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>AntView Java Test</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.jdt.core.javabuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.eclipse.jdt.core.javanature</nature>
- </natures>
-</projectDescription>
diff --git a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/bin.log b/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/bin.log
deleted file mode 100644
index e3b4fe51a..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/bin.log
+++ /dev/null
@@ -1,2 +0,0 @@
-Compiled 13 lines in 991 ms (13.1 lines/s)
-1 .class file generated \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/bin/main.class b/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/bin/main.class
deleted file mode 100644
index 820d96c4e..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/bin/main.class
+++ /dev/null
Binary files differ
diff --git a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/build.xml b/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/build.xml
deleted file mode 100644
index 7aab35264..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/build.xml
+++ /dev/null
@@ -1,40 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project name="Java Compile Test" basedir="." default="compile">
- <target name="properties" if="eclipse.running">
- <property name="build.compiler" value="org.eclipse.jdt.core.JDTCompilerAdapter"/>
- </target>
- <target name="compile" depends="properties,env">
- <javac destdir="bin" failonerror="false" verbose="true" debug="on" includeAntRuntime="no">
- <src path="src/"/>
- </javac>
- </target>
-
- <target name="clean">
- <delete file="bin/main.class"/>
- </target>
-
- <target name="env">
- <echo>
- System Properties
- -----------------
- java.version: ${java.version}
- java.vendor: ${java.vendor}
- java.home: ${java.home}
- java.class.path: ${java.class.path}
- java.ext.dirs: ${java.ext.dirs}
- os.name: ${os.name}
- os.arch: ${os.arch}
- os.version: ${os.version}
- user.name: ${user.name}
-
- Ant Environment
- ----------------
- basedir: ${basedir}
- ant.file: ${ant.file}
- ant.version: ${ant.version}
- ant.project.name: ${ant.project.name}
- ant.java.version: ${ant.java.version}
- build.compiler: ${build.compiler}
- </echo>
- </target>
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/src/main.class b/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/src/main.class
deleted file mode 100644
index 7ccc9b41f..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/src/main.class
+++ /dev/null
Binary files differ
diff --git a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/src/main.java b/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/src/main.java
deleted file mode 100644
index c5ab5b82e..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Java Test/src/main.java
+++ /dev/null
@@ -1,13 +0,0 @@
-/**
- * @author roscoe.m.rush
- *
- * To change this generated comment edit the template variable "typecomment":
- * Window>Preferences>Java>Templates.
- * To enable and disable the creation of type comments go to
- * Window>Preferences>Java>Code Generation.
- */
-public class main {
- public main() {
- System.out.println("Hello World!\n");
- }
-}
diff --git a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/.project b/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/.project
deleted file mode 100644
index 04e9dfb77..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/.project
+++ /dev/null
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>AntView Test</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- </buildSpec>
- <natures>
- </natures>
-</projectDescription>
diff --git a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Buildfile Error/build.xml b/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Buildfile Error/build.xml
deleted file mode 100644
index 89df62ba2..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Buildfile Error/build.xml
+++ /dev/null
@@ -1,44 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project name="AntView Test.01" basedir="." default="test-one">
- <target name="init">
- <echo message="Init"/>
- </target>
- <target name="test-one" depends="init,test-two">
- <echo message="One - multiple dependents"/>
- </target>
- <target name="test-two" depends="init,test-three" description="description of test-two">
- <echo message="Two - similar dependencies"/>
- </target>
- <target name="test-three" description="description of test-three">
- <echo message="Three - simple"/>
- </target>
- <target name="env"
- <echo>
- Shell Environment
- -----------------
- ANT_HOME: ${e.ANT_HOME}
- JAVA_HOME: ${e.JAVA_HOME}
- CLASSPATH: ${e.CLASSPATH}
-
- System Properties
- -----------------
- java.version: ${java.version}
- java.vendor: ${java.vendor}
- java.home: ${java.home}
- java.class.path: ${java.class.path}
- java.ext.dirs: ${java.ext.dirs}
- os.name: ${os.name}
- os.arch: ${os.arch}
- os.version: ${os.version}
- user.name: ${user.name}
-
- Ant Environment
- ----------------
- basedir: ${basedir}
- ant.file: ${ant.file}
- ant.version: ${ant.version}
- ant.project.name: ${ant.project.name}
- ant.java.version: ${ant.java.version}
- </echo>
- </target>
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Custom Build filename/customBuild.xml b/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Custom Build filename/customBuild.xml
deleted file mode 100644
index 040c97535..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Custom Build filename/customBuild.xml
+++ /dev/null
@@ -1,39 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project name="Custom build filename" basedir="." default="test-one">
- <target name="init">
- <echo message="Init"/>
- </target>
- <target name="test-one" depends="init,test-two">
- <echo message="One - multiple dependents"/>
- </target>
- <target name="test-two" depends="init,test-three" description="description of test-two">
- <echo message="Two - similar dependencies"/>
- </target>
- <target name="test-three" description="description of test-three">
- <echo message="Three - simple"/>
- </target>
- <target name="env">
- <echo>
- System Properties
- -----------------
- java.version: ${java.version}
- java.vendor: ${java.vendor}
- java.home: ${java.home}
- java.class.path: ${java.class.path}
- java.ext.dirs: ${java.ext.dirs}
- os.name: ${os.name}
- os.arch: ${os.arch}
- os.version: ${os.version}
- user.name: ${user.name}
-
- Ant Environment
- ----------------
- basedir: ${basedir}
- ant.file: ${ant.file}
- ant.version: ${ant.version}
- ant.project.name: ${ant.project.name}
- ant.java.version: ${ant.java.version}
- build.compiler: ${build.compiler}
- </echo>
- </target>
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Missing default target/build.xml b/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Missing default target/build.xml
deleted file mode 100644
index af8e4c3e8..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Missing default target/build.xml
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project name="Missing Project default test" basedir=".">
- <target name="env">
- <echo>
- System Properties
- -----------------
- java.version: ${java.version}
- java.vendor: ${java.vendor}
- java.home: ${java.home}
- java.class.path: ${java.class.path}
- java.ext.dirs: ${java.ext.dirs}
- os.name: ${os.name}
- os.arch: ${os.arch}
- os.version: ${os.version}
- user.name: ${user.name}
-
- Ant Environment
- ----------------
- basedir: ${basedir}
- ant.file: ${ant.file}
- ant.version: ${ant.version}
- ant.project.name: ${ant.project.name}
- ant.java.version: ${ant.java.version}
- build.compiler: ${build.compiler}
- </echo>
- </target>
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Missing project element/build.xml b/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Missing project element/build.xml
deleted file mode 100644
index cdfbda284..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Missing project element/build.xml
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<missingproject name="Missing project element" basedir="." default="env">
- <target name="env">
- <echo>
- System Properties
- -----------------
- java.version: ${java.version}
- java.vendor: ${java.vendor}
- java.home: ${java.home}
- java.class.path: ${java.class.path}
- java.ext.dirs: ${java.ext.dirs}
- os.name: ${os.name}
- os.arch: ${os.arch}
- os.version: ${os.version}
- user.name: ${user.name}
-
- Ant Environment
- ----------------
- basedir: ${basedir}
- ant.file: ${ant.file}
- ant.version: ${ant.version}
- ant.project.name: ${ant.project.name}
- ant.java.version: ${ant.java.version}
- build.compiler: ${build.compiler}
- </echo>
- </target>
-</missingproject> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Missing project name/build.xml b/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Missing project name/build.xml
deleted file mode 100644
index 530fe65db..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Missing project name/build.xml
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project basedir="." default="env">
- <target name="env">
- <echo>
- System Properties
- -----------------
- java.version: ${java.version}
- java.vendor: ${java.vendor}
- java.home: ${java.home}
- java.class.path: ${java.class.path}
- java.ext.dirs: ${java.ext.dirs}
- os.name: ${os.name}
- os.arch: ${os.arch}
- os.version: ${os.version}
- user.name: ${user.name}
-
- Ant Environment
- ----------------
- basedir: ${basedir}
- ant.file: ${ant.file}
- ant.version: ${ant.version}
- ant.project.name: ${ant.project.name}
- ant.java.version: ${ant.java.version}
- build.compiler: ${build.compiler}
- </echo>
- </target>
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Similar Dependencies/build.xml b/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Similar Dependencies/build.xml
deleted file mode 100644
index 8c5c6509a..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Similar Dependencies/build.xml
+++ /dev/null
@@ -1,15 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project name="Similiar dependencies" basedir="." default="test-one">
- <target name="init">
- <echo message="Init"/>
- </target>
- <target name="test-one" depends="init,test-two">
- <echo message="One - multiple dependents"/>
- </target>
- <target name="test-two" depends="init,test-three" description="description of test-two">
- <echo message="Two - similar dependencies"/>
- </target>
- <target name="test-three" description="description of test-three">
- <echo message="Three - simple"/>
- </target>
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Simple Dependency/build.xml b/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Simple Dependency/build.xml
deleted file mode 100644
index b21e8dd9d..000000000
--- a/ant/org.eclipse.ant.tests.ui/Ant View Tests/AntView Test/Simple Dependency/build.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project name="Simple" basedir="." default="test-a">
- <target name="test-a">
- <echo message="A - no dependents"/>
- </target>
- <target name="test-b" depends="test-a">
- <echo message="B - simple dependency"/>
- </target>
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/External Tools/org/eclipse/ant/tests/ui/externaltools/MigrationTests.java b/ant/org.eclipse.ant.tests.ui/External Tools/org/eclipse/ant/tests/ui/externaltools/MigrationTests.java
deleted file mode 100644
index 3bdfb6a27..000000000
--- a/ant/org.eclipse.ant.tests.ui/External Tools/org/eclipse/ant/tests/ui/externaltools/MigrationTests.java
+++ /dev/null
@@ -1,227 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.ui.externaltools;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import junit.framework.TestCase;
-
-import org.eclipse.ant.internal.ui.launchConfigurations.IAntLaunchConfigurationConstants;
-import org.eclipse.ant.internal.ui.model.AntUtil;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.debug.core.ILaunchConfigurationWorkingCopy;
-import org.eclipse.debug.ui.IDebugUIConstants;
-import org.eclipse.debug.ui.RefreshTab;
-import org.eclipse.ui.externaltools.internal.model.IExternalToolConstants;
-import org.eclipse.ui.externaltools.internal.registry.ExternalToolMigration;
-
-/**
- * Tests migration of Ant and External Tool configurations from old
- * formats to the current format.
- */
-public class MigrationTests extends TestCase {
-
- /**
- * Tests migration of arguments from an Eclipse 2.0 Ant buildfile
- * configuration to a current launch configuration.
- *
- * @throws CoreException
- */
- public void test20AntMigration() throws CoreException {
- Map argumentMap= get20AntArgumentMap();
- ILaunchConfigurationWorkingCopy config = ExternalToolMigration.configFromArgumentMap(argumentMap);
- assertNotNull("Migration failed", config);
-
- assertEquals("Wrong configuration type", IAntLaunchConfigurationConstants.ID_ANT_BUILDER_LAUNCH_CONFIGURATION_TYPE, config.getType().getIdentifier());
- assertEquals("ant tool", config.getName());
- assertEquals("location", config.getAttribute(IExternalToolConstants.ATTR_LOCATION, ""));
- assertEquals("refresh scope", config.getAttribute(RefreshTab.ATTR_REFRESH_SCOPE, ""));
- String[] targets= AntUtil.getTargetsFromConfig(config);
- assertNotNull("No targets found", targets);
- assertEquals("Wrong number of targets", 2, targets.length);
- assertEquals("target1", targets[0]);
- assertEquals("target2", targets[1]);
- assertEquals(true, config.getAttribute(IExternalToolConstants.ATTR_CAPTURE_OUTPUT, false));
- assertEquals(true, config.getAttribute(IDebugUIConstants.ATTR_LAUNCH_IN_BACKGROUND, false));
- assertEquals("build kinds", config.getAttribute(IExternalToolConstants.ATTR_RUN_BUILD_KINDS, ""));
- assertEquals("arg ", config.getAttribute(IExternalToolConstants.ATTR_TOOL_ARGUMENTS, ""));
- assertEquals("working dir", config.getAttribute(IExternalToolConstants.ATTR_WORKING_DIRECTORY, ""));
- }
-
- /**
- * Returns a map of arguments for an Ant buildfile using
- * Eclipse 2.0 arguments.
- *
- * @return a map of 2.0 arguments for an Ant buildfile.
- */
- private Map get20AntArgumentMap() {
- HashMap arguments= new HashMap();
- arguments.put(ExternalToolMigration.TAG_VERSION, "2.0");
- arguments.put(ExternalToolMigration.TAG_TOOL_TYPE, "org.eclipse.ui.externaltools.type.ant");
- arguments.put(ExternalToolMigration.TAG_TOOL_NAME, "ant tool");
- arguments.put(ExternalToolMigration.TAG_TOOL_LOCATION, "location");
- arguments.put(ExternalToolMigration.TAG_TOOL_REFRESH, "refresh scope");
- arguments.put(ExternalToolMigration.TAG_TOOL_ARGUMENTS, "arg ${ant_target:target1} ${ant_target:target2}");
- arguments.put(ExternalToolMigration.TAG_TOOL_SHOW_LOG, "true");
- arguments.put(ExternalToolMigration.TAG_TOOL_BLOCK, "false");
- arguments.put(ExternalToolMigration.TAG_TOOL_BUILD_TYPES, "build kinds");
- arguments.put(ExternalToolMigration.TAG_TOOL_DIRECTORY, "working dir");
- return arguments;
- }
-
- /**
- * Tests migration of arguments from an Eclipse 2.0 Ant buildfile
- * configuration to a current launch configuration.
- *
- * @throws CoreException
- */
- public void test20ProgramMigration() throws CoreException {
- Map argumentMap= get20ProgramArgumentMap();
- ILaunchConfigurationWorkingCopy config = ExternalToolMigration.configFromArgumentMap(argumentMap);
- assertEquals("Wrong configuration type", IExternalToolConstants.ID_PROGRAM_BUILDER_LAUNCH_CONFIGURATION_TYPE, config.getType().getIdentifier());
- assertEquals("program tool", config.getName());
- assertEquals("location", config.getAttribute(IExternalToolConstants.ATTR_LOCATION, ""));
- assertEquals("refresh scope", config.getAttribute(RefreshTab.ATTR_REFRESH_SCOPE, ""));
- assertEquals(true, config.getAttribute(IExternalToolConstants.ATTR_CAPTURE_OUTPUT, false));
- assertEquals(true, config.getAttribute(IDebugUIConstants.ATTR_LAUNCH_IN_BACKGROUND, false));
- assertEquals("build kinds", config.getAttribute(IExternalToolConstants.ATTR_RUN_BUILD_KINDS, ""));
- assertEquals("arg ${ant_target:target1} ${ant_target:target2}", config.getAttribute(IExternalToolConstants.ATTR_TOOL_ARGUMENTS, ""));
- assertEquals("working dir", config.getAttribute(IExternalToolConstants.ATTR_WORKING_DIRECTORY, ""));
- }
-
- /**
- * Returns a map of arguments for executing a program
- * using Eclipse 2.0 arguments.
- *
- * @return a map of 2.0 arguments for a program
- */
- private Map get20ProgramArgumentMap() {
- HashMap arguments= new HashMap();
- arguments.put(ExternalToolMigration.TAG_VERSION, "2.0");
- arguments.put(ExternalToolMigration.TAG_TOOL_TYPE, "org.eclipse.ui.externaltools.type.program");
- arguments.put(ExternalToolMigration.TAG_TOOL_NAME, "program tool");
- arguments.put(ExternalToolMigration.TAG_TOOL_LOCATION, "location");
- arguments.put(ExternalToolMigration.TAG_TOOL_REFRESH, "refresh scope");
- arguments.put(ExternalToolMigration.TAG_TOOL_ARGUMENTS, "arg ${ant_target:target1} ${ant_target:target2}");
- arguments.put(ExternalToolMigration.TAG_TOOL_SHOW_LOG, "true");
- arguments.put(ExternalToolMigration.TAG_TOOL_BLOCK, "false");
- arguments.put(ExternalToolMigration.TAG_TOOL_BUILD_TYPES, "build kinds");
- arguments.put(ExternalToolMigration.TAG_TOOL_DIRECTORY, "working dir");
- return arguments;
- }
-
- /**
- * Tests migration of arguments from an Eclipse 2.1 Ant buildfile
- * configuration to a current launch configuration.
- *
- * @throws CoreException
- */
- public void test21AntMigration() throws CoreException {
- Map argumentMap= get21AntArgumentMap();
- ILaunchConfigurationWorkingCopy config = ExternalToolMigration.configFromArgumentMap(argumentMap);
- assertNotNull("Migration failed", config);
-
- assertEquals("Wrong config type", IAntLaunchConfigurationConstants.ID_ANT_BUILDER_LAUNCH_CONFIGURATION_TYPE, config.getType().getIdentifier());
- assertEquals("ant config", config.getName());
- assertEquals("location", config.getAttribute(IExternalToolConstants.ATTR_LOCATION, ""));
- assertEquals("working directory", config.getAttribute(IExternalToolConstants.ATTR_WORKING_DIRECTORY, ""));
- assertEquals(true, config.getAttribute(IExternalToolConstants.ATTR_CAPTURE_OUTPUT, false));
- assertEquals(true, config.getAttribute(IExternalToolConstants.ATTR_SHOW_CONSOLE, false));
- assertEquals(true, config.getAttribute(IDebugUIConstants.ATTR_LAUNCH_IN_BACKGROUND, false));
- assertEquals(true, config.getAttribute(IExternalToolConstants.ATTR_PROMPT_FOR_ARGUMENTS, false));
- assertEquals("refresh scope", config.getAttribute(RefreshTab.ATTR_REFRESH_SCOPE, ""));
- assertEquals(true, config.getAttribute(RefreshTab.ATTR_REFRESH_RECURSIVE, false));
- assertEquals("build kinds", config.getAttribute(IExternalToolConstants.ATTR_RUN_BUILD_KINDS, ""));
- assertEquals("arg1 arg2", config.getAttribute(IExternalToolConstants.ATTR_TOOL_ARGUMENTS, ""));
- String[] targets= AntUtil.getTargetsFromConfig(config);
- assertEquals("Wrong number of targets", 2, targets.length);
- assertEquals("target1", targets[0]);
- assertEquals("target2", targets[1]);
- }
-
- /**
- * Returns a map of arguments for executing an Ant
- * buildfile using Eclipse 2.1 arguments.
- *
- * @return a map of 2.1 arguments for an Ant buildfile
- */
- private Map get21AntArgumentMap() {
- HashMap arguments= new HashMap();
- arguments.put(ExternalToolMigration.TAG_VERSION, "2.1");
- arguments.put(ExternalToolMigration.TAG_NAME, "ant config");
- arguments.put(ExternalToolMigration.TAG_TYPE, ExternalToolMigration.TOOL_TYPE_ANT_BUILD);
- arguments.put(ExternalToolMigration.TAG_LOCATION, "location");
- arguments.put(ExternalToolMigration.TAG_WORK_DIR, "working directory");
- arguments.put(ExternalToolMigration.TAG_CAPTURE_OUTPUT, "true");
- arguments.put(ExternalToolMigration.TAG_SHOW_CONSOLE, "true");
- arguments.put(ExternalToolMigration.TAG_SHOW_CONSOLE, "true");
- arguments.put(ExternalToolMigration.TAG_RUN_BKGRND, "true");
- arguments.put(ExternalToolMigration.TAG_PROMPT_ARGS, "true");
- arguments.put(ExternalToolMigration.TAG_REFRESH_SCOPE, "refresh scope");
- arguments.put(ExternalToolMigration.TAG_REFRESH_RECURSIVE, "true");
- arguments.put(ExternalToolMigration.TAG_RUN_BUILD_KINDS, "build kinds");
- arguments.put(ExternalToolMigration.TAG_ARGS, "arg1 arg2");
- arguments.put(ExternalToolMigration.TAG_EXTRA_ATTR, ExternalToolMigration.RUN_TARGETS_ATTRIBUTE + "=target1,target2");
- return arguments;
- }
-
- /**
- * Tests migration of arguments from an Eclipse 2.1 program
- * configuration to a current launch configuration.
- *
- * @throws CoreException
- */
- public void test21ProgramMigration() throws CoreException {
- Map argumentMap= get21ProgramArgumentMap();
- ILaunchConfigurationWorkingCopy config = ExternalToolMigration.configFromArgumentMap(argumentMap);
- assertNotNull("Migration failed", config);
-
- assertEquals("Wrong config type", IExternalToolConstants.ID_PROGRAM_BUILDER_LAUNCH_CONFIGURATION_TYPE, config.getType().getIdentifier());
- assertEquals("program config", config.getName());
- assertEquals("location", config.getAttribute(IExternalToolConstants.ATTR_LOCATION, ""));
- assertEquals("working directory", config.getAttribute(IExternalToolConstants.ATTR_WORKING_DIRECTORY, ""));
- assertEquals(true, config.getAttribute(IExternalToolConstants.ATTR_CAPTURE_OUTPUT, false));
- assertEquals(true, config.getAttribute(IExternalToolConstants.ATTR_SHOW_CONSOLE, false));
- assertEquals(true, config.getAttribute(IDebugUIConstants.ATTR_LAUNCH_IN_BACKGROUND, false));
- assertEquals(true, config.getAttribute(IExternalToolConstants.ATTR_PROMPT_FOR_ARGUMENTS, false));
- assertEquals("refresh scope", config.getAttribute(RefreshTab.ATTR_REFRESH_SCOPE, ""));
- assertEquals(true, config.getAttribute(RefreshTab.ATTR_REFRESH_RECURSIVE, false));
- assertEquals("build kinds", config.getAttribute(IExternalToolConstants.ATTR_RUN_BUILD_KINDS, ""));
- assertEquals("arg1 arg2", config.getAttribute(IExternalToolConstants.ATTR_TOOL_ARGUMENTS, ""));
- }
-
- /**
- * Returns a map of arguments for executing a program
- * buildfile using Eclipse 2.1 arguments.
- *
- * @return a map of 2.1 arguments for a program
- */
- private Map get21ProgramArgumentMap() {
- HashMap arguments= new HashMap();
- arguments.put(ExternalToolMigration.TAG_VERSION, "2.1");
- arguments.put(ExternalToolMigration.TAG_NAME, "program config");
- arguments.put(ExternalToolMigration.TAG_TYPE, IExternalToolConstants.TOOL_TYPE_PROGRAM);
- arguments.put(ExternalToolMigration.TAG_LOCATION, "location");
- arguments.put(ExternalToolMigration.TAG_WORK_DIR, "working directory");
- arguments.put(ExternalToolMigration.TAG_CAPTURE_OUTPUT, "true");
- arguments.put(ExternalToolMigration.TAG_SHOW_CONSOLE, "true");
- arguments.put(ExternalToolMigration.TAG_SHOW_CONSOLE, "true");
- arguments.put(ExternalToolMigration.TAG_RUN_BKGRND, "true");
- arguments.put(ExternalToolMigration.TAG_PROMPT_ARGS, "true");
- arguments.put(ExternalToolMigration.TAG_REFRESH_SCOPE, "refresh scope");
- arguments.put(ExternalToolMigration.TAG_REFRESH_RECURSIVE, "true");
- arguments.put(ExternalToolMigration.TAG_RUN_BUILD_KINDS, "build kinds");
- arguments.put(ExternalToolMigration.TAG_ARGS, "arg1 arg2");
- return arguments;
- }
-
-}
diff --git a/ant/org.eclipse.ant.tests.ui/about.html b/ant/org.eclipse.ant.tests.ui/about.html
deleted file mode 100644
index cde506f58..000000000
--- a/ant/org.eclipse.ant.tests.ui/about.html
+++ /dev/null
@@ -1,30 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<title>About</title>
-<meta http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<p>30th January, 2003</p>
-<h3>License</h3>
-<p>Eclipse.org makes available all content in this plug-in (&quot;Content&quot;). Unless otherwise indicated below, the Content is provided to you under the terms and conditions of the
-Common Public License Version 1.0 (&quot;CPL&quot;). A copy of the CPL is available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>.
-For purposes of the CPL, &quot;Program&quot; will mean the Content.</p>
-
-<h3>Contributions</h3>
-
-<p>If this Content is licensed to you under the terms and conditions of the CPL, any Contributions, as defined in the CPL, uploaded, submitted, or otherwise
-made available to Eclipse.org, members of Eclipse.org and/or the host of Eclipse.org web site, by you that relate to such
-Content are provided under the terms and conditions of the CPL and can be made available to others under the terms of the CPL.</p>
-
-<p>If this Content is licensed to you under license terms and conditions other than the CPL (&quot;Other License&quot;), any modifications, enhancements and/or
-other code and/or documentation (&quot;Modifications&quot;) uploaded, submitted, or otherwise made available to Eclipse.org, members of Eclipse.org and/or the
-host of Eclipse.org, by you that relate to such Content are provided under terms and conditions of the Other License and can be made available
-to others under the terms of the Other License. In addition, with regard to Modifications for which you are the copyright holder, you are also
-providing the Modifications under the terms and conditions of the CPL and such Modifications can be made available to others under the terms of
-the CPL.</p>
-
-</body>
-</html> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/build.properties b/ant/org.eclipse.ant.tests.ui/build.properties
deleted file mode 100644
index 2b6d76e3e..000000000
--- a/ant/org.eclipse.ant.tests.ui/build.properties
+++ /dev/null
@@ -1,27 +0,0 @@
-###############################################################################
-# Copyright (c) 2004 IBM Corporation and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Common Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/cpl-v10.html
-#
-# Contributors:
-# IBM Corporation - initial API and implementation
-###############################################################################
-bin.includes = plugin.xml,\
- plugin.properties,\
- test.xml,\
- about.html,\
- testbuildfiles/,\
- lib/,\
- lib/*.jar,\
- *.jar
-
-source.anttestsui.jar = test plugin/,\
- Ant Editor Tests/,\
- External Tools/,\
- Ant Tests/,\
- buildfiles/
-
-source.lib/antUITestsSupport.jar = test support/
-jars.compile.order=anttestsui.jar,lib/antUITestsSupport.jar \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/buildfiles/buildAntTestsSupportJAR.xml b/ant/org.eclipse.ant.tests.ui/buildfiles/buildAntTestsSupportJAR.xml
deleted file mode 100644
index dcab7230b..000000000
--- a/ant/org.eclipse.ant.tests.ui/buildfiles/buildAntTestsSupportJAR.xml
+++ /dev/null
@@ -1,42 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project name="build tests support jar" default="build" basedir="..">
-
- <property name="bootclasspath" value=""/>
-
- <target name="build" description="Removes all build artifacts, recreates the support jar, and refreshes this plugin's resources" depends="clean, lib/antUITestsSupport.jar"/>
-
- <target name="init" depends="properties">
- <property name="version.suffix" value="_3.0.0"/>
- <property name="ant_version.suffix" value="_1.6.1"/>
- <property name="temp.folder" value="${basedir}/temp.folder"/>
- <property name="plugin.destination" value="${basedir}"/>
- <property name="build.result.folder" value="${basedir}"/>
- </target>
-
- <target name="properties" if="eclipse.running">
- <property name="build.compiler" value="org.eclipse.jdt.core.JDTCompilerAdapter"/>
- </target>
-
- <target name="lib/antUITestsSupport.jar" depends="init" description= "Builds the support JAR">
- <property name="destdir" value="${temp.folder}/lib/antUITestsSupport.jar.bin"/>
- <delete dir="${temp.folder}/lib/antUITestsSupport.jar.bin"/>
- <mkdir dir="${temp.folder}/lib/antUITestsSupport.jar.bin"/>
- <!-- compile the source code -->
- <javac target="1.1" destdir="${temp.folder}/lib/antUITestsSupport.jar.bin" failonerror="false" verbose="false" debug="on" includeAntRuntime="yes" bootclasspath="${bootclasspath}"
- classpath="${basedir}/../org.eclipse.core.runtime/bin;
- ${eclipse.home}/plugins/org.eclipse.core.runtime${version.suffix}/runtime.jar;
- ${basedir}/bin;
- ${eclipse.home}/plugins/org.eclipse.ant.core${version.suffix}/antsupport.jar;
- ${basedir}/../org.eclipse.ant.core/bin">
- <src path="test support/"/>
- </javac>
- <mkdir dir="${build.result.folder}/lib"/>
- <jar jarfile="${build.result.folder}/lib/antUITestsSupport.jar" basedir="${temp.folder}/lib/antUITestsSupport.jar.bin"/>
- <delete dir="${temp.folder}"/>
- </target>
-
- <target name="clean" depends="init">
- <delete file="${build.result.folder}/lib/antUITestsSupport.jar"/>
- <delete dir="${temp.folder}"/>
- </target>
-</project>
diff --git a/ant/org.eclipse.ant.tests.ui/icons/ant.gif b/ant/org.eclipse.ant.tests.ui/icons/ant.gif
deleted file mode 100644
index 6da365c94..000000000
--- a/ant/org.eclipse.ant.tests.ui/icons/ant.gif
+++ /dev/null
Binary files differ
diff --git a/ant/org.eclipse.ant.tests.ui/lib/.cvsignore b/ant/org.eclipse.ant.tests.ui/lib/.cvsignore
deleted file mode 100644
index 2b90898bd..000000000
--- a/ant/org.eclipse.ant.tests.ui/lib/.cvsignore
+++ /dev/null
@@ -1 +0,0 @@
-antUITestsSupport.jar
diff --git a/ant/org.eclipse.ant.tests.ui/plugin.properties b/ant/org.eclipse.ant.tests.ui/plugin.properties
deleted file mode 100644
index 07228b297..000000000
--- a/ant/org.eclipse.ant.tests.ui/plugin.properties
+++ /dev/null
@@ -1,13 +0,0 @@
-###############################################################################
-# Copyright (c) 2003 IBM Corporation and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Common Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/cpl-v10.html
-#
-# Contributors:
-# IBM Corporation - initial API and implementation
-###############################################################################
-
-pluginName=Ant UI Test Plugin
-providerName=Eclipse.org \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/plugin.xml b/ant/org.eclipse.ant.tests.ui/plugin.xml
deleted file mode 100644
index cb5d656b7..000000000
--- a/ant/org.eclipse.ant.tests.ui/plugin.xml
+++ /dev/null
@@ -1,85 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.0"?>
-<plugin
- id="org.eclipse.ant.tests.ui"
- name="%pluginName"
- version="3.0.0"
- provider-name="%providerName"
- class="org.eclipse.ant.tests.ui.testplugin.AntUITestPlugin">
-
- <requires>
- <import plugin="org.eclipse.ui.ide" optional="true"/>
- <import plugin="org.eclipse.ui.views" optional="true"/>
- <import plugin="org.eclipse.jface.text" optional="true"/>
- <import plugin="org.eclipse.ui.workbench.texteditor" optional="true"/>
- <import plugin="org.eclipse.ui.editors" optional="true"/>
- <import plugin="org.apache.ant"/>
- <import plugin="org.junit"/>
- <import plugin="org.eclipse.core.resources"/>
- <import plugin="org.eclipse.jdt.core"/>
- <import plugin="org.eclipse.jdt.launching"/>
- <import plugin="org.eclipse.ui"/>
- <import plugin="org.eclipse.ant.core"/>
- <import plugin="org.eclipse.debug.core"/>
- <import plugin="org.eclipse.debug.ui"/>
- <import plugin="org.eclipse.jdt.debug"/>
- <import plugin="org.eclipse.update.core"/>
- <import plugin="org.eclipse.ui.externaltools"/>
- <import plugin="org.eclipse.ant.ui"/>
- <import plugin="org.eclipse.core.runtime"/>
- </requires>
-
-<runtime>
- <library name="anttestsui.jar" >
- <export name = "*"/>
- </library>
-</runtime>
-
- <extension
- point="org.eclipse.debug.ui.consoleLineTrackers">
- <consoleLineTracker
- class="org.eclipse.ant.tests.ui.testplugin.ConsoleLineTracker"
- processType="org.eclipse.ant.ui.antProcess"
- id="org.eclipse.ant.tests.ui.testplugin.ConsoleLineTracker">
- </consoleLineTracker>
- </extension>
-
- <extension
- point="org.eclipse.ant.core.extraClasspathEntries">
- <extraClasspathEntry
- library="lib/antUITestsSupport.jar"
- eclipseRuntime="false">
- </extraClasspathEntry>
- </extension>
-
- <extension point="org.eclipse.ant.core.antTasks">
- <antTask
- name="coolUITask"
- class="org.eclipse.ant.tests.ui.support.tasks.AntTestTask2"
- library="lib/antUITestsSupport.jar"
- eclipseRuntime="false">
- </antTask>
- </extension>
-
- <extension point="org.eclipse.ant.core.antTypes">
- <antType
- name="coolUIType"
- class="org.eclipse.ant.tests.ui.support.types.AntTestPath"
- library="lib/antUITestsSupport.jar"
- eclipseRuntime="false">
- </antType>
- </extension>
-
- <extension
- point="org.eclipse.ant.core.antProperties">
- <antProperty
- name="property.ui.testing"
- value="true">
- </antProperty>
- <antProperty
- name="property.ui.testing2"
- value="hey"
- eclipseRuntime="false">
- </antProperty>
- </extension>
-</plugin>
diff --git a/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/AbstractAntUITest.java b/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/AbstractAntUITest.java
deleted file mode 100644
index d84caffce..000000000
--- a/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/AbstractAntUITest.java
+++ /dev/null
@@ -1,344 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.ui.testplugin;
-
-import java.io.BufferedReader;
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.InputStreamReader;
-import java.io.UnsupportedEncodingException;
-
-import javax.xml.parsers.ParserConfigurationException;
-import javax.xml.parsers.SAXParser;
-import javax.xml.parsers.SAXParserFactory;
-
-import junit.framework.TestCase;
-
-import org.eclipse.ant.internal.ui.editor.outline.AntModel;
-import org.eclipse.ant.internal.ui.editor.outline.XMLCore;
-import org.eclipse.ant.internal.ui.launchConfigurations.IAntLaunchConfigurationConstants;
-import org.eclipse.ant.internal.ui.model.AntUIPlugin;
-import org.eclipse.ant.tests.ui.editor.support.TestLocationProvider;
-import org.eclipse.ant.tests.ui.editor.support.TestProblemRequestor;
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.debug.core.DebugEvent;
-import org.eclipse.debug.core.DebugPlugin;
-import org.eclipse.debug.core.ILaunch;
-import org.eclipse.debug.core.ILaunchConfiguration;
-import org.eclipse.debug.core.ILaunchConfigurationWorkingCopy;
-import org.eclipse.debug.core.ILaunchManager;
-import org.eclipse.debug.core.model.IProcess;
-import org.eclipse.debug.internal.ui.DebugUIPlugin;
-import org.eclipse.debug.internal.ui.views.console.ConsoleDocumentPartitioner;
-import org.eclipse.debug.internal.ui.views.console.HyperlinkPosition;
-import org.eclipse.debug.internal.ui.views.console.StreamPartition;
-import org.eclipse.debug.ui.console.IConsoleColorProvider;
-import org.eclipse.debug.ui.console.IConsoleHyperlink;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jface.text.BadLocationException;
-import org.eclipse.jface.text.BadPositionCategoryException;
-import org.eclipse.jface.text.Document;
-import org.eclipse.jface.text.IDocument;
-import org.eclipse.jface.text.ITypedRegion;
-import org.eclipse.jface.text.Position;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.ui.externaltools.internal.model.IExternalToolConstants;
-import org.xml.sax.InputSource;
-import org.xml.sax.SAXException;
-import org.xml.sax.helpers.DefaultHandler;
-
-public abstract class AbstractAntUITest extends TestCase {
- private IDocument currentDocument;
-
- public AbstractAntUITest(String name) {
- super(name);
- }
-
- protected File getBuildFile(String buildFileName) {
- IFile file = getProject().getFolder("buildfiles").getFile(buildFileName);
- assertTrue("Could not find build file named: " + buildFileName, file.exists());
- return file.getLocation().toFile();
- }
-
- /**
- * Returns the 'AntUITests' project.
- *
- * @return the test project
- */
- protected IProject getProject() {
- return ResourcesPlugin.getWorkspace().getRoot().getProject(ProjectHelper.PROJECT_NAME);
- }
-
- protected IDocument getDocument(String fileName) {
- File file = getBuildFile(fileName);
- InputStream in;
- try {
- in = new FileInputStream(file);
- } catch (FileNotFoundException e) {
- return null;
- }
- String initialContent= getStreamContentAsString(in);
- return new Document(initialContent);
- }
-
- protected String getStreamContentAsString(InputStream inputStream) {
- InputStreamReader reader;
- try {
- reader = new InputStreamReader(inputStream, ResourcesPlugin.getEncoding());
- } catch (UnsupportedEncodingException e) {
- AntUIPlugin.log(e);
- return ""; //$NON-NLS-1$
- }
- BufferedReader tempBufferedReader = new BufferedReader(reader);
-
- return getReaderContentAsString(tempBufferedReader);
- }
-
- protected String getReaderContentAsString(BufferedReader tempBufferedReader) {
- StringBuffer tempResult = new StringBuffer();
- try {
- String tempLine= tempBufferedReader.readLine();
-
- while(tempLine != null) {
- if(tempResult.length() != 0) {
- tempResult.append("\n"); //$NON-NLS-1$
- }
- tempResult.append(tempLine);
- tempLine = tempBufferedReader.readLine();
- }
- } catch (IOException e) {
- AntUIPlugin.log(e);
- return null;
- }
-
- return tempResult.toString();
- }
-
- protected AntModel getAntModel(String fileName) {
- currentDocument= getDocument(fileName);
- AntModel model= new AntModel(XMLCore.getDefault(), currentDocument, new TestProblemRequestor(), new TestLocationProvider(getBuildFile(fileName)));
- model.reconcile(null);
- return model;
- }
-
- /**
- * @return
- */
- public IDocument getCurrentDocument() {
- return currentDocument;
- }
-
- /**
- * @param currentDocument
- */
- public void setCurrentDocument(IDocument currentDocument) {
- this.currentDocument = currentDocument;
- }
-
- /**
- * Launches the Ant build with the buildfile name (no extension).
- *
- * @param buildFileName the ant buildfile name
- */
- protected void launch(String buildFileName) throws CoreException {
- ILaunchConfiguration config = getLaunchConfiguration(buildFileName);
- assertNotNull("Could not locate launch configuration for " + buildFileName, config);
- launchAndTerminate(config, 20000);
- }
-
- /**
- * Launches the Ant build with the buildfile name (no extension).
- *
- * @param buildFileName the buildfile
- * @param arguments the ant arguments
- */
- protected void launch(String buildFileName, String arguments) throws CoreException {
- ILaunchConfiguration config = getLaunchConfiguration(buildFileName);
- assertNotNull("Could not locate launch configuration for " + buildFileName, config);
- ILaunchConfigurationWorkingCopy copy= config.getWorkingCopy();
- copy.setAttribute(IExternalToolConstants.ATTR_TOOL_ARGUMENTS, arguments);
- launchAndTerminate(copy, 20000);
- }
-
- /**
- * Launches the Ant build in debug mode with the buildfile name (no extension).
- *
- * @param mainTypeName the program to launch
- * @return thread in which the first suspend event occurred
- */
- protected void launchInDebug(String buildFileName) throws CoreException {
- ILaunchConfiguration config = getLaunchConfiguration(buildFileName);
- assertNotNull("Could not locate launch configuration for " + buildFileName, config);
- ILaunchConfigurationWorkingCopy copy= config.getWorkingCopy();
- copy.setAttribute(IExternalToolConstants.ATTR_TOOL_ARGUMENTS, "-debug");
- launchAndTerminate(copy, 10000);
- }
-
- /**
- * Returns the launch configuration for the given buildfile
- *
- * @param buildFileName buildfile to launch
- * @see ProjectCreationDecorator
- */
- protected ILaunchConfiguration getLaunchConfiguration(String buildFileName) {
- IFile file = getJavaProject().getProject().getFolder("launchConfigurations").getFile(buildFileName + ".launch");
- ILaunchConfiguration config = getLaunchManager().getLaunchConfiguration(file);
- assertTrue("Could not find launch configuration for " + buildFileName, config.exists());
- return config;
- }
-
- /**
- * Returns the content of the specified file as <code>String</code>.
- */
- protected String getFileContentAsString(File aFile) throws FileNotFoundException {
- InputStream stream = new FileInputStream(aFile);
- InputStreamReader reader = new InputStreamReader(stream);
- BufferedReader bufferedReader = new BufferedReader(reader);
-
- String result = "";
- try {
- String line= bufferedReader.readLine();
-
- while(line != null) {
- result += "\n";
- result += line;
- line = bufferedReader.readLine();
- }
- } catch (IOException e) {
- e.printStackTrace();
- return null;
- }
- return result;
- }
-
- protected SAXParser getSAXParser() {
- SAXParser parser = null;
- try {
- parser = SAXParserFactory.newInstance().newSAXParser();
- } catch (ParserConfigurationException e) {
- AntUIPlugin.log(e);
- } catch (SAXException e) {
- AntUIPlugin.log(e);
- }
- return parser;
- }
-
-
- protected void parse(InputStream stream, SAXParser parser, DefaultHandler handler, File editedFile) {
- InputSource inputSource= new InputSource(stream);
- if (editedFile != null) {
- //needed for resolving relative external entities
- inputSource.setSystemId(editedFile.getAbsolutePath());
- }
-
- try {
- parser.parse(inputSource, handler);
- } catch (SAXException e) {
- } catch (IOException e) {
- }
- }
-
- /**
- * Returns the launch manager
- *
- * @return launch manager
- */
- protected ILaunchManager getLaunchManager() {
- return DebugPlugin.getDefault().getLaunchManager();
- }
-
- /**
- * Returns the 'AntUITests' project.
- *
- * @return the test project
- */
- protected IJavaProject getJavaProject() {
- return JavaCore.create( getProject());
- }
-
- protected void launchAndTerminate(ILaunchConfiguration config, int timeout) throws CoreException {
- DebugEventWaiter waiter= new DebugElementKindEventWaiter(DebugEvent.TERMINATE, IProcess.class);
- waiter.setTimeout(timeout);
-
- Object terminatee = launchAndWait(config, waiter);
- assertNotNull("Program did not terminate.", terminatee);
- assertTrue("terminatee is not an IProcess", terminatee instanceof IProcess);
- IProcess process = (IProcess) terminatee;
- assertTrue("process is not terminated", process.isTerminated());
- }
-
- /**
- * Launches the given configuration and waits for an event. Returns the
- * source of the event. If the event is not received, the launch is
- * terminated and an exception is thrown.
- *
- * @param configuration the configuration to launch
- * @param waiter the event waiter to use
- * @return Object the source of the event
- * @exception Exception if the event is never received.
- */
- protected Object launchAndWait(ILaunchConfiguration configuration, DebugEventWaiter waiter) throws CoreException {
- ILaunch launch = configuration.launch(ILaunchManager.RUN_MODE, null);
- Object suspendee= waiter.waitForEvent();
- if (suspendee == null) {
- try {
- launch.terminate();
- } catch (CoreException e) {
- e.printStackTrace();
- fail("Program did not suspend, and unable to terminate launch.");
- }
- }
- assertNotNull("Program did not suspend, launch terminated.", suspendee);
- return suspendee;
- }
-
- protected IConsoleHyperlink getHyperlink(int offset, IDocument doc) {
- if (offset >= 0 && doc != null) {
- Position[] positions = null;
- try {
- positions = doc.getPositions(HyperlinkPosition.HYPER_LINK_CATEGORY);
- } catch (BadPositionCategoryException ex) {
- // no links have been added
- return null;
- }
- for (int i = 0; i < positions.length; i++) {
- Position position = positions[i];
- if (offset >= position.getOffset() && offset <= (position.getOffset() + position.getLength())) {
- return ((HyperlinkPosition)position).getHyperLink();
- }
- }
- }
- return null;
- }
-
- protected Color getColorAtOffset(int offset, IDocument document) throws BadLocationException {
- if (document != null) {
- ConsoleDocumentPartitioner partitioner = (ConsoleDocumentPartitioner)document.getDocumentPartitioner();
- if (partitioner != null) {
- IConsoleColorProvider colorProvider = DebugUIPlugin.getDefault().getConsoleDocumentManager().getColorProvider(IAntLaunchConfigurationConstants.ID_ANT_PROCESS_TYPE);
- ITypedRegion[] regions= partitioner.computePartitioning(offset, document.getLineInformationOfOffset(offset).getLength());
-
- for (int i = 0; i < regions.length; i++) {
- StreamPartition partition = (StreamPartition)regions[i];
- return colorProvider.getColor(partition.getStreamIdentifier());
- }
- }
- }
- return null;
- }
-}
diff --git a/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/AntUITestPlugin.java b/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/AntUITestPlugin.java
deleted file mode 100644
index 41f1b1a36..000000000
--- a/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/AntUITestPlugin.java
+++ /dev/null
@@ -1,63 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.ui.testplugin;
-
-
-import java.io.File;
-import java.io.IOException;
-import java.net.URL;
-
-import org.eclipse.core.resources.IWorkspace;
-import org.eclipse.core.resources.IWorkspaceDescription;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.Platform;
-import org.eclipse.ui.plugin.AbstractUIPlugin;
-import org.osgi.framework.Bundle;
-
-
-public class AntUITestPlugin extends AbstractUIPlugin {
-
- private static AntUITestPlugin deflt;
-
- public AntUITestPlugin() {
- super();
- deflt= this;
- }
-
- public static AntUITestPlugin getDefault() {
- return deflt;
- }
-
- public static IWorkspace getWorkspace() {
- return ResourcesPlugin.getWorkspace();
- }
-
- public static void enableAutobuild(boolean enable) throws CoreException {
- // disable auto build
- IWorkspace workspace= AntUITestPlugin.getWorkspace();
- IWorkspaceDescription desc= workspace.getDescription();
- desc.setAutoBuilding(enable);
- workspace.setDescription(desc);
- }
-
- public File getFileInPlugin(IPath path) {
- try {
- Bundle bundle = getDefault().getBundle();
- URL installURL= new URL(bundle.getEntry("/"), path.toString());
- URL localURL= Platform.asLocalURL(installURL);
- return new File(localURL.getFile());
- } catch (IOException e) {
- return null;
- }
- }
-}
diff --git a/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/AntUITests.java b/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/AntUITests.java
deleted file mode 100644
index ea8f783d7..000000000
--- a/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/AntUITests.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2002, 2004 GEBIT Gesellschaft fuer EDV-Beratung
- * und Informatik-Technologien mbH,
- * Berlin, Duesseldorf, Frankfurt (Germany) and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * GEBIT Gesellschaft fuer EDV-Beratung und Informatik-Technologien mbH - initial implementation
- * IBM Corporation - additional tests
- *******************************************************************************/
-
-package org.eclipse.ant.tests.ui.testplugin;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-import org.eclipse.ant.tests.ui.BuildTests;
-import org.eclipse.ant.tests.ui.editor.AntEditorContentOutlineTests;
-import org.eclipse.ant.tests.ui.editor.CodeCompletionTest;
-import org.eclipse.ant.tests.ui.editor.TaskDescriptionProviderTest;
-import org.eclipse.ant.tests.ui.editor.formatter.XmlFormatterTest;
-import org.eclipse.ant.tests.ui.editor.formatter.XmlTagFormatterTest;
-import org.eclipse.ant.tests.ui.editor.formatter.FormattingPreferencesTest;
-import org.eclipse.ant.tests.ui.editor.formatter.XmlDocumentFormatterTest;
-import org.eclipse.ant.tests.ui.externaltools.MigrationTests;
-import org.eclipse.ant.tests.ui.separateVM.SeparateVMTests;
-
-/**
- * Test suite for the Ant UI
- */
-public class AntUITests extends TestSuite {
-
- public static Test suite() {
-
- TestSuite suite= new AntUITests();
- suite.setName("Ant UI Unit Tests");
- suite.addTest(new TestSuite(ProjectCreationDecorator.class));
- suite.addTest(new TestSuite(BuildTests.class));
- suite.addTest(new TestSuite(SeparateVMTests.class));
- suite.addTest(new TestSuite(CodeCompletionTest.class));
- suite.addTest(new TestSuite(TaskDescriptionProviderTest.class));
- suite.addTest(new TestSuite(AntEditorContentOutlineTests.class));
- suite.addTest(new TestSuite(MigrationTests.class));
- suite.addTest(new TestSuite(FormattingPreferencesTest.class));
- suite.addTest(new TestSuite(XmlDocumentFormatterTest.class));
- suite.addTest(new TestSuite(XmlTagFormatterTest.class));
- suite.addTest(new TestSuite(XmlFormatterTest.class));
- return suite;
- }
-}
diff --git a/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/ConsoleLineTracker.java b/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/ConsoleLineTracker.java
deleted file mode 100644
index fed66a94d..000000000
--- a/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/ConsoleLineTracker.java
+++ /dev/null
@@ -1,112 +0,0 @@
-package org.eclipse.ant.tests.ui.testplugin;
-
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.debug.ui.console.IConsole;
-import org.eclipse.debug.ui.console.IConsoleLineTrackerExtension;
-import org.eclipse.jface.text.BadLocationException;
-import org.eclipse.jface.text.IDocument;
-import org.eclipse.jface.text.IRegion;
-
-/**
- * Simple console line tracker extension point that collects the lines
- * appended to the console.
- */
-public class ConsoleLineTracker implements IConsoleLineTrackerExtension {
-
- private static IConsole console;
- private static List lines= new ArrayList();
-
- private static boolean consoleClosed= false;
-
- /**
- * @see org.eclipse.debug.ui.console.IConsoleLineTracker#dispose()
- */
- public void dispose() {
- console = null;
- lines= new ArrayList();
- }
-
- /**
- * @see org.eclipse.debug.ui.console.IConsoleLineTracker#init(org.eclipse.debug.ui.console.IConsole)
- */
- public synchronized void init(IConsole c) {
- ConsoleLineTracker.console= c;
- lines= new ArrayList();
- consoleClosed= false;
- }
-
- /**
- * @see org.eclipse.debug.ui.console.IConsoleLineTracker#lineAppended(org.eclipse.jface.text.IRegion)
- */
- public void lineAppended(IRegion line) {
- lines.add(line);
- }
-
- public static int getNumberOfMessages() {
- return lines.size();
- }
-
- public static String getMessage(int index) {
- if (index < lines.size()){
- IRegion lineRegion= (IRegion)lines.get(index);
- try {
- return console.getDocument().get(lineRegion.getOffset(), lineRegion.getLength());
- } catch (BadLocationException e) {
- return null;
- }
- }
- return null;
- }
-
- public static List getAllMessages() {
- List all= new ArrayList(lines.size());
- for (int i = 0; i < lines.size(); i++) {
- IRegion lineRegion= (IRegion)lines.get(i);
- try {
- all.add(console.getDocument().get(lineRegion.getOffset(), lineRegion.getLength()));
- } catch (BadLocationException e) {
- continue;
- }
- }
- return all;
- }
-
- public static IDocument getDocument() {
- return console.getDocument();
- }
-
- public static void waitForConsole() {
- if (consoleClosed) {
- return;
- }
- try {
- synchronized (lines) {
- lines.wait(20000);
- }
- } catch (InterruptedException ie) {
- }
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.debug.ui.console.IConsoleLineTrackerExtension#consoleClosed()
- */
- public void consoleClosed() {
- consoleClosed= true;
-
- synchronized (lines) {
- lines.notifyAll();
- }
- }
-} \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/DebugElementKindEventWaiter.java b/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/DebugElementKindEventWaiter.java
deleted file mode 100644
index e7ea27a45..000000000
--- a/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/DebugElementKindEventWaiter.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.ui.testplugin;
-
-import org.eclipse.debug.core.DebugEvent;
-
-/**
- * Waits for a type of event on a kind of element. Compare this to SpecificDebugElementEventWaiter which is
- * used to wait for a type of event on a specific debug element object.
- */
-
-public class DebugElementKindEventWaiter extends DebugEventWaiter {
-
- protected Class fElementClass;
-
- public DebugElementKindEventWaiter(int eventKind, Class elementClass) {
- super(eventKind);
- fElementClass = elementClass;
- }
-
- public boolean accept(DebugEvent event) {
- Object o = event.getSource();
- return super.accept(event) && fElementClass.isInstance(o);
- }
-
-}
-
-
diff --git a/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/DebugEventWaiter.java b/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/DebugEventWaiter.java
deleted file mode 100644
index 130637e3e..000000000
--- a/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/DebugEventWaiter.java
+++ /dev/null
@@ -1,170 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.ui.testplugin;
-
-import org.eclipse.debug.core.DebugEvent;
-import org.eclipse.debug.core.DebugPlugin;
-import org.eclipse.debug.core.IDebugEventSetListener;
-
-/**
- * The <code>DebugEventWaiter</code> is
- * to wait for a specific kind of debug event.
- * <p>
- * When a <code>DebugEventWaiter</code> is created, it
- * registers itself with the <code>DebugPlugin</code> as
- * an <code>IDebugEventSetListener</code>.
- * <p>
- * NOTE: <code>DebugEventWaiter</code> objects are intended for
- * one time use only!
- */
-public class DebugEventWaiter implements IDebugEventSetListener {
- /**
- * The kind of event the waiter is waiting for
- */
- protected int fEventType;
-
- /**
- * The number of milliseconds the waiter will wait before timing out.
- */
- protected long fTimeout;
-
- /**
- * The <code>IDebugModelManager</code> this waiter is listening to.
- */
- protected DebugPlugin fDebugPlugin;
-
- /**
- * The <code>DebugEvent</code> received.
- */
- protected DebugEvent fEvent;
-
- /**
- * The event set that was accepted
- */
- protected DebugEvent[] fEventSet;
-
- /**
- * The default timeout value if none is given (20000).
- */
- public static final long DEFAULT_TIMEOUT= 15000;
-
- /**
- * Creates a new <code>DebugEventWaiter</code> which
- * waits for events of a kind <code>eventType</code>.
- * The wait method will wait the default timeout value.
- */
- public DebugEventWaiter(int eventType) {
- fDebugPlugin= DebugPlugin.getDefault();
- fEventType= eventType;
- fTimeout= DEFAULT_TIMEOUT;
-
- fDebugPlugin.addDebugEventListener(this);
- }
-
- /**
- * Answers true if the <code>DebugEvent</code> is acceptable.
- */
- public boolean accept(DebugEvent event) {
- return event.getKind() == fEventType && event.getDetail() != DebugEvent.EVALUATION_IMPLICIT;
- }
- /**
- * Answers the event name associated with the given flag.
- */
- public String getEventName(int flag) {
- switch (flag) {
- case DebugEvent.CREATE :
- return "Create";
- case DebugEvent.TERMINATE :
- return "Terminate";
- case DebugEvent.RESUME :
- return "Resume";
- case DebugEvent.SUSPEND :
- return "Suspend";
- default :
- return "UNKNOWN";
- }
- }
-
- /**
- * Handles debug events.
- *
- * @see IDebugEventListener
- * @see #accept(DebugEvent)
- */
- public synchronized void handleDebugEvents(DebugEvent[] events) {
- //printReceived(events);
- for (int i = 0; i < events.length; i++) {
- if (accept(events[i])) {
- fEvent= events[i];
- fEventSet = events;
- unregister();
- notifyAll();
- return;
- }
- }
- }
-
- /**
- * Prints a message indicating which event was received.
- */
- protected void printReceived(DebugEvent[] events) {
- for (int i = 0; i < events.length; i++) {
- System.out.println(this +" got " + events[i]);
- }
- }
-
- /**
- * Sets the number of milliseconds to wait for this callback
- */
- public void setTimeout(long milliseconds) {
- fTimeout= milliseconds;
- }
-
- /**
- * Unregisters this waiter as a listener
- */
- public void unregister() {
- fDebugPlugin.removeDebugEventListener(this);
- }
-
- /**
- * Returns the source of the accepted event, or <code>null</code>
- * if no event was accepted.
- */
- public synchronized Object waitForEvent() {
- if (fEvent == null) {
- try {
- wait(fTimeout);
- } catch (InterruptedException ie) {
- System.err.println("Interrupted waiting for event");
- }
- }
- unregister();
- if (fEvent == null)
- return null;
- return fEvent.getSource();
- }
-
- /**
- * Returns the accepted event, if any.
- */
- public DebugEvent getEvent() {
- return fEvent;
- }
-
- /**
- * Returns the accepted event set, if any.
- */
- public DebugEvent[] getEventSet() {
- return fEventSet;
- }
-}
-
diff --git a/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/ProjectCreationDecorator.java b/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/ProjectCreationDecorator.java
deleted file mode 100644
index 5fb4ffd81..000000000
--- a/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/ProjectCreationDecorator.java
+++ /dev/null
@@ -1,111 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.ui.testplugin;
-
-
-import java.io.File;
-
-import org.eclipse.ant.internal.ui.launchConfigurations.IAntLaunchConfigurationConstants;
-import org.eclipse.ant.internal.ui.model.AntUIPlugin;
-import org.eclipse.ant.internal.ui.model.IAntUIConstants;
-import org.eclipse.ant.internal.ui.model.IAntUIPreferenceConstants;
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.debug.core.DebugPlugin;
-import org.eclipse.debug.core.ILaunchConfigurationType;
-import org.eclipse.debug.core.ILaunchConfigurationWorkingCopy;
-import org.eclipse.debug.ui.IDebugUIConstants;
-import org.eclipse.jdt.launching.IJavaLaunchConfigurationConstants;
-import org.eclipse.jdt.launching.IVMInstall;
-import org.eclipse.jdt.launching.JavaRuntime;
-import org.eclipse.ui.externaltools.internal.model.IExternalToolConstants;
-
-/**
- * Test to close the workbench, since debug tests do not run in the UI
- * thread.
- */
-public class ProjectCreationDecorator extends AbstractAntUITest {
-
- public ProjectCreationDecorator(String name) {
- super(name);
- }
-
- public void testProjectCreation() throws Exception {
- try {
- // delete any pre-existing project
- IProject pro = ResourcesPlugin.getWorkspace().getRoot().getProject(ProjectHelper.PROJECT_NAME);
- if (pro.exists()) {
- pro.delete(true, true, null);
- }
- // create project and import buildfiles and support files
- IProject project = ProjectHelper.createProject(ProjectHelper.PROJECT_NAME);
- IFolder folder = ProjectHelper.addFolder(project, "buildfiles");
- ProjectHelper.addFolder(project, "launchConfigurations");
- File root = AntUITestPlugin.getDefault().getFileInPlugin(ProjectHelper.TEST_BUILDFILES_DIR);
- ProjectHelper.importFilesFromDirectory(root, folder.getFullPath(), null);
-
- createLaunchConfiguration("echoing");
- createLaunchConfiguration("build");
- createLaunchConfiguration("bad");
- createLaunchConfigurationForSeparateVM("echoingSepVM");
- createLaunchConfigurationForSeparateVM("extensionPointSepVM");
- createLaunchConfigurationForSeparateVM("extensionPointTaskSepVM");
- createLaunchConfigurationForSeparateVM("extensionPointTypeSepVM");
- } finally {
- //do not show the Ant build failed error dialog
- AntUIPlugin.getDefault().getPreferenceStore().setValue(IAntUIPreferenceConstants.ANT_ERROR_DIALOG, false);
- }
- }
-
- /**
- * Creates a shared launch configuration for launching Ant in a separate VM with the given
- * name.
- */
- protected void createLaunchConfigurationForSeparateVM(String launchConfigName) throws Exception {
- ILaunchConfigurationType type = getLaunchManager().getLaunchConfigurationType(IAntLaunchConfigurationConstants.ID_ANT_LAUNCH_CONFIGURATION_TYPE);
- ILaunchConfigurationWorkingCopy config = type.newInstance(getJavaProject().getProject().getFolder("launchConfigurations"), launchConfigName);
-
- config.setAttribute(IJavaLaunchConfigurationConstants.ATTR_MAIN_TYPE_NAME, "org.eclipse.ant.internal.ui.antsupport.InternalAntRunner"); //$NON-NLS-1$
- config.setAttribute(IJavaLaunchConfigurationConstants.ATTR_CLASSPATH_PROVIDER, "org.eclipse.ant.ui.AntClasspathProvider"); //$NON-NLS-1$
- config.setAttribute(IJavaLaunchConfigurationConstants.ATTR_PROJECT_NAME, getJavaProject().getElementName());
- config.setAttribute(IExternalToolConstants.ATTR_LOCATION, "${workspace_loc:/" + ProjectHelper.PROJECT_NAME + "/buildfiles/" + launchConfigName + ".xml}");
- config.setAttribute(IDebugUIConstants.ATTR_LAUNCH_IN_BACKGROUND, true);
- config.setAttribute(DebugPlugin.ATTR_PROCESS_FACTORY_ID, IAntUIConstants.REMOTE_ANT_PROCESS_FACTORY_ID);
-
- setVM(config);
-
- config.doSave();
- }
-
- /**
- * Creates a shared launch configuration for launching Ant in a separate VM with the given
- * name.
- */
- protected void createLaunchConfiguration(String launchConfigName) throws Exception {
- ILaunchConfigurationType type = getLaunchManager().getLaunchConfigurationType(IAntLaunchConfigurationConstants.ID_ANT_LAUNCH_CONFIGURATION_TYPE);
- ILaunchConfigurationWorkingCopy config = type.newInstance(getJavaProject().getProject().getFolder("launchConfigurations"), launchConfigName);
-
- config.setAttribute(IJavaLaunchConfigurationConstants.ATTR_PROJECT_NAME, getJavaProject().getElementName());
- config.setAttribute(IExternalToolConstants.ATTR_LOCATION, "${workspace_loc:/" + ProjectHelper.PROJECT_NAME + "/buildfiles/" + launchConfigName + ".xml}");
- config.setAttribute(IDebugUIConstants.ATTR_LAUNCH_IN_BACKGROUND, true);
-
- config.doSave();
- }
-
- private void setVM(ILaunchConfigurationWorkingCopy config) {
- IVMInstall vm = JavaRuntime.getDefaultVMInstall();
- String vmName= vm.getName();
- String vmTypeID= vm.getVMInstallType().getId();
- config.setAttribute(IJavaLaunchConfigurationConstants.ATTR_VM_INSTALL_NAME, vmName);
- config.setAttribute(IJavaLaunchConfigurationConstants.ATTR_VM_INSTALL_TYPE, vmTypeID);
- }
-} \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/ProjectHelper.java b/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/ProjectHelper.java
deleted file mode 100644
index b662503dd..000000000
--- a/ant/org.eclipse.ant.tests.ui/test plugin/org/eclipse/ant/tests/ui/testplugin/ProjectHelper.java
+++ /dev/null
@@ -1,138 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.ui.testplugin;
-
-
-import java.io.File;
-import java.io.IOException;
-import java.lang.reflect.InvocationTargetException;
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IProjectDescription;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IWorkspaceRoot;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.ui.dialogs.IOverwriteQuery;
-import org.eclipse.ui.wizards.datatransfer.FileSystemStructureProvider;
-import org.eclipse.ui.wizards.datatransfer.IImportStructureProvider;
-import org.eclipse.ui.wizards.datatransfer.ImportOperation;
-
-/**
- * Helper methods to set up an IProject.
- */
-public class ProjectHelper {
-
- public static final IPath TEST_BUILDFILES_DIR= new Path("testbuildfiles");
- public static final IPath TEST_RESOURCES_DIR= new Path("testresources");
- public static final IPath TEST_LIB_DIR= new Path("testlib");
-
- public static final String PROJECT_NAME= "Ant UI Tests";
-
- /**
- * Creates a IProject.
- */
- public static IProject createProject(String projectName) throws CoreException {
- IWorkspaceRoot root= ResourcesPlugin.getWorkspace().getRoot();
- IProject project= root.getProject(projectName);
- if (!project.exists()) {
- project.create(null);
- } else {
- project.refreshLocal(IResource.DEPTH_INFINITE, null);
- }
-
- if (!project.isOpen()) {
- project.open(null);
- }
-
- if (!project.hasNature(JavaCore.NATURE_ID)) {
- addNatureToProject(project, JavaCore.NATURE_ID, null);
- }
-
- return project;
- }
-
- private static void addNatureToProject(IProject proj, String natureId, IProgressMonitor monitor) throws CoreException {
- IProjectDescription description = proj.getDescription();
- String[] prevNatures= description.getNatureIds();
- String[] newNatures= new String[prevNatures.length + 1];
- System.arraycopy(prevNatures, 0, newNatures, 0, prevNatures.length);
- newNatures[prevNatures.length]= natureId;
- description.setNatureIds(newNatures);
- proj.setDescription(description, monitor);
- }
-
- /**
- * Removes an IProject.
- */
- public static void delete(IProject project) throws CoreException {
- project.delete(true, true, null);
- }
-
-
- /**
- * Adds a folder to an IProject.
- */
- public static IFolder addFolder(IProject project, String containerName) throws CoreException {
-
- IFolder folder= project.getFolder(containerName);
- if (!folder.exists()) {
- folder.create(false, true, null);
- }
-
- return folder;
-
- }
-
- public static void importFilesFromDirectory(File rootDir, IPath destPath, IProgressMonitor monitor) throws InvocationTargetException, IOException {
- IImportStructureProvider structureProvider = FileSystemStructureProvider.INSTANCE;
- List files = new ArrayList(100);
- addFiles(rootDir, files);
- try {
- ImportOperation op= new ImportOperation(destPath, rootDir, structureProvider, new ImportOverwriteQuery(), files);
- op.setCreateContainerStructure(false);
- op.run(monitor);
- } catch (InterruptedException e) {
- // should not happen
- }
- }
-
- private static void addFiles(File dir, List collection) throws IOException {
- File[] files = dir.listFiles();
- List subDirs = new ArrayList(2);
- for (int i = 0; i < files.length; i++) {
- if (files[i].isFile()) {
- collection.add(files[i]);
- } else if (files[i].isDirectory()) {
- subDirs.add(files[i]);
- }
- }
- Iterator iter = subDirs.iterator();
- while (iter.hasNext()) {
- File subDir = (File)iter.next();
- addFiles(subDir, collection);
- }
- }
-
- private static class ImportOverwriteQuery implements IOverwriteQuery {
- public String queryOverwrite(String file) {
- return ALL;
- }
- }
-} \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/test support/org/eclipse/ant/tests/ui/support/tasks/AntTestTask.java b/ant/org.eclipse.ant.tests.ui/test support/org/eclipse/ant/tests/ui/support/tasks/AntTestTask.java
deleted file mode 100644
index ce7b33ad6..000000000
--- a/ant/org.eclipse.ant.tests.ui/test support/org/eclipse/ant/tests/ui/support/tasks/AntTestTask.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.ui.support.tasks;
-
-import org.apache.tools.ant.BuildException;
-import org.apache.tools.ant.Task;
-import org.apache.tools.ant.taskdefs.Echo;
-
-
-public class AntTestTask extends Task {
-
- public AntTestTask() {
- super();
- }
-
- /**
- * @see org.apache.tools.ant.Task#execute()
- */
- public void execute() throws BuildException {
- Echo echo= new Echo();
- echo.setProject(getProject());
- echo.setMessage("Testing Ant in Eclipse with a custom task");
- echo.execute();
- }
-}
diff --git a/ant/org.eclipse.ant.tests.ui/test support/org/eclipse/ant/tests/ui/support/tasks/AntTestTask2.java b/ant/org.eclipse.ant.tests.ui/test support/org/eclipse/ant/tests/ui/support/tasks/AntTestTask2.java
deleted file mode 100644
index 3ab7baf95..000000000
--- a/ant/org.eclipse.ant.tests.ui/test support/org/eclipse/ant/tests/ui/support/tasks/AntTestTask2.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.ui.support.tasks;
-
-import org.apache.tools.ant.BuildException;
-import org.apache.tools.ant.Task;
-import org.apache.tools.ant.taskdefs.Echo;
-import org.apache.tools.ant.types.EnumeratedAttribute;
-import org.apache.tools.ant.types.Reference;
-
-
-public class AntTestTask2 extends Task {
-
- String fMessage= "Default";
- Reference fRef= null;
-
- public AntTestTask2() {
- super();
- }
-
- /**
- * @see org.apache.tools.ant.Task#execute()
- */
- public void execute() throws BuildException {
- Echo echo= new Echo();
- echo.setProject(getProject());
- echo.setMessage("Testing Ant in Eclipse with a custom task2: " + fMessage);
- echo.execute();
- }
-
- public void setMessage(Cool attr) {
- fMessage = attr.getValue();
- }
-
- public void setReference(Reference ref) {
- fRef= ref;
- }
-
- /**
- * Enumerated attribute with the values "cool", "chillin" and "awesome".
- */
- public static class Cool extends EnumeratedAttribute {
- public String[] getValues() {
- return new String[] {"cool", "chillin", "awesome"};
- }
- }
-}
diff --git a/ant/org.eclipse.ant.tests.ui/test support/org/eclipse/ant/tests/ui/support/tasks/NestElementTask.java b/ant/org.eclipse.ant.tests.ui/test support/org/eclipse/ant/tests/ui/support/tasks/NestElementTask.java
deleted file mode 100644
index 6541072f8..000000000
--- a/ant/org.eclipse.ant.tests.ui/test support/org/eclipse/ant/tests/ui/support/tasks/NestElementTask.java
+++ /dev/null
@@ -1,52 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.ant.tests.ui.support.tasks;
-
-import org.apache.tools.ant.BuildException;
-import org.apache.tools.ant.Task;
-import org.apache.tools.ant.taskdefs.Echo;
-
-public class NestElementTask extends Task {
-
- String message= "bar";
- NestedElement e;
- public static class NestedElement{
- Boolean works= Boolean.FALSE;
- public NestedElement() {
- }
-
- public void setWorks(Boolean booleanValue) {
- works= booleanValue;
- }
-
- public boolean works() {
- return works.booleanValue();
- }
- }
- public void addNestedElement(NestedElement nestedElement) {
- e= nestedElement;
- }
-
- /* (non-Javadoc)
- * @see org.apache.tools.ant.Task#execute()
- */
- public void execute() throws BuildException {
- Echo echo= new Echo();
- echo.setProject(getProject());
- if (e.works()) {
- echo.setMessage(message);
- } else {
- echo.setMessage("ack");
- }
- echo.execute();
- }
-} \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/test support/org/eclipse/ant/tests/ui/support/types/AntTestPath.java b/ant/org.eclipse.ant.tests.ui/test support/org/eclipse/ant/tests/ui/support/types/AntTestPath.java
deleted file mode 100644
index 602242086..000000000
--- a/ant/org.eclipse.ant.tests.ui/test support/org/eclipse/ant/tests/ui/support/types/AntTestPath.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ant.tests.ui.support.types;
-
-import org.apache.tools.ant.Project;
-import org.apache.tools.ant.types.Path;
-
-public class AntTestPath extends Path {
-
- String message;
-
- public AntTestPath(Project project) {
- super(project);
- }
-
- public void setMessage(String message) {
- this.message= message;
- }
-
- public String getMessage() {
- return message;
- }
-
-}
diff --git a/ant/org.eclipse.ant.tests.ui/test.xml b/ant/org.eclipse.ant.tests.ui/test.xml
deleted file mode 100644
index e5dff43e1..000000000
--- a/ant/org.eclipse.ant.tests.ui/test.xml
+++ /dev/null
@@ -1,50 +0,0 @@
-<?xml version="1.0"?>
-
-<project name="testsuite" default="run" basedir=".">
- <!-- sets the properties eclipse-home, and library-file -->
- <!-- The property ${eclipse-home} should be passed into this script -->
- <!-- Set a meaningful default value for when it is not. -->
- <property name="eclipse-home" value="${basedir}\..\.."/>
-<property name="plugin-name" value="org.eclipse.ant.tests.ui"/>
- <property name="library-file"
- value="${eclipse-home}/plugins/org.eclipse.test/library.xml"/>
-
- <!-- This target holds all initialization code that needs to be done for -->
- <!-- all tests that are to be run. Initialization for individual tests -->
- <!-- should be done within the body of the suite target. -->
- <target name="init">
- <tstamp/>
- <delete>
- <fileset dir="${eclipse-home}" includes="org*.xml"/>
- </delete>
- </target>
-
- <!-- This target defines the tests that need to be run. -->
- <target name="suite">
- <property name="jdt-folder"
- value="${eclipse-home}/jdt_folder"/>
- <delete dir="${jdt-folder}" quiet="true"/>
- <ant target="ui-test" antfile="${library-file}" dir="${eclipse-home}">
- <property name="data-dir" value="${jdt-folder}"/>
- <property name="plugin-name" value="${plugin-name}"/>
- <property name="classname"
- value="org.eclipse.ant.tests.ui.testplugin.AntUITests"/>
- </ant>
- </target>
-
- <!-- This target holds code to cleanup the testing environment after -->
- <!-- after all of the tests have been run. You can use this target to -->
- <!-- delete temporary files that have been created. -->
- <target name="cleanup">
- </target>
-
- <!-- This target runs the test suite. Any actions that need to happen -->
- <!-- after all the tests have been run should go here. -->
- <target name="run" depends="init,suite,cleanup">
- <ant target="collect" antfile="${library-file}" dir="${eclipse-home}">
- <property name="includes" value="org*.xml"/>
- <property name="output-file" value="${plugin-name}.xml"/>
- </ant>
- </target>
-
-</project>
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/antUITestsSupport.jar b/ant/org.eclipse.ant.tests.ui/testbuildfiles/antUITestsSupport.jar
deleted file mode 100644
index 054eec8ad..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/antUITestsSupport.jar
+++ /dev/null
Binary files differ
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/bad.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/bad.xml
deleted file mode 100644
index f1c4d51bf..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/bad.xml
+++ /dev/null
@@ -1,14 +0,0 @@
-<project name="Echoing" default="echo1" basedir="..">
-
- <target name="echo1">
- <echo messge="echo1"/>
- </target>
-
- <target name="echo2">
- <echo message="echo2"/>
- </target>
-
- <target name="echo3" description= "An echo3!">
- <echo message="echo3"/>
- </target>
-</project>
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/badproject.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/badproject.xml
deleted file mode 100644
index 60a79a89a..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/badproject.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<project ndefault="make">
- <target name="make">
- </target>
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/build.Cp1251.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/build.Cp1251.xml
deleted file mode 100644
index 6ff953999..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/build.Cp1251.xml
+++ /dev/null
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="windows-1251"?>
-<project name="test" default="init" basedir=".">
-
- <target name="init">
- <!-- displays Hello in Russian -->
- <echo message="Çäðàâñòâóéòå"/>
- </target>
-
-
-</project>
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/build.UTF8.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/build.UTF8.xml
deleted file mode 100644
index 08e4733f1..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/build.UTF8.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project name="test" default="init" basedir=".">
-
- <target name="init">
- <!-- displays Hello in Russian -->
- <echo message="ЗдравÑ?твуйте"/>
- </target>
-
-</project>
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/build.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/build.xml
deleted file mode 100644
index 5cdd64da7..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/build.xml
+++ /dev/null
@@ -1,14 +0,0 @@
-<project name="Echoing" default="echo1" basedir="..">
-
- <target name="echo1">
- <echo message="echo1"/>
- </target>
-
- <target name="echo2">
- <echo message="echo2"/>
- </target>
-
- <target name="echo3" description= "An echo3!">
- <echo message="echo3"/>
- </target>
-</project>
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/buildtest1.properties b/ant/org.eclipse.ant.tests.ui/testbuildfiles/buildtest1.properties
deleted file mode 100644
index c407ebe5b..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/buildtest1.properties
+++ /dev/null
@@ -1,2 +0,0 @@
-prop1=val1
-prop2 = val2
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/buildtest1.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/buildtest1.xml
deleted file mode 100644
index 9e042ff45..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/buildtest1.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project name="testproject" basedir="." default="main">
- <property name="propD" value="valD" />
- <property file="buildtest1.properties" />
- <property name="propV" value="valV" />
- <target name="main">
- <property name="property_in_target" value="val"/>
- <echo>${</echo>
- </target>
- <target name="pretest"></target>
- <target name="test" depends="">
- <echo>depends</echo>
- </target>
- <target name="test2"></target>
- <target name="test3"></target>
- <target name="testIf" if=""></target>
- <target name="testUnless" unless="prop"></target>
- <target name="testMoreDepends" depends="pretest, ">
- <echo message="$"></echo>
- </target>
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/buildtest2.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/buildtest2.xml
deleted file mode 100644
index 0e3e5d3a5..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/buildtest2.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project name="testproject" basedir="." default="main">
- <property name="propD" value="valD" />
- <property file="buildtest1.properties" />
- <target name="main" depends="properties">
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/customBoolean.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/customBoolean.xml
deleted file mode 100644
index 1dd37a02a..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/customBoolean.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-<project default="defaultTargetName">
- <target name="defaultTargetName">
- <eclipse.buildScript recursivegeneration=""/>
- </target>
-</project>
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/dependencytest.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/dependencytest.xml
deleted file mode 100644
index d26ba5769..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/dependencytest.xml
+++ /dev/null
@@ -1,38 +0,0 @@
-<!-- Ein test case sollte die property proposals in main -->
-<!-- Ueberpruefen, und ob die diversen properties entsprechend -->
-<!-- der dependencies gesetzt sind -->
-
-<project default="main">
-
- <property name="do_init" value="val"></property>
-
- <target name="properties">
- <property name="prop_prop" value="val"></property>
- <property name="do_not_compile" value="val"></property>
- <echo message="executing properties"></echo>
- </target>
-
- <!-- should never be executed since property is not set -->
- <target name="additional_properties" if="do_addit_props">
- <property name="adit_prop" value="val" />
- <echo message="executing additional_properties"></echo>
- </target>
-
- <target name="init" if="doinit" depends="properties,additional_properties">
- <property name="init_prop" value="val"></property>
- <echo message="executing init"></echo>
- </target>
-
- <!-- should never be executed since property should be set -->
- <!-- by properties because of dependencies before -->
- <target name="compile" unless="do_not_compile">
- <property name="compile_prop" value="val"></property>
- <echo message="executing compile"></echo>
- </target>
-
- <target name="main" depends="init, compile">
- <property name="main_prop" value="val"></property>
- <echo message="executing main ${well}"></echo>
- </target>
-
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/echoing.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/echoing.xml
deleted file mode 100644
index 5cdd64da7..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/echoing.xml
+++ /dev/null
@@ -1,14 +0,0 @@
-<project name="Echoing" default="echo1" basedir="..">
-
- <target name="echo1">
- <echo message="echo1"/>
- </target>
-
- <target name="echo2">
- <echo message="echo2"/>
- </target>
-
- <target name="echo3" description= "An echo3!">
- <echo message="echo3"/>
- </target>
-</project>
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/echoingSepVM.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/echoingSepVM.xml
deleted file mode 100644
index 97b498461..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/echoingSepVM.xml
+++ /dev/null
@@ -1,19 +0,0 @@
-<project name="Echoing" default="echo1" basedir="..">
-
- <target name="echo1">
- <echo message="echo1"/>
- </target>
-
- <target name="echo2">
- <echo message="echo2"/>
- </target>
-
- <target name="echo3" description= "An echo3!">
- <echo message="echo3"/>
- </target>
-
- <target name="Bug42984">
- <echo message="user.dir: ${user.dir}"/>
- </target>
-
-</project>
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/empty.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/empty.xml
deleted file mode 100644
index e69de29bb..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/empty.xml
+++ /dev/null
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/extensionPointSepVM.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/extensionPointSepVM.xml
deleted file mode 100644
index 2735ed092..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/extensionPointSepVM.xml
+++ /dev/null
@@ -1,14 +0,0 @@
-<project name="Extension point testing in separate VM"
- default="Extension Points"
- basedir="."
- >
- <taskdef name="separateVMTask" classname="org.eclipse.ant.tests.ui.support.tasks.AntTestTask">
- </taskdef>
- <target name="Extension Points"
- description= "Ensure that an extra classpath entry designated as not requiring the Eclipse runtime shows up in a separate VM build"
- >
- <separateVMTask/>
- <echo>${property.ui.testing}</echo>
- <echo>${property.ui.testing2}</echo>
- </target>
-</project>
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/extensionPointTaskSepVM.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/extensionPointTaskSepVM.xml
deleted file mode 100644
index c8e4945ec..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/extensionPointTaskSepVM.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-<project name="Extension Point Task" default="Extension Point Task" basedir=".">
- <target name="Extension Point Task" description= "Ensure that an extension point defined task is present">
- <coolUITask message="cool" reference=""/>
- </target>
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/extensionPointTypeSepVM.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/extensionPointTypeSepVM.xml
deleted file mode 100644
index bba955e35..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/extensionPointTypeSepVM.xml
+++ /dev/null
@@ -1,12 +0,0 @@
-<project name="Extension Point Type" default="Extension Point Type" basedir=".">
-
- <coolUIType id="compile.classpath">
- <fileset dir="lib">
- <include name="**/*.jar"/>
- </fileset>
- </coolUIType>
-
- <target name="Extension Point Type" description= "Ensure that an extension point defined type is present">
- <echo message="Ensure that an extension point defined type is present"/>
- </target>
-</project>
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/formatTest_source01.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/formatTest_source01.xml
deleted file mode 100644
index be1ff78fd..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/formatTest_source01.xml
+++ /dev/null
@@ -1,14 +0,0 @@
-<project default="formatTest">
-
-<!-- = = = = = = --><!-- formatTest --><!-- = = = = = = --><target name="formatTest" depends="init" description="--> test target one"><!-- hello world --><greeting /></target>
-
-<!-- - - - - - - -->
-<!-- init -->
-<!-- - - - - - - -->
-<target name="init">
- <property name="greeting" value="hi" />
- <presetdef name="greeting"><echo>${greeting}</echo>
-</presetdef>
- </target>
-
-</project>
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/formatTest_target01.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/formatTest_target01.xml
deleted file mode 100644
index 30592281e..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/formatTest_target01.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<project default="formatTest">
-
- <!-- = = = = = = -->
- <!-- formatTest -->
- <!-- = = = = = = -->
- <target name="formatTest" depends="init" description="--> test target one">
- <!-- hello world -->
- <greeting />
- </target>
-
- <!-- - - - - - - -->
- <!-- init -->
- <!-- - - - - - - -->
- <target name="init">
- <property name="greeting" value="hi" />
- <presetdef name="greeting">
- <echo>${greeting}</echo>
- </presetdef>
- </target>
-
-</project>
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/formatTest_target02.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/formatTest_target02.xml
deleted file mode 100644
index 6a1ad9c13..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/formatTest_target02.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<project default="formatTest">
-
- <!-- = = = = = = -->
- <!-- formatTest -->
- <!-- = = = = = = -->
- <target name="formatTest" depends="init" description="--> test target one">
- <!-- hello world -->
- <greeting />
- </target>
-
- <!-- - - - - - - -->
- <!-- init -->
- <!-- - - - - - - -->
- <target name="init">
- <property name="greeting" value="hi" />
- <presetdef name="greeting">
- <echo>${greeting}</echo>
- </presetdef>
- </target>
-
-</project>
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/formatTest_target03.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/formatTest_target03.xml
deleted file mode 100644
index 89cd95330..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/formatTest_target03.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<project default="formatTest">
-
- <!-- = = = = = = -->
- <!-- formatTest -->
- <!-- = = = = = = -->
- <target name="formatTest" depends="init" description="--> test target one">
- <!-- hello world -->
- <greeting />
- </target>
-
- <!-- - - - - - - -->
- <!-- init -->
- <!-- - - - - - - -->
- <target name="init">
- <property name="greeting" value="hi" />
- <presetdef name="greeting">
- <echo>${greeting}</echo>
- </presetdef>
- </target>
-
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/javac.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/javac.xml
deleted file mode 100644
index 61e00c2c4..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/javac.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-<project default="javacIt">
- <target name="javacIt">
- <javac includejavaruntime=""
- followsymlinks=""
- includeantruntime=""/>
- </target>
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/macrodef.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/macrodef.xml
deleted file mode 100644
index 051f01b58..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/macrodef.xml
+++ /dev/null
@@ -1,18 +0,0 @@
-<project default="type">
-
- <macrodef name="eclipseMacro">
- <attribute name="v" default="NOT SET" />
- <attribute name="eclipse" default="yes" description="Testing Eclipse"/>
- <element name="some-tasks" optional="yes" />
- <sequential>
- <echo>Eclipse!: @{v}</echo>
- </sequential>
- </macrodef>
-
- <target name="type">
- <eclipseMacro v="This is v">
-
- </eclipseMacro>
- </target>
-
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/mixed.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/mixed.xml
deleted file mode 100644
index 368edbb86..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/mixed.xml
+++ /dev/null
@@ -1 +0,0 @@
-<project><target><sql driver="" password="" url="" userid=""></sql><concat></concat></target></project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/nestedElementAttributes.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/nestedElementAttributes.xml
deleted file mode 100644
index 3b0d91923..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/nestedElementAttributes.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-<project default="go">
- <taskdef name="nestedTest" classname="org.eclipse.ant.tests.ui.support.tasks.NestElementTask" />
- <target name="go">
- <nestedTest>
- <nestedelement works="" />
- </nestedTest>
- </target>
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/outline_select_test_build.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/outline_select_test_build.xml
deleted file mode 100644
index 7df0f5e96..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/outline_select_test_build.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project name="org.eclipse.ui.externaltools.internal.ant.editor" default="zip.plugin" basedir=".">
- <target name="init" depends="properties">
- <property file="build.properties" />
- <property name="version.suffix" value="_0.4.5" />
- <property name="plugins_dir" value="${eclipse_dir}/plugins" />
- <property name="plugin" value="org.eclipse.ui.externaltools.internal.ant.editor" />
- <property name="full.name" value="${plugin}${version.suffix}" />
- <property name="temp.folder" value="${basedir}/temp.folder" />
- <property name="plugin.destination" value="${basedir}" />
- <property name="build.result.folder" value="${basedir}" />
- <property name="source.antEditor.jar" value="src/" />
- <echo message="Value is ${plugins_dir}" />
- </target>
-
- <target name="properties" if="eclipse.running">
- <property name="build.compiler" value="org.eclipse.jdt.core.JDTCompilerAdapter"/>
- </target>
-
-</project>
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/projectOnly.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/projectOnly.xml
deleted file mode 100644
index 35ece5b8f..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/projectOnly.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-
-
-
-<project ></project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/refid.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/refid.xml
deleted file mode 100644
index 23eb56c5d..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/refid.xml
+++ /dev/null
@@ -1,13 +0,0 @@
-<project default="1">
- <path id="project.class.path">
- <pathelement location="lib/" />
- <pathelement path="${java.class.path}/" />
- <pathelement path="${additional.path}" />
- </path>
-
- <target name="1">
- <path id="project.class.path2">
- <path refid="project.class.path" />
- </path>
- </target>
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/russianbuild.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/russianbuild.xml
deleted file mode 100644
index d8535663e..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/russianbuild.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-<?xml version="1.0" encoding="windows-1251"?>
-<project name="test" default="init" basedir=".">
-
- <target name="init">
- <!-- displays Hello in Russian -->
- <echo message="Çäðàâñòâóéòå"/>
- </target>
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/taskdef.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/taskdef.xml
deleted file mode 100644
index 4aa66a840..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/taskdef.xml
+++ /dev/null
@@ -1,10 +0,0 @@
-<project default="type">
-
- <taskdef name="mine" classname="org.eclipse.ant.tests.ui.support.tasks.AntTestTask" classpath="antUITestsSupport.jar">
- </taskdef>
-
- <target name="type">
-
- </target>
-
-</project> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/test1.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/test1.xml
deleted file mode 100644
index 6f60a3281..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/test1.xml
+++ /dev/null
@@ -1,10 +0,0 @@
-
-<bla>
- <blub></blub>
- <klick>
- <gurgel></gurgel>
- <hal
- <klack/>
- <humpf/>
- </klick>
-</bla> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/test2.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/test2.xml
deleted file mode 100644
index 1ca876585..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/test2.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-<bla>
- <blub></blub>
- <klick>
- <gurgel></gurgel>
- <hal></hal>
- <klack/>
- <humpf/>
- </klick>
-</bla> \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/test3.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/test3.xml
deleted file mode 100644
index 674088ee7..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/test3.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<bla>
- <blub>
- </blub>
-</
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/test4.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/test4.xml
deleted file mode 100644
index fd60f79fb..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/test4.xml
+++ /dev/null
@@ -1 +0,0 @@
-<target name="main"><mk \ No newline at end of file
diff --git a/ant/org.eclipse.ant.tests.ui/testbuildfiles/test5.xml b/ant/org.eclipse.ant.tests.ui/testbuildfiles/test5.xml
deleted file mode 100644
index c297d9565..000000000
--- a/ant/org.eclipse.ant.tests.ui/testbuildfiles/test5.xml
+++ /dev/null
@@ -1,6 +0,0 @@
-<project name="main">
- <target name="bla" />
- <property name="prop1" value="val1"/>
- <property name="prop2" value="val2"/>
- <property name="prop3" value="val3"/>
-<g \ No newline at end of file
diff --git a/platform/org.eclipse.platform/css/whatsnew/swt.properties b/platform/org.eclipse.platform/css/whatsnew/swt.properties
index 1f60ce8fd..c3ae882ae 100644
--- a/platform/org.eclipse.platform/css/whatsnew/swt.properties
+++ b/platform/org.eclipse.platform/css/whatsnew/swt.properties
@@ -7,4 +7,9 @@ news.page-content.news-links.migration.link-icon = css/graphics/icons/obj48/migr
news.page-content.news-links.updates.link-icon = css/graphics/icons/obj48/updates_obj.gif
news.page-content.news-links.eclipse.link-icon = css/graphics/icons/obj48/community_obj.gif
+news.page-content.noteworthy-links.layout.ncolumns = 2
+news.page-content.noteworthy-links.layout.vspacing = 30
+
+news.link-icon = css/graphics/icons/obj48/new_obj.gif
+
news.subtitle-id = news/page-content/page-title
diff --git a/platform/org.eclipse.platform/css/whatsnew/whatsnew.css b/platform/org.eclipse.platform/css/whatsnew/whatsnew.css
index 653025b8b..db426ebf7 100644
--- a/platform/org.eclipse.platform/css/whatsnew/whatsnew.css
+++ b/platform/org.eclipse.platform/css/whatsnew/whatsnew.css
@@ -12,6 +12,59 @@ body {
* two columns that are centered in the middle of the page.
*/
+#noteworthy-links {
+ text-align : left;
+ width : 760px;
+ /* To center in Moz (have to use text-align for IE) */
+ margin: 0px auto;
+}
+
+#noteworthy-links a {
+ width : 370px;
+ text-align : left;
+ margin-left : 5px;
+ margin-right : 5px;
+ margin-top : 5px;
+ margin-bottom : -20px;
+ vertical-align : top;
+}
+
+#noteworthy-links > a { vertical-align : middle; }
+
+#noteworthy-links a img {
+ height : 57px;
+ width : 57px;
+ vertical-align : middle;
+}
+
+#noteworthy-links a .link-label {
+ display : block;
+ width : 300px;
+ position : relative;
+ top : -50px;
+ left : 60px;
+}
+
+#noteworthy-links a p .text {
+ display : block;
+ width : 300px;
+ position : relative;
+ top : -45px;
+ left : 53px;
+}
+
+/* Special case for Mozilla, because the links are displayed
+ in 1 vertical column instead of 2 centered columns */
+#noteworthy-links > a { width : 700px; }
+#noteworthy-links a > .link-label { width : 700px; }
+#noteworthy-links a p > .text { width : 700px; }
+
+#noteworthy-links a:hover { border-right : 5px; }
+
+#noteworthy-links a img { background-image : url(../graphics/icons/obj48/new_obj.gif); }
+#noteworthy-links a:hover img { background-image : url(../graphics/icons/obj48/newhov_obj.gif); }
+
+
#news-links {
text-align : left;
width : 760px;
diff --git a/platform/org.eclipse.platform/introContent.xml b/platform/org.eclipse.platform/introContent.xml
index 10628ad97..154adce1f 100644
--- a/platform/org.eclipse.platform/introContent.xml
+++ b/platform/org.eclipse.platform/introContent.xml
@@ -167,10 +167,15 @@
<group id="page-content">
<text style-id="page-title" id="page-title">WHAT'S NEW</text>
<anchor id="beginAnchor"/>
- <group id="news-links">
- <link label="New and noteworthy" url="http://org.eclipse.ui.intro/showHelpTopic?id=/org.eclipse.platform.doc.user/whatsNew/platform_whatsnew.html" id="new-and-noteworthy">
+ <group id="noteworthy-links" label="New and Noteworthy">
+ <link label="Eclipse Platform" url="http://org.eclipse.ui.intro/showHelpTopic?id=/org.eclipse.platform.doc.user/whatsNew/platform_whatsnew.html" id="platform-noteworthy" style-id="noteworthy-link">
<text>Find out about the major new features in this release</text>
</link>
+ <anchor id="jdtAnchor"/>
+ <anchor id="pdeAnchor"/>
+ <anchor id="generalAnchor"/>
+ </group>
+ <group id="news-links" label="General">
<link label="Migration from the previous release" url="http://org.eclipse.ui.intro/showHelpTopic?id=/org.eclipse.platform.doc.isv/porting/eclipse_3_0_porting_guide.html" id="migration">
<text>Learn what you need to do to make your old code work in Eclipse 3.0</text>
</link>
diff --git a/platform/org.eclipse.sdk/.project b/platform/org.eclipse.sdk/.project
deleted file mode 100644
index 2e498c237..000000000
--- a/platform/org.eclipse.sdk/.project
+++ /dev/null
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.sdk</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- </buildSpec>
- <natures>
- </natures>
-</projectDescription>
diff --git a/platform/org.eclipse.sdk/about.html b/platform/org.eclipse.sdk/about.html
deleted file mode 100644
index 9db411aab..000000000
--- a/platform/org.eclipse.sdk/about.html
+++ /dev/null
@@ -1,30 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<title>About</title>
-<meta http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<p>20th June, 2002</p>
-<h3>License</h3>
-<p>Eclipse.org makes available all content in this plug-in (&quot;Content&quot;). Unless otherwise indicated below, the Content is provided to you under the terms and conditions of the
-Common Public License Version 1.0 (&quot;CPL&quot;). A copy of the CPL is available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>.
-For purposes of the CPL, &quot;Program&quot; will mean the Content.</p>
-
-<h3>Contributions</h3>
-
-<p>If this Content is licensed to you under the terms and conditions of the CPL, any Contributions, as defined in the CPL, uploaded, submitted, or otherwise
-made available to Eclipse.org, members of Eclipse.org and/or the host of Eclipse.org web site, by you that relate to such
-Content are provided under the terms and conditions of the CPL and can be made available to others under the terms of the CPL.</p>
-
-<p>If this Content is licensed to you under license terms and conditions other than the CPL (&quot;Other License&quot;), any modifications, enhancements and/or
-other code and/or documentation (&quot;Modifications&quot;) uploaded, submitted, or otherwise made available to Eclipse.org, members of Eclipse.org and/or the
-host of Eclipse.org, by you that relate to such Content are provided under terms and conditions of the Other License and can be made available
-to others under the terms of the Other License. In addition, with regard to Modifications for which you are the copyright holder, you are also
-providing the Modifications under the terms and conditions of the CPL and such Modifications can be made available to others under the terms of
-the CPL.</p>
-
-</body>
-</html> \ No newline at end of file
diff --git a/platform/org.eclipse.sdk/about.ini b/platform/org.eclipse.sdk/about.ini
deleted file mode 100644
index 42c1189f5..000000000
--- a/platform/org.eclipse.sdk/about.ini
+++ /dev/null
@@ -1,31 +0,0 @@
-# about.ini
-# contains information about a feature
-# java.io.Properties file (ISO 8859-1 with "\" escapes)
-# "%key" are externalized strings defined in about.properties
-# This file does not need to be translated.
-
-# Property "aboutText" contains blurb for "About" dialog (translated)
-aboutText=%blurb
-
-# Property "windowImage" contains path to window icon (16x16)
-# needed for primary features only
-
-# Property "featureImage" contains path to feature image (32x32)
-featureImage=eclipse32.gif
-
-# Property "aboutImage" contains path to product image (500x330 or 115x164)
-# needed for primary features only
-
-# Property "appName" contains name of the application (translated)
-# needed for primary features only
-
-# Property "welcomePage" contains path to welcome page (special XML-based format)
-# optional
-
-# Property "welcomePerspective" contains the id of the perspective in which the
-# welcome page is to be opened.
-# optional
-
-
-
-
diff --git a/platform/org.eclipse.sdk/about.mappings b/platform/org.eclipse.sdk/about.mappings
deleted file mode 100644
index 720ca870f..000000000
--- a/platform/org.eclipse.sdk/about.mappings
+++ /dev/null
@@ -1,6 +0,0 @@
-# about.mappings
-# contains fill-ins for about.properties
-# java.io.Properties file (ISO 8859-1 with "\" escapes)
-# This file does not need to be translated.
-
-0=@build@ \ No newline at end of file
diff --git a/platform/org.eclipse.sdk/about.properties b/platform/org.eclipse.sdk/about.properties
deleted file mode 100644
index 0d65b0914..000000000
--- a/platform/org.eclipse.sdk/about.properties
+++ /dev/null
@@ -1,14 +0,0 @@
-# about.properties
-# contains externalized strings for about.ini
-# java.io.Properties file (ISO 8859-1 with "\" escapes)
-# fill-ins are supplied by about.mappings
-# This file should be translated.
-
-blurb=Eclipse Project SDK\n\
-\n\
-Version: {featureVersion}\n\
-Build id: {0}\n\
-\n\
-(c) Copyright Eclipse contributors and others 2000, 2004. All rights reserved.\n\
-Visit http://www.eclipse.org/eclipse
-
diff --git a/platform/org.eclipse.sdk/build.properties b/platform/org.eclipse.sdk/build.properties
deleted file mode 100644
index 043a4f2bf..000000000
--- a/platform/org.eclipse.sdk/build.properties
+++ /dev/null
@@ -1,8 +0,0 @@
-bin.includes=\
-about.html,\
-about.ini,\
-about.mappings,\
-about.properties,\
-eclipse32.gif,\
-plugin.xml,\
-plugin.properties
diff --git a/platform/org.eclipse.sdk/eclipse32.gif b/platform/org.eclipse.sdk/eclipse32.gif
deleted file mode 100644
index f71a8f6f9..000000000
--- a/platform/org.eclipse.sdk/eclipse32.gif
+++ /dev/null
Binary files differ
diff --git a/platform/org.eclipse.sdk/plugin.properties b/platform/org.eclipse.sdk/plugin.properties
deleted file mode 100644
index 73152aaa0..000000000
--- a/platform/org.eclipse.sdk/plugin.properties
+++ /dev/null
@@ -1,21 +0,0 @@
-pluginName=Eclipse Project SDK
-providerName=Eclipse.org
-
-activity.java=Java Development
-activity.java.desc=Develop Java applications.
-activity.plugin=Plug-in Development
-activity.plugin.desc=Develop plug-ins, fragments, and features for Eclipse.
-
-activity.team.cvs=CVS Support
-activity.team.cvs.desc=Use the Concurrent Versions System (CVS) to manage resources.
-activity.team=Core Team Support
-activity.team.desc=Share projects using configuration management systems.
-
-activity.cat.development=Development
-activity.cat.development.desc=Use the Eclipse SDK to develop applications.
-activity.cat.team=Team
-activity.cat.team.desc=Use configuration management systems to manage resources.
-
-
-
-
diff --git a/platform/org.eclipse.sdk/plugin.xml b/platform/org.eclipse.sdk/plugin.xml
deleted file mode 100644
index 57d9ec300..000000000
--- a/platform/org.eclipse.sdk/plugin.xml
+++ /dev/null
@@ -1,156 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.0"?>
-<plugin
- id="org.eclipse.sdk"
- name="%pluginName"
- version="3.0.0"
- provider-name="%providerName">
-
- <requires>
- <import plugin="org.eclipse.ui"/>
- </requires>
-
-
- <extension
- point="org.eclipse.ui.activities">
-
- <activity
- name="%activity.java"
- description="%activity.java.desc"
- id="org.eclipse.javaDevelopment">
- </activity>
-
- <activity
- name="%activity.plugin"
- description="%activity.plugin.desc"
- id="org.eclipse.plugInDevelopment">
- </activity>
-
- <activityRequirementBinding
- activityId="org.eclipse.plugInDevelopment"
- requiredActivityId="org.eclipse.javaDevelopment">
- </activityRequirementBinding>
-
- <activity
- name="%activity.team.cvs"
- description="%activity.team.cvs.desc"
- id="org.eclipse.team.cvs">
- </activity>
-
- <activity
- name="%activity.team"
- description="%activity.team.desc"
- id="org.eclipse.team">
- </activity>
-
- <activityRequirementBinding
- activityId="org.eclipse.team.cvs"
- requiredActivityId="org.eclipse.team">
- </activityRequirementBinding>
-
- <activityPatternBinding
- activityId="org.eclipse.javaDevelopment"
- pattern="org\.eclipse\.jdt\.debug/debugModel">
- </activityPatternBinding>
-
- <activityPatternBinding
- activityId="org.eclipse.javaDevelopment"
- pattern="org\.eclipse\.jdt\..*/.*">
- </activityPatternBinding>
-
- <activityPatternBinding
- activityId="org.eclipse.javaDevelopment"
- pattern="org\.eclipse\.jdt\.core/javanature">
-
- </activityPatternBinding>
-
- <activityPatternBinding
- activityId="org.eclipse.plugInDevelopment"
- pattern="org\.eclipse\.pde\..*/.*">
- </activityPatternBinding>
-
- <activityPatternBinding
- activityId="org.eclipse.plugInDevelopment"
- pattern="org\.eclipse\.pde/PluginNature">
- </activityPatternBinding>
- <activityPatternBinding
- activityId="org.eclipse.team"
- pattern="org\.eclipse\.team\.ui/org.*">
- </activityPatternBinding>
- <activityPatternBinding
- activityId="org.eclipse.team.cvs"
- pattern="org\.eclipse\.team\.cvs\.ui/.*">
- </activityPatternBinding>
- <activityPatternBinding
- activityId="org.eclipse.team.cvs"
- pattern="org\.eclipse\.team\.cvs\.core/.*cvsnature">
- </activityPatternBinding>
-
- <category
- name="%activity.cat.development"
- description="%activity.cat.development.desc"
- id="org.eclipse.categories.developmentCategory">
- </category>
-
- <category
- name="%activity.cat.team"
- description="%activity.cat.team.desc"
- id="org.eclipse.categories.teamCategory">
-
- </category>
-
- <categoryActivityBinding
- activityId="org.eclipse.javaDevelopment"
- categoryId="org.eclipse.categories.developmentCategory">
- </categoryActivityBinding>
-
- <categoryActivityBinding
- activityId="org.eclipse.plugInDevelopment"
- categoryId="org.eclipse.categories.developmentCategory">
- </categoryActivityBinding>
-
- <categoryActivityBinding
- activityId="org.eclipse.team"
- categoryId="org.eclipse.categories.teamCategory">
- </categoryActivityBinding>
-
- <categoryActivityBinding
- activityId="org.eclipse.team.cvs"
- categoryId="org.eclipse.categories.teamCategory">
- </categoryActivityBinding>
-
- <!-- bind all elements that start with "org" -->
-
- <defaultEnablement
- id="org.eclipse.javaDevelopment">
- </defaultEnablement>
-
- <defaultEnablement
- id="org.eclipse.plugInDevelopment">
- </defaultEnablement>
-
- <defaultEnablement
- id="org.eclipse.team">
- </defaultEnablement>
- </extension>
-
- <extension
- point="org.eclipse.ui.newWizards">
- <primaryWizard
- id="org.eclipse.jdt.ui.wizards.JavaProjectWizard">
- </primaryWizard>
- <primaryWizard
- id="org.eclipse.pde.ui.NewProjectWizard">
- </primaryWizard>
- <primaryWizard
- id="org.eclipse.jdt.ui.wizards.NewClassCreationWizard">
- </primaryWizard>
- <primaryWizard
- id="org.eclipse.jdt.ui.wizards.NewInterfaceCreationWizard">
- </primaryWizard>
- <primaryWizard
- id="org.eclipse.pde.ui.NewSchemaFileWizard">
- </primaryWizard>
- </extension>
-
-</plugin>
diff --git a/update/org.eclipse.update.configurator/.classpath b/update/org.eclipse.update.configurator/.classpath
deleted file mode 100644
index 065ac06e1..000000000
--- a/update/org.eclipse.update.configurator/.classpath
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
- <classpathentry kind="src" path="src"/>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/update/org.eclipse.update.configurator/.cvsignore b/update/org.eclipse.update.configurator/.cvsignore
deleted file mode 100644
index 60463af3f..000000000
--- a/update/org.eclipse.update.configurator/.cvsignore
+++ /dev/null
@@ -1,2 +0,0 @@
-bin
-build.xml
diff --git a/update/org.eclipse.update.configurator/.options b/update/org.eclipse.update.configurator/.options
deleted file mode 100644
index a2c714f73..000000000
--- a/update/org.eclipse.update.configurator/.options
+++ /dev/null
@@ -1,5 +0,0 @@
-# Debugging options for the org.eclipse.update.configurator plugin
-
-# Turn on general debugging for the plugin.
-org.eclipse.update.configurator/debug=false
-
diff --git a/update/org.eclipse.update.configurator/.project b/update/org.eclipse.update.configurator/.project
deleted file mode 100644
index 0f091b258..000000000
--- a/update/org.eclipse.update.configurator/.project
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.update.configurator</name>
- <comment></comment>
- <projects>
- <project>org.eclipse.core.boot</project>
- <project>org.eclipse.core.runtime</project>
- <project>org.eclipse.osgi</project>
- <project>org.eclipse.osgi.util</project>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.jdt.core.javabuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.ManifestBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.SchemaBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.eclipse.jdt.core.javanature</nature>
- <nature>org.eclipse.pde.PluginNature</nature>
- </natures>
-</projectDescription>
diff --git a/update/org.eclipse.update.configurator/about.html b/update/org.eclipse.update.configurator/about.html
deleted file mode 100644
index 9db411aab..000000000
--- a/update/org.eclipse.update.configurator/about.html
+++ /dev/null
@@ -1,30 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<title>About</title>
-<meta http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<p>20th June, 2002</p>
-<h3>License</h3>
-<p>Eclipse.org makes available all content in this plug-in (&quot;Content&quot;). Unless otherwise indicated below, the Content is provided to you under the terms and conditions of the
-Common Public License Version 1.0 (&quot;CPL&quot;). A copy of the CPL is available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>.
-For purposes of the CPL, &quot;Program&quot; will mean the Content.</p>
-
-<h3>Contributions</h3>
-
-<p>If this Content is licensed to you under the terms and conditions of the CPL, any Contributions, as defined in the CPL, uploaded, submitted, or otherwise
-made available to Eclipse.org, members of Eclipse.org and/or the host of Eclipse.org web site, by you that relate to such
-Content are provided under the terms and conditions of the CPL and can be made available to others under the terms of the CPL.</p>
-
-<p>If this Content is licensed to you under license terms and conditions other than the CPL (&quot;Other License&quot;), any modifications, enhancements and/or
-other code and/or documentation (&quot;Modifications&quot;) uploaded, submitted, or otherwise made available to Eclipse.org, members of Eclipse.org and/or the
-host of Eclipse.org, by you that relate to such Content are provided under terms and conditions of the Other License and can be made available
-to others under the terms of the Other License. In addition, with regard to Modifications for which you are the copyright holder, you are also
-providing the Modifications under the terms and conditions of the CPL and such Modifications can be made available to others under the terms of
-the CPL.</p>
-
-</body>
-</html> \ No newline at end of file
diff --git a/update/org.eclipse.update.configurator/build.properties b/update/org.eclipse.update.configurator/build.properties
deleted file mode 100644
index 9fd124f3a..000000000
--- a/update/org.eclipse.update.configurator/build.properties
+++ /dev/null
@@ -1,9 +0,0 @@
-bin.includes = .options,\
- about.html,\
- plugin.properties,\
- plugin.xml,\
- *.jar,\
- META-INF/,\
- config.ini
-src.includes = about.html
-source.configurator.jar = src/
diff --git a/update/org.eclipse.update.configurator/config.ini b/update/org.eclipse.update.configurator/config.ini
deleted file mode 100644
index 2dcd1a8f9..000000000
--- a/update/org.eclipse.update.configurator/config.ini
+++ /dev/null
@@ -1,60 +0,0 @@
-# Eclipse runtime configuration file
-# This file contains a number of key/value pairs that are merged into the
-# System properties on system startup. The values control the way the
-# runtime is structured and runs.
-
-# Note: Only platform:/base/ and file: URLs are supported. In general the
-# URLs given may include a version number (e.g., .../location_1.2.3).
-# If a version is not specified, the system binds
-# to the location which matches exactly or to the versioned location with the
-# latest version number. If a version number is given then only exact matches
-# are considered.
-
-# The URL for the runtime entry point. The default value is
-# platform:/base/plugins/org.eclipse.osgi
-#osgi.framework = platform:/base/plugins/org.eclipse.osgi
-
-# The classpath for the framework found at the osgi.framework location. This
-# comma-separated list contains either URLs or simple element names. Simple
-# names are assumed to be relative to the framework's install directory.
-# Typically this value need not be set as it is initialized by the framework itself.
-# Version match searching is not done for URLs listed here.
-#osgi.frameworkClassPath =
-
-# The comma-separated list of locations to search for the splash screen file (splash.bmp).
-# For each list element a subdirectory structure based on the pattern nl/<locale> is searched.
-# The system binds to the first matching file. There is no default value.
-osgi.splashPath = platform:/base/plugins/org.eclipse.platform
-
-# The location of the splash screen file. If this value is set at system startup it is used
-# in favour of the osgi.splashPath searching outlined above. If the value is not set
-# the searching is done and this key is bound to the result of the search.
-#osgi.splashLocation =
-
-# The comma-separated list of bundles which are automatically installed and started
-# once the system is up and running. Each entry if of the form
-# <URL | simple bundle location>[@<startlevel>]
-# Simple bundle locations are interepreted as relative to the framework's parent directory.
-# The startlevel indicates the OSGi start level at which the bundle should run.
-# If this value is not set, the system computes an appropriate default.
-# osgi.bundles =
-#osgi.bundles=org.eclipse.core.runtime@2:start, org.eclipse.update.configurator@3:start
-
-# Default start level of bundles
-#osgi.bundles.defaultStartLevel=4
-
-# The product to run. A given Eclipse configuration may contain many products.
-# The product identified will supply the branding (window icons, title bar text) etc
-# as well as define the default application to run.
-eclipse.product=org.eclipse.platform
-
-# The application to run. The value specified here is the id of the application extension
-# the runtime will find, instantiate and execute once the system is up. When this
-# application exits, eclipse will also exit. Note that typically the identified eclipse.product
-# defines the default application to run.
-#eclipse.application=org.eclipse.ui.ide.workbench
-
-
-
-# End of file marker - must be here
-eof=eof \ No newline at end of file
diff --git a/update/org.eclipse.update.configurator/plugin.properties b/update/org.eclipse.update.configurator/plugin.properties
deleted file mode 100644
index 9ec972da8..000000000
--- a/update/org.eclipse.update.configurator/plugin.properties
+++ /dev/null
@@ -1,14 +0,0 @@
-###############################################################################
-# Copyright (c) 2003 IBM Corporation and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Common Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/cpl-v10.html
-#
-# Contributors:
-# IBM Corporation - initial API and implementation
-###############################################################################
-pluginName= Install/Update Configurator
-providerName= Eclipse.org
-productProviderName= Update Configurator Product Provider
-
diff --git a/update/org.eclipse.update.configurator/plugin.xml b/update/org.eclipse.update.configurator/plugin.xml
deleted file mode 100644
index 3b5bbefd0..000000000
--- a/update/org.eclipse.update.configurator/plugin.xml
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.0"?>
-<plugin
- id="org.eclipse.update.configurator"
- name="%pluginName"
- version="3.0.0"
- provider-name="%providerName"
- class="org.eclipse.update.internal.configurator.ConfigurationActivator">
-
- <runtime>
- <library name="configurator.jar">
- <export name="*"/>
- </library>
- </runtime>
- <requires>
- <import plugin="org.eclipse.core.runtime"/>
- </requires>
-
-
- <extension
- id="updateConfiguratorProductProvider"
- name="%productProviderName"
- point="org.eclipse.core.runtime.products">
- <provider>
- <run class="org.eclipse.update.internal.configurator.ProductProvider"/>
- </provider>
-
- </extension>
-
-</plugin>
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/configurator/ConfiguratorUtils.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/configurator/ConfiguratorUtils.java
deleted file mode 100644
index c6c3ed052..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/configurator/ConfiguratorUtils.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.update.configurator;
-
-import java.io.*;
-import java.net.*;
-
-import org.eclipse.update.internal.configurator.ConfigurationActivator;
-import org.osgi.framework.*;
-
-/**
- * Helper class to get platform configuration data without having to
- * use BootLoader methods from the compatibility layer.
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @since 3.0
- */
-public class ConfiguratorUtils {
- /**
- * Returns the current platform configuration. This method replaces the one we used
- * to call on BootLoader.
- *
- * @return platform configuration used in current instance of platform
- * @since 3.0
- */
- public static IPlatformConfiguration getCurrentPlatformConfiguration() {
- // acquire factory service first
- BundleContext context = ConfigurationActivator.getBundleContext();
- ServiceReference configFactorySR = context.getServiceReference(IPlatformConfigurationFactory.class.getName());
- if (configFactorySR == null)
- throw new IllegalStateException();
- IPlatformConfigurationFactory configFactory = (IPlatformConfigurationFactory) context.getService(configFactorySR);
- if (configFactory == null)
- throw new IllegalStateException();
- // get the configuration using the factory
- IPlatformConfiguration currentConfig = configFactory.getCurrentPlatformConfiguration();
- context.ungetService(configFactorySR);
- return currentConfig;
- }
-
- /**
- * Returns a platform configuration object, optionally initialized with previously saved
- * configuration information. We will use this method instead of the old one in BootLoader.
- *
- * @param url location of previously save configuration information. If <code>null</code>
- * is specified, an empty configuration object is returned
- * @return platform configuration used in current instance of platform
- */
- public static IPlatformConfiguration getPlatformConfiguration(URL url) throws IOException {
- // acquire factory service first
- BundleContext context = ConfigurationActivator.getBundleContext();
- ServiceReference configFactorySR = context.getServiceReference(IPlatformConfigurationFactory.class.getName());
- if (configFactorySR == null)
- throw new IllegalStateException();
- IPlatformConfigurationFactory configFactory = (IPlatformConfigurationFactory) context.getService(configFactorySR);
- if (configFactory == null)
- throw new IllegalStateException();
- // get the configuration using the factory
- IPlatformConfiguration config = configFactory.getPlatformConfiguration(url);
- context.ungetService(configFactorySR);
- return config;
- }
-
- public static URL getInstallURL() {
- return ConfigurationActivator.getInstallURL();
- }
-}
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/configurator/IPlatformConfiguration.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/configurator/IPlatformConfiguration.java
deleted file mode 100644
index 2e402b5a3..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/configurator/IPlatformConfiguration.java
+++ /dev/null
@@ -1,583 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.configurator;
-
-import java.io.IOException;
-import java.net.URL;
-
-/**
- * Platform configuration interface. Represents the runtime
- * configuration used by the Eclipse platform. Any configuration
- * changes do not take effect until next startup of the Eclipse
- * platform.
- * <p>
- * Do not provide implementations of this interface or its nested interfaces. Use the factory methods
- * on IPlatformConfigurationFactory to create a IPlatformConfiguration, then use the factory methods
- * on the IPlatformConfiguration to create instances of ISiteEntry,IFeatureEntry and ISitePolicy.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @since 3.0
- */
-public interface IPlatformConfiguration {
-
- /**
- * Configuration entry representing an install site.
- *
- * @since 2.0
- */
- public interface ISiteEntry {
-
- /**
- * Returns the URL for this site
- *
- * @return site url
- * @since 2.0
- */
- public URL getURL();
-
- /**
- * Returns the policy for this site
- *
- * @return site policy
- * @since 2.0
- */
- public ISitePolicy getSitePolicy();
-
- /**
- * Sets the site policy
- *
- * @param policy site policy
- * @since 2.0
- */
- public void setSitePolicy(ISitePolicy policy);
-
- /**
- * Returns a list of features visible on the site. Note, that this is simply a
- * reflection of the site content. The features may or may not be actually configured.
- *
- * @return an array of feature entries, or an empty array if no features are found.
- * A feature entry is returned as a path relative to the site URL
- * @since 2.0
- */
- public String[] getFeatures();
-
- /**
- * Returns a list of plug-ins visible on the site. Note, that this is simply a
- * reflection of the site content and the current policy for the site. The plug-ins
- * may or may not end up being used by Eclipse (depends on which plug-in are
- * actually bound by the platform).
- *
- * @return an array of plug-in entries, or an empty array if no plug-ins are found.
- * A plug-in entry is returned as a path relative to the site URL *
- * @since 2.0
- */
- public String[] getPlugins();
-
- /**
- * Returns a stamp reflecting the current state of the site. If called repeatedly,
- * returns the same value as long as no changes were made to the site (changes to
- * features or plugins).
- *
- * @return site change stamp
- * @since 2.0
- */
- public long getChangeStamp();
-
- /**
- * Returns a stamp reflecting the current state of the features on the site.
- * If called repeatedly, returns the same value as long as no changes were made to
- * features on the site.
- *
- * @return site features change stamp
- * @since 2.0
- * @deprecated Do not use this method
- */
- public long getFeaturesChangeStamp();
-
- /**
- * Returns a stamp reflecting the current state of the plug-ins on the site.
- * If called repeatedly, returns the same value as long as no changes were made to
- * plug-ins on the site.
- *
- * @return site plug-ins change stamp
- * @since 2.0
- * @deprecated Do not use this method
- */
- public long getPluginsChangeStamp();
-
- /**
- * Returns an indication whether the site can be updated.
- *
- * @return <code>true</code> if site can be updated, <code>false</code> otherwise
- * @since 2.0
- */
- public boolean isUpdateable();
-
- /**
- * Returns an indication whether the site represents an install site
- * that has been linked via a native installer (using the links/<linkfile>
- * mechanism)
- *
- * @return <code>true</code> if the site is linked, <code>false</code> otherwise
- * @since 2.0
- */
- public boolean isNativelyLinked();
- }
-
- /**
- * Site policy. The site policy object determines how plug-ins
- * contained on the site are processed during startup. In general,
- * there are 3 ways of configuring a site policy
- * <ul>
- * <li>explicitly specify which plug-ins are to be included at
- * startup (type==USER_INCLUDE). Any other plug-ins located
- * at the site are ignored at startup. This is typically the best
- * policy when using remote sites where the user wishes
- * to retain explicit control over the plug-ins that are included
- * from such site.
- * <li>explicitly specify which plug-ins are to be excluded at
- * startup (type==USER-EXCLUDE). All other plug-ins located
- * at the site are used at startup. This policy requires that
- * the site support an access "protocol" that allows plug-in
- * discovery. In general, these are sites defined using the "file"
- * URL protocol. This is typically the best policy for local
- * install sites (on the user system).
- * </ul>
- *
- * @since 2.0
- */
- public interface ISitePolicy {
-
- /**
- * Policy type constants.
- */
-
- /**
- * User-defined inclusion list. The list associated with this
- * policy type is interpreted as path entries to included plugin.xml
- * or fragment.xml <b>relative</b> to the site URL
- */
- public static final int USER_INCLUDE = 0;
-
- /**
- * User-defined exclusion list. The list associated with this
- * policy type is interpreted as path entries to excluded plugin.xml
- * or fragment.xml <b>relative</b> to the site URL
- */
- public static final int USER_EXCLUDE = 1;
-
- /**
- * Return policy type
- *
- * @return policy type
- * @since 2.0
- */
- public int getType();
-
- /**
- * Return policy inclusion/ exclusion list
- *
- * @return the list as an array
- * @since 2.0
- */
- public String[] getList();
-
- /**
- * Set new policy list. The list entries are interpreted based on the policy
- * type. See description of the policy type constants for details.
- *
- * @param list policy inclusion/ exclusion list as an array.
- * Returns an empty array if there are no entries.
- * @see #USER_INCLUDE
- * @see #USER_EXCLUDE
- * @since 2.0
- */
- public void setList(String[] list);
- }
-
- /**
- * Feature entry.
- * Represents runtime "hints" about configured features.
- * The information is used during execution to locate the
- * correct attribution information for a feature. Note,
- * that a typical configuration can declare multiple feature
- * entries. At execution time, only one can be selected as
- * the active primary feature. This is determined based on
- * specified command line arguments or computed defaults.
- *
- * @since 2.0
- */
- public interface IFeatureEntry {
-
- /**
- * Returns feature identifier.
- * @return feature identifier
- * @since 2.0
- */
- public String getFeatureIdentifier();
-
- /**
- * Returns the currently configured version for the feature.
- * @return feature version (as string), or <code>null</code>
- * @since 2.0
- */
- public String getFeatureVersion();
-
- /**
- * Returns the identifier of the feature plug-in for this feature entry.
- * Note, that there is no guarantee that a feature in fact
- * supplies a corresponding feature plugin, so the result can be
- * <code>null</code>. Also, if supplied, there is no guarantee that the
- * plugin will in fact be loaded into the plug-in registry at runtime
- * (due to rules and constraint checking performed by the registry
- * loading support). Consequently code making use of this method must
- * handle these conditions.
- * @return feature identifier (as string), or <code>null</code>
- * @since 2.1
- */
- public String getFeaturePluginIdentifier();
-
- /**
- * Returns the version of the feature plug-in for this feature
- * entry. Note, that there is no guarantee that a feature in fact
- * supplies a corresponding feature plugin, so the result can be
- * <code>null</code>. Also, if supplied, there is no guarantee that the
- * plugin will in fact be loaded into the plug-in registry at runtime
- * (due to rules and constraint checking performed by the registry
- * loading support). Consequently code making use of this method must
- * handle these conditions.
- * @return feature version (as string), or <code>null</code>
- * @since 2.0
- */
- public String getFeaturePluginVersion();
-
- /**
- * Returns the application to run when this feature is the
- * primary feature.
- * @return application identifier, or <code>null</code>
- * @since 2.0
- */
- public String getFeatureApplication();
-
- /**
- * Returns URLs to the feature "root" locations. The root
- * URLs are install locations of the feature plugin and its
- * fragments.
- *
- * @return array of URLs, or an empty array
- * @since 2.0
- */
- public URL[] getFeatureRootURLs();
-
- /**
- * Returns an indication whether this feature has been defined
- * to act as a primary feature.
- * @return <code>true</code> if the feature can be primary,
- * <code>false</code> otherwise.
- * @since 2.0
- */
- public boolean canBePrimary();
- }
-
- /**
- * Create a site entry
- *
- * @param url site URL
- * @param policy site policy
- * @return created site entry
- * @since 2.0
- */
- public ISiteEntry createSiteEntry(URL url, ISitePolicy policy);
-
- /**
- * Create a site policy. The policy determines the way the site
- * plug-in are processed at startpu
- *
- * @param type policy type
- * @param list an array of site-relative paths representing the
- * inclusion/ exclusion list
- * @return created site policy entry
- * @since 2.0
- */
- public ISitePolicy createSitePolicy(int type, String[] list);
-
- /**
- * Create a feature entry
- * @param id feature identifier. Must not be <code>null</code>.
- * @param version feature version (as String). Can be <code>null</code>.
- * @param pluginVersion version of the feature plugin (as String). Can be
- * <code>null</code>.
- * @param primary <code>true</code> if the feature is defined as a primary
- * feature, otherwise <code>false</code>.
- * @param application identifier of the application to run when
- * this feature is the primary feature. Can be <code>null</code>.
- * If specified, the identifier must represent a valid extension
- * registered in the <code>org.eclipse.core.runtime.applications</code>
- * extension point.
- * @param root an array of URLs to feature root directories.
- * These are URLs to install locations for the feature plugin
- * and its fragments. Can be <code>null</code>.
- * @return create feature entry
- * @since 2.0
- */
- public IFeatureEntry createFeatureEntry(String id, String version, String pluginVersion, boolean primary, String application, URL[] root);
-
- /**
- * Create a feature entry
- * @param id feature identifier. Must not be <code>null</code>.
- * @param version feature version (as String). Can be <code>null</code>.
- * @param pluginIdentifier identifier of the feature plugin (as String). Can
- * be <code>null</code>.
- * @param pluginVersion version of the feature plugin (as String). Can be
- * <code>null</code>.
- * @param primary <code>true</code> if the feature is defined as a primary
- * feature, otherwise <code>false</code>.
- * @param application identifier of the application to run when
- * this feature is the primary feature. Can be <code>null</code>.
- * If specified, the identifier must represent a valid extension
- * registered in the <code>org.eclipse.core.runtime.applications</code>
- * extension point.
- * @param root an array of URLs to feature root directories.
- * These are URLs to install locations for the feature plugin
- * and its fragments. Can be <code>null</code>.
- * @return create feature entry
- * @since 2.1
- */
- public IFeatureEntry createFeatureEntry(String id, String version, String pluginIdentifier, String pluginVersion, boolean primary, String application, URL[] root);
-
- /**
- * Configures the specified site entry. If a site entry with the
- * same site URL is already configured, the entry is <b>not</b> replaced.
- *
- * @param entry site entry
- * @since 2.0
- */
- public void configureSite(ISiteEntry entry);
-
- /**
- * Configures the specified site entry. If a site entry with the
- * same site URL is already configured, the replacement behavior for
- * the entry can be specified.
- *
- * @param entry site entry
- * @param replace indicating whether an existing configured entry with
- * the same URL should be replaced (<code>true</code>) or not (<code>false</code>).
- * @since 2.0
- */
- public void configureSite(ISiteEntry entry, boolean replace);
-
- /**
- * Unconfigures the specified entry. Does not do anything if the entry
- * is not configured.
- *
- * @param entry site entry
- * @since 2.0
- */
- public void unconfigureSite(ISiteEntry entry);
-
- /**
- * Returns configured site entries
- *
- * @return array of site entries. Returns an empty array if no sites are
- * configured
- * @since 2.0
- */
- public ISiteEntry[] getConfiguredSites();
-
- /**
- * Returns a site entry matching the specified URL
- *
- * @param url site url
- * @return matching site entry, or <code>null</code> if no match found
- * @since 2.0
- */
- public ISiteEntry findConfiguredSite(URL url);
-
- /**
- * Configures the feature entry.
- * If another feature entry with the same feature identifier
- * already exists, it is replaced.
- * @param entry feature entry
- * @since 2.0
- */
- public void configureFeatureEntry(IFeatureEntry entry);
-
- /**
- * Unconfigures the specified feature entry if it exists.
- * @param entry feature entry
- * @since 2.0
- */
- public void unconfigureFeatureEntry(IFeatureEntry entry);
-
- /**
- * Returns a list of configured feature entries.
- * @return array or entries, or an empty array if no entries
- * are configured
- * @since 2.0
- */
- public IFeatureEntry[] getConfiguredFeatureEntries();
-
- /**
- * Locates the specified feature entry.
- * @param id feature identifier
- * @return ferature entry, or <code>null</code>.
- * @since 2.0
- */
- public IFeatureEntry findConfiguredFeatureEntry(String id);
-
- /**
- * Returns the URL location of the configuration information
- *
- * @return configuration location URL, or <code>null</code> if the
- * configuration location could not be determined.
- * @since 2.0
- */
- public URL getConfigurationLocation();
-
- /**
- * Returns a stamp reflecting the current state of the configuration. If called repeatedly,
- * returns the same value as long as no changes were made to the configuration (changes to
- * sites, features or plugins).
- *
- * @return configuration change stamp
- * @since 2.0
- */
- public long getChangeStamp();
-
- /**
- * Returns a stamp reflecting the current state of the features in the configuration.
- * If called repeatedly, returns the same value as long as no changes were made to
- * features in the configuration.
- *
- * @return configuration features change stamp
- * @since 2.0
- * @deprecated Do not use this method.
- */
- public long getFeaturesChangeStamp();
-
- /**
- * Returns a stamp reflecting the current state of the plug-ins in the configuration.
- * If called repeatedly, returns the same value as long as no changes were made to
- * plug-ins in the configuration.
- *
- * @return configuration plug-ins change stamp
- * @since 2.0
- * @deprecated Do not use this method
- */
- public long getPluginsChangeStamp();
-
- /**
- * Returns the identifier of the configured primary feature. A primary feature
- * is used to specify product customization information for a running instance
- * of Eclipse.
- *
- * @return primary feature identifier, or <code>null</code> if none configured
- * @since 2.0
- */
- public String getPrimaryFeatureIdentifier();
-
- /**
- * Computes the plug-in path for this configuration. The result includes all plug-ins
- * visible on each of the configured sites based on each site policy.
- *
- * @return an array of plug-in path elements (full URL entries), or an empty array.
- * @since 2.0
- */
- public URL[] getPluginPath();
-
- /**
- * Returns an array of bootstrap plugin identifiers whose
- * location needs to be explicitly identified in the configuration.
- *
- * @return an array of identifiers, or empty array
- * otherwise
- * @since 2.0
- * @deprecated Do not use this method. Check the osgi.bundles system property for the
- * urls of the automatically started bundles
- */
- public String[] getBootstrapPluginIdentifiers();
-
- /**
- * Sets the location of a bootstrap plugin.
- *
- * @see IPlatformConfiguration#getBootstrapPluginIdentifiers()
- * @param id plugin identifier. Must match one of the entries returned
- * by getBootstrapPluginIdentifiers()
- * @param location
- * @since 2.0
- * @deprecated Do not use this method. Use the osig.bundles system property contains
- * the urls of the automatically started bundles.
- */
- public void setBootstrapPluginLocation(String id, URL location);
-
- /**
- * Returns an indication whether the configuration can be updated.
- *
- * @return <code>true</code> if configuration can be updated, <code>false</code>
- * otherwise
- * @since 2.0
- */
- public boolean isUpdateable();
-
- /**
- * Returns an indication whether the configuration is transient. A transient
- * configuration typically represents a scenario where the configuration
- * was computed for a single instantiation of the platform and is not
- * guaranteed to be valid on subsequent instantiations.
- *
- * @return <code>true</code> if configuration is transient, <code>false</code>
- * otherwise
- * @since 2.0
- */
- public boolean isTransient();
-
- /**
- * Indicates whether the configuration is transient or not. A transient
- * configuration typically represents a scenario where the configuration
- * was computed for a single instantiation of the platform and is not
- * guaranteed to be valid on subsequent instantiations. This method has
- * no effect if called on the current platform configuration.
- *
- * @param value <code>true</code> if configuration is transient, <code>false</code>
- * otherwise
- * @since 2.0
- */
- public void isTransient(boolean value);
-
- /**
- * Called to refresh the configuration information. In particular,
- * causes change stamps to be recomputed based on the current
- * configuration state, and updates the lists of available plug-ins.
- * @since 2.0
- */
- public void refresh();
-
- /**
- * Called to save the configuration information
- * @since 2.0
- */
- public void save() throws IOException;
-
- /**
- * Called to save the configuration information in the
- * specified location
- *
- * @param url save location.
- * @since 2.0
- */
- public void save(URL url) throws IOException;
-
-}
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/configurator/IPlatformConfigurationFactory.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/configurator/IPlatformConfigurationFactory.java
deleted file mode 100644
index b09c988e6..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/configurator/IPlatformConfigurationFactory.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.configurator;
-
-import java.io.IOException;
-import java.net.URL;
-
-/**
- * Factory for creating platform configurations.
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
-public interface IPlatformConfigurationFactory {
- /**
- * Returns the current platform configuration.
- *
- * @return platform configuration used in current instance of platform
- */
- public IPlatformConfiguration getCurrentPlatformConfiguration();
- /**
- * Returns a platform configuration object, optionally initialized with previously saved
- * configuration information.
- *
- * @param url location of previously save configuration information. If <code>null</code>
- * is specified, an empty configuration object is returned
- * @return platform configuration used in current instance of platform
- */
- public IPlatformConfiguration getPlatformConfiguration(URL url) throws IOException;
-}
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/configurator/package.html b/update/org.eclipse.update.configurator/src/org/eclipse/update/configurator/package.html
deleted file mode 100644
index fa0f9f694..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/configurator/package.html
+++ /dev/null
@@ -1,22 +0,0 @@
-<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
-<html>
-<head>
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
- <meta name="Author" content="IBM">
- <meta name="GENERATOR" content="Mozilla/4.72 [en] (Windows NT 5.0; U) [Netscape]">
- <title>Package-level Javadoc</title>
-</head>
-<body>
-Provides support for accessing platform configuration data.
-<h2>
-Package Specification</h2>
-This package contains interfaces for accessing and manipulating the local
-system installation and configuration information.
-<p>
-<b>Note:</b> This package is part of an interim API that is still under development and expected to
-change significantly before reaching stability. It is being made 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.
-</p>
-</body>
-</html>
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/BootDescriptor.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/BootDescriptor.java
deleted file mode 100644
index bc63b75b8..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/BootDescriptor.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator;
-
-import java.net.*;
-
-
-public class BootDescriptor {
- private String id;
- private String version;
- private String[] libs;
- private URL dir;
-
- public BootDescriptor(String id, String version, String[] libs, URL dir) {
- this.id = id;
- this.version = version;
- this.libs = libs;
- this.dir = dir;
- }
-
- public String getId() {
- return id;
- }
-
- public String getVersion() {
- return version;
- }
-
- public String[] getLibraries() {
- return libs;
- }
-
- public URL getPluginDirectoryURL() {
- return dir;
- }
-} \ No newline at end of file
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/BundleManifest.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/BundleManifest.java
deleted file mode 100644
index bdaba9e65..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/BundleManifest.java
+++ /dev/null
@@ -1,130 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator;
-import java.io.*;
-import java.util.jar.*;
-
-import org.eclipse.osgi.util.*;
-import org.osgi.framework.*;
-/**
- * Parses MANIFEST.MF
- */
-public class BundleManifest implements IConfigurationConstants {
- private File manifestFile;
- private PluginEntry pluginEntry;
- private IOException exception;
- private String bundleURL;
- /**
- * Constructor for local file
- */
- public BundleManifest(File manifest) {
- super();
- manifestFile = manifest;
- if (manifest.exists() && !manifest.isDirectory()) {
- FileInputStream fos = null;
- try {
- fos = new FileInputStream(manifest);
- parse(fos);
- } catch (IOException ioe) {
- } finally {
- if (fos != null) {
- try {
- fos.close();
- } catch (IOException e) {
- }
- }
- }
- }
- }
- /**
- * Constructor for local file
- */
- public BundleManifest(InputStream input, String bundleUrl) {
- super();
- bundleURL = bundleUrl;
- if (input != null) {
- parse(input);
- }
- }
- /**
- * Parses manifest, creates PluginEntry if manifest is valid, stores
- * exception if any occurs
- *
- * @param in
- * InputStream
- */
- private void parse(InputStream in) {
- try {
- Manifest m = new Manifest(in);
- Attributes a = m.getMainAttributes();
- // plugin id
- String symbolicName = a.getValue(Constants.BUNDLE_SYMBOLICNAME);
- if (symbolicName == null) {
- // In Eclipse manifest must have Bundle-SymbolicName attribute
- return;
- }
- String id;
- try {
- ManifestElement[] elements = ManifestElement.parseHeader(
- Constants.BUNDLE_SYMBOLICNAME, symbolicName);
- id = elements[0].getValue();
- } catch (BundleException be) {
- throw new IOException(be.getMessage());
- }
- // plugin version
- String version = a.getValue(Constants.BUNDLE_VERSION);
- if (version == null) {
- Utils.log(Messages.getString(
- "BundleManifest.noVersion", Constants.BUNDLE_VERSION, //$NON-NLS-1$
- id));
- return;
- }
- String hostPlugin = a.getValue(Constants.FRAGMENT_HOST);
- pluginEntry = new PluginEntry();
- pluginEntry.setVersionedIdentifier(new VersionedIdentifier(id,
- version));
- pluginEntry.isFragment(hostPlugin != null
- && hostPlugin.length() > 0);
- // Set URL
- if(bundleURL!=null){
- pluginEntry.setURL(bundleURL);
- }else{
- File pluginDir = manifestFile.getParentFile();
- if (pluginDir != null) {
- pluginDir = pluginDir.getParentFile();
- }
- if (pluginDir != null){
- pluginEntry.setURL(PLUGINS + "/" + pluginDir.getName() + "/"); //$NON-NLS-1$ //$NON-NLS-2$
- }
- }
- //
- } catch (IOException ioe) {
- exception = ioe;
- }
- }
- public boolean exists() {
- return exception != null || pluginEntry != null;
- }
- /**
- * Obtains PluginEntry from a manifest.
- *
- * @return PluginEntry or null if valid manifest does not exist
- * @throws IOException
- * if exception during parsing
- */
- public PluginEntry getPluginEntry() throws IOException {
- if (exception != null) {
- throw exception;
- } else {
- return pluginEntry;
- }
- }
-} \ No newline at end of file
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/Configuration.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/Configuration.java
deleted file mode 100644
index 2c4a76052..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/Configuration.java
+++ /dev/null
@@ -1,163 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator;
-
-import java.net.*;
-import java.util.*;
-
-import org.eclipse.core.runtime.*;
-import org.eclipse.update.configurator.*;
-import org.w3c.dom.*;
-
-
-public class Configuration implements IConfigurationConstants {
-
- private HashMap sites = new HashMap();
- private Date date;
- private long lastModified; // needed to account for file system limitations
- private URL url;
- private boolean transientConfig;
- private boolean isDirty;
- private Configuration linkedConfig; // shared configuration
-
- public Configuration() {
- this(new Date());
- // the config is created now or out of a platform.xml without a date
- isDirty = true;
- }
- public Configuration(Date date) {
- this.date = date;
- }
-
- public void setURL(URL url) {
- this.url = url;
- }
-
- public URL getURL() {
- return url;
- }
-
- public void setLinkedConfig(Configuration linkedConfig) {
- this.linkedConfig = linkedConfig;
- // make all the sites read-only
- SiteEntry[] linkedSites = linkedConfig.getSites();
- for (int i=0; i<linkedSites.length; i++)
- linkedSites[i].setUpdateable(false);
- }
-
- public Configuration getLinkedConfig() {
- return linkedConfig;
- }
-
- /**
- * @return true if the config needs to be saved
- */
- public boolean isDirty() {
- return isDirty;
- }
-
- public void setDirty(boolean dirty) {
- isDirty = dirty;
- }
-
- public void addSiteEntry(String url, SiteEntry site) {
- // only add the same site once
- if (sites.get(url) == null && (linkedConfig == null || linkedConfig.sites.get(url) == null)) {
- site.setConfig(this);
- sites.put(url, site);
- }
- }
-
- public void removeSiteEntry(String url) {
- sites.remove(url);
- }
-
- public SiteEntry getSiteEntry(String url) {
- SiteEntry site = (SiteEntry)sites.get(url);
- if (site == null && linkedConfig != null)
- site = linkedConfig.getSiteEntry(url);
- return site;
- }
-
- public SiteEntry[] getSites() {
- if (linkedConfig == null)
- return (SiteEntry[]) sites.values().toArray(new SiteEntry[sites.size()]);
- else {
- ArrayList combinedSites = new ArrayList(sites.values());
- combinedSites.addAll(linkedConfig.sites.values());
- return (SiteEntry[]) combinedSites.toArray(new SiteEntry[combinedSites.size()]);
- }
- }
-
- public Element toXML(Document doc) throws CoreException {
- try {
- Element configElement = doc.createElement(CFG);
-
- configElement.setAttribute(CFG_VERSION, VERSION);
- configElement.setAttribute(CFG_DATE, String.valueOf(date.getTime()));
- String transitory = isTransient() ? "true" : "false"; //$NON-NLS-1$ //$NON-NLS-2$
- configElement.setAttribute(CFG_TRANSIENT, transitory);
-
- if (linkedConfig != null) {
- configElement.setAttribute(CFG_SHARED_URL, linkedConfig.getURL().toExternalForm());
- }
-
- // collect site entries
- SiteEntry[] list = (SiteEntry[]) sites.values().toArray(new SiteEntry[0]);
- for (int i = 0; i < list.length; i++) {
- if (linkedConfig != null && linkedConfig.getSiteEntry(list[i].getURL().toExternalForm()) != null)
- continue;
- Element siteElement = list[i].toXML(doc);
- configElement.appendChild(siteElement);
- }
-
- return configElement;
-
- } catch (Exception e) {
- throw Utils.newCoreException("", e); //$NON-NLS-1$
- }
- }
-
- public boolean isTransient() {
- return transientConfig;
- }
-
- public void setTransient(boolean isTransient) {
- this.transientConfig = isTransient;
- }
-
- public Date getDate() {
- return date;
- }
-
- public void setDate(Date date) {
- this.date = date;
- }
-
- public boolean unconfigureFeatureEntry(IPlatformConfiguration.IFeatureEntry feature) {
- SiteEntry[] sites = getSites();
- for (int i=0; i<sites.length; i++)
- if (sites[i].unconfigureFeatureEntry(feature))
- return true;
- return false;
- }
-
- public void setLastModified(long lastModified) {
- this.lastModified = lastModified;
- }
-
- public long lastModified() {
- if (lastModified != 0)
- return lastModified;
- else
- return date.getTime();
- }
-}
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/ConfigurationActivator.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/ConfigurationActivator.java
deleted file mode 100644
index 3f03d986f..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/ConfigurationActivator.java
+++ /dev/null
@@ -1,483 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator;
-
-import java.io.*;
-import java.net.*;
-import java.util.*;
-
-import org.eclipse.core.runtime.*;
-import org.eclipse.osgi.framework.log.*;
-import org.eclipse.osgi.service.datalocation.*;
-import org.eclipse.osgi.service.debug.*;
-import org.eclipse.update.configurator.*;
-import org.osgi.framework.*;
-import org.osgi.service.packageadmin.*;
-import org.osgi.service.startlevel.*;
-import org.osgi.util.tracker.*;
-
-public class ConfigurationActivator implements BundleActivator, IBundleGroupProvider, IConfigurationConstants {
-
- public static String PI_CONFIGURATOR = "org.eclipse.update.configurator"; //$NON-NLS-1$
- public static final String INSTALL_LOCATION = "osgi.installLocation"; //$NON-NLS-1$
- public static final String LAST_CONFIG_STAMP = "last.config.stamp"; //$NON-NLS-1$
- public static final String NAME_SPACE = "org.eclipse.update"; //$NON-NLS-1$
- public static final String UPDATE_PREFIX = "update@"; //$NON-NLS-1$
- private static final String INITIAL_PREFIX = "initial@"; //$NON-NLS-1$
-
- // debug options
- public static String OPTION_DEBUG = PI_CONFIGURATOR + "/debug"; //$NON-NLS-1$
- // debug values
- public static boolean DEBUG = false;
- // os
- private static boolean isWindows = System.getProperty("os.name").startsWith("Win"); //$NON-NLS-1$ //$NON-NLS-2$
-
- private static BundleContext context;
- private ServiceTracker platformTracker;
- private ServiceRegistration configurationFactorySR;
- private PlatformConfiguration configuration;
-
- // Install location
- private static URL installURL;
-
- // Location of the configuration data
- private Location configLocation;
-
- //Need to store that because it is not provided by the platformConfiguration
- private long lastTimeStamp;
-
- // The expected states timestamp
- private long lastStateTimeStamp;
-
- // Singleton
- private static ConfigurationActivator configurator;
-
- public ConfigurationActivator() {
- configurator = this;
- }
-
- public void start(BundleContext ctx) throws Exception {
- context = ctx;
- loadOptions();
- acquireFrameworkLogService();
- initialize();
-
- //Short cut, if the configuration has not changed
- String product = configuration.getPrimaryFeatureIdentifier();
-
- if (canRunWithCachedData()) {
- Utils.debug("Same last time stamp *****"); //$NON-NLS-1$
- if (System.getProperty(ECLIPSE_PRODUCT) == null && product != null) {
- Utils.debug("no eclipse.product, setting it and returning"); //$NON-NLS-1$
- System.setProperty(ECLIPSE_PRODUCT, product);
- }
- Platform.registerBundleGroupProvider(this);
- return;
- }
-
- Utils.debug("Starting update configurator..."); //$NON-NLS-1$
-
- installBundles();
- Platform.registerBundleGroupProvider(this);
- }
-
-
- private void initialize() throws Exception {
- // TODO this test is not really needed any more than any plugin has
- // to test to see if the runtime is running. It was there from earlier days
- // where startup was much more disjoint. Some day that level of decoupling
- // will return but for now...
- if (!Platform.isRunning())
- throw new Exception(Messages.getString("ConfigurationActivator.initialize")); //$NON-NLS-1$
-
- configLocation = Platform.getConfigurationLocation();
- // create the name space directory for update (configuration/org.eclipse.update)
- if (!configLocation.isReadOnly()) {
- try {
- URL privateURL = new URL(configLocation.getURL(), NAME_SPACE);
- File f = new File(privateURL.getFile());
- if(!f.exists())
- f.mkdirs();
- } catch (MalformedURLException e1) {
- // ignore
- }
- }
- configurationFactorySR = context.registerService(IPlatformConfigurationFactory.class.getName(), new PlatformConfigurationFactory(), null);
- configuration = getPlatformConfiguration(getInstallURL(), configLocation);
- if (configuration == null)
- throw Utils.newCoreException(Messages.getString("ConfigurationActivator.createConfig", configLocation.getURL().toExternalForm()), null); //$NON-NLS-1$
-
- DataInputStream stream = null;
- try {
- stream = new DataInputStream(new URL(configLocation.getURL(),NAME_SPACE+'/'+LAST_CONFIG_STAMP).openStream());
- lastTimeStamp = stream.readLong();
- lastStateTimeStamp = stream.readLong();
- } catch (Exception e) {
- lastTimeStamp = configuration.getChangeStamp() - 1;
- lastStateTimeStamp = -1;
- } finally {
- if (stream != null)
- try {
- stream.close();
- } catch (IOException e1) {
- Utils.log(e1.getLocalizedMessage());
- }
- }
- }
-
-
- public void stop(BundleContext ctx) throws Exception {
- // quick fix (hack) for bug 47861
- try {
- PlatformConfiguration.shutdown();
- } catch (IOException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- configurationFactorySR.unregister();
- }
-
- public boolean installBundles() {
- Utils.debug("Installing bundles..."); //$NON-NLS-1$
- ServiceReference reference = context.getServiceReference(StartLevel.class.getName());
- int startLevel = 4;
- String defaultStartLevel = System.getProperty("osgi.bundles.defaultStartLevel"); //$NON-NLS-1$
- if (defaultStartLevel != null) {
- try {
- startLevel = Integer.parseInt(defaultStartLevel);
- } catch (NumberFormatException e1) {
- startLevel = 4;
- }
- }
- if (startLevel < 1)
- startLevel = 4;
-
- StartLevel start = null;
- if (reference != null)
- start = (StartLevel) context.getService(reference);
- try {
- // Get the list of cached bundles and compare with the ones to be installed.
- // Uninstall all the cached bundles that do not appear on the new list
- Bundle[] cachedBundles = context.getBundles();
- URL[] plugins = configuration.getPluginPath();
-
- Bundle[] bundlesToUninstall = getBundlesToUninstall(cachedBundles, plugins);
- for (int i=0; i<bundlesToUninstall.length; i++) {
- try {
- if (DEBUG)
- Utils.debug("Uninstalling " + bundlesToUninstall[i].getLocation()); //$NON-NLS-1$
- bundlesToUninstall[i].uninstall();
- } catch (Exception e) {
- Utils.log(Messages.getString("ConfigurationActivator.uninstallBundle", bundlesToUninstall[i].getLocation())); //$NON-NLS-1$
- }
- }
-
- // starts the list of bundles to refresh with all currently unresolved bundles (see bug 50680)
- List toRefresh = getUnresolvedBundles();
-
- // Get the urls to install
- String[] bundlesToInstall = getBundlesToInstall(cachedBundles, plugins);
-
- for (int i = 0; i < bundlesToInstall.length; i++) {
- try {
- if (DEBUG)
- Utils.debug("Installing " + bundlesToInstall[i]); //$NON-NLS-1$
- URL bundleURL = new URL("reference:file:"+bundlesToInstall[i]); //$NON-NLS-1$
- //Bundle target = context.installBundle(bundlesToInstall[i]);
- Bundle target = context.installBundle(UPDATE_PREFIX+bundlesToInstall[i], bundleURL.openStream());
- // any new bundle should be refreshed as well
- toRefresh.add(target);
- if (start != null)
- start.setBundleStartLevel(target, startLevel);
-
- } catch (Exception e) {
- if (!Utils.isAutomaticallyStartedBundle(bundlesToInstall[i]))
- Utils.log(Messages.getString("ConfigurationActivator.installBundle", bundlesToInstall[i]) + " " + e.getMessage()); //$NON-NLS-1$ //$NON-NLS-2$
- }
- }
- context.ungetService(reference);
- removeInitialBundles(toRefresh, cachedBundles);
- refreshPackages((Bundle[]) toRefresh.toArray(new Bundle[toRefresh.size()]));
-
- if (System.getProperty(ECLIPSE_PRODUCT) == null && configuration.getPrimaryFeatureIdentifier() != null)
- System.setProperty(ECLIPSE_PRODUCT, configuration.getPrimaryFeatureIdentifier());
-
- // keep track of the last config successfully processed
- writePlatformConfigurationTimeStamp();
- return true;
- } catch (Exception e) {
- return false;
- }
- }
-
- private void removeInitialBundles(List bundles, Bundle[] cachedBundles) {
- String[] initialSymbolicNames = getInitialSymbolicNames(cachedBundles);
- Iterator iter = bundles.iterator();
- while(iter.hasNext()) {
- Bundle bundle = (Bundle) iter.next();
- String symbolicName = bundle.getSymbolicName();
- for(int i = 0; i < initialSymbolicNames.length; i++) {
- if (initialSymbolicNames[i].equals(symbolicName)) {
- iter.remove();
- break;
- }
- }
- }
- }
-
- private String[] getInitialSymbolicNames(Bundle[] cachedBundles) {
- ArrayList initial = new ArrayList();
- for (int i = 0; i < cachedBundles.length; i++) {
- Bundle bundle = cachedBundles[i];
- if (bundle.getLocation().startsWith(INITIAL_PREFIX)) {
- String symbolicName = bundle.getSymbolicName();
- if (symbolicName != null)
- initial.add(symbolicName);
- }
- }
- return (String[]) initial.toArray(new String[initial.size()]);
- }
-
- private List getUnresolvedBundles() {
- Bundle[] allBundles = context.getBundles();
- List unresolved = new ArrayList();
- for (int i = 0; i < allBundles.length; i++)
- if (allBundles[i].getState() == Bundle.INSTALLED)
- unresolved.add(allBundles[i]);
- return unresolved;
- }
-
- private String[] getBundlesToInstall(Bundle[] cachedBundles, URL[] newPlugins) {
- // First, create a map of the cached bundles, for faster lookup
- HashSet cachedBundlesSet = new HashSet(cachedBundles.length);
- int offset = UPDATE_PREFIX.length();
- for (int i=0; i<cachedBundles.length; i++) {
- if (cachedBundles[i].getBundleId() == 0)
- continue; // skip the system bundle
- String bundleLocation = cachedBundles[i].getLocation();
- // Ignore bundles not installed by us
- if (!bundleLocation.startsWith(UPDATE_PREFIX))
- continue;
-
- bundleLocation = bundleLocation.substring(offset);
- cachedBundlesSet.add(bundleLocation);
- // On windows, we will be doing case insensitive search as well, so lower it now
- if (isWindows)
- cachedBundlesSet.add(bundleLocation.toLowerCase());
- }
-
- ArrayList bundlesToInstall = new ArrayList(newPlugins.length);
- for (int i = 0; i < newPlugins.length; i++) {
- String location = newPlugins[i].getFile();
- // check if already installed
- if (cachedBundlesSet.contains(location))
- continue;
- if (isWindows && cachedBundlesSet.contains(location.toLowerCase()))
- continue;
-
- bundlesToInstall.add(location);
- }
- return (String[])bundlesToInstall.toArray(new String[bundlesToInstall.size()]);
- }
-
-
- private Bundle[] getBundlesToUninstall(Bundle[] cachedBundles, URL[] newPlugins) {
- // First, create a map for faster lookups
- HashSet newPluginsSet = new HashSet(newPlugins.length);
- for (int i=0; i<newPlugins.length; i++) {
-
- String pluginLocation = newPlugins[i].getFile();
- newPluginsSet.add(pluginLocation);
- // On windows, we will be doing case insensitive search as well, so lower it now
- if (isWindows)
- newPluginsSet.add(pluginLocation.toLowerCase());
- }
-
- ArrayList bundlesToUninstall = new ArrayList();
- int offset = UPDATE_PREFIX.length();
- for (int i=0; i<cachedBundles.length; i++) {
- if (cachedBundles[i].getBundleId() == 0)
- continue; // skip the system bundle
- String cachedBundleLocation = cachedBundles[i].getLocation();
- // Only worry about bundles we installed
- if (!cachedBundleLocation.startsWith(UPDATE_PREFIX))
- continue;
- cachedBundleLocation = cachedBundleLocation.substring(offset);
-
- if (newPluginsSet.contains(cachedBundleLocation))
- continue;
- if (isWindows && newPluginsSet.contains(cachedBundleLocation.toLowerCase()))
- continue;
-
- bundlesToUninstall.add(cachedBundles[i]);
- }
- return (Bundle[])bundlesToUninstall.toArray(new Bundle[bundlesToUninstall.size()]);
- }
-
-
- /**
- * Creates and starts the platform configuration.
- * @return the just started platform configuration
- */
- private PlatformConfiguration getPlatformConfiguration(URL installURL, Location configLocation) {
- try {
- PlatformConfiguration.startup(installURL, configLocation);
- } catch (Exception e) {
- if (platformTracker != null) {
- String message = e.getMessage();
- if (message == null)
- message = ""; //$NON-NLS-1$
- Utils.log(Utils.newStatus(message, e));
- }
- }
- return PlatformConfiguration.getCurrent();
-
- }
-
- /**
- * Do PackageAdmin.refreshPackages() in a synchronous way. After installing
- * all the requested bundles we need to do a refresh and want to ensure that
- * everything is done before returning.
- * @param bundles
- */
- private void refreshPackages(Bundle[] bundles) {
- if (bundles.length == 0)
- return;
- ServiceReference packageAdminRef = context.getServiceReference(PackageAdmin.class.getName());
- PackageAdmin packageAdmin = null;
- if (packageAdminRef != null) {
- packageAdmin = (PackageAdmin) context.getService(packageAdminRef);
- if (packageAdmin == null)
- return;
- }
- // TODO this is such a hack it is silly. There are still cases for race conditions etc
- // but this should allow for some progress...
- // (patch from John A.)
- final boolean[] flag = new boolean[] {false};
- FrameworkListener listener = new FrameworkListener() {
- public void frameworkEvent(FrameworkEvent event) {
- if (event.getType() == FrameworkEvent.PACKAGES_REFRESHED)
- synchronized (flag) {
- flag[0] = true;
- flag.notifyAll();
- }
- }
- };
- context.addFrameworkListener(listener);
- packageAdmin.refreshPackages(bundles);
- synchronized (flag) {
- while (!flag[0]) {
- try {
- flag.wait();
- } catch (InterruptedException e) {
- }
- }
- }
- context.removeFrameworkListener(listener);
- context.ungetService(packageAdminRef);
- }
-
- private void writePlatformConfigurationTimeStamp() {
- DataOutputStream stream = null;
- try {
- if (configLocation.isReadOnly())
- return;
-
- String configArea = configLocation.getURL().getFile();
- lastTimeStamp = configuration.getChangeStamp();
- lastStateTimeStamp = Platform.getPlatformAdmin().getState(false).getTimeStamp();
- stream = new DataOutputStream(new FileOutputStream(configArea +File.separator+ NAME_SPACE+ File.separator+ LAST_CONFIG_STAMP));
- stream.writeLong(lastTimeStamp);
- stream.writeLong(lastStateTimeStamp);
- } catch (Exception e) {
- Utils.log(e.getLocalizedMessage());
- } finally {
- if (stream != null)
- try {
- stream.close();
- } catch (IOException e1) {
- Utils.log(e1.getLocalizedMessage());
- }
- }
- }
-
- private void loadOptions() {
- // all this is only to get the application args
- DebugOptions service = null;
- ServiceReference reference = context.getServiceReference(DebugOptions.class.getName());
- if (reference != null)
- service = (DebugOptions) context.getService(reference);
- if (service == null)
- return;
- try {
- DEBUG = service.getBooleanOption(OPTION_DEBUG, false);
- } finally {
- // we have what we want - release the service
- context.ungetService(reference);
- }
- }
-
- private boolean canRunWithCachedData() {
- return !"true".equals(System.getProperty("osgi.checkConfiguration")) && //$NON-NLS-1$ //$NON-NLS-2$
- System.getProperties().get("osgi.dev") == null && //$NON-NLS-1$
- lastTimeStamp==configuration.getChangeStamp() &&
- lastStateTimeStamp==Platform.getPlatformAdmin().getState(false).getTimeStamp();
- }
-
- public static BundleContext getBundleContext() {
- return context;
- }
-
- public static URL getInstallURL() {
- if (installURL == null)
- installURL = Platform.getInstallLocation().getURL();
- return installURL;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.core.runtime.IBundleGroupProvider#getName()
- */
- public String getName() {
- return Messages.getString("BundleGroupProvider"); //$NON-NLS-1$
- }
- /* (non-Javadoc)
- * @see org.eclipse.core.runtime.IBundleGroupProvider#getBundleGroups()
- */
- public IBundleGroup[] getBundleGroups() {
- if (configuration == null)
- return new IBundleGroup[0];
- else {
- IPlatformConfiguration.IFeatureEntry[] features = configuration.getConfiguredFeatureEntries();
- ArrayList bundleGroups = new ArrayList(features.length);
- for (int i=0; i<features.length; i++) {
- if (features[i] instanceof FeatureEntry
- && ((FeatureEntry)features[i]).hasBranding())
- bundleGroups.add(features[i]);
- }
- return (IBundleGroup[])bundleGroups.toArray(new IBundleGroup[bundleGroups.size()]);
- }
- }
-
- public static void setConfigurator(ConfigurationActivator configurator) {
- ConfigurationActivator.configurator = configurator;
- }
-
- public static ConfigurationActivator getConfigurator() {
- return configurator;
- }
-
- private void acquireFrameworkLogService() throws Exception{
- ServiceReference logServiceReference = context.getServiceReference(FrameworkLog.class.getName());
- if (logServiceReference == null)
- return;
- Utils.log = (FrameworkLog) context.getService(logServiceReference);
- }
-} \ No newline at end of file
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/ConfigurationParser.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/ConfigurationParser.java
deleted file mode 100644
index 976564e17..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/ConfigurationParser.java
+++ /dev/null
@@ -1,362 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator;
-import java.io.*;
-import java.lang.reflect.*;
-import java.net.*;
-import java.util.*;
-import javax.xml.parsers.*;
-
-import org.eclipse.core.runtime.*;
-import org.xml.sax.*;
-import org.xml.sax.helpers.*;
-
-/**
- * parse the default site.xml
- */
-
-public class ConfigurationParser extends DefaultHandler implements IConfigurationConstants {
-
- private final static SAXParserFactory parserFactory =
- SAXParserFactory.newInstance();
- private SAXParser parser;
-
- private URL currentSiteURL;
- private Configuration config;
- private URL configURL;
- private InputStream input;
-
- /**
- * Constructor for ConfigurationParser
- */
- public ConfigurationParser() throws InvocationTargetException {
-
- try {
- parserFactory.setNamespaceAware(true);
- this.parser = parserFactory.newSAXParser();
- } catch (ParserConfigurationException e) {
- Utils.log(Utils.newStatus("ConfigurationParser", e)); //$NON-NLS-1$
- throw new InvocationTargetException(e);
- } catch (SAXException e) {
- Utils.log(Utils.newStatus("ConfigurationParser", e)); //$NON-NLS-1$
- throw new InvocationTargetException(e);
- }
- }
-
- public Configuration parse(URL url) throws Exception {
-
- // DEBUG:
- Utils.debug("Start parsing Configuration:" + url); //$NON-NLS-1$
- long lastModified = 0;
- try {
- configURL = url;
- if ("file".equals(url.getProtocol())) { //$NON-NLS-1$
- File inputFile = new File(url.getFile());
- if (!inputFile.exists() || !inputFile.canRead())
- return null;
- lastModified = inputFile.lastModified();
- input = new FileInputStream(inputFile);
- } else
- input = url.openStream();
- parser.parse(new InputSource(input), this);
- return config;
- } catch (Exception e) {
- Utils.log(Utils.newStatus("ConfigurationParser.parse() error:", e)); //$NON-NLS-1$
- throw e;
- } finally {
- if (config != null)
- config.setLastModified(lastModified);
- try {
- if (input != null) {
- input.close();
- input = null;
- }
- } catch (IOException e1) {
- Utils.log(e1.getLocalizedMessage());
- }
- }
- }
-
- /**
- * @see DefaultHandler#startElement(String, String, String, Attributes)
- */
- public void startElement(
- String uri,
- String localName,
- String qName,
- Attributes attributes)
- throws SAXException {
-
- // DEBUG:
- Utils.debug("Start Element: uri:" + uri + " local Name:" + localName + " qName:" + qName); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
- try {
-
- String tag = localName.trim();
-
- if (tag.equalsIgnoreCase(CFG)) {
- processConfig(attributes);
- return;
- }
-
- if (tag.equalsIgnoreCase(CFG_SITE)) {
- processSite(attributes);
- return;
- }
-
- if (tag.equalsIgnoreCase(CFG_FEATURE_ENTRY)) {
- processFeature(attributes);
- return;
- }
-
- } catch (MalformedURLException e) {
- throw new SAXException(Messages.getString("InstalledSiteParser.UnableToCreateURL", e.getMessage()), e); //$NON-NLS-1$
- } catch (CoreException e) {
- throw new SAXException(Messages.getString("InstalledSiteParser.InternalError", e.toString()), e); //$NON-NLS-1$
- }
- }
-
- /**
- * process the Site info
- */
- private void processSite(Attributes attributes)
- throws MalformedURLException, CoreException {
-
- if (config == null)
- return;
-
- // reset current site
- currentSiteURL = null;
-
- String urlString = attributes.getValue(CFG_URL); //$NON-NLS-1$
- if (urlString == null)
- return;
-
- URL url = null;
- try {
- url = new URL(urlString);
- } catch (MalformedURLException e) {
- // try relative to install url
- url = new URL(PlatformConfiguration.getInstallURL(), urlString);
- return;
- }
-
- if (!isValidSite(url))
- return;
-
- // use this new site
- currentSiteURL = url;
-
- int policyType;
- String[] policyList = null;
- String typeString = attributes.getValue(CFG_POLICY); //$NON-NLS-1$
- if (typeString == null) {
- policyType = DEFAULT_POLICY_TYPE;
- policyList = DEFAULT_POLICY_LIST;
- } else {
- int i;
- for (i = 0; i < CFG_POLICY_TYPE.length; i++) {
- if (typeString.equals(CFG_POLICY_TYPE[i])) {
- break;
- }
- }
- if (i >= CFG_POLICY_TYPE.length) {
- policyType = DEFAULT_POLICY_TYPE;
- policyList = DEFAULT_POLICY_LIST;
- } else {
- policyType = i;
- String pluginList = attributes.getValue(CFG_LIST);
- if (pluginList != null) {
- StringTokenizer st = new StringTokenizer(pluginList,","); //$NON-NLS-1$
- policyList = new String[st.countTokens()];
- for (i=0; i<policyList.length; i++)
- policyList[i] = st.nextToken();
- }
- }
- }
-
- SitePolicy sp = new SitePolicy(policyType, policyList);
- SiteEntry site = (SiteEntry) new SiteEntry(url, sp);
-
- String flag = attributes.getValue(CFG_UPDATEABLE); //$NON-NLS-1$
- if (flag != null) {
- if (flag.equals("true")) //$NON-NLS-1$
- site.setUpdateable(true);
- else
- site.setUpdateable(false);
- }
-
- flag = attributes.getValue(CFG_ENABLED); //$NON-NLS-1$
- if (flag != null && flag.equals("false")) //$NON-NLS-1$
- site.setEnabled(false);
- else
- site.setEnabled(true);
-
- String linkname = attributes.getValue(CFG_LINK_FILE); //$NON-NLS-1$
- if (linkname != null && !linkname.equals("")) { //$NON-NLS-1$
- site.setLinkFileName(linkname.replace('/', File.separatorChar));
- }
-
- // DEBUG:
- Utils.debug("End process config site url:" + urlString + " policy:" + typeString + " updatable:"+flag ); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
-
- config.addSiteEntry(url.toExternalForm(), site);
- }
-
- /**
- * process the DefaultFeature info
- */
- private void processFeature(Attributes attributes)
- throws MalformedURLException, CoreException {
-
- if (currentSiteURL == null)
- return; // the site was not correct
-
- String id = attributes.getValue(CFG_FEATURE_ENTRY_ID); //$NON-NLS-1$
- if (id == null)
- return;
- String version = attributes.getValue(CFG_FEATURE_ENTRY_VERSION); //$NON-NLS-1$
- String pluginVersion = attributes.getValue(CFG_FEATURE_ENTRY_PLUGIN_VERSION); //$NON-NLS-1$
- if (pluginVersion == null || pluginVersion.trim().length() == 0)
- pluginVersion = version;
- String pluginIdentifier = attributes.getValue(CFG_FEATURE_ENTRY_PLUGIN_IDENTIFIER); //$NON-NLS-1$
- if (pluginIdentifier != null && pluginIdentifier.trim().length() == 0)
- pluginIdentifier = null;
- String application = attributes.getValue(CFG_FEATURE_ENTRY_APPLICATION); //$NON-NLS-1$
-
- // get install locations
- String locations = attributes.getValue(CFG_FEATURE_ENTRY_ROOT);
- StringTokenizer st = locations != null ? new StringTokenizer(locations,",") : new StringTokenizer(""); //$NON-NLS-1$ //$NON-NLS-2$
- ArrayList rootList = new ArrayList(st.countTokens());
- while (st.hasMoreTokens()){
- try{
- URL rootEntry = new URL(st.nextToken());
- rootList.add(rootEntry);
- } catch (MalformedURLException e) {
- // skip bad entries ...
- }
- }
- URL[] roots = (URL[]) rootList.toArray(new URL[rootList.size()]);
-
- // get primary flag
- boolean primary = false;
- String flag = attributes.getValue(CFG_FEATURE_ENTRY_PRIMARY); //$NON-NLS-1$
- if (flag != null) {
- if (flag.equals("true")) //$NON-NLS-1$
- primary = true;
- }
-
- FeatureEntry featureEntry = new FeatureEntry(id, version, pluginIdentifier, pluginVersion, primary, application, roots);
-
- // set the url
- String url = attributes.getValue(CFG_URL); //$NON-NLS-1$
- if (url != null && url.trim().length() > 0)
- featureEntry.setURL(url);
-
- SiteEntry site = config.getSiteEntry(currentSiteURL.toExternalForm());
- site.addFeatureEntry(featureEntry);
-
- // configured ?
-// String configuredString = attributes.getValue("configured"); //$NON-NLS-1$
-// boolean configured = configuredString.trim().equalsIgnoreCase("true") ? true : false; //$NON-NLS-1$
- }
-
-
- /**
- * process the Config info
- */
- private void processConfig(Attributes attributes) {
- String date = attributes.getValue(CFG_DATE);
- if (date == null || date.trim().length() == 0)
- config = new Configuration(); // constructed with current date
- else {
- long time = 0;
- try {
- time = Long.parseLong(date);
- config = new Configuration(new Date(time));
- } catch (NumberFormatException e1) {
- time = new Date().getTime();
- Utils.log(Messages.getString("InstalledSiteParser.date", date)); //$NON-NLS-1$
- config = new Configuration(); // constructed with current date
- }
- }
-
- config.setURL(configURL);
-
- try {
- String sharedURL = attributes.getValue(CFG_SHARED_URL);
- if (sharedURL != null) {
- ConfigurationParser parser = new ConfigurationParser();
- Configuration sharedConfig = parser.parse(new URL(sharedURL));
- if (sharedConfig == null)
- throw new Exception();
- config.setLinkedConfig(sharedConfig);
- }
- } catch (Exception e) {
- // could not load from shared install
- Utils.log(Utils.newStatus(Messages.getString("ConfigurationParser.cannotLoadSharedInstall"), e)); //$NON-NLS-1$
- }
-
- String flag = attributes.getValue(CFG_TRANSIENT);
- if (flag != null) {
- config.setTransient(flag.equals("true")); //$NON-NLS-1$
- }
-
- // DEBUG:
- Utils.debug("End Processing Config Tag: date:" + attributes.getValue(CFG_DATE)); //$NON-NLS-1$
- }
-
- private boolean isValidSite(URL url) {
- URL resolvedURL= url;
- if (url.getProtocol().equals("platform")) { // $NON-NLS-1$
- try {
- resolvedURL = PlatformConfiguration.resolvePlatformURL(url); // 19536
- } catch (IOException e) {
- // will use the baseline URL ...
- }
- }
-
- if (!PlatformConfiguration.supportsDetection(resolvedURL))
- return false;
-
- File siteRoot = new File(resolvedURL.getFile().replace('/', File.separatorChar));
- if (!siteRoot.exists()) {
- Utils.debug("Site " + resolvedURL + " does not exist "); //$NON-NLS-1$ //$NON-NLS-2$
- return false;
- } else
- return true;
- }
- /* (non-Javadoc)
- * @see org.xml.sax.ContentHandler#endElement(java.lang.String, java.lang.String, java.lang.String)
- */
- public void endElement(String uri, String localName, String qName)
- throws SAXException {
- super.endElement(uri, localName, qName);
-
- // DEBUG:
- Utils.debug("End Element: uri:" + uri + " local Name:" + localName + " qName:" + qName); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
- try {
-
- String tag = localName.trim();
-
- if (tag.equalsIgnoreCase(CFG)) {
- // This is a bit of a hack.
- // When no features were added to the site, but the site is initialized from platform.xml
- // we need to set the feature set to empty, so we don't try to detect them.
- SiteEntry[] sites = config.getSites();
- for (int i=0; i<sites.length; i++)
- sites[i].initialized();
- return;
- }
- } catch (Exception e) {
- // silent ignore
- }
- }
-}
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/FeatureEntry.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/FeatureEntry.java
deleted file mode 100644
index a0683bdcc..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/FeatureEntry.java
+++ /dev/null
@@ -1,354 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator;
-
-import java.net.*;
-import java.util.*;
-
-import org.eclipse.core.runtime.*;
-import org.eclipse.update.configurator.*;
-import org.eclipse.update.internal.configurator.branding.*;
-import org.osgi.framework.*;
-import org.w3c.dom.*;
-
-
-/**
- *
- * Feature information
- */
-public class FeatureEntry
- implements
- IPlatformConfiguration.IFeatureEntry,
- IConfigurationConstants,
- IBundleGroup,
- IBundleGroupConstants,
- IProduct,
- IProductConstants {
- private String id;
- private String version;
- private String pluginVersion;
- private String application;
- private URL[] root;
- private boolean primary;
- private String pluginIdentifier;
- private String url;
- private String description;
- private String licenseURL;
- private ArrayList plugins;
- private AboutInfo branding;
- private SiteEntry site;
- private ResourceBundle resourceBundle;
- private boolean fullyParsed;
-
- public FeatureEntry(String id, String version, String pluginIdentifier, String pluginVersion, boolean primary, String application, URL[] root) {
- if (id == null)
- throw new IllegalArgumentException();
- this.id = id;
- this.version = version;
- this.pluginVersion = pluginVersion;
- this.pluginIdentifier = pluginIdentifier;
- this.primary = primary;
- this.application = application;
- this.root = (root == null ? new URL[0] : root);
- }
-
- public FeatureEntry( String id, String version, String pluginVersion, boolean primary, String application, URL[] root) {
- this(id, version, id, pluginVersion, primary, application, root);
- }
-
- public void setSite(SiteEntry site) {
- this.site = site;
- }
-
- public SiteEntry getSite() {
- return this.site;
- }
-
- public void addPlugin(PluginEntry plugin) {
- if (plugins == null)
- plugins = new ArrayList();
- plugins.add(plugin);
- }
-
- /**
- * Sets the url string (relative to the site url)
- * @param url
- */
- public void setURL(String url) {
- this.url = url;
- }
-
- /**
- * @return the feature url (relative to the site): features/org.eclipse.platform/
- */
- public String getURL() {
-// if (url == null)
-// url = FEATURES + "/" + id + "_" + version + "/";
- return url;
- }
-
- /*
- * @see IFeatureEntry#getFeatureIdentifier()
- */
- public String getFeatureIdentifier() {
- return id;
- }
-
- /*
- * @see IFeatureEntry#getFeatureVersion()
- */
- public String getFeatureVersion() {
- return version;
- }
-
- /*
- * @see IFeatureEntry#getFeaturePluginVersion()
- */
- public String getFeaturePluginVersion() {
- return pluginVersion != null && pluginVersion.length() > 0 ? pluginVersion : null;
- }
-
- /*
- * @see IFeatureEntry#getFeaturePluginIdentifier()
- */
- public String getFeaturePluginIdentifier() {
- // if no plugin is specified, use the feature id
- return pluginIdentifier != null && pluginIdentifier.length() > 0 ? pluginIdentifier : id;
- }
-
- /*
- * @see IFeatureEntry#getFeatureApplication()
- */
- public String getFeatureApplication() {
- return application;
- }
-
- /*
- * @see IFeatureEntry#getFeatureRootURLs()
- */
- public URL[] getFeatureRootURLs() {
- return root;
- }
-
- /*
- * @see IFeatureEntry#canBePrimary()
- */
- public boolean canBePrimary() {
- return primary;
- }
-
- public Element toXML(Document doc) {
-
- Element featureElement = doc.createElement(CFG_FEATURE_ENTRY);
- // write out feature entry settings
- if (id != null)
- featureElement.setAttribute(CFG_FEATURE_ENTRY_ID, id);
- if (primary)
- featureElement.setAttribute(CFG_FEATURE_ENTRY_PRIMARY, "true"); //$NON-NLS-1$
- if (version != null)
- featureElement.setAttribute(CFG_FEATURE_ENTRY_VERSION, version);
- if (pluginVersion != null && !pluginVersion.equals(version) && pluginVersion.length() > 0)
- featureElement.setAttribute(CFG_FEATURE_ENTRY_PLUGIN_VERSION, pluginVersion);
- if (pluginIdentifier != null && !pluginIdentifier.equals(id) && pluginIdentifier.length() > 0)
- featureElement.setAttribute(CFG_FEATURE_ENTRY_PLUGIN_IDENTIFIER, pluginIdentifier);
- if (application != null)
- featureElement.setAttribute(CFG_FEATURE_ENTRY_APPLICATION, application);
- if (url != null)
- featureElement.setAttribute(CFG_URL, url);
-
- URL[] roots = getFeatureRootURLs();
- for (int i=0; i<roots.length; i++) {
- String root = roots[i].toExternalForm();
- if (root != null && root.trim().length() > 0){
- Element rootElement = doc.createElement(CFG_FEATURE_ENTRY_ROOT);
- rootElement.appendChild(doc.createTextNode(root));
- featureElement.appendChild(rootElement);
- }
- }
-
- return featureElement;
- }
-
- public void setDescription(String description) {
- this.description = description;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.core.runtime.IBundleGroup#getBundles()
- */
- public Bundle[] getBundles() {
- if (plugins == null)
- fullParse();
-
- ArrayList bundles = new ArrayList(plugins.size());
- for (int i=0; i<plugins.size(); i++) {
- PluginEntry plugin = (PluginEntry)plugins.get(i);
- // get the highest version for the plugin
- Bundle bundle = Platform.getBundle(plugin.getPluginIdentifier());
- if (bundle != null)
- bundles.add(bundle);
- }
- return (Bundle[])bundles.toArray(new Bundle[bundles.size()]);
- }
- /* (non-Javadoc)
- * @see org.eclipse.core.runtime.IBundleGroup#getDescription()
- */
- public String getDescription() {
- if (description == null)
- fullParse();
- return description;
- }
- /* (non-Javadoc)
- * @see org.eclipse.core.runtime.IBundleGroup#getIdentifier()
- */
- public String getIdentifier() {
- return id;
- }
- /* (non-Javadoc)
- * @see org.eclipse.core.runtime.IBundleGroup#getName()
- */
- public String getName() {
- if (branding == null)
- branding = AboutInfo.readFeatureInfo(id, version, getFeaturePluginIdentifier());
- return branding.getProductName();
- }
- /* (non-Javadoc)
- * @see org.eclipse.core.runtime.IBundleGroup#getProperty(java.lang.String)
- */
- public String getProperty(String key) {
- if (key == null)
- return null;
-
- if (branding == null)
- branding = AboutInfo.readFeatureInfo(id, version, getFeaturePluginIdentifier());
-
- // IBundleGroupConstants
- if (key.equals(FEATURE_IMAGE))
- return branding.getFeatureImageURL() == null ? null : branding.getFeatureImageURL().toExternalForm();
- else if (key.equals(TIPS_AND_TRICKS_HREF))
- return branding.getTipsAndTricksHref();
- else if (key.equals(IBundleGroupConstants.WELCOME_PAGE)) // same value is used by product and bundle group
- return branding.getWelcomePageURL() == null ? null : branding.getWelcomePageURL().toExternalForm();
- else if (key.equals(WELCOME_PERSPECTIVE))
- return branding.getWelcomePerspectiveId();
- // IProductConstants
- else if (key.equals(APP_NAME))
- return branding.getAppName();
- else if (key.equals(ABOUT_TEXT))
- return branding.getAboutText();
- else if (key.equals(ABOUT_IMAGE))
- return branding.getAboutImageURL() == null ? null : branding.getAboutImageURL().toExternalForm();
- else if (key.equals(WINDOW_IMAGE))
- return branding.getWindowImageURL()== null ? null : branding.getWindowImageURL().toExternalForm();
- else if (key.equals(WINDOW_IMAGES)) {
- URL[] urls = branding.getWindowImagesURLs();
- if (urls == null)
- return null;
- StringBuffer windowImagesURLs = new StringBuffer();
- for (int i=0; i<urls.length; i++){
- windowImagesURLs.append(urls[i].toExternalForm());
- if (i != urls.length-1)
- windowImagesURLs.append(',');
- }
- return windowImagesURLs.toString();
- } else if (key.equals(LICENSE_HREF))
- return getLicenseURL();
-
- return null;
- }
- /* (non-Javadoc)
- * @see org.eclipse.core.runtime.IBundleGroup#getProviderName()
- */
- public String getProviderName() {
- if (branding == null)
- branding = AboutInfo.readFeatureInfo(id, version, getFeaturePluginIdentifier());
- return branding.getProviderName();
- }
- /* (non-Javadoc)
- * @see org.eclipse.core.runtime.IBundleGroup#getVersion()
- */
- public String getVersion() {
- return version;
- }
- /* (non-Javadoc)
- * @see org.eclipse.core.runtime.IProduct#getApplication()
- */
- public String getApplication() {
- return application;
- }
- /* (non-Javadoc)
- * @see org.eclipse.core.runtime.IProduct#getId()
- */
- public String getId() {
- return id;
- }
-
- public ResourceBundle getResourceBundle(){
- if (resourceBundle != null)
- return resourceBundle;
-
- // Determine the properties file location
- if (site == null)
- return null;
-
- ResourceBundle bundle = null;
- try {
- URL propertiesURL = new URL(site.getResolvedURL(), getURL());
- ClassLoader l = new URLClassLoader(new URL[] { propertiesURL }, null);
- bundle = ResourceBundle.getBundle(IConfigurationConstants.CFG_FEATURE_ENTRY, Utils.getDefaultLocale(), l);
- } catch (MissingResourceException e) {
- Utils.log(e.getLocalizedMessage());
- } catch (MalformedURLException e) {
- Utils.log(e.getLocalizedMessage());
- }
- return bundle;
- }
-
- public void setLicenseURL(String licenseURL) {
- this.licenseURL = licenseURL;
- }
-
- public String getLicenseURL() {
- if (licenseURL == null)
- fullParse();
- if (licenseURL == null)
- return null;
-
- String resolvedURL = Utils.getResourceString(getResourceBundle(), licenseURL);
- if (resolvedURL.startsWith("http://")) //$NON-NLS-1$
- return resolvedURL;
- else {
- try {
- return new URL(getSite().getResolvedURL(), getURL() + resolvedURL).toExternalForm();
- } catch (MalformedURLException e) {
- return resolvedURL;
- }
- }
- }
-
- private void fullParse() {
- if (fullyParsed)
- return;
- fullyParsed = true;
- if (plugins == null)
- plugins = new ArrayList();
- FullFeatureParser parser = new FullFeatureParser(this);
- parser.parse();
- }
-
- public Bundle getDefiningBundle() {
- return Platform.getBundle(getFeaturePluginIdentifier());
- }
-
- public boolean hasBranding() {
- return pluginIdentifier != null || Platform.getBundle(id) != null;
- }
-} \ No newline at end of file
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/FeatureParser.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/FeatureParser.java
deleted file mode 100644
index 86429de85..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/FeatureParser.java
+++ /dev/null
@@ -1,135 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator;
-
-
-import java.io.*;
-import java.net.*;
-
-import javax.xml.parsers.*;
-
-import org.xml.sax.*;
-import org.xml.sax.helpers.*;
-
-/**
- * Default feature parser.
- * Parses the feature manifest file as defined by the platform.
- *
- * @since 3.0
- */
-public class FeatureParser extends DefaultHandler {
-
- private SAXParser parser;
- private FeatureEntry feature;
- private URL url;
-
- private final static SAXParserFactory parserFactory =
- SAXParserFactory.newInstance();
-
- /**
- * Constructs a feature parser.
- */
- public FeatureParser() {
- super();
- try {
- parserFactory.setNamespaceAware(true);
- this.parser = parserFactory.newSAXParser();
- } catch (ParserConfigurationException e) {
- System.out.println(e);
- } catch (SAXException e) {
- System.out.println(e);
- }
- }
- /**
- * Parses the specified url and constructs a feature
- */
- public FeatureEntry parse(URL featureURL){
- feature=null;
- InputStream in = null;
- try {
- this.url = featureURL;
- in = featureURL.openStream();
- parser.parse(new InputSource(in), this);
- } catch (SAXException e) {;
- } catch (IOException e) {
- } finally {
- if (in != null)
- try {
- in.close();
- } catch (IOException e1) {
- Utils.log(e1.getLocalizedMessage());
- }
- }
- return feature;
- }
-
- /**
- * Handle start of element tags
- * @see DefaultHandler#startElement(String, String, String, Attributes)
- * @since 2.0
- */
- public void startElement(String uri, String localName, String qName, Attributes attributes) throws SAXException {
-
- Utils.debug("Start Element: uri:" + uri + " local Name:" + localName + " qName:" + qName); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
-
- if ("feature".equals(localName)) { //$NON-NLS-1$
- processFeature(attributes);
- // stop parsing now
- throw new SAXException(""); //$NON-NLS-1$
- } else {
- }
-
- }
-
- /*
- * Process feature information
- */
- private void processFeature(Attributes attributes) {
-
- // identifier and version
- String id = attributes.getValue("id"); //$NON-NLS-1$
- String ver = attributes.getValue("version"); //$NON-NLS-1$
-
- if (id == null || id.trim().equals("") //$NON-NLS-1$
- || ver == null || ver.trim().equals("")) { //$NON-NLS-1$
- System.out.println(Messages.getString("FeatureParser.IdOrVersionInvalid", new String[] { id, ver})); //$NON-NLS-1$
- } else {
-// String label = attributes.getValue("label"); //$NON-NLS-1$
-// String provider = attributes.getValue("provider-name"); //$NON-NLS-1$
-// String imageURL = attributes.getValue("image"); //$NON-NLS-1$
- String os = attributes.getValue("os"); //$NON-NLS-1$
- String ws = attributes.getValue("ws"); //$NON-NLS-1$
- String nl = attributes.getValue("nl"); //$NON-NLS-1$
- String arch = attributes.getValue("arch"); //$NON-NLS-1$
- if (!Utils.isValidEnvironment(os, ws, arch, nl))
- return;
-// String exclusive = attributes.getValue("exclusive"); //$NON-NLS-1$
-// String affinity = attributes.getValue("colocation-affinity"); //$NON-NLS-1$
-
- String primary = attributes.getValue("primary"); //$NON-NLS-1$
- boolean isPrimary = "true".equals(primary); //$NON-NLS-1$
- String application = attributes.getValue("application"); //$NON-NLS-1$
- String plugin = attributes.getValue("plugin"); //$NON-NLS-1$
-
- //TODO rootURLs
- feature = new FeatureEntry(id, ver, plugin, "", isPrimary, application, null ); //$NON-NLS-1$
- if ("file".equals(url.getProtocol())) { //$NON-NLS-1$
- File f = new File(url.getFile().replace('/', File.separatorChar));
- feature.setURL("features" + "/" + f.getParentFile().getName() + "/");// + f.getName()); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
- } else {
- feature.setURL(url.toExternalForm());
- }
-
- Utils.
- debug("End process DefaultFeature tag: id:" +id + " ver:" +ver + " url:" + feature.getURL()); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
- }
- }
-} \ No newline at end of file
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/FullFeatureParser.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/FullFeatureParser.java
deleted file mode 100644
index 69e14e14a..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/FullFeatureParser.java
+++ /dev/null
@@ -1,149 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator;
-
-
-import java.io.*;
-import java.net.*;
-import java.util.*;
-
-import javax.xml.parsers.*;
-
-import org.xml.sax.*;
-import org.xml.sax.helpers.*;
-
-/**
- * A more complete feature parser. It adds the plugins listed to the feature.
- */
-public class FullFeatureParser extends DefaultHandler implements IConfigurationConstants{
-
- private SAXParser parser;
- private FeatureEntry feature;
- private URL url;
- private boolean isDescription;
- private StringBuffer description = new StringBuffer();
-
- private final static SAXParserFactory parserFactory =
- SAXParserFactory.newInstance();
-
- /**
- * Constructs a feature parser.
- */
- public FullFeatureParser(FeatureEntry feature) {
- super();
- this.feature = feature;
- try {
- parserFactory.setNamespaceAware(true);
- this.parser = parserFactory.newSAXParser();
- } catch (ParserConfigurationException e) {
- System.out.println(e);
- } catch (SAXException e) {
- System.out.println(e);
- }
- }
- /**
- */
- public void parse(){
- InputStream in = null;
- try {
- if (feature.getSite() == null)
- return;
- this.url = new URL(feature.getSite().getResolvedURL(), feature.getURL() + FEATURE_XML);
- in = url.openStream();
- parser.parse(new InputSource(in), this);
- } catch (SAXException e) {;
- } catch (IOException e) {
- } finally {
- if (in != null)
- try {
- in.close();
- } catch (IOException e1) {
- Utils.log(e1.getLocalizedMessage());
- }
- }
- }
-
- /**
- * Handle start of element tags
- * @see DefaultHandler#startElement(String, String, String, Attributes)
- * @since 2.0
- */
- public void startElement(String uri, String localName, String qName, Attributes attributes) throws SAXException {
-
- Utils.debug("Start Element: uri:" + uri + " local Name:" + localName + " qName:" + qName); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
-
- if ("plugin".equals(localName)) { //$NON-NLS-1$
- processPlugin(attributes);
- } else if ("description".equals(localName)){ //$NON-NLS-1$
- isDescription = true;
- } else if ("license".equals(localName)) { //$NON-NLS-1$
- processLicense(attributes);
- }
- }
-
- /*
- * Process feature information
- */
- private void processPlugin(Attributes attributes) {
-
- // identifier and version
- String id = attributes.getValue("id"); //$NON-NLS-1$
- String ver = attributes.getValue("version"); //$NON-NLS-1$
-
- if (id == null || id.trim().equals("") //$NON-NLS-1$
- || ver == null || ver.trim().equals("")) { //$NON-NLS-1$
- System.out.println(Messages.getString("FeatureParser.IdOrVersionInvalid", new String[] { id, ver})); //$NON-NLS-1$
- } else {
-// String label = attributes.getValue("label"); //$NON-NLS-1$
-// String provider = attributes.getValue("provider-name"); //$NON-NLS-1$
- String nl = attributes.getValue("nl"); //$NON-NLS-1$
- String os = attributes.getValue("os"); //$NON-NLS-1$
- String ws = attributes.getValue("ws"); //$NON-NLS-1$
- String arch = attributes.getValue("arch"); //$NON-NLS-1$
- if (!Utils.isValidEnvironment(os, ws, arch,nl))
- return;
-
- PluginEntry plugin = new PluginEntry();
- plugin.setPluginIdentifier(id);
- plugin.setPluginVersion(ver);
- feature.addPlugin(plugin);
-
- Utils.
- debug("End process DefaultFeature tag: id:" +id + " ver:" +ver + " url:" + feature.getURL()); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
- }
- }
-
- private void processLicense(Attributes attributes ){
- feature.setLicenseURL(attributes.getValue("url")); //$NON-NLS-1$
- }
-
- /* (non-Javadoc)
- * @see org.xml.sax.ContentHandler#characters(char[], int, int)
- */
- public void characters(char[] ch, int start, int length)
- throws SAXException {
- if (!isDescription)
- return;
- description.append(ch, start, length);
- }
- /* (non-Javadoc)
- * @see org.xml.sax.ContentHandler#endElement(java.lang.String, java.lang.String, java.lang.String)
- */
- public void endElement(String uri, String localName, String qName)
- throws SAXException {
- if ("description".equals(localName)) { //$NON-NLS-1$
- isDescription = false;
- String d = description.toString().trim();
- ResourceBundle bundle = feature.getResourceBundle();
- feature.setDescription(Utils.getResourceString(bundle, d));
- }
- }
-} \ No newline at end of file
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/IConfigurationConstants.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/IConfigurationConstants.java
deleted file mode 100644
index bc90bbc9b..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/IConfigurationConstants.java
+++ /dev/null
@@ -1,64 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator;
-
-import org.eclipse.update.configurator.IPlatformConfiguration.*;
-
-/**
- * Constants
- */
-public interface IConfigurationConstants {
- public static final String ECLIPSE_PRODUCT = "eclipse.product"; //$NON-NLS-1$
- public static final String ECLIPSE_APPLICATION = "eclipse.application"; //$NON-NLS-1$
- public static final String CFG = "config"; //$NON-NLS-1$
- public static final String CFG_BOOT_PLUGIN = "bootstrap"; //$NON-NLS-1$
- public static final String CFG_SITE = "site"; //$NON-NLS-1$
- public static final String CFG_URL = "url"; //$NON-NLS-1$
- public static final String CFG_POLICY = "policy"; //$NON-NLS-1$
- public static final String[] CFG_POLICY_TYPE = { "USER-INCLUDE", "USER-EXCLUDE" }; //$NON-NLS-1$ //$NON-NLS-2$
- public static final String CFG_POLICY_TYPE_UNKNOWN = "UNKNOWN"; //$NON-NLS-1$
- public static final String CFG_LIST = "list"; //$NON-NLS-1$
- public static final String CFG_STAMP = "stamp"; //$NON-NLS-1$
- public static final String CFG_FEATURE_STAMP = "stamp.features"; //$NON-NLS-1$
- public static final String CFG_PLUGIN_STAMP = "stamp.plugins"; //$NON-NLS-1$
- public static final String CFG_UPDATEABLE = "updateable"; //$NON-NLS-1$
- public static final String CFG_LINK_FILE = "linkfile"; //$NON-NLS-1$
- public static final String CFG_FEATURE_ENTRY = "feature"; //$NON-NLS-1$
- public static final String CFG_FEATURE_ENTRY_ID = "id"; //$NON-NLS-1$
- public static final String CFG_FEATURE_ENTRY_PRIMARY = "primary"; //$NON-NLS-1$
- public static final String CFG_FEATURE_ENTRY_VERSION = "version"; //$NON-NLS-1$
- public static final String CFG_FEATURE_ENTRY_PLUGIN_VERSION = "plugin-version"; //$NON-NLS-1$
- public static final String CFG_FEATURE_ENTRY_PLUGIN_IDENTIFIER = "plugin-identifier"; //$NON-NLS-1$
- public static final String CFG_FEATURE_ENTRY_APPLICATION = "application"; //$NON-NLS-1$
- public static final String CFG_FEATURE_ENTRY_ROOT = "root"; //$NON-NLS-1$
- public static final String CFG_DATE = "date"; //$NON-NLS-1$
- public static final String CFG_PLUGIN = "plugin"; //$NON-NLS-1$
- public static final String CFG_FRAGMENT = "fragment"; //$NON-NLS-1$
- public static final String CFG_ENABLED = "enabled"; //$NON-NLS-1$
- public static final String CFG_SHARED_URL = "shared_ur"; //$NON-NLS-1$
-
-
- public static final String CFG_VERSION = "version"; //$NON-NLS-1$
- public static final String CFG_TRANSIENT = "transient"; //$NON-NLS-1$
- public static final String VERSION = "3.0"; //$NON-NLS-1$
-// public static final String EOF = "eof"; //$NON-NLS-1$
- public static final int CFG_LIST_LENGTH = 10;
-
- public static final int DEFAULT_POLICY_TYPE = ISitePolicy.USER_EXCLUDE;
- public static final String[] DEFAULT_POLICY_LIST = new String[0];
-
- public static final String PLUGINS = "plugins"; //$NON-NLS-1$
- public static final String FEATURES = "features"; //$NON-NLS-1$
- public static final String PLUGIN_XML = "plugin.xml"; //$NON-NLS-1$
- public static final String FRAGMENT_XML = "fragment.xml"; //$NON-NLS-1$
- public static final String META_MANIFEST_MF = "META-INF/MANIFEST.MF"; //$NON-NLS-1$
- public static final String FEATURE_XML = "feature.xml"; //$NON-NLS-1$
-}
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/Messages.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/Messages.java
deleted file mode 100644
index 211c181b6..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/Messages.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator;
-
-import java.text.MessageFormat;
-import java.util.*;
-
-public class Messages {
- private static String bundleName = "org.eclipse.update.internal.configurator.messages"; //$NON-NLS-1$
- private static ResourceBundle bundle = ResourceBundle.getBundle(bundleName, Locale.getDefault());
-
- /**
- * Lookup the message with the given ID in this catalog
- */
- public static String getString(String id) {
- return getString(id, (String[]) null);
- }
- /**
- * Lookup the message with the given ID in this catalog and bind its
- * substitution locations with the given string.
- */
- public static String getString(String id, String binding) {
- return getString(id, new String[] { binding });
- }
- /**
- * Lookup the message with the given ID in this catalog and bind its
- * substitution locations with the given strings.
- */
- public static String getString(String id, String binding1, String binding2) {
- return getString(id, new String[] { binding1, binding2 });
- }
-
- /**
- * Lookup the message with the given ID in this catalog and bind its
- * substitution locations with the given string values.
- */
- public static String getString(String id, String[] bindings) {
- if (id == null)
- return "No message available"; //$NON-NLS-1$
- String message = null;
- try {
- message = bundle.getString(id);
- } catch (MissingResourceException e) {
- // If we got an exception looking for the message, fail gracefully by just returning
- // the id we were looking for. In most cases this is semi-informative so is not too bad.
- return "Missing message: " + id + " in: " + bundleName; //$NON-NLS-1$ //$NON-NLS-2$
- }
- if (bindings == null)
- return message;
- return MessageFormat.format(message, bindings);
- }
- /**
- * Print a debug message to the console. If the given boolean is <code>true</code> then
- * pre-pend the message with the current date.
- */
- public static void debug(boolean includeDate, String message) {
- if (includeDate)
- message = new Date(System.currentTimeMillis()).toString() + " - " + message; //$NON-NLS-1$
- System.out.println(message);
- }
-}
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/PlatformConfiguration.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/PlatformConfiguration.java
deleted file mode 100644
index 695bec86d..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/PlatformConfiguration.java
+++ /dev/null
@@ -1,1169 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator;
-
-import java.io.*;
-import java.lang.reflect.*;
-import java.net.*;
-import java.nio.channels.*;
-import java.util.*;
-
-import javax.xml.parsers.*;
-import javax.xml.transform.*;
-import javax.xml.transform.dom.*;
-import javax.xml.transform.stream.*;
-
-import org.eclipse.core.runtime.*;
-import org.eclipse.osgi.service.datalocation.*;
-import org.eclipse.update.configurator.*;
-import org.w3c.dom.*;
-
-/**
- * This class is responsible for providing the features and plugins (bundles) to
- * the runtime. Configuration data is stored in the configuration/org.eclipse.update/platform.xml file.
- * When eclipse starts, it tries to load the config info from platform.xml.
- * If the file does not exist, then it also tries to read it from a temp or backup file.
- * If this does not succeed, a platform.xml is created by inspecting the eclipse
- * installation directory (its features and plugin folders).
- * If platform.xml already exists, a check is made to see when it was last modified
- * and whether there are any file system changes that are newer (users may manually unzip
- * features and plugins). In this case, the newly added features and plugins are picked up.
- * A check for existence of features and plugins is also performed, to detect deletions.
- */
-public class PlatformConfiguration implements IPlatformConfiguration, IConfigurationConstants {
-
- private static PlatformConfiguration currentPlatformConfiguration = null;
- private static final DocumentBuilderFactory documentBuilderFactory = DocumentBuilderFactory.newInstance();
- private static final TransformerFactory transformerFactory = TransformerFactory.newInstance();
-
- private Configuration config;
- private URL configLocation;
- private HashMap externalLinkSites; // used to restore prior link site state
- private long changeStamp;
- private long featuresChangeStamp;
- private boolean featuresChangeStampIsValid;
- private long pluginsChangeStamp;
- private boolean pluginsChangeStampIsValid;
- private FileLock lock;
-
- private static final String ECLIPSE = "eclipse"; //$NON-NLS-1$
- private static final String CONFIG_HISTORY = "history"; //$NON-NLS-1$
- private static final String PLATFORM_XML = "platform.xml"; //$NON-NLS-1$
- private static final String CONFIG_NAME = ConfigurationActivator.NAME_SPACE + "/" + PLATFORM_XML; //$NON-NLS-1$
- private static final String CONFIG_INI = "config.ini"; //NON-NLS-1$ //$NON-NLS-1$
- private static final String CONFIG_FILE_LOCK_SUFFIX = ".lock"; //$NON-NLS-1$
- private static final String CONFIG_FILE_TEMP_SUFFIX = ".tmp"; //$NON-NLS-1$
- private static final String LINKS = "links"; //$NON-NLS-1$
- private static final String[] BOOTSTRAP_PLUGINS = {}; //$NON-NLS-1$
-
- private static final String DEFAULT_FEATURE_ID = "org.eclipse.platform"; //$NON-NLS-1$
- private static final String DEFAULT_FEATURE_APPLICATION = "org.eclipse.ui.ide.workbench"; //$NON-NLS-1$
-
- private static final String LINK_PATH = "path"; //$NON-NLS-1$
- private static final String LINK_READ = "r"; //$NON-NLS-1$
- private static final String LINK_READ_WRITE = "rw"; //$NON-NLS-1$
- private static URL installURL;
-
- private PlatformConfiguration(Location platformConfigLocation) throws CoreException, IOException {
-
- this.externalLinkSites = new HashMap();
- this.config = null;
-
- // initialize configuration
- initializeCurrent(platformConfigLocation);
-
- // Detect external links. These are "soft link" to additional sites. The link
- // files are usually provided by external installation programs. They are located
- // relative to this configuration URL.
- // Note: don't do it for self hosting
- if (!isTransient())
- configureExternalLinks();
-
- // Validate sites in the configuration. Causes any sites that do not exist to
- // be removed from the configuration
- validateSites();
-
- // compute differences between configuration and actual content of the sites
- // (base sites and link sites)
- // Note: when the config is transient (generated by PDE, etc.) we don't reconcile
- if (isTransient())
- return;
-
- changeStamp = computeChangeStamp();
- if (changeStamp > config.getDate().getTime())
- reconcile();
- }
-
- PlatformConfiguration(URL url) throws Exception {
- this.externalLinkSites = new HashMap();
- initialize(url);
- }
-
- /*
- * @see IPlatformConfiguration#createSiteEntry(URL, ISitePolicy)
- */
- public ISiteEntry createSiteEntry(URL url, ISitePolicy policy) {
- return new SiteEntry(url, policy);
- }
-
- /*
- * @see IPlatformConfiguration#createSitePolicy(int, String[])
- */
- public ISitePolicy createSitePolicy(int type, String[] list) {
- return new SitePolicy(type, list);
- }
-
- /*
- * @see IPlatformConfiguration#createFeatureEntry(String, String, String, boolean, String, URL)
- */
- public IFeatureEntry createFeatureEntry(String id, String version, String pluginVersion, boolean primary, String application, URL[] root) {
- return new FeatureEntry(id, version, pluginVersion, primary, application, root);
- }
-
- /*
- * @see IPlatformConfiguration#createFeatureEntry(String, String, String,
- * String, boolean, String, URL)
- */
- public IFeatureEntry createFeatureEntry(String id, String version, String pluginIdentifier, String pluginVersion, boolean primary, String application, URL[] root) {
- return new FeatureEntry(id, version, pluginIdentifier, pluginVersion, primary, application, root);
- }
-
- /*
- * @see IPlatformConfiguration#configureSite(ISiteEntry)
- */
- public void configureSite(ISiteEntry entry) {
- configureSite(entry, false);
- }
-
- /*
- * @see IPlatformConfiguration#configureSite(ISiteEntry, boolean)
- */
- public synchronized void configureSite(ISiteEntry entry, boolean replace) {
-
- if (entry == null)
- return;
-
- URL url = entry.getURL();
- if (url == null)
- return;
-
- String key = url.toExternalForm();
- if (config.getSiteEntry(key) != null && !replace)
- return;
-
- if (entry instanceof SiteEntry)
- config.addSiteEntry(key, (SiteEntry)entry);
- }
-
- /*
- * @see IPlatformConfiguration#unconfigureSite(ISiteEntry)
- */
- public synchronized void unconfigureSite(ISiteEntry entry) {
- if (entry == null)
- return;
-
- URL url = entry.getURL();
- if (url == null)
- return;
-
- String key = url.toExternalForm();
- if (entry instanceof SiteEntry)
- config.removeSiteEntry(key);
- }
-
- /*
- * @see IPlatformConfiguration#getConfiguredSites()
- */
- public ISiteEntry[] getConfiguredSites() {
- if (config == null)
- return new ISiteEntry[0];
-
- SiteEntry[] sites = config.getSites();
- ArrayList enabledSites = new ArrayList(sites.length);
- for (int i=0; i<sites.length; i++) {
- if (sites[i].isEnabled())
- enabledSites.add(sites[i]);
- }
- return (ISiteEntry[])enabledSites.toArray(new ISiteEntry[enabledSites.size()]);
- }
-
- /*
- * @see IPlatformConfiguration#findConfiguredSite(URL)
- */
- public ISiteEntry findConfiguredSite(URL url) {
- return findConfiguredSite(url, true);
- }
-
- /**
- *
- * @param url site url
- * @param checkPlatformURL if true, check for url format that is platform:/...
- * @return
- */
- public SiteEntry findConfiguredSite(URL url, boolean checkPlatformURL) {
- if (url == null)
- return null;
- String key = url.toExternalForm();
-
- SiteEntry result = config.getSiteEntry(key);
- if (result == null) { // retry with decoded URL string
- try {
- key = URLDecoder.decode(key, "UTF-8"); //$NON-NLS-1$
- } catch (UnsupportedEncodingException e) {
- // ignore
- }
- result = config.getSiteEntry(key);
- }
-
- if (result == null && checkPlatformURL) {
- try {
- result = findConfiguredSite(Utils.asPlatformURL(url), false);
- } catch (Exception e) {
- //ignore
- }
- }
- return result;
- }
-
- /*
- * @see IPlatformConfiguration#configureFeatureEntry(IFeatureEntry)
- */
- public synchronized void configureFeatureEntry(IFeatureEntry entry) {
- if (entry == null)
- return;
-
- String key = entry.getFeatureIdentifier();
- if (key == null)
- return;
-
- // we should check each site and find where the feature is
- // located and then configure it
- if (config == null)
- config = new Configuration();
-
- SiteEntry[] sites = config.getSites();
- for (int i=0; i<sites.length; i++) {
- // find out what site contains the feature and configure it
- try {
- URL url = new URL(sites[i].getURL(), FEATURES + "/" + entry.getFeatureIdentifier()+ "_" + entry.getFeatureVersion() + "/"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
- if (new File(url.getFile()).exists())
- sites[i].addFeatureEntry(entry);
- else {
- url = new URL(sites[i].getURL(), FEATURES + "/" + entry.getFeatureIdentifier() + "/"); //$NON-NLS-1$ //$NON-NLS-2$
- if (new File(url.getFile()).exists())
- sites[i].addFeatureEntry(entry);
- }
- } catch (MalformedURLException e) {
- }
- }
- }
-
- /*
- * @see IPlatformConfiguration#unconfigureFeatureEntry(IFeatureEntry)
- */
- public synchronized void unconfigureFeatureEntry(IFeatureEntry entry) {
- if (entry == null)
- return;
-
- String key = entry.getFeatureIdentifier();
- if (key == null)
- return;
-
- config.unconfigureFeatureEntry(entry);
- }
-
- /*
- * @see IPlatformConfiguration#getConfiguredFeatureEntries()
- */
- public IFeatureEntry[] getConfiguredFeatureEntries() {
- ArrayList configFeatures = new ArrayList();
- SiteEntry[] sites = config.getSites();
- for (int i=0; i<sites.length; i++) {
- FeatureEntry[] features = sites[i].getFeatureEntries();
- for (int j=0; j<features.length; j++)
- configFeatures.add(features[j]);
- }
- return (IFeatureEntry[])configFeatures.toArray(new FeatureEntry[configFeatures.size()]);
- }
-
- /*
- * @see IPlatformConfiguration#findConfiguredFeatureEntry(String)
- */
- public IFeatureEntry findConfiguredFeatureEntry(String id) {
- if (id == null)
- return null;
-
- SiteEntry[] sites = config.getSites();
- for (int i=0; i<sites.length; i++) {
- FeatureEntry f = sites[i].getFeatureEntry(id);
- if (f != null)
- return f;
- }
- return null;
- }
-
- /*
- * @see IPlatformConfiguration#getConfigurationLocation()
- */
- public URL getConfigurationLocation() {
- return configLocation;
- }
-
- /*
- * @see IPlatformConfiguration#getChangeStamp()
- */
- public long getChangeStamp() {
- if (config.getLinkedConfig() == null)
- return config.getDate().getTime();
- else
- return Math.max(config.getDate().getTime(), config.getLinkedConfig().getDate().getTime());
- }
-
- /*
- * @see IPlatformConfiguration#getFeaturesChangeStamp()
- * @deprecated Don't use this method
- */
- public long getFeaturesChangeStamp() {
- return 0;
- }
-
- /*
- * @see IPlatformConfiguration#getPluginsChangeStamp()
- * @deprecated Don't use this method
- */
- public long getPluginsChangeStamp() {
- return 0;
- }
-
-
- public String getApplicationIdentifier() {
- // Return the app if defined in system properties
- String application = System.getProperty(ECLIPSE_APPLICATION);
- if (application != null)
- return application;
-
- // Otherwise, try to get it from the primary feature (aka product)
- String feature = getPrimaryFeatureIdentifier();
-
- // lookup application for feature (specified or defaulted)
- if (feature != null) {
- IFeatureEntry fe = findConfiguredFeatureEntry(feature);
- if (fe != null) {
- if (fe.getFeatureApplication() != null)
- return fe.getFeatureApplication();
- }
- }
-
- // return hardcoded default if we failed
- return DEFAULT_FEATURE_APPLICATION;
- }
-
- /*
- * @see IPlatformConfiguration#getPrimaryFeatureIdentifier()
- */
- public String getPrimaryFeatureIdentifier() {
- // Return the product if defined in system properties
- String primaryFeatureId = System.getProperty(ECLIPSE_PRODUCT);
- if (primaryFeatureId == null)
- primaryFeatureId = DEFAULT_FEATURE_ID; // return hardcoded default
-
- // check if feature exists
- if (findConfiguredFeatureEntry(primaryFeatureId) == null)
- return null;
- else
- return primaryFeatureId;
- }
-
- /*
- * @see IPlatformConfiguration#getPluginPath()
- */
- public URL[] getPluginPath() {
- ArrayList path = new ArrayList();
- Utils.debug("computed plug-in path:"); //$NON-NLS-1$
-
- ISiteEntry[] sites = getConfiguredSites();
- URL pathURL;
- for (int i = 0; i < sites.length; i++) {
- String[] plugins = sites[i].getPlugins();
- for (int j = 0; j < plugins.length; j++) {
- try {
- pathURL = new URL(((SiteEntry) sites[i]).getResolvedURL(), plugins[j]);
- path.add(pathURL);
- Utils.debug(" " + pathURL.toString()); //$NON-NLS-1$
- } catch (MalformedURLException e) {
- // skip entry ...
- Utils.debug(" bad URL: " + e); //$NON-NLS-1$
- }
- }
- }
- return (URL[]) path.toArray(new URL[0]);
- }
-
-
- /*
- * A variation of the getPluginPath, but it returns the actual plugin entries
- */
- public PluginEntry[] getPlugins() {
- ArrayList allPlugins = new ArrayList();
- Utils.debug("computed plug-ins:"); //$NON-NLS-1$
-
- ISiteEntry[] sites = getConfiguredSites();
- for (int i = 0; i < sites.length; i++) {
- if (!(sites[i] instanceof SiteEntry)) {
- Utils.debug("Site " + sites[i].getURL() + " is not a SiteEntry"); //$NON-NLS-1$ //$NON-NLS-2$
- continue;
- }
- PluginEntry[] plugins = ((SiteEntry)sites[i]).getPluginEntries();
- for (int j = 0; j < plugins.length; j++) {
- allPlugins.add(plugins[j]);
- Utils.debug(" " + plugins[j].getURL()); //$NON-NLS-1$
- }
- }
- return (PluginEntry[]) allPlugins.toArray(new PluginEntry[0]);
- }
-
-
- /*
- * @see IPlatformConfiguration#getBootstrapPluginIdentifiers()
- */
- public String[] getBootstrapPluginIdentifiers() {
- return BOOTSTRAP_PLUGINS;
- }
-
- /*
- * @see IPlatformConfiguration#setBootstrapPluginLocation(String, URL)
- */
- public void setBootstrapPluginLocation(String id, URL location) {
- }
-
- /*
- * @see IPlatformConfiguration#isUpdateable()
- */
- public boolean isUpdateable() {
- return true;
- }
-
- /*
- * @see IPlatformConfiguration#isTransient()
- */
- public boolean isTransient() {
- if (config != null)
- return config.isTransient();
- else
- return false;
- }
-
- /*
- * @see IPlatformConfiguration#isTransient(boolean)
- */
- public void isTransient(boolean value) {
- if (this != getCurrent() && config != null)
- config.setTransient(value);
- }
-
- /*
- * @see IPlatformConfiguration#refresh()
- */
- public synchronized void refresh() {
- // Reset computed values. Will be lazily refreshed
- // on next access
- ISiteEntry[] sites = getConfiguredSites();
- for (int i = 0; i < sites.length; i++) {
- // reset site entry
- ((SiteEntry) sites[i]).refresh();
- }
- }
-
- /*
- * @see IPlatformConfiguration#save()
- */
- public void save() throws IOException {
- if (isUpdateable())
- save(configLocation);
- }
-
- /*
- * @see IPlatformConfiguration#save(URL)
- */
- public synchronized void save(URL url) throws IOException {
- if (url == null)
- throw new IOException(Messages.getString("cfig.unableToSave.noURL")); //$NON-NLS-1$
-
- OutputStream os = null;
- if (!url.getProtocol().equals("file")) { //$NON-NLS-1$
- // not a file protocol - attempt to save to the URL
- URLConnection uc = url.openConnection();
- uc.setDoOutput(true);
- os = uc.getOutputStream();
- try {
- saveAsXML(os);
- config.setDirty(false);
- } catch (CoreException e) {
- Utils.log(e.getMessage());
- Utils.log(e.getStatus());
- throw new IOException(Messages.getString("cfig.unableToSave", url.toExternalForm())); //$NON-NLS-1$
- } finally {
- os.close();
- }
- } else {
- // file protocol - do safe i/o
- File cfigFile = new File(url.getFile().replace('/', File.separatorChar));
- if (!cfigFile.getName().equals(PLATFORM_XML)) {
- if (cfigFile.exists() && cfigFile.isFile()) {
- Utils.log(Messages.getString("PlatformConfiguration.expectingPlatformXMLorDirectory") + cfigFile.getName()); //$NON-NLS-1$
- cfigFile = cfigFile.getParentFile();
- }
- cfigFile = new File(cfigFile, CONFIG_NAME);
- }
- File workingDir = cfigFile.getParentFile();
- if (workingDir != null && !workingDir.exists())
- workingDir.mkdirs();
-
- // Do safe i/o:
- // - backup current config, by moving it to the history folder
- // - write new config to platform.xml.tmp file
- // - rename the temp file to platform.xml
- File cfigFileOriginal = new File(cfigFile.getAbsolutePath());
- File cfigTmp = new File(cfigFile.getAbsolutePath() + CONFIG_FILE_TEMP_SUFFIX);
-
- // Backup old file
- if (cfigFile.exists()){
- File backupDir = new File(workingDir, CONFIG_HISTORY);
- if (!backupDir.exists())
- backupDir.mkdir();
- long timestamp = cfigFile.lastModified();
- File preservedFile = new File(backupDir, String.valueOf(timestamp)+".xml"); //$NON-NLS-1$
- // If the target file exists, increment the timestamp. Try at most 100 times.
- long increment = 1;
- while (preservedFile.exists() && increment < 100){
- preservedFile = new File(backupDir, String.valueOf(timestamp+increment++)+".xml"); //$NON-NLS-1$
- }
- if (!preservedFile.exists()) {
- // try renaming current config to backup copy
- if (!cfigFile.renameTo(preservedFile))
- Utils.log(Messages.getString("PlatformConfiguration.cannotBackupConfig")); //$NON-NLS-1$
- }
- }
-
- // If config.ini does not exist, generate it in the configuration area
- writeConfigIni(workingDir.getParentFile());
-
- // first save the file as temp
- os = new FileOutputStream(cfigTmp);
- try {
- saveAsXML(os);
- // Try flushing any internal buffers, and synchronize with the disk
- try {
- os.flush();
- ((FileOutputStream)os).getFD().sync();
- } catch (SyncFailedException e2) {
- Utils.log(e2.getMessage());
- } catch (IOException e2) {
- Utils.log(e2.getMessage());
- }
- try {
- os.close();
- os = null;
- } catch (IOException e1) {
- Utils.log(Messages.getString("PlatformConfiguration.cannotCloseStream") + cfigTmp); //$NON-NLS-1$
- Utils.log(e1.getMessage());
- }
- // set file time stamp to match that of the config element
- cfigTmp.setLastModified(config.getDate().getTime());
- // set this on config, in case the value was rounded off
- config.setLastModified(cfigTmp.lastModified());
- // make the change stamp to be the same as the config file
- changeStamp = config.getDate().getTime();
- config.setDirty(false);
- } catch (CoreException e) {
- throw new IOException(Messages.getString("cfig.unableToSave", cfigTmp.getAbsolutePath())); //$NON-NLS-1$
- } finally {
- if (os != null)
- try {
- os.close();
- } catch (IOException e1) {
- Utils.log(Messages.getString("PlatformConfiguration.cannotCloseTempFile") + cfigTmp); //$NON-NLS-1$
- }
- }
-
- // at this point we have old config (if existed) as "bak" and the
- // new config as "tmp".
- boolean ok = cfigTmp.renameTo(cfigFileOriginal);
- if (!ok) {
- // this codepath represents a tiny failure window. The load processing
- // on startup will detect missing config and will attempt to start
- // with "tmp" (latest), then "bak" (the previous). We can also end up
- // here if we failed to rename the current config to "bak". In that
- // case we will restart with the previous state.
- Utils.log(Messages.getString("PlatformConfiguration.cannotRenameTempFile")); //$NON-NLS-1$
-
- throw new IOException(Messages.getString("cfig.unableToSave", cfigTmp.getAbsolutePath())); //$NON-NLS-1$
- }
- }
- }
-
- private void writeConfigIni(File configDir) {
- try {
- File configIni = new File(configDir, CONFIG_INI);
- if (!configIni.exists()) {
- URL configIniURL = ConfigurationActivator.getBundleContext().getBundle().getEntry(CONFIG_INI);
- copy(configIniURL, configIni);
- }
- } catch (Exception e) {
- System.out.println(Messages.getString("cfg.unableToCreateConfig.ini")); //$NON-NLS-1$
- }
- }
-
- public static PlatformConfiguration getCurrent() {
- return currentPlatformConfiguration;
- }
-
- /**
- * Starts a platform installed at specified installURL using configuration located at platformConfigLocation.
- */
- public static synchronized void startup(URL installURL, Location platformConfigLocation) throws Exception {
- PlatformConfiguration.installURL = installURL;
-
- // create current configuration
- if (currentPlatformConfiguration == null) {
- currentPlatformConfiguration = new PlatformConfiguration(platformConfigLocation);
- if (currentPlatformConfiguration.config == null)
- throw new Exception(Messages.getString("PlatformConfiguration.cannotLoadConfig") + platformConfigLocation.getURL()); //$NON-NLS-1$
- if (currentPlatformConfiguration.config.isDirty())
- // If this is a transient config (generated by PDE),do nothing
- // otherwise, save the configuration with proper date
- if (!currentPlatformConfiguration.isTransient())
- currentPlatformConfiguration.save();
- }
- }
-
- public static synchronized void shutdown() throws IOException {
-
- // save platform configuration
- PlatformConfiguration config = getCurrent();
- if (config != null) {
- // only save if there are changes in the config
- if (config.config.isDirty() && !config.isTransient()) {
- try {
- config.save();
- } catch (IOException e) {
- Utils.debug("Unable to save configuration " + e.toString()); //$NON-NLS-1$
- // will recover on next startup
- }
- }
- }
- }
-
-
- private synchronized void initializeCurrent(Location platformConfigLocation) throws IOException {
-
- // Configuration URL was is specified by the OSGi layer.
- // Default behavior is to look
- // for configuration in the specified meta area. If not found, look
- // for pre-initialized configuration in the installation location.
- // If it is found it is used as the initial configuration. Otherwise
- // a new configuration is created. In either case the resulting
- // configuration is written into the specified configuration area.
-
- URL configFileURL = new URL(platformConfigLocation.getURL(), CONFIG_NAME);
- try {
- // check concurrent use lock
- getConfigurationLock(platformConfigLocation.getURL());
-
- // try loading the configuration
- try {
- config = loadConfig(configFileURL);
- Utils.debug("Using configuration " + configFileURL.toString()); //$NON-NLS-1$
- } catch (Exception e) {
- // failed to load, see if we can find pre-initialized configuration.
- try {
- Location parentLocation = platformConfigLocation.getParentLocation();
- if (parentLocation == null)
- throw new IOException(); // no platform.xml found, need to create default site
-
- URL sharedConfigFileURL = new URL(parentLocation.getURL(), CONFIG_NAME);
- config = loadConfig(sharedConfigFileURL);
-
- // pre-initialized config loaded OK ... copy any remaining update metadata
- // Only copy if the default config location is not the install location
- if (!sharedConfigFileURL.equals(configFileURL)) {
- // need to link config info instead of using a copy
- linkInitializedState(config, parentLocation, platformConfigLocation);
- Utils.debug("Configuration initialized from " + sharedConfigFileURL.toString()); //$NON-NLS-1$
- }
- return;
- } catch (Exception ioe) {
- Utils.debug("Creating default configuration from " + configFileURL.toExternalForm()); //$NON-NLS-1$
- createDefaultConfiguration(configFileURL);
- }
- }
- } finally {
- configLocation = configFileURL;
- if (config.getURL() == null)
- config.setURL(configFileURL);
- verifyPath(configLocation);
- Utils.debug("Creating configuration " + configFileURL.toString()); //$NON-NLS-1$
- // releaes concurrent use lock
- clearConfigurationLock();
- }
- }
-
-
- private synchronized void initialize(URL url) throws Exception {
- if (url != null) {
- config = loadConfig(url);
- Utils.debug("Using configuration " + url.toString()); //$NON-NLS-1$
- }
- if (config == null) {
- config = new Configuration();
- Utils.debug("Creating empty configuration object"); //$NON-NLS-1$
- }
- config.setURL(url);
- configLocation = url;
- }
-
- private void createDefaultConfiguration(URL url)throws IOException{
- // we are creating new configuration
- config = new Configuration();
- config.setURL(url);
- SiteEntry defaultSite = (SiteEntry)getRootSite();
- configureSite(defaultSite);
- try {
- // parse the site directory to discover features
- defaultSite.loadFromDisk(0);
- } catch (CoreException e1) {
- Utils.log(Messages.getString("PlatformConfiguration.cannotLoadDefaultSite") + defaultSite.getResolvedURL()); //$NON-NLS-1$
- return;
- }
- }
- private ISiteEntry getRootSite() {
- // create default site entry for the root
- ISitePolicy defaultPolicy = createSitePolicy(DEFAULT_POLICY_TYPE, DEFAULT_POLICY_LIST);
- URL siteURL = null;
- try {
- siteURL = new URL("platform:/base/"); //$NON-NLS-1$ // try using platform-relative URL
- } catch (MalformedURLException e) {
- siteURL = getInstallURL(); // ensure we come up ... use absolute file URL
- }
- ISiteEntry defaultSite = createSiteEntry(siteURL, defaultPolicy);
- return defaultSite;
- }
-
- /**
- * Gets the configuration lock
- * @param url configuration directory
- */
- private void getConfigurationLock(URL url) {
- if (!url.getProtocol().equals("file")) //$NON-NLS-1$
- return;
-
- File lockFile = new File(url.getFile(), ConfigurationActivator.NAME_SPACE+ File.separator+CONFIG_FILE_LOCK_SUFFIX);
- verifyPath(url);
- try {
- RandomAccessFile raf = new RandomAccessFile(lockFile, "rw"); //$NON-NLS-1$
- lock = raf.getChannel().lock();
- } catch (IOException ioe) {
- lock = null;
- }
- }
-
- private void clearConfigurationLock() {
- if (lock != null) {
- try {
- lock.channel().close();
- } catch (IOException ioe) {
- }
- }
- }
-
-
- private long computeChangeStamp() {
- featuresChangeStamp = computeFeaturesChangeStamp();
- pluginsChangeStamp = computePluginsChangeStamp();
- changeStamp = Math.max(featuresChangeStamp, pluginsChangeStamp);
- // round off to seconds
- changeStamp = (changeStamp/1000)*1000;
- return changeStamp;
- }
-
- private long computeFeaturesChangeStamp() {
- if (featuresChangeStampIsValid)
- return featuresChangeStamp;
-
- long result = 0;
- ISiteEntry[] sites = config.getSites();
- for (int i = 0; i < sites.length; i++) {
- result = Math.max(result, sites[i].getFeaturesChangeStamp());
- }
- featuresChangeStamp = result;
- featuresChangeStampIsValid = true;
- return featuresChangeStamp;
- }
-
- private long computePluginsChangeStamp() {
- if (pluginsChangeStampIsValid)
- return pluginsChangeStamp;
-
- long result = 0;
- ISiteEntry[] sites = config.getSites();
- for (int i = 0; i < sites.length; i++) {
- result = Math.max(result, sites[i].getPluginsChangeStamp());
- }
- pluginsChangeStamp = result;
- pluginsChangeStampIsValid = true;
- return pluginsChangeStamp;
- }
-
- private void configureExternalLinks() {
- URL linkURL = getInstallURL();
- if (!supportsDetection(linkURL))
- return;
-
- try {
- linkURL = new URL(linkURL, LINKS + "/"); //$NON-NLS-1$
- } catch (MalformedURLException e) {
- // skip bad links ...
- Utils.debug("Unable to obtain link URL"); //$NON-NLS-1$
- return;
- }
-
- File linkDir = new File(linkURL.getFile());
- File[] links = linkDir.listFiles();
- if (links == null || links.length == 0) {
- Utils.debug("No links detected in " + linkURL.toExternalForm()); //$NON-NLS-1$
- return;
- }
-
- for (int i = 0; i < links.length; i++) {
- if (links[i].isDirectory())
- continue;
- Utils.debug("Link file " + links[i].getAbsolutePath()); //$NON-NLS-1$
- Properties props = new Properties();
- FileInputStream is = null;
- try {
- is = new FileInputStream(links[i]);
- props.load(is);
- configureExternalLinkSite(links[i], props);
- } catch (IOException e) {
- // skip bad links ...
- Utils.debug(" unable to load link file " + e); //$NON-NLS-1$
- continue;
- } finally {
- if (is != null) {
- try {
- is.close();
- } catch (IOException e) {
- // ignore ...
- }
- }
- }
- }
- }
-
- private void configureExternalLinkSite(File linkFile, Properties props) {
- String path = props.getProperty(LINK_PATH);
- if (path == null) {
- Utils.debug(" no path definition"); //$NON-NLS-1$
- return;
- }
-
- String link;
- boolean updateable = true;
- URL siteURL;
-
- // parse out link information
- if (path.startsWith(LINK_READ + " ")) { //$NON-NLS-1$
- updateable = false;
- link = path.substring(2).trim();
- } else if (path.startsWith(LINK_READ_WRITE + " ")) { //$NON-NLS-1$
- link = path.substring(3).trim();
- } else {
- link = path.trim();
- }
-
- // make sure we have a valid link specification
- try {
- File siteFile = new File(link);
- siteFile = new File(siteFile, ECLIPSE);
- siteURL = siteFile.toURL();
- if (findConfiguredSite(siteURL, true) != null)
- // linked site is already known
- return;
- } catch (MalformedURLException e) {
- // ignore bad links ...
- Utils.debug(" bad URL " + e); //$NON-NLS-1$
- return;
- }
-
- // process the link
- SiteEntry linkSite = (SiteEntry) externalLinkSites.get(siteURL);
- if (linkSite == null) {
- // this is a link to a new target so create site for it
- ISitePolicy linkSitePolicy = createSitePolicy(DEFAULT_POLICY_TYPE, DEFAULT_POLICY_LIST);
- linkSite = (SiteEntry) createSiteEntry(siteURL, linkSitePolicy);
- }
- // update site entry if needed
- linkSite.setUpdateable(updateable);
- linkSite.setLinkFileName(linkFile.getAbsolutePath());
-
- // configure the new site
- // NOTE: duplicates are not replaced (first one in wins)
- configureSite(linkSite);
- // there are changes in the config
- config.setDirty(true);
- Utils.debug(" " + (updateable ? "R/W -> " : "R/O -> ") + siteURL.toString()); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
- }
-
- private void validateSites() {
-
- // check to see if all sites are valid. Remove any sites that do not exist.
- SiteEntry[] list = config.getSites();
- for (int i = 0; i < list.length; i++) {
- URL siteURL = list[i].getResolvedURL();
- if (!supportsDetection(siteURL))
- continue;
-
- File siteRoot = new File(siteURL.getFile().replace('/', File.separatorChar));
- if (!siteRoot.exists()) {
- unconfigureSite(list[i]);
- Utils.debug("Site " + siteURL + " does not exist ... removing from configuration"); //$NON-NLS-1$ //$NON-NLS-2$
- }
-
- // If multiple paths are defined in the same link file
- // or if the path changes, the old site will still be kept.
- // A better algorithm could be implemented by keeping track
- // of the previous content of the link file.
- // TODO do the above
- String linkName = list[i].getLinkFileName();
- if (linkName != null) {
- File linkFile = new File(linkName);
- if (!linkFile.exists()) {
- unconfigureSite(list[i]);
- config.setDirty(true);
- Utils.debug("Site " + siteURL + " is no longer linked ... removing from configuration"); //$NON-NLS-1$ //$NON-NLS-2$
- }
- }
- }
- }
-
- private void linkInitializedState(Configuration sharedConfig, Location sharedConfigLocation, Location newConfigLocation) {
- try {
- URL newConfigIniURL = new URL(newConfigLocation.getURL(), CONFIG_INI);
- if (!newConfigIniURL.getProtocol().equals("file")) //$NON-NLS-1$
- return; // need to be able to do write
-
- // modify config.ini and platform.xml to only link original files
- File configIni = new File(newConfigIniURL.getFile());
- Properties props = new Properties();
- props.put("osgi.sharedConfiguration.area", sharedConfigLocation.getURL().toExternalForm()); //$NON-NLS-1$
- props.store(new FileOutputStream(configIni), "Linked configuration"); //$NON-NLS-1$
-
- config = new Configuration(new Date());
- config.setURL(new URL(newConfigLocation.getURL(), CONFIG_NAME));
- config.setLinkedConfig(sharedConfig);
- config.setDirty(true);
- } catch (IOException e) {
- // this is an optimistic copy. If we fail, the state will be reconciled
- // when the update manager is triggered.
- System.out.println(e);
- }
- }
-
-
- private void copy(URL src, File tgt) throws IOException {
- InputStream is = null;
- OutputStream os = null;
- try {
- is = src.openStream();
- os = new FileOutputStream(tgt);
- byte[] buff = new byte[1024];
- int count = is.read(buff);
- while (count != -1) {
- os.write(buff, 0, count);
- count = is.read(buff);
- }
- } finally {
- if (is != null)
- try {
- is.close();
- } catch (IOException e) {
- // ignore ...
- }
- if (os != null)
- try {
- os.close();
- } catch (IOException e) {
- // ignore ...
- }
- }
- }
-
- private Configuration loadConfig(URL url) throws Exception {
- if (url == null)
- throw new IOException(Messages.getString("cfig.unableToLoad.noURL")); //$NON-NLS-1$
-
- // try to load saved configuration file (watch for failed prior save())
- ConfigurationParser parser = null;
- try {
- parser = new ConfigurationParser();
- } catch (InvocationTargetException e) {
- throw (Exception)e.getTargetException();
- }
-
- config = null;
- Exception originalException = null;
- try {
- config = parser.parse(url);
- if (config == null)
- throw new Exception(Messages.getString("PlatformConfiguration.cannotFindConfigFile")); //$NON-NLS-1$
- } catch (Exception e1) {
- // check for save failures, so open temp and backup configurations
- originalException = e1;
- try {
- URL tempURL = new URL(url.toExternalForm()+CONFIG_FILE_TEMP_SUFFIX);
- config = parser.parse(tempURL);
- if (config == null)
- throw new Exception();
- else
- config.setDirty(true); // force saving to platform.xml
- } catch (Exception e2) {
- try {
- // check the backup
- if ("file".equals(url.getProtocol())) { //$NON-NLS-1$
- File cfigFile = new File(url.getFile().replace('/', File.separatorChar));
- File workingDir = cfigFile.getParentFile();
- if (workingDir != null && workingDir.exists()) {
- File[] backups = workingDir.listFiles(new FileFilter(){
- public boolean accept(File pathname) {
- return pathname.isFile() && pathname.getName().endsWith(".xml"); //$NON-NLS-1$
- }});
- if (backups != null && backups.length > 0) {
- URL backupUrl = backups[backups.length-1].toURL();
- config = parser.parse(backupUrl);
- }
- }
- }
- if (config == null)
- throw originalException; // we tried, but no config here ...
- else
- config.setDirty(true); // force saving to platform.xml
- } catch (IOException e3) {
- throw originalException; // we tried, but no config here ...
- }
- }
- }
-
- return config;
- }
-
- public static boolean supportsDetection(URL url) {
- String protocol = url.getProtocol();
- if (protocol.equals("file")) //$NON-NLS-1$
- return true;
- else if (protocol.equals("platform")) {
- URL resolved = null;
- try {
- resolved = resolvePlatformURL(url); // 19536
- } catch (IOException e) {
- return false; // we tried but failed to resolve the platform URL
- }
- return resolved.getProtocol().equals("file"); //$NON-NLS-1$
- } else
- return false;
- }
-
- private static void verifyPath(URL url) {
- String protocol = url.getProtocol();
- String path = null;
- if (protocol.equals("file")) //$NON-NLS-1$
- path = url.getFile();
- else if (protocol.equals("platform")) { // $NON-NLS-1$
- URL resolved = null;
- try {
- resolved = resolvePlatformURL(url); // 19536
- if (resolved.getProtocol().equals("file")) //$NON-NLS-1$
- path = resolved.getFile();
- } catch (IOException e) {
- // continue ...
- }
- }
-
- if (path != null) {
- File dir = new File(path).getParentFile();
- if (dir != null)
- dir.mkdirs();
- }
- }
-
- public static URL resolvePlatformURL(URL url) throws IOException {
- // 19536
- if (url.getProtocol().equals("platform")) { // $NON-NLS-1$;
- url = Platform.asLocalURL(url);
- // TODO URL resolution by platform returns url file:d:/path as opposed to file:/d:/path
- File f = new File(url.getFile());
- url = f.toURL();
- }
- return url;
- }
-
- public static URL getInstallURL() {
- return installURL;
- }
-
- private void saveAsXML(OutputStream stream) throws CoreException {
- StreamResult result = null;
- try {
- DocumentBuilder docBuilder = documentBuilderFactory.newDocumentBuilder();
- Document doc = docBuilder.newDocument();
-
- if (config == null)
- throw Utils.newCoreException(Messages.getString("PlatformConfiguration.cannotSaveNonExistingConfig"),null); //$NON-NLS-1$
-
- config.setDate(new Date());
- doc.appendChild(doc.createComment("Created on " + config.getDate().toString())); //$NON-NLS-1$
- Element configElement = config.toXML(doc);
- doc.appendChild(configElement);
-
- // Write out to a file
-
- Transformer transformer=transformerFactory.newTransformer();
- transformer.setOutputProperty(OutputKeys.METHOD, "xml"); //$NON-NLS-1$
- transformer.setOutputProperty(OutputKeys.ENCODING, "UTF-8"); //$NON-NLS-1$
- transformer.setOutputProperty(OutputKeys.INDENT, "yes"); //$NON-NLS-1$
- DOMSource source = new DOMSource(doc);
- result = new StreamResult(stream);
-
- transformer.transform(source,result);
- //will close the stream in the caller
- //stream.close();
- } catch (Exception e) {
- throw Utils.newCoreException("", e); //$NON-NLS-1$
- } finally {
- result.setOutputStream(null);
- result = null;
- }
- }
-
- private void reconcile() throws CoreException {
- long lastChange = config.getDate().getTime();
- SiteEntry[] sites = config.getSites();
- for (int s=0; s<sites.length; s++) {
- long siteTimestamp = sites[s].getChangeStamp();
- if (siteTimestamp > lastChange)
- sites[s].loadFromDisk(lastChange);
- }
- config.setDirty(true);
- }
-
- public Configuration getConfiguration() {
- return config;
- }
-}
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/PlatformConfigurationFactory.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/PlatformConfigurationFactory.java
deleted file mode 100644
index 80c445753..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/PlatformConfigurationFactory.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator;
-
-import java.io.IOException;
-import java.net.URL;
-
-import org.eclipse.update.configurator.*;
-
-
-
-public class PlatformConfigurationFactory implements IPlatformConfigurationFactory {
- public IPlatformConfiguration getCurrentPlatformConfiguration() {
- return PlatformConfiguration.getCurrent();
- }
- public IPlatformConfiguration getPlatformConfiguration(URL url) throws IOException {
- try {
- return new PlatformConfiguration(url);
- } catch (Exception e) {
- if(e instanceof IOException)
- throw (IOException)e;
- else
- throw new IOException(e.getMessage());
- }
- }
-}
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/PluginEntry.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/PluginEntry.java
deleted file mode 100644
index 736a6d3cf..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/PluginEntry.java
+++ /dev/null
@@ -1,157 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator;
-
-
-/**
- */
-public class PluginEntry {
-
- private String pluginId;
- private String pluginVersion;
- private boolean isFragment = false;
- private VersionedIdentifier versionId;
- private String url;
-
- public PluginEntry() {
- super();
- }
-
- /**
- * @return url relative to the site location: plugins/org.eclipse.foo/plugin.xml
- * Note: to do: we should probably only use plugins/org.eclipse.foo/ in the future
- */
- public String getURL() {
- return url;
- }
-
- /**
- * url is relative to the site
- */
- public void setURL(String url) {
- this.url = url;
- }
-
- /**
- * Returns the plug-in identifier for this entry.
- *
- * @return the plug-in identifier, or <code>null</code>
- */
- public String getPluginIdentifier() {
- return pluginId;
- }
-
- /**
- * Returns the plug-in version for this entry.
- *
- * @return the plug-in version, or <code>null</code>
- */
- public String getPluginVersion() {
- return pluginVersion;
- }
-
- /**
- * Indicates whether the entry describes a full plug-in, or
- * a plug-in fragment.
- *
- * @return <code>true</code> if the entry is a plug-in fragment,
- * <code>false</code> if the entry is a plug-in
- */
- public boolean isFragment() {
- return isFragment;
- }
-
- /**
- * Sets the entry plug-in identifier.
- * Throws a runtime exception if this object is marked read-only.
- *
- * @param pluginId the entry identifier.
- */
- void setPluginIdentifier(String pluginId) {
- this.pluginId = pluginId;
- }
-
- /**
- * Sets the entry plug-in version.
- * Throws a runtime exception if this object is marked read-only.
- *
- * @param pluginVersion the entry version.
- */
- void setPluginVersion(String pluginVersion) {
- this.pluginVersion = pluginVersion;
- }
-
- /**
- * Indicates whether this entry represents a fragment or plug-in.
- * Throws a runtime exception if this object is marked read-only.
- *
- * @param isFragment fragment setting
- */
- public void isFragment(boolean isFragment) {
- this.isFragment = isFragment;
- }
-
- /**
- * @see Object#toString()
- */
- public String toString() {
- String msg = (getPluginIdentifier()!=null)?getPluginIdentifier().toString():""; //$NON-NLS-1$
- msg += getPluginVersion()!=null?" "+getPluginVersion().toString():""; //$NON-NLS-1$ //$NON-NLS-2$
- msg += isFragment()?" fragment":" plugin"; //$NON-NLS-1$ //$NON-NLS-2$
- return msg;
- }
-
-
- /**
- * Returns the identifier of this plugin entry
- */
- public VersionedIdentifier getVersionedIdentifier() {
- if (versionId != null)
- return versionId;
-
- String id = getPluginIdentifier();
- String ver = getPluginVersion();
- if (id != null && ver != null) {
- try {
- versionId = new VersionedIdentifier(id, ver);
- return versionId;
- } catch (Exception e) {
- Utils.log(Messages.getString("PluginEntry.versionError", id, ver)); //$NON-NLS-1$ //$NON-NLS-2$
- }
- }
-
- versionId = new VersionedIdentifier("",null); //$NON-NLS-1$
- return versionId;
- }
-
- /**
- * Sets the identifier of this plugin entry.
- *
- */
- void setVersionedIdentifier(VersionedIdentifier identifier) {
- setPluginIdentifier(identifier.getIdentifier());
- setPluginVersion(identifier.getVersion().toString());
- }
-
- /**
- * Compares two plugin entries for equality
- *
- * @param object plugin entry object to compare with
- * @return <code>true</code> if the two entries are equal,
- * <code>false</code> otherwise
- */
- public boolean equals(Object object) {
- if (!(object instanceof PluginEntry))
- return false;
- PluginEntry e = (PluginEntry) object;
- return getVersionedIdentifier().equals(e.getVersionedIdentifier());
- }
-} \ No newline at end of file
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/PluginParser.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/PluginParser.java
deleted file mode 100644
index 7363aee7a..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/PluginParser.java
+++ /dev/null
@@ -1,117 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator;
-
-
-import java.io.*;
-
-import javax.xml.parsers.*;
-
-import org.xml.sax.*;
-import org.xml.sax.helpers.*;
-
-/**
- * Parse default feature.xml
- */
-
-public class PluginParser extends DefaultHandler implements IConfigurationConstants {
- private final static SAXParserFactory parserFactory =
- SAXParserFactory.newInstance();
- private SAXParser parser;
- private PluginEntry pluginEntry;
-
- private class ParseCompleteException extends SAXException {
- public ParseCompleteException(String arg0) {
- super(arg0);
- }
- }
-
- /**
- * Constructor for DefaultFeatureParser
- */
- public PluginParser() {
- super();
- try {
- parserFactory.setNamespaceAware(true);
- this.parser = parserFactory.newSAXParser();
- } catch (ParserConfigurationException e) {
- System.out.println(e);
- } catch (SAXException e) {
- System.out.println(e);
- }
- }
-
- /**
- * @since 2.0
- */
- public synchronized PluginEntry parse(File pluginFile) throws SAXException, IOException {
- FileInputStream in = null;;
- try{
- in = new FileInputStream(pluginFile);
- return parse(in, PLUGINS + "/" + pluginFile.getParentFile().getName() + "/"); //$NON-NLS-1$ //$NON-NLS-2$
- }finally{
- if (in != null){
- try{
- in.close();
- }catch(IOException e){
- }
- }
- }
- }
- /**
- * @since 3.0
- */
- public synchronized PluginEntry parse(InputStream in, String bundleUrl) throws SAXException, IOException {
- try {
- pluginEntry = new PluginEntry();
- pluginEntry.setURL(bundleUrl);
- parser.parse(new InputSource(in), this);
- } catch (ParseCompleteException e) {
- // expected, we stopped the parsing when we have the information we need
- /// no need to pursue the parsing
- }
- return pluginEntry;
- }
-
- /**
- * @see DefaultHandler#startElement(String, String, String, Attributes)
- */
- public void startElement(String uri, String localName, String qName, Attributes attributes) throws SAXException {
-
- String tag = localName.trim();
-
- if (tag.equalsIgnoreCase(CFG_PLUGIN)) {
- pluginEntry.isFragment(false);
- processPlugin(attributes);
- return;
- }
-
- if (tag.equalsIgnoreCase(CFG_FRAGMENT)) {
- pluginEntry.isFragment(true);
- processPlugin(attributes);
- return;
- }
- }
-
- /**
- * process plugin entry info
- */
- private void processPlugin(Attributes attributes) throws ParseCompleteException {
- String id = attributes.getValue("id"); //$NON-NLS-1$
- String version = attributes.getValue("version"); //$NON-NLS-1$
- if (id == null || id.trim().length() == 0)
- id = "_no_id_"; //$NON-NLS-1$
- pluginEntry.setVersionedIdentifier(new VersionedIdentifier(id, version));
-
- // stop parsing now
- throw new ParseCompleteException(""); //$NON-NLS-1$
- }
-}
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/ProductProvider.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/ProductProvider.java
deleted file mode 100644
index 6c7f19901..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/ProductProvider.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator;
-
-import java.util.*;
-
-import org.eclipse.core.runtime.*;
-import org.eclipse.update.configurator.*;
-
-/**
- * Maps primary features to IProduct
- */
-public class ProductProvider implements IProductProvider{
- /* (non-Javadoc)
- * @see org.eclipse.core.runtime.IProductProvider#getProducts()
- */
- public IProduct[] getProducts() {
- IPlatformConfiguration configuration = ConfiguratorUtils.getCurrentPlatformConfiguration();
- if (configuration == null)
- return new IProduct[0];
- else {
- IPlatformConfiguration.IFeatureEntry[] features = configuration.getConfiguredFeatureEntries();
- ArrayList primaryFeatures = new ArrayList();
- for (int i=0; i<features.length; i++)
- if (features[i].canBePrimary())
- primaryFeatures.add(features[i]);
- // TODO handle unmanaged plugins later
- return (IProduct[])primaryFeatures.toArray(new IProduct[primaryFeatures.size()]);
- }
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.core.runtime.IProductProvider#getName()
- */
- public String getName() {
- return Messages.getString("ProductProvider"); //$NON-NLS-1$
- }
-}
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/SiteEntry.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/SiteEntry.java
deleted file mode 100644
index 7a0890511..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/SiteEntry.java
+++ /dev/null
@@ -1,744 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator;
-
-import java.io.*;
-import java.net.*;
-import java.util.*;
-import java.util.zip.*;
-
-import org.eclipse.core.runtime.*;
-import org.eclipse.update.configurator.*;
-import org.eclipse.update.configurator.IPlatformConfiguration.*;
-import org.w3c.dom.*;
-import org.xml.sax.*;
-
-
-public class SiteEntry implements IPlatformConfiguration.ISiteEntry, IConfigurationConstants{
- private URL url; // this is the external URL for the site
- private URL resolvedURL; // this is the resolved URL used internally
- private ISitePolicy policy;
- private boolean updateable = true;
- private Map featureEntries;
- private ArrayList pluginEntries;
- private long changeStamp;
- private long featuresChangeStamp;
- private long pluginsChangeStamp;
- private String linkFileName;
- private boolean enabled = true;
- private Configuration config;
-
- private static FeatureParser featureParser = new FeatureParser();
- private static PluginParser pluginParser = new PluginParser();
-
- public SiteEntry(URL url) {
- this(url,null);
- }
-
- public SiteEntry(URL url, ISitePolicy policy) {
- if (url == null)
- try {
- url = new URL("platform:/base/"); //$NON-NLS-1$ try using platform-relative URL
- } catch (MalformedURLException e) {
- url = PlatformConfiguration.getInstallURL(); // ensure we come up ... use absolute file URL
- }
-
- if (policy == null)
- policy = new SitePolicy(DEFAULT_POLICY_TYPE, DEFAULT_POLICY_LIST);
-
- if (url.getProtocol().equals("file")) { //$NON-NLS-1$
- try {
- // TODO remove this when platform fixes local file url's
- this.url = new File(url.getFile()).toURL();
- } catch (MalformedURLException e1) {
- this.url = url;
- }
- } else
- this.url = url;
-
- this.policy = policy;
- this.resolvedURL = this.url;
- if (url.getProtocol().equals("platform")) { // $NON-NLS-1$
- try {
- resolvedURL = PlatformConfiguration.resolvePlatformURL(url); // 19536
- } catch (IOException e) {
- // will use the baseline URL ...
- }
- }
- }
-
- public void setConfig(Configuration config) {
- this.config = config;
- }
-
- public Configuration getConfig() {
- return config;
- }
-
- /*
- * @see ISiteEntry#getURL()
- */
- public URL getURL() {
- return url;
- }
-
- /*
- * @see ISiteEntry#getSitePolicy()
- */
- public ISitePolicy getSitePolicy() {
- return policy;
- }
-
- /*
- * @see ISiteEntry#setSitePolicy(ISitePolicy)
- */
- public synchronized void setSitePolicy(ISitePolicy policy) {
- if (policy == null)
- throw new IllegalArgumentException();
- this.policy = policy;
- }
-
- /*
- * @see ISiteEntry#getFeatures()
- */
- public String[] getFeatures() {
- return getDetectedFeatures();
- }
-
- /*
- * @see ISiteEntry#getPlugins()
- */
- public String[] getPlugins() {
-
- ISitePolicy policy = getSitePolicy();
-
- if (policy.getType() == ISitePolicy.USER_INCLUDE)
- return policy.getList();
-
- if (policy.getType() == ISitePolicy.USER_EXCLUDE) {
- ArrayList detectedPlugins = new ArrayList(Arrays.asList(getDetectedPlugins()));
- String[] excludedPlugins = policy.getList();
- for (int i = 0; i < excludedPlugins.length; i++) {
- if (detectedPlugins.contains(excludedPlugins[i]))
- detectedPlugins.remove(excludedPlugins[i]);
- }
- return (String[]) detectedPlugins.toArray(new String[0]);
- }
-
- // bad policy type
- return new String[0];
- }
-
- public PluginEntry[] getPluginEntries() {
- String[] pluginURLs = getPlugins();
- // hash the array, for faster lookups
- HashMap map = new HashMap(pluginURLs.length);
- for (int i=0; i<pluginURLs.length; i++)
- map.put(pluginURLs[i], pluginURLs[i]);
-
- if (pluginEntries == null)
- detectPlugins();
-
- ArrayList plugins = new ArrayList(pluginURLs.length);
- for (int i=0; i<pluginEntries.size(); i++) {
- PluginEntry p = (PluginEntry)pluginEntries.get(i);
- if (map.containsKey(p.getURL()))
- plugins.add(p);
- }
- return (PluginEntry[])plugins.toArray(new PluginEntry[plugins.size()]);
- }
-
- /*
- * @see ISiteEntry#getChangeStamp()
- */
- public long getChangeStamp() {
- if (changeStamp == 0)
- computeChangeStamp();
- return changeStamp;
- }
-
- /*
- * @see ISiteEntry#getFeaturesChangeStamp()
- */
- public long getFeaturesChangeStamp() {
- if (featuresChangeStamp == 0)
- computeFeaturesChangeStamp();
- return featuresChangeStamp;
- }
-
- /*
- * @see ISiteEntry#getPluginsChangeStamp()
- */
- public long getPluginsChangeStamp() {
- if (pluginsChangeStamp == 0)
- computePluginsChangeStamp();
- return pluginsChangeStamp;
- }
-
- /*
- * @see ISiteEntry#isUpdateable()
- */
- public boolean isUpdateable() {
- return updateable;
- }
-
- public void setUpdateable(boolean updateable) {
- this.updateable = updateable;
- }
-
- /*
- * @see ISiteEntry#isNativelyLinked()
- */
- public boolean isNativelyLinked() {
- return isExternallyLinkedSite();
- }
-
- public URL getResolvedURL() {
- return resolvedURL;
- }
-
- /**
- * Detect new features (timestamp > current site timestamp)
- * and validates existing features (they might have been removed)
- */
- private void detectFeatures() {
-
- if (featureEntries != null)
- validateFeatureEntries();
- else
- featureEntries = new HashMap();
-
- if (!PlatformConfiguration.supportsDetection(resolvedURL))
- return;
-
- // locate feature entries on site
- File siteRoot = new File(resolvedURL.getFile().replace('/', File.separatorChar));
- File featuresDir = new File(siteRoot, FEATURES);
- if (featuresDir.exists()) {
- // handle the installed features under the features directory
- File[] dirs = featuresDir.listFiles(new FileFilter() {
- public boolean accept(File f) {
- boolean valid = f.isDirectory() && (new File(f,FEATURE_XML).exists());
- if (!valid)
- Utils.log(Messages.getString("SiteEntry.cannotFindFeatureInDir", f.getAbsolutePath())); //$NON-NLS-1$
- return valid;
- }
- });
-
- for (int index = 0; index < dirs.length; index++) {
- try {
- File featureXML = new File(dirs[index], FEATURE_XML);
- if (featureXML.lastModified() <= featuresChangeStamp &&
- dirs[index].lastModified() <= featuresChangeStamp)
- continue;
- URL featureURL = featureXML.toURL();
- FeatureEntry featureEntry = featureParser.parse(featureURL);
- if (featureEntry != null)
- addFeatureEntry(featureEntry);
- } catch (MalformedURLException e) {
- Utils.log(Messages.getString("InstalledSiteParser.UnableToCreateURLForFile", featuresDir.getAbsolutePath()));//$NON-NLS-1$
- }
- }
- }
-
- Utils.debug(resolvedURL.toString() + " located " + featureEntries.size() + " feature(s)"); //$NON-NLS-1$ //$NON-NLS-2$
- }
-
- /**
- * Detect new plugins (timestamp > current site timestamp)
- * and validates existing plugins (they might have been removed)
- */
- private void detectPlugins() {
- boolean compareTimeStamps = false;
- if (pluginEntries != null) {
- validatePluginEntries();
- compareTimeStamps = true; // only pick up newer plugins
- } else
- pluginEntries = new ArrayList();
-
- if (!PlatformConfiguration.supportsDetection(resolvedURL))
- return;
-
- // locate plugin entries on site
- File pluginsDir = new File(resolvedURL.getFile(), PLUGINS);
-
- if (pluginsDir.exists() && pluginsDir.isDirectory()) {
- File[] files = pluginsDir.listFiles();
- for (int i = 0; i < files.length; i++) {
- if(files[i].isDirectory()){
- detectUnpackedPlugin(files[i], compareTimeStamps);
- }else if(files[i].getName().endsWith(".jar")){ //$NON-NLS-1$
- detectPackedPlugin(files[i], compareTimeStamps);
- }else{
- // not bundle file
- }
- }
- }
-
- Utils.debug(resolvedURL.toString() + " located " + pluginEntries.size() + " plugin(s)"); //$NON-NLS-1$ //$NON-NLS-2$
- }
-
- /**
- * @param file a plugin jar
- * @param compareTimeStamps set to true when looking for plugins changed since last time they were detected
- */
- private void detectPackedPlugin(File file, boolean compareTimeStamps) {
- // plugin to run directly from jar
- if (compareTimeStamps && file.lastModified() <= pluginsChangeStamp) {
- return;
- }
- String entryName = META_MANIFEST_MF;
- ZipFile z = null;
- InputStream bundleManifestIn = null;
- InputStream pluginManifestIn = null;
- String pluginURL = PLUGINS + "/" + file.getName(); //$NON-NLS-1$
- try {
- // First, check if has valid bundle manifest
- z = new ZipFile(file);
- if (z.getEntry(entryName) != null) {
- bundleManifestIn = z.getInputStream(new ZipEntry(entryName));
- BundleManifest manifest = new BundleManifest(bundleManifestIn,
- pluginURL);
- if (manifest.exists()) {
- addPluginEntry(manifest.getPluginEntry());
- return;
- }
- }
- // no bundle manifest, check for plugin.xml or fragment.xml
- entryName = PLUGIN_XML;
- if (z.getEntry(entryName) == null) {
- entryName = FRAGMENT_XML;
- }
- if (z.getEntry(entryName) != null) {
- pluginManifestIn = z.getInputStream(new ZipEntry(entryName));
- PluginEntry entry1 = pluginParser.parse(pluginManifestIn,
- pluginURL);
- addPluginEntry(entry1);
- }
- } catch (IOException e5) {
- String pluginFileString2 = pluginURL + "!" + entryName; //$NON-NLS-1$
- Utils.log(Messages.getString("InstalledSiteParser.ErrorAccessing", //$NON-NLS-1$
- pluginFileString2)); //$NON-NLS-1$
- } catch (SAXException e3) {
- String pluginFileString1 = pluginURL + "!" + entryName; //$NON-NLS-1$
- Utils.log(Messages.getString(
- "InstalledSiteParser.ErrorParsingFile", pluginFileString1)); //$NON-NLS-1$
- } finally {
- if (bundleManifestIn != null) {
- try {
- bundleManifestIn.close();
- } catch (IOException e4) {
- }
- }
- if (pluginManifestIn != null) {
- try {
- pluginManifestIn.close();
- } catch (IOException e2) {
- }
- }
- if (z != null) {
- try {
- z.close();
- } catch (IOException e1) {
- }
- }
- }
- }
- /**
- * @param file a plugin directory
- * @param compareTimeStamps set to true when looking for plugins changed since last time they were detected
- */
- private void detectUnpackedPlugin(File file, boolean compareTimeStamps) {
- // unpacked plugin
- long dirTimestamp = file.lastModified();
- File pluginFile = new File(file, META_MANIFEST_MF);
- try {
- // First, check if has valid bundle manifest
- BundleManifest bundleManifest = new BundleManifest(pluginFile);
- if (bundleManifest.exists()) {
- if (compareTimeStamps
- && dirTimestamp <= pluginsChangeStamp
- && pluginFile.lastModified() <= pluginsChangeStamp)
- return;
- PluginEntry entry = bundleManifest.getPluginEntry();
- addPluginEntry(entry);
- } else {
- // no bundle manifest, check for plugin.xml or fragment.xml
- pluginFile = new File(file, PLUGIN_XML);
- if (!pluginFile.exists()) { //$NON-NLS-1$
- pluginFile = new File(file, FRAGMENT_XML); //$NON-NLS-1$
- }
- if (pluginFile.exists() && !pluginFile.isDirectory()) {
- // TODO in the future, assume that the timestamps are not
- // reliable,
- // or that the user manually modified an existing plugin,
- // so
- // the apparently modifed plugin may actually be configured
- // already.
- // We will need to double check for this. END to do.
- if (compareTimeStamps
- && dirTimestamp <= pluginsChangeStamp
- && pluginFile.lastModified() <= pluginsChangeStamp)
- return;
- PluginEntry entry = pluginParser.parse(pluginFile);
- addPluginEntry(entry);
- }
- }
- } catch (IOException e) {
- String pluginFileString = pluginFile.getAbsolutePath();
- if (ConfigurationActivator.DEBUG)
- Utils.log(Utils.newStatus(Messages.getString(
- "InstalledSiteParser.ErrorParsingFile", pluginFileString), e));//$NON-NLS-1$
- else
- Utils.log(Messages.getString("InstalledSiteParser.ErrorAccessing", //$NON-NLS-1$
- pluginFileString)); //$NON-NLS-1$
- } catch (SAXException e) {
- String pluginFileString = pluginFile.getAbsolutePath();
- Utils.log(Messages.getString(
- "InstalledSiteParser.ErrorParsingFile", pluginFileString)); //$NON-NLS-1$
- }
- }
-
- /**
- * @return list of feature url's (relative to site)
- */
- private synchronized String[] getDetectedFeatures() {
- if (featureEntries == null)
- detectFeatures();
- String[] features = new String[featureEntries.size()];
- Iterator iterator = featureEntries.values().iterator();
- for (int i=0; i<features.length; i++)
- features[i] = ((FeatureEntry)iterator.next()).getURL();
- return features;
- }
-
- /**
- * @return list of plugin url's (relative to site)
- */
- private synchronized String[] getDetectedPlugins() {
- if (pluginEntries == null)
- detectPlugins();
-
- String[] plugins = new String[pluginEntries.size()];
- for (int i=0; i<plugins.length; i++)
- plugins[i] = ((PluginEntry)pluginEntries.get(i)).getURL();
- return plugins;
- }
-
- private void computeChangeStamp() {
- changeStamp = Math.max(computeFeaturesChangeStamp(), computePluginsChangeStamp());
-// changeStampIsValid = true;
- }
-
- private synchronized long computeFeaturesChangeStamp() {
- if (featuresChangeStamp > 0)
- return featuresChangeStamp;
-
- long start = 0;
- if (ConfigurationActivator.DEBUG)
- start = (new Date()).getTime();
- String[] features = getFeatures();
-
- // compute stamp for the features directory
- long dirStamp = 0;
- if (PlatformConfiguration.supportsDetection(resolvedURL)) {
- File root = new File(resolvedURL.getFile().replace('/', File.separatorChar));
- File featuresDir = new File(root, FEATURES);
- dirStamp = featuresDir.lastModified();
- }
- featuresChangeStamp = Math.max(dirStamp, computeStamp(features));
- if (ConfigurationActivator.DEBUG) {
- long end = (new Date()).getTime();
- Utils.debug(resolvedURL.toString() + " feature stamp: " + featuresChangeStamp + " in " + (end - start) + "ms"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$ //$NON-NLS-6$
- }
- return featuresChangeStamp;
- }
-
- private synchronized long computePluginsChangeStamp() {
- if (pluginsChangeStamp > 0)
- return pluginsChangeStamp;
-
- if (!PlatformConfiguration.supportsDetection(resolvedURL)) {
- Utils.log(Messages.getString("SiteEntry.computePluginStamp", resolvedURL.toExternalForm())); //$NON-NLS-1$
- return 0;
- }
- long start = 0;
- if (ConfigurationActivator.DEBUG)
- start = (new Date()).getTime();
- // compute stamp for the plugins directory
- File root = new File(resolvedURL.getFile().replace('/', File.separatorChar));
- File pluginsDir = new File(root, PLUGINS);
- if (!pluginsDir.exists() || !pluginsDir.isDirectory()) {
- Utils.log(Messages.getString("SiteEntry.pluginsDir", pluginsDir.getAbsolutePath())); //$NON-NLS-1$
- return 0;
- }
-
- // Compute the plugins list
- String[] plugins = null;
- ISitePolicy policy = getSitePolicy();
- if (policy.getType() == ISitePolicy.USER_INCLUDE)
- plugins = policy.getList();
- else if (policy.getType() == ISitePolicy.USER_EXCLUDE) {
- File[] files = pluginsDir.listFiles();
- ArrayList detectedPlugins = new ArrayList(files.length);
- for (int i = 0; i < files.length; i++) {
- if(files[i].isDirectory())
- detectedPlugins.add(PLUGINS + "/" + files[i].getName() + "/"); //$NON-NLS-1$ //$NON-NLS-2$
- else if(files[i].getName().endsWith(".jar")) //$NON-NLS-1$
- detectedPlugins.add(PLUGINS + "/" + files[i].getName()); //$NON-NLS-1$
- }
-
- String[] excludedPlugins = policy.getList();
- for (int i = 0; i < excludedPlugins.length; i++) {
- if (detectedPlugins.contains(excludedPlugins[i]))
- detectedPlugins.remove(excludedPlugins[i]);
- }
- plugins = (String[])detectedPlugins.toArray(new String[0]);
- }
-
-
- long dirStamp = pluginsDir.lastModified();
- pluginsChangeStamp = Math.max(dirStamp, computeStamp(plugins));
- if (ConfigurationActivator.DEBUG) {
- long end = (new Date()).getTime();
- Utils.debug(resolvedURL.toString() + " plugin stamp: " + pluginsChangeStamp + " in " + (end - start) + "ms"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$ //$NON-NLS-6$
- }
- return pluginsChangeStamp;
- }
-
- private long computeStamp(String[] targets) {
-
- long result = 0;
- if (!PlatformConfiguration.supportsDetection(resolvedURL)) {
- // NOTE: this path should not be executed until we support running
- // from an arbitrary URL (in particular from http server). For
- // now just compute stamp across the list of names. Eventually
- // when general URLs are supported we need to do better (factor
- // in at least the existence of the target). However, given this
- // code executes early on the startup sequence we need to be
- // extremely mindful of performance issues.
- // In fact, we should get the last modified from the connection
- for (int i = 0; i < targets.length; i++)
- result ^= targets[i].hashCode();
- Utils.debug("*WARNING* computing stamp using URL hashcodes only"); //$NON-NLS-1$
- } else {
- // compute stamp across local targets
- File rootFile = new File(resolvedURL.getFile().replace('/', File.separatorChar));
- if (rootFile.exists()) {
- File f = null;
- for (int i = 0; i < targets.length; i++) {
- f = new File(rootFile, targets[i]);
- if (f.exists())
- result = Math.max(result, f.lastModified());
- }
- }
- }
-
- return result;
- }
-
- public void setLinkFileName(String linkFileName) {
- this.linkFileName = linkFileName;
- }
-
- public String getLinkFileName() {
- return linkFileName;
- }
-
- public boolean isExternallyLinkedSite() {
- return (linkFileName != null && !linkFileName.trim().equals("")); //$NON-NLS-1$
- }
-
- public synchronized void refresh() {
- // reset computed values. Will be updated on next access.
- featuresChangeStamp = 0;
- pluginsChangeStamp = 0;
- changeStamp = 0;
- featureEntries = null;
- pluginEntries = null;
- }
-
- public void refreshPlugins() {
- // reset computed values. Will be updated on next access.
- pluginsChangeStamp = 0;
- changeStamp = 0;
- pluginEntries = null;
- }
-
- public void addFeatureEntry(IFeatureEntry feature) {
- if (featureEntries == null)
- featureEntries = new HashMap();
- // Make sure we keep the larger version of same feature
- IFeatureEntry existing = (FeatureEntry)featureEntries.get(feature.getFeatureIdentifier());
- if (existing != null) {
- VersionedIdentifier existingVersion = new VersionedIdentifier(existing.getFeatureIdentifier(), existing.getFeatureVersion());
- VersionedIdentifier newVersion = new VersionedIdentifier(feature.getFeatureIdentifier(), feature.getFeatureVersion());
- if (existingVersion.compareVersion(newVersion) == VersionedIdentifier.LESS_THAN) {
- featureEntries.put(feature.getFeatureIdentifier(), feature);
- pluginsChangeStamp = 0;
- } else if (existingVersion.equals(newVersion)) {
- // log error if same feature version/id but a different url
- if (feature instanceof FeatureEntry && existing instanceof FeatureEntry &&
- !((FeatureEntry)feature).getURL().equals(((FeatureEntry)existing).getURL()))
- Utils.log(Messages.getString("SiteEntry.duplicateFeature",getURL().toExternalForm(), existing.getFeatureIdentifier())); //$NON-NLS-1$ //$NON-NLS-2$
- }
- } else {
- featureEntries.put(feature.getFeatureIdentifier(), feature);
- pluginsChangeStamp = 0;
- }
- if (feature instanceof FeatureEntry)
- ((FeatureEntry)feature).setSite(this);
- }
-
- public FeatureEntry[] getFeatureEntries() {
- if (featureEntries == null)
- detectFeatures();
-
- if (featureEntries == null)
- return new FeatureEntry[0];
- else
- return (FeatureEntry[])featureEntries.values().toArray(new FeatureEntry[featureEntries.size()]);
- }
-
- public void addPluginEntry(PluginEntry plugin) {
- if (pluginEntries == null)
- pluginEntries = new ArrayList();
- // Note: we could use the latest version of the same plugin, like we do for features, but we let the runtime figure it out
- pluginEntries.add(plugin);
- }
-
- public PluginEntry[] getAllPluginEntries() {
- if (pluginEntries == null)
- detectPlugins();
- return (PluginEntry[])pluginEntries.toArray(new PluginEntry[pluginEntries.size()]);
- }
-
- public void loadFromDisk(long lastChange) throws CoreException{
- featuresChangeStamp = lastChange;
- pluginsChangeStamp = lastChange;
- detectFeatures();
- detectPlugins();
- }
-
- /**
- * Saves state as xml content in a given parent element
- * @param doc
- */
- public Element toXML(Document doc) {
-
- Element siteElement = doc.createElement(CFG_SITE);
-
- if (getURL().toString() != null)
- siteElement.setAttribute(CFG_URL, getURL().toString());
-
- siteElement.setAttribute(CFG_ENABLED, isEnabled() ? "true" : "false"); //$NON-NLS-1$ //$NON-NLS-2$
- siteElement.setAttribute(CFG_UPDATEABLE, isUpdateable() ? "true" : "false"); //$NON-NLS-1$ //$NON-NLS-2$
- if (isExternallyLinkedSite())
- siteElement.setAttribute(CFG_LINK_FILE, getLinkFileName().trim().replace(File.separatorChar, '/'));
-
- int type = getSitePolicy().getType();
- String typeString = CFG_POLICY_TYPE_UNKNOWN;
- try {
- typeString = CFG_POLICY_TYPE[type];
- } catch (IndexOutOfBoundsException e) {
- // ignore bad attribute ...
- }
- siteElement.setAttribute(CFG_POLICY, typeString);
- String[] list = getSitePolicy().getList();
- if (list.length > 0) {
- StringBuffer sb = new StringBuffer(256);
- for (int i=0; i<list.length-1; i++) {
- sb.append(list[i]);
- sb.append(',');
- }
- sb.append(list[list.length-1]);
- siteElement.setAttribute(CFG_LIST, sb.toString());
- }
-// // note: we don't save features inside the site element.
-
- // collect feature entries
-// configElement.setAttribute(CFG_FEATURE_ENTRY_DEFAULT, defaultFeature);
- FeatureEntry[] feats = getFeatureEntries();
- for (int i = 0; i < feats.length; i++) {
- Element featureElement = feats[i].toXML(doc);
- siteElement.appendChild(featureElement);
- }
-
- return siteElement;
- }
-
- private void validateFeatureEntries() {
- File root = new File(resolvedURL.getFile().replace('/', File.separatorChar));
- Iterator iterator = featureEntries.values().iterator();
- Collection deletedFeatures = new ArrayList();
- while(iterator.hasNext()) {
- FeatureEntry feature = (FeatureEntry)iterator.next();
- // Note: in the future, we can check for absolute url as well.
- // For now, feature url is features/org.eclipse.foo/feature.xml
- File featureXML = new File(root, feature.getURL());
- if (!featureXML.exists())
- deletedFeatures.add(feature.getFeatureIdentifier());
- }
- for(Iterator it=deletedFeatures.iterator(); it.hasNext();){
- featureEntries.remove(it.next());
- }
- }
-
- private void validatePluginEntries() {
- File root = new File(resolvedURL.getFile().replace('/', File.separatorChar));
- Collection deletedPlugins = new ArrayList();
- for (int i=0; i<pluginEntries.size(); i++) {
- PluginEntry plugin = (PluginEntry)pluginEntries.get(i);
- // Note: in the future, we can check for absolute url as well.
- // For now, feature url is plugins/org.eclipse.foo/plugin.xml
- File pluginLocation = new File(root, plugin.getURL());
- if (!pluginLocation.exists())
- deletedPlugins.add(plugin);
- }
- for(Iterator it=deletedPlugins.iterator(); it.hasNext();){
- pluginEntries.remove(it.next());
- }
- }
-
- public boolean isEnabled() {
- return enabled;
- }
-
- public void setEnabled(boolean enable) {
- this.enabled = enable;
- }
-
- public FeatureEntry getFeatureEntry(String id) {
- FeatureEntry[] features = getFeatureEntries();
- for (int i=0; i<features.length; i++)
- if (features[i].getFeatureIdentifier().equals(id))
- return features[i];
- return null;
- }
-
-
- public boolean unconfigureFeatureEntry(IFeatureEntry feature) {
- FeatureEntry existingFeature = getFeatureEntry(feature.getFeatureIdentifier());
- if (existingFeature != null)
- featureEntries.remove(existingFeature.getFeatureIdentifier());
- return existingFeature != null;
- }
-
- /*
- * This is a bit of a hack.
- * When no features were added to the site, but the site is initialized from platform.xml
- * we need to set the feature set to empty, so we don't try to detect them.
- */
- void initialized() {
- if (featureEntries == null)
- featureEntries = new HashMap();
- }
-} \ No newline at end of file
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/SitePolicy.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/SitePolicy.java
deleted file mode 100644
index b192fc4db..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/SitePolicy.java
+++ /dev/null
@@ -1,59 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator;
-
-import org.eclipse.update.configurator.*;
-import org.eclipse.update.configurator.IPlatformConfiguration.*;
-
-
-public class SitePolicy implements IPlatformConfiguration.ISitePolicy {
-
- private int type;
- private String[] list;
-
- public SitePolicy() {
- }
- public SitePolicy(int type, String[] list) {
- if (type != ISitePolicy.USER_INCLUDE && type != ISitePolicy.USER_EXCLUDE)
- throw new IllegalArgumentException();
- this.type = type;
-
- if (list == null)
- this.list = new String[0];
- else
- this.list = list;
- }
-
- /*
- * @see ISitePolicy#getType()
- */
- public int getType() {
- return type;
- }
-
- /*
- * @see ISitePolicy#getList()
- */
- public String[] getList() {
- return list;
- }
-
- /*
- * @see ISitePolicy#setList(String[])
- */
- public synchronized void setList(String[] list) {
- if (list == null)
- this.list = new String[0];
- else
- this.list = list;
- }
-
-} \ No newline at end of file
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/Utils.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/Utils.java
deleted file mode 100644
index abe514210..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/Utils.java
+++ /dev/null
@@ -1,259 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator;
-
-import java.io.*;
-import java.net.URL;
-import java.util.*;
-
-import org.eclipse.core.runtime.*;
-import org.eclipse.osgi.framework.log.*;
-
-public class Utils {
- private static final String KEY_PREFIX = "%"; //$NON-NLS-1$
- private static final String KEY_DOUBLE_PREFIX = "%%"; //$NON-NLS-1$
- static FrameworkLog log;
-
- public static void debug(String s) {
- if (ConfigurationActivator.DEBUG)
- System.out.println("PlatformConfig: " + s); //$NON-NLS-1$
- }
-
- /**
- * Creates a CoreException from some other exception.
- * The type of the CoreException is <code>IStatus.ERROR</code>
- * If the exception passed as a parameter is also a CoreException,
- * the new CoreException will contain all the status of the passed
- * CoreException.
- *
- * @see IStatus#ERROR
- * @param s exception string
- * @param e actual exception being reported
- * @return a CoreException
- * @since 2.0
- */
- public static CoreException newCoreException(String s, Throwable e) {
-
- // check the case of a multistatus
- IStatus status;
- if (e instanceof CoreException) {
- if (s == null)
- s = ""; //$NON-NLS-1$
- status = new MultiStatus("org.eclipse.update.configurator", 0, s, e); //$NON-NLS-1$
- IStatus childrenStatus = ((CoreException) e).getStatus();
- ((MultiStatus) status).add(childrenStatus);
- ((MultiStatus) status).addAll(childrenStatus);
- } else {
- StringBuffer completeString = new StringBuffer(""); //$NON-NLS-1$
- if (s != null)
- completeString.append(s);
- if (e != null) {
- completeString.append(" ["); //$NON-NLS-1$
- String msg = e.getLocalizedMessage();
- completeString.append(msg!=null?msg:e.toString());
- completeString.append("]"); //$NON-NLS-1$
- }
- status = newStatus(completeString.toString(), e);
- }
- return new CoreException(status); //$NON-NLS-1$
- }
-
- public static IStatus newStatus(String message, Throwable e) {
- return new Status(IStatus.ERROR, "org.eclipse.update.configurator", IStatus.OK, message, e); //$NON-NLS-1$
- }
-
- public static void log(String message) {
- log(newStatus(message, null));
- }
-
- public static void log(IStatus status) {
- if (log != null) {
- log.log(new FrameworkLogEntry(ConfigurationActivator.PI_CONFIGURATOR, status.getMessage(), 0, status.getException(), null));
- } else {
- System.out.println(status.getMessage());
- if (status.getException() != null)
- status.getException().printStackTrace();
- }
- }
-
- /**
- * Returns the url as a platform:/ url, if possible, else leaves it unchanged
- * @param url
- * @return
- */
- public static URL asPlatformURL(URL url) {
- try {
- URL platformURL = new URL("platform:/base/"); //$NON-NLS-1$ // try using platform-relative URL
- URL resolvedPlatformURL = Platform.asLocalURL(platformURL);
- // TODO workaround bug in platform url resolution
- if (resolvedPlatformURL.getProtocol().equals("file")) //$NON-NLS-1$
- resolvedPlatformURL = new File(resolvedPlatformURL.getFile()).toURL();
- String platformURLAsString = resolvedPlatformURL.toExternalForm();
- String urlAsString = url.toExternalForm();
- if (urlAsString.startsWith(platformURLAsString))
- return new URL(platformURL.toExternalForm() + urlAsString.substring(platformURLAsString.length()) );
- else
- return url;
- } catch (Exception e) {
- return url;
- }
- }
-
-
- /**
- *
- */
- public static boolean isValidEnvironment(String os, String ws, String arch, String nl) {
- if (os!=null && !isMatching(os, Platform.getOS())) return false;
- if (ws!=null && !isMatching(ws, Platform.getWS())) return false;
- if (arch!=null && !isMatching(arch, Platform.getOSArch())) return false;
- if (nl!=null && !isMatchingLocale(nl, Platform.getNL())) return false;
- return true;
- }
-
- /**
- *
- */
- private static boolean isMatching(String candidateValues, String siteValues) {
- if (siteValues==null) return false;
- if ("*".equalsIgnoreCase(candidateValues)) return true; //$NON-NLS-1$
- siteValues = siteValues.toUpperCase();
- StringTokenizer stok = new StringTokenizer(candidateValues, ","); //$NON-NLS-1$
- while (stok.hasMoreTokens()) {
- String token = stok.nextToken().toUpperCase();
- if (siteValues.indexOf(token)!=-1) return true;
- }
- return false;
- }
-
- /**
- *
- */
- private static boolean isMatchingLocale(String candidateValues, String locale) {
- if (locale==null) return false;
- if ("*".equalsIgnoreCase(candidateValues)) return true; //$NON-NLS-1$
-
- locale = locale.toUpperCase();
- candidateValues = candidateValues.toUpperCase();
- StringTokenizer stok = new StringTokenizer(candidateValues, ","); //$NON-NLS-1$
- while (stok.hasMoreTokens()) {
- String candidate = stok.nextToken();
- if (locale.indexOf(candidate) == 0)
- return true;
- if (candidate.indexOf(locale) == 0)
- return true;
- }
- return false;
- }
-
- public static Locale getDefaultLocale() {
- String nl = Platform.getNL();
- // sanity test
- if (nl == null)
- return Locale.getDefault();
-
- // break the string into tokens to get the Locale object
- StringTokenizer locales = new StringTokenizer(nl,"_"); //$NON-NLS-1$
- if (locales.countTokens() == 1)
- return new Locale(locales.nextToken(), ""); //$NON-NLS-1$
- else if (locales.countTokens() == 2)
- return new Locale(locales.nextToken(), locales.nextToken());
- else if (locales.countTokens() == 3)
- return new Locale(locales.nextToken(), locales.nextToken(), locales.nextToken());
- else
- return Locale.getDefault();
- }
-
-
- /**
- * Returns a resource string corresponding to the given argument
- * value and bundle.
- * If the argument value specifies a resource key, the string
- * is looked up in the given resource bundle. If the argument does not
- * specify a valid key, the argument itself is returned as the
- * resource string. The key lookup is performed against the
- * specified resource bundle. If a resource string
- * corresponding to the key is not found in the resource bundle
- * the key value, or any default text following the key in the
- * argument value is returned as the resource string.
- * A key is identified as a string begining with the "%" character.
- * Note that the "%" character is stripped off prior to lookup
- * in the resource bundle.
- * <p>
- * For example, assume resource bundle plugin.properties contains
- * name = Project Name
- * <pre>
- * resolveNLString(b,"Hello World") returns "Hello World"</li>
- * resolveNLString(b,"%name") returns "Project Name"</li>
- * resolveNLString(b,"%name Hello World") returns "Project Name"</li>
- * resolveNLString(b,"%abcd Hello World") returns "Hello World"</li>
- * resolveNLString(b,"%abcd") returns "%abcd"</li>
- * resolveNLString(b,"%%name") returns "%name"</li>
- * </pre>
- * </p>
- *
- * @param resourceBundle resource bundle.
- * @param string translatable string from model
- * @return string, or <code>null</code>
- * @since 2.0
- */
- public static String getResourceString(ResourceBundle resourceBundle, String string) {
-
- if (string == null)
- return null;
-
- String s = string.trim();
-
- if (s.equals("")) //$NON-NLS-1$
- return string;
-
- if (!s.startsWith(KEY_PREFIX))
- return string;
-
- if (s.startsWith(KEY_DOUBLE_PREFIX))
- return s.substring(1);
-
- int ix = s.indexOf(" "); //$NON-NLS-1$
- String key = ix == -1 ? s : s.substring(0, ix);
- String dflt = ix == -1 ? s : s.substring(ix + 1);
-
- if (resourceBundle == null)
- return dflt;
-
- try {
- return resourceBundle.getString(key.substring(1));
- } catch (MissingResourceException e) {
- return dflt;
- }
- }
-
- public static boolean isAutomaticallyStartedBundle(String bundleURL) {
- if (bundleURL.indexOf("org.eclipse.osgi") != -1) //$NON-NLS-1$
- return true;
-
- String osgiBundles = System.getProperty("osgi.bundles"); //$NON-NLS-1$
- StringTokenizer st = new StringTokenizer(osgiBundles, ","); //$NON-NLS-1$
- while (st.hasMoreTokens()) {
- String token = st.nextToken().trim();
- int index = token.indexOf('@');
- if (index != -1)
- token = token.substring(0,index);
- if (token.startsWith("reference:file:")) { //$NON-NLS-1$
- File f = new File(token.substring(15));
- if (bundleURL.indexOf(f.getName()) != -1)
- return true;
- }
- if (bundleURL.indexOf(token) != -1)
- return true;
- }
- return false;
- }
-}
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/VersionedIdentifier.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/VersionedIdentifier.java
deleted file mode 100644
index 694ce2671..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/VersionedIdentifier.java
+++ /dev/null
@@ -1,153 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator;
-
-import java.util.*;
-
-
-public class VersionedIdentifier {
- private String identifier = ""; //$NON-NLS-1$
- private int major = 0;
- private int minor = 0;
- private int service = 0;
- private String qualifier = ""; //$NON-NLS-1$
- private String version;
-
- private static final String VER_SEPARATOR = "."; //$NON-NLS-1$
- private static final String ID_SEPARATOR = "_"; //$NON-NLS-1$
-
- public static final int LESS_THAN = -1;
- public static final int EQUAL = 0;
- public static final int EQUIVALENT = 1;
- public static final int COMPATIBLE = 2;
- public static final int GREATER_THAN = 3;
-
- public VersionedIdentifier(String s) {
- if (s == null || (s = s.trim()).equals("")) //$NON-NLS-1$
- return;
-
- int loc = s.lastIndexOf(ID_SEPARATOR);
- if (loc != -1) {
- this.identifier = s.substring(0, loc);
- version = s.substring(loc + 1);
- parseVersion(version);
- } else
- this.identifier = s;
- }
-
- public VersionedIdentifier(String id, String version) {
- this(id+ID_SEPARATOR+version);
- this.version = version;
- }
-
- public String getVersion() {
- return version;
- }
-
- public String getIdentifier() {
- return identifier;
- }
-
- public boolean equalIdentifiers(VersionedIdentifier id) {
- if (id == null)
- return identifier == null;
- else
- return id.identifier.equals(identifier);
- }
-
- public int compareVersion(VersionedIdentifier id) {
-
- if (id == null) {
- if (major == 0 && minor == 0 && service == 0)
- return -1;
- else
- return 1;
- }
-
- if (major > id.major)
- return GREATER_THAN;
- if (major < id.major)
- return LESS_THAN;
- if (minor > id.minor)
- return COMPATIBLE;
- if (minor < id.minor)
- return LESS_THAN;
- if (service > id.service)
- return EQUIVALENT;
- if (service < id.service)
- return LESS_THAN;
- return compareQualifiers(qualifier, id.qualifier);
- }
-
- private int compareQualifiers(String q1, String q2) {
- int result = q1.compareTo(q2);
- if (result < 0)
- return LESS_THAN;
- else if (result > 0)
- return EQUIVALENT;
- else
- return EQUAL;
- }
-
- private void parseVersion(String v) {
- if (v == null || (v = v.trim()).equals("")) //$NON-NLS-1$
- return;
-
- try {
- StringTokenizer st = new StringTokenizer(v, VER_SEPARATOR);
- ArrayList elements = new ArrayList(4);
-
- while (st.hasMoreTokens()) {
- elements.add(st.nextToken());
- }
-
- if (elements.size() >= 1)
- this.major = (new Integer((String) elements.get(0))).intValue();
- if (elements.size() >= 2)
- this.minor = (new Integer((String) elements.get(1))).intValue();
- if (elements.size() >= 3)
- this.service = (new Integer((String) elements.get(2))).intValue();
- if (elements.size() >= 4)
- this.qualifier = removeWhiteSpace((String) elements.get(3));
-
- } catch (Exception e) {
- // use what we got so far ...
- }
- }
-
- private String removeWhiteSpace(String s) {
- char[] chars = s.trim().toCharArray();
- boolean whitespace = false;
- for (int i = 0; i < chars.length; i++) {
- if (Character.isWhitespace(chars[i])) {
- chars[i] = '_';
- whitespace = true;
- }
- }
- return whitespace ? new String(chars) : s;
- }
- /* (non-Javadoc)
- * @see java.lang.Object#equals(java.lang.Object)
- */
- public boolean equals(Object obj) {
- if (this == obj)
- return true;
- if (!(obj instanceof VersionedIdentifier))
- return false;
-
- VersionedIdentifier other = (VersionedIdentifier)obj;
- return equalIdentifiers(other) &&
- this.major == other.major &&
- this.minor == other.minor &&
- this.service == other.service &&
- compareQualifiers(this.qualifier, other.qualifier) == EQUAL;
- }
-} \ No newline at end of file
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/branding/AboutInfo.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/branding/AboutInfo.java
deleted file mode 100644
index a3a7a31bc..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/branding/AboutInfo.java
+++ /dev/null
@@ -1,253 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator.branding;
-
-import java.net.*;
-import java.util.*;
-
-import org.eclipse.core.runtime.*;
-
-
-/**
- * The information within this object is obtained from the about INI file.
- * This file resides within an install configurations directory and must be a
- * standard java property file.
- * <p>
- * This class is not intended to be instantiated or subclassed by clients.
- * </p>
- */
-public final class AboutInfo {
- private final static String INI_FILENAME = "about.ini"; //$NON-NLS-1$
- private final static String PROPERTIES_FILENAME = "about.properties"; //$NON-NLS-1$
- private final static String MAPPINGS_FILENAME = "about.mappings"; //$NON-NLS-1$
-
- private String featureId;
- private String versionId = ""; //$NON-NLS-1$
- private String featurePluginLabel;
- private String providerName;
- private String appName;
- private URL windowImageURL;
- private URL[] windowImagesURLs;
- private URL aboutImageURL;
- private URL featureImageURL;
- private URL welcomePageURL;
- private String aboutText;
- private String welcomePerspective;
- private String tipsAndTricksHref;
-
-
- /*
- * Create a new about info for a feature with the given id.
- */
- /* package */ AboutInfo(String featureId) {
- super();
- this.featureId = featureId;
- }
-
- /**
- * Returns the configuration information for the feature with the
- * given id.
- *
- * @param featureId the feature id
- * @param versionId the version id (of the feature)
- * @param pluginId the plug-in id
- * @return the configuration information for the feature
- */
- public static AboutInfo readFeatureInfo(String featureId, String versionId, String pluginId) {
-// Assert.isNotNull(featureId);
-// Assert.isNotNull(versionId);
-// Assert.isNotNull(pluginId);
- IniFileReader reader = new IniFileReader(featureId, pluginId, INI_FILENAME, PROPERTIES_FILENAME, MAPPINGS_FILENAME);
- IStatus status = reader.load();
- if (!status.isOK()) {
- //return null;
- return new AboutInfo(featureId); // dummy about info
- }
-
- AboutInfo info = new AboutInfo(featureId);
- Hashtable runtimeMappings = new Hashtable();
- runtimeMappings.put("{featureVersion}", versionId); //$NON-NLS-1$
- info.versionId = versionId;
- info.featurePluginLabel = reader.getFeaturePluginLabel();
- info.providerName = reader.getProviderName();
- info.appName = reader.getString("appName", true, runtimeMappings); //$NON-NLS-1$
- info.aboutText = reader.getString("aboutText", true, runtimeMappings); //$NON-NLS-1$
- info.windowImageURL = reader.getURL("windowImage"); //$NON-NLS-1$
- // look for the newer array, but if its not there then use the older,
- // single image definition
- info.windowImagesURLs = reader.getURLs("windowImages"); //$NON-NLS-1$
- info.aboutImageURL = reader.getURL("aboutImage"); //$NON-NLS-1$
- info.featureImageURL = reader.getURL("featureImage"); //$NON-NLS-1$
- info.welcomePageURL = reader.getURL("welcomePage"); //$NON-NLS-1$
- info.welcomePerspective = reader.getString("welcomePerspective", false, runtimeMappings); //$NON-NLS-1$
- info.tipsAndTricksHref = reader.getString("tipsAndTricksHref", false, runtimeMappings); //$NON-NLS-1$
- return info;
- }
-
- /**
- * Returns the URL for an image which can be shown in an "about" dialog
- * for this product. Products designed to run "headless" typically would not
- * have such an image.
- *
- * @return the URL for an about image, or <code>null</code> if none
- */
- public URL getAboutImageURL() {
- return aboutImageURL;
- }
-
- /**
- * Returns the URL for an image which can be shown in an "about features"
- * dialog. Products designed to run "headless" typically would not have such an image.
- *
- * @return the URL for a feature image, or <code>null</code> if none
- */
- public URL getFeatureImageURL() {
- return featureImageURL;
- }
-
- /**
- * Returns the simple name of the feature image file.
- *
- * @return the simple name of the feature image file,
- * or <code>null</code> if none
- */
- public String getFeatureImageName() {
- if (featureImageURL != null) {
- IPath path = new Path(featureImageURL.getPath());
- return path.lastSegment();
- } else {
- return null;
- }
- }
-
-
- /**
- * Returns a label for the feature plugn, or <code>null</code>.
- */
- public String getFeatureLabel() {
- return featurePluginLabel;
- }
-
- /**
- * Returns the id for this feature.
- *
- * @return the feature id
- */
- public String getFeatureId() {
- return featureId;
- }
-
- /**
- * Returns the text to show in an "about" dialog for this product.
- * Products designed to run "headless" typically would not have such text.
- *
- * @return the about text, or <code>null</code> if none
- */
- public String getAboutText() {
- return aboutText;
- }
-
- /**
- * Returns the application name or <code>null</code>.
- * Note this is never shown to the user.
- * It is used to initialize the SWT Display.
- * <p>
- * On Motif, for example, this can be used
- * to set the name used for resource lookup.
- * </p>
- *
- * @return the application name, or <code>null</code>
- */
- public String getAppName() {
- return appName;
- }
-
- /**
- * Returns the product name or <code>null</code>.
- * This is shown in the window title and the About action.
- *
- * @return the product name, or <code>null</code>
- */
- public String getProductName() {
- return featurePluginLabel;
- }
-
- /**
- * Returns the provider name or <code>null</code>.
- *
- * @return the provider name, or <code>null</code>
- */
- public String getProviderName() {
- return providerName;
- }
-
- /**
- * Returns the feature version id.
- *
- * @return the version id of the feature
- */
- public String getVersionId() {
- return versionId;
- }
-
- /**
- * Returns a <code>URL</code> for the welcome page.
- * Products designed to run "headless" typically would not have such an page.
- *
- * @return the welcome page, or <code>null</code> if none
- */
- public URL getWelcomePageURL() {
- return welcomePageURL;
- }
-
- /**
- * Returns the ID of a perspective in which to show the welcome page.
- * May be <code>null</code>.
- *
- * @return the welcome page perspective id, or <code>null</code> if none
- */
- public String getWelcomePerspectiveId() {
- return welcomePerspective;
- }
-
- /**
- * Returns a <code>String</code> for the tips and trick href.
- *
- * @return the tips and tricks href, or <code>null</code> if none
- */
- public String getTipsAndTricksHref() {
- return tipsAndTricksHref;
- }
-
- /**
- * Returns the image url for the window image to use for this product.
- * Products designed to run "headless" typically would not have such an image.
- *
- * @return the image url for the window image, or <code>null</code> if none
- */
- public URL getWindowImageURL() {
- return windowImageURL;
- }
-
- /**
- * Return an array of image URLs for the window images to use for
- * this product. The expectations is that the elements will be the same
- * image rendered at different sizes. Products designed to run "headless"
- * typically would not have such images.
- *
- * @return an array of the image descriptors for the window images, or
- * <code>null</code> if none
- * @since 3.0
- */
- public URL[] getWindowImagesURLs() {
- return windowImagesURLs;
- }
-}
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/branding/IBundleGroupConstants.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/branding/IBundleGroupConstants.java
deleted file mode 100644
index 45179c070..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/branding/IBundleGroupConstants.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator.branding;
-
-/**
- * These constants define the set of properties that the UI expects to
- * be available via <code>IBundleGroup.getProperty(String)</code>.
- *
- * @since 3.0
- * @see org.eclipse.core.runtime.IBundleGroup#getProperty(String)
- */
-public interface IBundleGroupConstants {
- /**
- * An image which can be shown in an "about features" dialog (32x32).
- */
- public static final String FEATURE_IMAGE = "featureImage"; //$NON-NLS-1$
-
- /**
- * A help reference for the feature's tips and tricks page (optional).
- */
- public static final String TIPS_AND_TRICKS_HREF = "tipsAndTricksHref"; //$NON-NLS-1$
-
- /**
- * A URL for the feature's welcome page (special XML-based format)
- * ($nl$/ prefix to permit locale-specific translations of entire file).
- * Products designed to run "headless" typically would not have such a page.
- */
- public static final String WELCOME_PAGE = "welcomePage"; //$NON-NLS-1$
-
- /**
- * The id of a perspective in which to show the welcome page
- * (optional).
- */
- public static final String WELCOME_PERSPECTIVE = "welcomePerspective"; //$NON-NLS-1$
-
- /**
- * The URL of the license page for the feature
- * (optional).
- */
- public static final String LICENSE_HREF = "licenseHref"; //$NON-NLS-1$
-} \ No newline at end of file
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/branding/IProductConstants.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/branding/IProductConstants.java
deleted file mode 100644
index 179ef52d7..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/branding/IProductConstants.java
+++ /dev/null
@@ -1,77 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator.branding;
-
-/**
- * These constants define the set of properties that the UI expects to
- * be available via <code>IProduct.getProperty(String)</code>.
- *
- * @since 3.0
- * @see org.eclipse.core.runtime.IProduct#getProperty(String)
- */
-public interface IProductConstants {
- /**
- * The application name, used to initialize the SWT Display. This
- * value is distinct from the string displayed in the application
- * title bar.
- * <p>
- * E.g., On motif, this can be used to set the name used for
- * resource lookup.
- * </p>
- */
- public static final String APP_NAME = "appName"; //$NON-NLS-1$
-
- /**
- * The text to show in an "about" dialog for this product.
- * Products designed to run "headless" typically would not
- * have such text.
- */
- public static final String ABOUT_TEXT = "aboutText"; //$NON-NLS-1$
-
- /**
- * An image which can be shown in an "about" dialog for this
- * product. Products designed to run "headless" typically would not
- * have such an image.
- * <p>
- * A full-sized product image (no larger than 500x330 pixels) is
- * shown without the "aboutText" blurb. A half-sized product image
- * (no larger than 250x330 pixels) is shown with the "aboutText"
- * blurb beside it.
- */
- public static final String ABOUT_IMAGE = "aboutImage"; //$NON-NLS-1$
-
- /**
- * An image to be used as the window icon for this product (16x16).
- * Products designed to run "headless" typically would not have such an image.
- * <p>
- * If the <code>WINDOW_IMAGES</code> property is given, then it supercedes
- * this one.
- * </p>
- */
- public static final String WINDOW_IMAGE = "windowImage"; //$NON-NLS-1$
-
- /**
- * An array of one or more images to be used for this product. The
- * expectation is that the array will contain the same image rendered
- * at different sizes (16x16 and 32x32).
- * Products designed to run "headless" typically would not have such images.
- * <p>
- * If this property is given, then it supercedes <code>WINDOW_IMAGE</code>.
- * </p>
- */
- public static final String WINDOW_IMAGES = "windowImages"; //$NON-NLS-1$
- /**
- * A URL for the products's welcome page (special XML-based format)
- * ($nl$/ prefix to permit locale-specific translations of entire file).
- * Products designed to run "headless" typically would not have such a page.
- */
- public static final String WELCOME_PAGE = "welcomePage"; //$NON-NLS-1$
-} \ No newline at end of file
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/branding/IniFileReader.java b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/branding/IniFileReader.java
deleted file mode 100644
index 7f2f1e0fb..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/branding/IniFileReader.java
+++ /dev/null
@@ -1,378 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.internal.configurator.branding;
-
-import java.io.*;
-import java.net.*;
-import java.text.*;
-import java.util.*;
-
-import org.eclipse.core.runtime.*;
-import org.eclipse.update.internal.configurator.*;
-import org.osgi.framework.*;
-
-/**
- * Reads the information found in an "INI" file. This file must be in a
- * standard Java properties format. A properties file may also be provided
- * to NL values in the INI file - values must start with the % prefix. A
- * mapping file may also be provided that contains "fill-ins" for the
- * properties file - format being "n = some text", where n is a number.
- */
-public class IniFileReader {
- private static final String PID = "org.eclipse.update.configurator"; //$NON-NLS-1$
- private static final Status OK_STATUS = new Status(IStatus.OK, PID, 0, "", null); //$NON-NLS-1$
- private static final String KEY_PREFIX = "%"; //$NON-NLS-1$
- private static final String KEY_DOUBLE_PREFIX = "%%"; //$NON-NLS-1$
- private static final String NLS_TAG = "$nl$"; //$NON-NLS-1$
-
- private String featureId;
- private String pluginId;
- private String iniFilename;
- private String propertiesFilename;
- private String mappingsFilename;
- private Properties ini = null;
- private PropertyResourceBundle properties = null;
- private String[] mappings = null;
- private Bundle bundle;
-
- /**
- * Creates an INI file reader that can parse the contents into key,value pairs.
- *
- * @param featureId the unique identifier of the feature, must not be <code>null</code>
- * @param pluginId the unique identifier of the feature plug-in, must not be <code>null</code>
- * @param iniFilename the INI file name, must not be <code>null</code>
- * @param propertiesFilename the properties filename, can be <code>null</code> if not required
- * @param mappingsFilename the mappings filename, can be <code>null</code> if not required
- */
- public IniFileReader(String featureId, String pluginId, String iniFilename, String propertiesFilename, String mappingsFilename) {
- super();
-
- if (featureId == null || pluginId == null || iniFilename == null) {
- throw new IllegalArgumentException();
- }
-
- this.featureId = featureId;
- this.pluginId = pluginId;
- this.iniFilename = iniFilename;
- this.propertiesFilename = propertiesFilename;
- this.mappingsFilename = mappingsFilename;
- }
-
- /**
- * Read the contents of the INI, properties, and mappings files.
- * Does nothing if the content has already been read and parsed.
- *
- * @return an <code>IStatus</code> indicating the success or failure
- * of reading and parsing the INI file content
- */
- public IStatus load() {
- if (ini != null)
- return OK_STATUS;
-
- // attempt to locate the corresponding plugin
- bundle = Platform.getBundle(pluginId);
- if (bundle == null || bundle.getState() == Bundle.UNINSTALLED || bundle.getState() == Bundle.INSTALLED) {
- bundle = null; // make it null for other test down the road
- String message = Messages.getString("IniFileReader.MissingDesc", featureId); //$NON-NLS-1$
- return new Status(IStatus.ERROR, PID, 0, message, null);
- }
-
- // Determine the ini file location
- URL iniURL = null;
- IOException ioe = null;
- try {
- iniURL = Platform.find(bundle, new Path(NLS_TAG).append(iniFilename));
- if (iniURL != null)
- iniURL = Platform.resolve(iniURL);
- } catch (IOException e) {
- ioe = e;
- }
- if (iniURL == null) {
- String message = Messages.getString("IniFileReader.OpenINIError", iniFilename); //$NON-NLS-1$
- return new Status(IStatus.ERROR, PID, 0, message, ioe);
- }
-
- // Determine the properties file location
- URL propertiesURL = null;
- if (propertiesFilename != null & propertiesFilename.length() > 0) {
- try {
- propertiesURL = Platform.find(bundle, new Path(NLS_TAG).append(propertiesFilename));
- if (propertiesURL != null)
- propertiesURL = Platform.resolve(propertiesURL);
- } catch (IOException e) {
- String message = Messages.getString("IniFileReader.OpenPropError", propertiesFilename); //$NON-NLS-1$
- return new Status(IStatus.ERROR, PID, 0, message, e);
- }
- }
-
- // Determine the mappings file location
- URL mappingsURL = null;
- if (mappingsFilename != null && mappingsFilename.length() > 0) {
- try {
- mappingsURL = Platform.find(bundle, new Path(NLS_TAG).append(mappingsFilename));
- if (mappingsURL != null)
- mappingsURL = Platform.resolve(mappingsURL);
- } catch (IOException e) {
- String message = Messages.getString("IniFileReader.OpenMapError", mappingsFilename); //$NON-NLS-1$
- return new Status(IStatus.ERROR, PID, 0, message, e);
- }
- }
-
- // OK to pass null properties and/or mapping file
- return load(iniURL, propertiesURL, mappingsURL);
- }
-
- /**
- * Returns the string value for the given key, or <code>null</code>.
- * The string value is NLS if requested.
- *
- * @return the string value for the given key, or <code>null</code>
- */
- public String getString(String key, boolean doNls, Hashtable runtimeMappings) {
- if (ini == null)
- return null;
- String value = ini.getProperty(key);
- if (value != null && doNls)
- return getResourceString(value, runtimeMappings);
- return value;
- }
-
-
- /**
- * Returns a URL for the given key, or <code>null</code>.
- *
- * @return a URL for the given key, or <code>null</code>
- */
- public URL getURL(String key) {
- if (ini == null)
- return null;
-
- URL url = null;
- String fileName = ini.getProperty(key);
- if (fileName != null) {
- if (bundle == null)
- return null;
- url = Platform.find(bundle, new Path(fileName));
- }
- return url;
- }
-
- /**
- * Returns a array of URL for the given key, or <code>null</code>. The
- * property value should be a comma separated list of urls, tokens for
- * which bundle cannot build an url will have a null entry.
- *
- * @param key name of the property containing the requested urls
- * @return a URL for the given key, or <code>null</code>
- * @since 3.0
- */
- public URL[] getURLs(String key) {
- if (ini == null || bundle == null)
- return null;
-
- String value = ini.getProperty(key);
- if (value == null)
- return null;
-
- StringTokenizer tokens = new StringTokenizer(value, ","); //$NON-NLS-1$
- ArrayList array = new ArrayList(10);
- while (tokens.hasMoreTokens()) {
- String str = tokens.nextToken().trim();
- array.add(Platform.find(bundle, new Path(str)));
- }
-
- URL[] urls = new URL[array.size()];
- array.toArray(urls);
- return urls;
- }
-
- /**
- * Returns the feature plugin label, or <code>null</code>.
- *
- * @return the feature plugin lable, or <code>null</code> if none.
- */
- public String getFeaturePluginLabel() {
- if (bundle == null)
- return null;
- else {
- return (String)bundle.getHeaders().get(Constants.BUNDLE_NAME);
- }
- }
-
- /**
- * Returns the provider name for this feature, or <code>null</code>.
- *
- * @return the provider name for this feature, or <code>null</code>
- */
- public String getProviderName() {
- if (bundle == null)
- return null;
- else {
- return (String)bundle.getHeaders().get(Constants.BUNDLE_VENDOR);
- }
- }
-
- /*
- * Returns a resource string corresponding to the given argument
- * value and bundle.
- * If the argument value specifies a resource key, the string
- * is looked up in the given resource bundle. If the argument does not
- * specify a valid key, the argument itself is returned as the
- * resource string. The key lookup is performed against the
- * specified resource bundle. If a resource string
- * corresponding to the key is not found in the resource bundle
- * the key value, or any default text following the key in the
- * argument value is returned as the resource string.
- * A key is identified as a string begining with the "%" character.
- * Note that the "%" character is stripped off prior to lookup
- * in the resource bundle.
- * <p>
- * For example, assume resource bundle plugin.properties contains
- * name = Project Name
- * <pre>
- * <li>getResourceString("Hello World") returns "Hello World"</li>
- * <li>getResourceString("%name") returns "Project Name"</li>
- * <li>getResourceString("%name Hello World") returns "Project Name"</li>
- * <li>getResourceString("%abcd Hello World") returns "Hello World"</li>
- * <li>getResourceString("%abcd") returns "%abcd"</li>
- * <li>getResourceString("%%name") returns "%name"</li>
- * <li>getResourceString(<code>null</code>) returns <code>null</code></li>
- * </pre>
- * </p>
- *
- * @param value the value or <code>null</code>
- * @param runtimeMappings runtime mappings or <code>null</code>
- * @return the resource string
- */
- public String getResourceString(String value, Hashtable runtimeMappings) {
-
- if (value == null)
- return null;
- String s = value.trim();
-
- if (!s.startsWith(KEY_PREFIX))
- return s;
-
- if (s.startsWith(KEY_DOUBLE_PREFIX))
- return s.substring(1);
-
- int ix = s.indexOf(" "); //$NON-NLS-1$
- String key = ix == -1 ? s : s.substring(0, ix);
- String dflt = ix == -1 ? s : s.substring(ix + 1);
-
- if (properties == null)
- return dflt;
-
- String result = null;
- try {
- result = properties.getString(key.substring(1));
- } catch (MissingResourceException e) {
- return dflt;
- }
- if (runtimeMappings != null) {
- for (Enumeration e = runtimeMappings.keys(); e.hasMoreElements();) {
- String keyValue = (String) e.nextElement();
- int i = result.indexOf(keyValue);
- if (i != -1) {
- String s1 = result.substring(0,i);
- String s2 = (String) runtimeMappings.get(keyValue);
- String s3 = result.substring(i+keyValue.length());
- result = s1 + s2 + s3;
- }
- }
- }
-
- if (result.indexOf('{') != -1) {
- // We test for the curly braces since due to NL issues we do not
- // want to use MessageFormat unless we have to.
- result = MessageFormat.format(result, mappings);
- }
-
- return result;
- }
-
- /*
- * Read the contents of the ini, properties, and mappings files.
- */
- private IStatus load(URL iniURL, URL propertiesURL, URL mappingsURL) {
-
- InputStream is = null;
- try {
- is = iniURL.openStream();
- ini = new Properties();
- ini.load(is);
- } catch (IOException e) {
- ini = null;
- String message = Messages.getString("IniFileReader.ReadIniError", iniURL.toExternalForm()); //$NON-NLS-1$
- return new Status(IStatus.ERROR, PID, 0, message, e);
- } finally {
- try {
- if (is != null)
- is.close();
- } catch (IOException e) {
- }
- }
-
- if (propertiesURL != null) {
- is = null;
- try {
- is = propertiesURL.openStream();
- properties = new PropertyResourceBundle(is);
- } catch (IOException e) {
- properties = null;
- String message = Messages.getString("IniFileReader.ReadPropError", propertiesURL.toExternalForm()); //$NON-NLS-1$
- return new Status(IStatus.ERROR, PID, 0, message, e);
- } finally {
- try {
- if (is != null)
- is.close();
- } catch (IOException e) {
- }
- }
- }
-
- PropertyResourceBundle bundle = null;
- if (mappingsURL != null) {
- is = null;
- try {
- is = mappingsURL.openStream();
- bundle = new PropertyResourceBundle(is);
- } catch (IOException e) {
- bundle = null;
- String message = Messages.getString("IniFileReader.ReadMapError", mappingsURL.toExternalForm()); //$NON-NLS-1$
- return new Status(IStatus.ERROR, PID, 0, message, e);
- } finally {
- try {
- if (is != null)
- is.close();
- } catch (IOException e) {
- }
- }
- }
-
- ArrayList mappingsList = new ArrayList();
- if (bundle != null) {
- boolean found = true;
- int i = 0;
- while (found) {
- try {
- mappingsList.add(bundle.getString(Integer.toString(i)));
- } catch (MissingResourceException e) {
- found = false;
- }
- i++;
- }
- }
- mappings = (String[])mappingsList.toArray(new String[mappingsList.size()]);
-
- return OK_STATUS;
- }
-}
diff --git a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/messages.properties b/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/messages.properties
deleted file mode 100644
index c0a04aeba..000000000
--- a/update/org.eclipse.update.configurator/src/org/eclipse/update/internal/configurator/messages.properties
+++ /dev/null
@@ -1,90 +0,0 @@
-###############################################################################
-# Copyright (c) 2000, 2003 IBM Corporation and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Common Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/cpl-v10.html
-#
-# Contributors:
-# IBM Corporation - initial API and implementation
-###############################################################################
-### Boot plugin message catalog
-
-ok = OK
-
-### URL
-url.badVariant=Unsupported \"platform:\" protocol variation {0}
-url.invalidURL=Invalid "platform:" URL {0}
-url.createConnection=Unable to create connection {0}
-url.noaccess=Unable to access URL as local {0}.
-
-### Platform Configuration
-cfig.inUse=\nConfiguration file \"{0}\" is in use by another instance of the platform, \n\
- or there was a failure in deleting the old lock file. If no other platform instances are running, \n\
- delete file \"{1}\" and try starting the platform again.
-cfig.failCreateLock=Failed to create lock for configuration file \"{0}\"
-cfig.badUrlArg=Bad -configuration argument \"{0}\"
-cfig.unableToLoad.incomplete=Unable to load {0}
-cfig.unableToLoad.noURL=Configuration file location not specified
-cfig.unableToSave.noURL=Configuration file save location not specified
-cfig.unableToSave=Unable to save configuration file \"{0}\"
-cfig.badVersion=Unsupported configuration version \"{0}\"
-cfg.unableToCreateConfig.ini = Unable to create config.ini
-
-platform.running=The Platform is already running.
-platform.mustNotBeRunning=The Platform must not be running.
-platform.notRunning=The Platform is not running.
-
-ignore.plugin=Ignoring invalid plug-in location: {0}.
-application.notFound=Application not found: {0}.
-error.fatal=Fatal Error: Unable to determine platform installation URL {0}.
-error.boot=Fatal Error: Unable to locate boot.xml file for executing org.eclipse.core.boot.
-error.runtime=Fatal Error: Unable to locate matching org.eclipse.core.runtime plug-in.
-error.xerces=Fatal Error: Unable to locate matching org.apache.xerces plug-in.
-error.badNL=Bad value: \"{0}\" for NL. Using system default.
-
-InstalledSiteParser.DirectoryDoesNotExist=The directory \"{0}\" does not exist on the file system.
-InstalledSiteParser.UnableToCreateURL= Internal Error. Unable to create URL from \"{0}\".
-InstalledSiteParser.FileDoesNotExist= The file \"{0}\" does not exist.
-InstalledSiteParser.UnableToCreateURLForFile= Unable to create URL from \"{0}\".
-InstalledSiteParser.ErrorParsingFile= Unable to parse file \"{0}\".
-InstalledSiteParser.ErrorAccessing= Unable to access file \"{0}\".
-InstalledSiteParser.date = Invalid date attribute {0}
-BundleManifest.noVersion = {0} attribute not found in manifest for bundle \"{1}\". Bundle will be ignored.
-
-FeatureParser.IdOrVersionInvalid= Error parsing feature stream. The unique identifier or the version is null or empty: unique identifier=\"{0}\" version=\"{1}\".
-
-BundleGroupProvider=Update Manager Configurator
-ProductProvider=Update Manager Configurator
-
-AboutInfo.notSpecified=Unspecified
-ConfigurationActivator.initialize=Cannot initialize the Update Configurator
-ConfigurationActivator.createConfig=Cannot create configuration in {0}
-ConfigurationActivator.uninstallBundle=Could not uninstall unused bundle {0}
-ConfigurationParser.cannotLoadSharedInstall=Could not load from shared install
-ConfigurationActivator.installBundle=Could not install bundle {0}
-PluginEntry.versionError=Unable to create versioned identifier: {0} {1}
-
-IniFileReader.MissingDesc = Cannot find plugin for feature {0}
-IniFileReader.OpenINIError = Cannot open branding file {0}
-IniFileReader.OpenPropError = Cannot open branding properties file {0}
-IniFileReader.OpenMapError = Cannot open mapping file {0}
-IniFileReader.ReadIniError = Error reading branding file {0}
-IniFileReader.ReadPropError = Error reading branding properties file {0}
-IniFileReader.ReadMapError = Error reading mapping files {0}
-
-SiteEntry.computePluginStamp = Cannot compute plugins change stamp for site {0} because it does not support plugin detection.
-SiteEntry.cannotFindFeatureInDir=Unable to find feature.xml in directory: {0}
-SiteEntry.duplicateFeature=Duplicate feature found on site {0} : {1}
-SiteEntry.pluginsDir = {0} is not a valid plugins directory.
-PlatformConfiguration.expectingPlatformXMLorDirectory=Either specify the configuration directory or a file named platform.xml
-PlatformConfiguration.cannotBackupConfig=Cannot backup current configuration
-PlatformConfiguration.cannotCloseStream=Could not close output stream for
-PlatformConfiguration.cannotCloseTempFile=Could not close output stream for temp file
-PlatformConfiguration.cannotRenameTempFile=Could not rename configuration temp file
-PlatformConfiguration.cannotLoadConfig=Cannot load configuration from
-PlatformConfiguration.cannotLoadDefaultSite=Cannot load default site
-PlatformConfiguration.cannotFindConfigFile=Platform configuration file cannot be found
-PlatformConfiguration.cannotSaveNonExistingConfig=Configuration cannot be saved because it does not exist
-HttpResponse.rangeExpected=Server returned full content instead of a range.
-HttpResponse.wrongRange=Server returned wrong range
diff --git a/update/org.eclipse.update.core.linux/.classpath b/update/org.eclipse.update.core.linux/.classpath
deleted file mode 100644
index 484824984..000000000
--- a/update/org.eclipse.update.core.linux/.classpath
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
- <classpathentry kind="src" path="src"/>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/update/org.eclipse.update.core.linux/.cvsignore b/update/org.eclipse.update.core.linux/.cvsignore
deleted file mode 100644
index c5e82d745..000000000
--- a/update/org.eclipse.update.core.linux/.cvsignore
+++ /dev/null
@@ -1 +0,0 @@
-bin \ No newline at end of file
diff --git a/update/org.eclipse.update.core.linux/.project b/update/org.eclipse.update.core.linux/.project
deleted file mode 100644
index 178e2b76a..000000000
--- a/update/org.eclipse.update.core.linux/.project
+++ /dev/null
@@ -1,33 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.update.core.linux</name>
- <comment></comment>
- <projects>
- <project>org.eclipse.core.boot</project>
- <project>org.eclipse.core.runtime</project>
- <project>org.eclipse.core.runtime.compatibility</project>
- <project>org.eclipse.update.configurator</project>
- <project>org.eclipse.update.core</project>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.jdt.core.javabuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.ManifestBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.SchemaBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.eclipse.jdt.core.javanature</nature>
- <nature>org.eclipse.pde.PluginNature</nature>
- </natures>
-</projectDescription>
diff --git a/update/org.eclipse.update.core.linux/about.html b/update/org.eclipse.update.core.linux/about.html
deleted file mode 100644
index 9db411aab..000000000
--- a/update/org.eclipse.update.core.linux/about.html
+++ /dev/null
@@ -1,30 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<title>About</title>
-<meta http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<p>20th June, 2002</p>
-<h3>License</h3>
-<p>Eclipse.org makes available all content in this plug-in (&quot;Content&quot;). Unless otherwise indicated below, the Content is provided to you under the terms and conditions of the
-Common Public License Version 1.0 (&quot;CPL&quot;). A copy of the CPL is available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>.
-For purposes of the CPL, &quot;Program&quot; will mean the Content.</p>
-
-<h3>Contributions</h3>
-
-<p>If this Content is licensed to you under the terms and conditions of the CPL, any Contributions, as defined in the CPL, uploaded, submitted, or otherwise
-made available to Eclipse.org, members of Eclipse.org and/or the host of Eclipse.org web site, by you that relate to such
-Content are provided under the terms and conditions of the CPL and can be made available to others under the terms of the CPL.</p>
-
-<p>If this Content is licensed to you under license terms and conditions other than the CPL (&quot;Other License&quot;), any modifications, enhancements and/or
-other code and/or documentation (&quot;Modifications&quot;) uploaded, submitted, or otherwise made available to Eclipse.org, members of Eclipse.org and/or the
-host of Eclipse.org, by you that relate to such Content are provided under terms and conditions of the Other License and can be made available
-to others under the terms of the Other License. In addition, with regard to Modifications for which you are the copyright holder, you are also
-providing the Modifications under the terms and conditions of the CPL and such Modifications can be made available to others under the terms of
-the CPL.</p>
-
-</body>
-</html> \ No newline at end of file
diff --git a/update/org.eclipse.update.core.linux/build.properties b/update/org.eclipse.update.core.linux/build.properties
deleted file mode 100644
index 68d414f73..000000000
--- a/update/org.eclipse.update.core.linux/build.properties
+++ /dev/null
@@ -1,17 +0,0 @@
-###############################################################################
-# Copyright (c) 2000, 2004 IBM Corporation and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Common Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/cpl-v10.html
-#
-# Contributors:
-# IBM Corporation - initial API and implementation
-###############################################################################
-bin.includes = fragment.xml,\
- os/,\
- fragment.properties,\
- about.html
-src.includes = src/,\
- fragment.xml,\
- about.html
diff --git a/update/org.eclipse.update.core.linux/fragment.xml b/update/org.eclipse.update.core.linux/fragment.xml
deleted file mode 100644
index 6740684ed..000000000
--- a/update/org.eclipse.update.core.linux/fragment.xml
+++ /dev/null
@@ -1,16 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.0"?>
-<fragment
- id="org.eclipse.update.core.linux"
- name="%fragmentNameLinux"
- version="3.0.0"
- provider-name="%providerName"
- plugin-id="org.eclipse.update.core"
- plugin-version="3.0.0"
- match="compatible">
-
- <runtime>
- </runtime>
-
-
-</fragment>
diff --git a/update/org.eclipse.update.core.linux/os/linux/x86/libupdate.so b/update/org.eclipse.update.core.linux/os/linux/x86/libupdate.so
deleted file mode 100644
index d70a9e971..000000000
--- a/update/org.eclipse.update.core.linux/os/linux/x86/libupdate.so
+++ /dev/null
Binary files differ
diff --git a/update/org.eclipse.update.core.linux/src/build.xml b/update/org.eclipse.update.core.linux/src/build.xml
deleted file mode 100644
index cf44eadd0..000000000
--- a/update/org.eclipse.update.core.linux/src/build.xml
+++ /dev/null
@@ -1,70 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project name="buildlibrary" default="run" basedir=".">
-
- <!-- The properties ${eclipse-home} ${jdk-path} should be passed into this script -->
- <!-- Set a meaningful default value for when it is not. -->
- <property name="eclipse-home" value="${basedir}/../.."/>
- <property name="jdk-path" value="${java.home}"/>
- <property name="destination" value="${eclipse-home}/org.eclipse.update.core.linux/os/linux/x86/"/>
- <property name="obj-path" value="${eclipse-home}/org.eclipse.update.core.linux/src/"/>
- <property name="src-path" value="${eclipse-home}/org.eclipse.update.core.linux/src/"/>
-
- <!-- sets the properties -->
- <property name="library-name" value="libupdate"/>
- <property name="library-platform" value="so"/>
- <property name="library-file" value="${library-name}.${library-platform}"/>
-
- <!-- This target holds all initialization code that needs to be done for -->
- <!-- all tests that are to be run. Initialization for individual tests -->
- <!-- should be done within the body of the suite target. -->
- <target name="init">
- <tstamp/>
- <delete>
- <fileset dir="${obj-path}" includes="${library-file}"/>
- <fileset dir="${obj-path}" includes="${library-name}.o"/>
- </delete>
- </target>
-
- <!-- This target holds code to cleanup the testing environment after -->
- <!-- after all of the tests have been run. You can use this target to -->
- <!-- delete temporary files that have been created. -->
- <target name="cleanup">
- <delete>
- <fileset dir="${obj-path}" includes="${library-file}"/>
- <fileset dir="${obj-path}" includes="${library-name}.o"/>
- </delete>
- </target>
-
-
- <!-- This target runs the build. -->
- <target name="run" depends="init,build,cleanup">
- </target>
-
- <!-- This target build the library -->
- <target name="build">
- <echo message="Building ${library-file}"/>
-
- <property name="header-path" value="${jdk-path}/../include"/>
- <property name="header-linux-path" value="${header-path}/linux" />
-
- <echo message="gcc -o ${library-file} -shared -I${src-path} -I${header-linux-path} ${library-file} -static -lc"/>
-
- <apply executable="gcc" dest="${eclipse-home}/" parallel="false">
- <arg value="-o"/>
- <arg value="${library-file}"/>
- <arg value="-shared"/>
- <arg value="-I${src-path}"/>
- <arg value="-I${header-path}"/>
- <arg value="-I${header-linux-path}"/>
- <srcfile/>
- <arg value="-static"/>
- <arg value="-lc"/>
- <fileset dir="${src-path}" includes="*.c"/>
- <mapper type="glob" from="*.c" to="*.o"/>
- </apply>
-
- <move file="${library-file}" todir="${destination}"/>
- </target>
-
-
-</project> \ No newline at end of file
diff --git a/update/org.eclipse.update.core.linux/src/update.c b/update/org.eclipse.update.core.linux/src/update.c
deleted file mode 100644
index 2acb3a4f3..000000000
--- a/update/org.eclipse.update.core.linux/src/update.c
+++ /dev/null
@@ -1,162 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2002 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-# include <sys/types.h>
-# include <sys/statfs.h>
-# include <update.h>
-
-/*
- * Class: org_eclipse_update_configuration_LocalSystemInfo
- * Method: nativeGetFreeSpace
- * Signature: (Ljava/io/File;)J
- */
-JNIEXPORT jlong JNICALL Java_org_eclipse_update_configuration_LocalSystemInfo_nativeGetFreeSpace(
- JNIEnv * jnienv,
- jclass javaClass,
- jobject file) {
-
- // to retrive the String
- jclass cls;
- jmethodID id;
- jobject obj;
-
- // java.io.File.getAbsolutePath()
- const char * lpDirectoryName;
-
- // Linux Parameters
- struct statfs buffer;
-
- // the result
- jlong result = org_eclipse_update_configuration_LocalSystemInfo_SIZE_UNKNOWN;
-
- cls = (*jnienv) -> GetObjectClass(jnienv, file);
- id = (*jnienv) -> GetMethodID(jnienv, cls, "getAbsolutePath", "()Ljava/lang/String;");
- obj = (*jnienv) -> CallObjectMethod(jnienv, file, id);
- lpDirectoryName = (*jnienv) -> GetStringUTFChars(jnienv, (jstring) obj, 0);
-
- // cast one argument as jlong to have a jlong result
- int err = statfs(lpDirectoryName,&buffer);
- if (err==0){
- long size = buffer.f_bsize;
- jlong free = buffer.f_bfree;
- result = size*free;
- }
-
- return result;
-}
-
-/*
- * Class: org_eclipse_update_configuration_LocalSystemInfo
- * Method: nativeGetLabel
- * Signature: (Ljava/io/File;)Ljava/lang/String;
- */
-JNIEXPORT jstring JNICALL Java_org_eclipse_update_configuration_LocalSystemInfo_nativeGetLabel(
- JNIEnv * jnienv,
- jclass javaClass,
- jobject file) {
-
- // to retrive the String
- jclass cls;
- jmethodID id;
- jobject obj;
-
- // java.io.File.getAbsolutePath()
- const char * lpDirectoryName;
-
- // obtain the String from the parameter
- cls = (*jnienv) -> GetObjectClass(jnienv, file);
- id = (*jnienv) -> GetMethodID(jnienv, cls, "getAbsolutePath", "()Ljava/lang/String;");
- obj = (*jnienv) -> CallObjectMethod(jnienv, file, id);
- lpDirectoryName = (*jnienv) -> GetStringUTFChars(jnienv, (jstring) obj, 0);
-
- jstring result = NULL;
-
- // Linux implementation following
-
- return result;
-}
-
-/*
- * Class: org_eclipse_update_configuration_LocalSystemInfo
- * Method: nativeGetType
- * Signature: (Ljava/io/File;)I
- */
-JNIEXPORT jint JNICALL Java_org_eclipse_update_configuration_LocalSystemInfo_nativeGetType(
- JNIEnv * jnienv,
- jclass javaClass,
- jobject file) {
-
- // to retrive the String
- jclass cls;
- jmethodID id;
- jobject obj;
-
- // java.io.File.getAbsolutePath()
- const char * lpDirectoryName;
-
- // obtain the String from the parameter
- cls = (*jnienv) -> GetObjectClass(jnienv, file);
- id = (*jnienv) -> GetMethodID(jnienv, cls, "getAbsolutePath", "()Ljava/lang/String;");
- obj = (*jnienv) -> CallObjectMethod(jnienv, file, id);
- lpDirectoryName = (*jnienv) -> GetStringUTFChars(jnienv, (jstring) obj, 0);
-
- int result;
-
- // Linux implemantation
-
- result = org_eclipse_update_configuration_LocalSystemInfo_VOLUME_INVALID_PATH;
- return result;
-}
-
-/*
- * Class: org_eclipse_update_configuration_LocalSystemInfo
- * Method: nativeListMountPoints
- * Signature: ()[Ljava/lang/String;
- */
-JNIEXPORT jobjectArray JNICALL Java_org_eclipse_update_configuration_LocalSystemInfo_nativeListMountPoints(
- JNIEnv * jnienv,
- jclass javaClass) {
-
- //
- int drive;
- char driveName[100];
- jobjectArray returnArray;
- int nDrive = 0;
-
- //
- jclass stringClass;
- jobject empty;
- int index = 0;
- jobject str;
-
- // Linux implementation
- // find mount points
-
- drive = 0;
- stringClass = (*jnienv) -> FindClass(jnienv, "java/lang/String");
- empty = (*jnienv) -> NewStringUTF(jnienv, "");
- //returnArray = (*jnienv) -> NewObjectArray(jnienv, nDrive, stringClass, empty);
-
- // for now return null as method is not implemented
- returnArray = NULL;
-
- int i;
- for (i = 0; i < drive; i++) {
- // Linux implementation, create String for each mount point
-
- str = (*jnienv) -> NewStringUTF(jnienv, driveName);
- (*jnienv) -> SetObjectArrayElement(jnienv, returnArray, index, str);
-
- index++;
- }
-
- return returnArray;
-}
diff --git a/update/org.eclipse.update.core.linux/src/update.h b/update/org.eclipse.update.core.linux/src/update.h
deleted file mode 100644
index fef03474b..000000000
--- a/update/org.eclipse.update.core.linux/src/update.h
+++ /dev/null
@@ -1,76 +0,0 @@
-/* DO NOT EDIT THIS FILE - it is machine generated */
-
-/*******************************************************************************
- * Copyright (c) 2000, 2002 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-#include <jni.h>
-/* Header for class org_eclipse_update_configuration_LocalSystemInfo */
-
-#ifndef _Included_org_eclipse_update_configuration_LocalSystemInfo
-#define _Included_org_eclipse_update_configuration_LocalSystemInfo
-#ifdef __cplusplus
-extern "C" {
-#endif
-#undef org_eclipse_update_configuration_LocalSystemInfo_SIZE_UNKNOWN
-#define org_eclipse_update_configuration_LocalSystemInfo_SIZE_UNKNOWN -1L
-#undef org_eclipse_update_configuration_LocalSystemInfo_VOLUME_UNKNOWN
-#define org_eclipse_update_configuration_LocalSystemInfo_VOLUME_UNKNOWN -1L
-#undef org_eclipse_update_configuration_LocalSystemInfo_VOLUME_INVALID_PATH
-#define org_eclipse_update_configuration_LocalSystemInfo_VOLUME_INVALID_PATH -2L
-#undef org_eclipse_update_configuration_LocalSystemInfo_VOLUME_REMOVABLE
-#define org_eclipse_update_configuration_LocalSystemInfo_VOLUME_REMOVABLE 1L
-#undef org_eclipse_update_configuration_LocalSystemInfo_VOLUME_FIXED
-#define org_eclipse_update_configuration_LocalSystemInfo_VOLUME_FIXED 2L
-#undef org_eclipse_update_configuration_LocalSystemInfo_VOLUME_REMOTE
-#define org_eclipse_update_configuration_LocalSystemInfo_VOLUME_REMOTE 3L
-#undef org_eclipse_update_configuration_LocalSystemInfo_VOLUME_CDROM
-#define org_eclipse_update_configuration_LocalSystemInfo_VOLUME_CDROM 4L
-#undef org_eclipse_update_configuration_LocalSystemInfo_VOLUME_RAMDISK
-#define org_eclipse_update_configuration_LocalSystemInfo_VOLUME_RAMDISK 5L
-/* Inaccessible static: listeners */
-/* Inaccessible static: hasNatives */
-/*
- * Class: org_eclipse_update_configuration_LocalSystemInfo
- * Method: nativeGetFreeSpace
- * Signature: (Ljava/io/File;)J
- */
-JNIEXPORT jlong JNICALL Java_org_eclipse_update_configuration_LocalSystemInfo_nativeGetFreeSpace
- (JNIEnv *, jclass, jobject);
-
-/*
- * Class: org_eclipse_update_configuration_LocalSystemInfo
- * Method: nativeGetLabel
- * Signature: (Ljava/io/File;)Ljava/lang/String;
- */
-JNIEXPORT jstring JNICALL Java_org_eclipse_update_configuration_LocalSystemInfo_nativeGetLabel
- (JNIEnv *, jclass, jobject);
-
-/*
- * Class: org_eclipse_update_configuration_LocalSystemInfo
- * Method: nativeGetType
- * Signature: (Ljava/io/File;)I
- */
-JNIEXPORT jint JNICALL Java_org_eclipse_update_configuration_LocalSystemInfo_nativeGetType
- (JNIEnv *, jclass, jobject);
-
-/*
- * Class: org_eclipse_update_configuration_LocalSystemInfo
- * Method: nativeListMountPoints
- * Signature: ()[Ljava/lang/String;
- */
-JNIEXPORT jobjectArray JNICALL Java_org_eclipse_update_configuration_LocalSystemInfo_nativeListMountPoints
- (JNIEnv *, jclass);
-
-#ifdef __cplusplus
-}
-
-#endif
-#endif
diff --git a/update/org.eclipse.update.core.win32/.project b/update/org.eclipse.update.core.win32/.project
deleted file mode 100644
index 8c9b28f05..000000000
--- a/update/org.eclipse.update.core.win32/.project
+++ /dev/null
@@ -1,22 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.update.core.win32</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.pde.ManifestBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.SchemaBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.eclipse.pde.PluginNature</nature>
- </natures>
-</projectDescription>
diff --git a/update/org.eclipse.update.core.win32/about.html b/update/org.eclipse.update.core.win32/about.html
deleted file mode 100644
index 9db411aab..000000000
--- a/update/org.eclipse.update.core.win32/about.html
+++ /dev/null
@@ -1,30 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<title>About</title>
-<meta http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<p>20th June, 2002</p>
-<h3>License</h3>
-<p>Eclipse.org makes available all content in this plug-in (&quot;Content&quot;). Unless otherwise indicated below, the Content is provided to you under the terms and conditions of the
-Common Public License Version 1.0 (&quot;CPL&quot;). A copy of the CPL is available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>.
-For purposes of the CPL, &quot;Program&quot; will mean the Content.</p>
-
-<h3>Contributions</h3>
-
-<p>If this Content is licensed to you under the terms and conditions of the CPL, any Contributions, as defined in the CPL, uploaded, submitted, or otherwise
-made available to Eclipse.org, members of Eclipse.org and/or the host of Eclipse.org web site, by you that relate to such
-Content are provided under the terms and conditions of the CPL and can be made available to others under the terms of the CPL.</p>
-
-<p>If this Content is licensed to you under license terms and conditions other than the CPL (&quot;Other License&quot;), any modifications, enhancements and/or
-other code and/or documentation (&quot;Modifications&quot;) uploaded, submitted, or otherwise made available to Eclipse.org, members of Eclipse.org and/or the
-host of Eclipse.org, by you that relate to such Content are provided under terms and conditions of the Other License and can be made available
-to others under the terms of the Other License. In addition, with regard to Modifications for which you are the copyright holder, you are also
-providing the Modifications under the terms and conditions of the CPL and such Modifications can be made available to others under the terms of
-the CPL.</p>
-
-</body>
-</html> \ No newline at end of file
diff --git a/update/org.eclipse.update.core.win32/build.properties b/update/org.eclipse.update.core.win32/build.properties
deleted file mode 100644
index 99cd557dc..000000000
--- a/update/org.eclipse.update.core.win32/build.properties
+++ /dev/null
@@ -1,17 +0,0 @@
-###############################################################################
-# Copyright (c) 2000, 2004 IBM Corporation and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Common Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/cpl-v10.html
-#
-# Contributors:
-# IBM Corporation - initial API and implementation
-###############################################################################
-bin.includes = fragment.xml,\
- os/,\
- fragment.properties,\
- about.html
-src.includes = fragment.xml,\
- about.html,\
- src/
diff --git a/update/org.eclipse.update.core.win32/fragment.xml b/update/org.eclipse.update.core.win32/fragment.xml
deleted file mode 100644
index 81d8e7b52..000000000
--- a/update/org.eclipse.update.core.win32/fragment.xml
+++ /dev/null
@@ -1,16 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.0"?>
-<fragment
- id="org.eclipse.update.core.win32"
- name="%fragmentNameWin"
- version="3.0.0"
- provider-name="%providerName"
- plugin-id="org.eclipse.update.core"
- plugin-version="3.0.0"
- match="compatible">
-
- <runtime>
- </runtime>
-
-
-</fragment>
diff --git a/update/org.eclipse.update.core.win32/os/win32/x86/update.dll b/update/org.eclipse.update.core.win32/os/win32/x86/update.dll
deleted file mode 100644
index 428e60ebf..000000000
--- a/update/org.eclipse.update.core.win32/os/win32/x86/update.dll
+++ /dev/null
Binary files differ
diff --git a/update/org.eclipse.update.core.win32/src/build.xml b/update/org.eclipse.update.core.win32/src/build.xml
deleted file mode 100644
index 92286b75e..000000000
--- a/update/org.eclipse.update.core.win32/src/build.xml
+++ /dev/null
@@ -1,74 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project name="buildlibrary" default="run" basedir=".">
-
- <!-- The properties ${eclipse-home} ${jdk-path} should be passed into this script -->
- <!-- The Path should point to the bin directory of BCC55 -->
- <!-- http://www.borland.com/products/downloads/download_cbuilder.html -->
-
- <!-- Set a meaningful default value for when it is not. -->
- <property name="eclipse-home" value="${basedir}/../.."/>
- <property name="jdk-path" value="${java.home}"/>
- <property name="destination" value="${eclipse-home}/org.eclipse.update.core.win32/os/win32/x86/"/>
- <property name="obj-path" value="${eclipse-home}/org.eclipse.update.core.win32/src"/>
- <property name="src-path" value="${eclipse-home}/org.eclipse.update.core.win32/src/"/>
-
- <!-- sets the properties -->
- <property name="library-name" value="update"/>
- <property name="library-platform" value="dll"/>
- <property name="library-file" value="${library-name}.${library-platform}"/>
-
- <!-- This target holds all initialization code that needs to be done for -->
- <!-- all tests that are to be run. Initialization for individual tests -->
- <!-- should be done within the body of the suite target. -->
- <target name="init">
- <tstamp/>
- <delete>
- <fileset dir="${obj-path}" includes="${library-file}"/>
- <fileset dir="${obj-path}" includes="${library-name}.obj"/>
- <fileset dir="${obj-path}" includes="${library-name}.tds"/>
- </delete>
- </target>
-
- <!-- This target holds code to cleanup the testing environment after -->
- <!-- after all of the tests have been run. You can use this target to -->
- <!-- delete temporary files that have been created. -->
- <target name="cleanup">
- <delete>
- <fileset dir="${obj-path}" includes="${library-file}"/>
- <fileset dir="${obj-path}" includes="${library-name}.obj"/>
- <fileset dir="${obj-path}" includes="${library-name}.tds"/>
- </delete>
- </target>
-
-
- <!-- This target runs the test suite. Any actions that need to happen -->
- <!-- after all the tests have been run should go here. -->
- <target name="run" depends="init,build,cleanup">
- </target>
-
- <!-- This target build the dll -->
- <target name="build">
- <echo message="Building ${library-file}"/>
-
- <property name="header-path" value="${jdk-path}/include"/>
- <property name="header-windows-path" value="${header-path}/win32" />
-
- <echo message="bcc32 -I${src-path} -I${header-windows-path} -WD"/>
-
- <apply executable="bcc32" dest="${eclipse-home}/" parallel="false">
- <arg value="-I${src-path}"/>
- <arg value="-I${header-path}"/>
- <arg value="-I${header-windows-path}"/>
- <!-- arg value="-DUNICODE" -->
- <arg value="-w-8057"/>
- <arg value="-WD"/>
- <srcfile/>
- <fileset dir="${src-path}" includes="*.cpp"/>
- <mapper type="glob" from="*.cpp" to="*.obj"/>
- </apply>
-
- <move file="${library-file}" todir="${destination}"/>
- </target>
-
-
-</project> \ No newline at end of file
diff --git a/update/org.eclipse.update.core.win32/src/update.cpp b/update/org.eclipse.update.core.win32/src/update.cpp
deleted file mode 100644
index cb27fd518..000000000
--- a/update/org.eclipse.update.core.win32/src/update.cpp
+++ /dev/null
@@ -1,487 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2002 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-# include <update.h>
-# include <windows.h>
-# include <winioctl.h> // IOCTL codes: MediaType
-
-// Windows Version
-int WIN98 = 0;
-int WINNT = 1;
-int WINME = 2;
-int WIN2000 = 3;
-int WINXP = 4;
-
-// set to 1 for DEBUG
-int DEBUG = 0;
-
-// set to 0 to run on Windows 95 *Unsupported*
-int NOWIN95 = 1;
-
-
-// GLOBAL METHODS
-// ---------------
-
-/*
- *
- */
-jstring WindowsTojstring( JNIEnv* jnienv, char* buf )
-{
- jstring rtn = 0;
- wchar_t* buffer = 0;
- int bufferLen = strlen(buf);
- if( bufferLen == 0 ){
- rtn = jnienv ->NewStringUTF(buf);
- if (DEBUG)
- printf("WindowsToJString Buffer is empty\n");
- } else {
- int length = MultiByteToWideChar( CP_ACP, 0, (LPCSTR)buf, bufferLen, NULL, 0 );
- buffer = (wchar_t*)malloc( length*2 + 1 );
- if(int err=MultiByteToWideChar( CP_ACP, 0, (LPCSTR)buf, bufferLen, (LPWSTR)buffer, length ) >0 ){
- rtn = jnienv->NewString((jchar*)buffer, length );
- } else {
- if (DEBUG)
- printf("MultiByteToWideChar %i\n",err);
- }
- }
- if( buffer )
- free( buffer );
- return rtn;
-}
-
-
-
-/*
- * calls GetVolumeInformation to retrive the label of the volume
- * Returns NULL if an error occurs
- * @param driveLetter path to the drive "c:\\"
- * @prama jnienv JNIEnvironment
- */
-jstring getLabel(TCHAR driveLetter[],JNIEnv * jnienv){
-
- jstring result = NULL;
- TCHAR buf[128];
-
- // always return null as UNICODE is not implemented
- // how can we get the label of a volume as UNICODE char ?
- return result;
-
- int err = GetVolumeInformation(
- driveLetter,
- buf,
- sizeof(buf) - 1,
- NULL,
- NULL,
- NULL,
- NULL,
- 0);
- if (err){
- result = WindowsTojstring(jnienv, buf);
- } else {
- if (DEBUG)
- printf("Error GetVolumeInformation %i\n",err);
- }
- return result;
-}
-
-/*
- * returns the Version of Windows
- * int 0 WIN98;
- * int 1 WINNT;
- * int 2 WINME;
- * int 3 WIN2000;
- * int 4 WINXP;
- * returns -1 otherwise
- */
-int getWindowsVersion(){
- OSVERSIONINFOEX osvi;
- int UNKNOWN = -1;
-
- ZeroMemory(&osvi, sizeof(OSVERSIONINFOEX));
- osvi.dwOSVersionInfoSize = sizeof(OSVERSIONINFOEX);
-
- if(!(GetVersionEx((OSVERSIONINFO *)&osvi))){
- if (DEBUG)
- printf("UNKNOWN VERSION: Cannot execute GetVersionEx\n");
- // if OSVERSIONEX doesn't work, try OSVERSIONINFO
- osvi.dwOSVersionInfoSize = sizeof(OSVERSIONINFO);
- if(!(GetVersionEx((OSVERSIONINFO *)&osvi))){
- if (DEBUG)
- printf("UNKNOWN VERSION: Cannot execute GetVersionEx\n");
- return UNKNOWN;
- }
- }
-
- switch(osvi.dwPlatformId){
- case VER_PLATFORM_WIN32_NT:
- if (DEBUG)
- printf("VERSION NT: Maj %i Min %i\n",osvi.dwMajorVersion,osvi.dwMinorVersion);
- if(osvi.dwMajorVersion<=4)
- return WINNT;
- if(osvi.dwMajorVersion==5){
- if (osvi.dwMinorVersion==0)
- return WIN2000;
- if (osvi.dwMinorVersion==1)
- return WINXP;
- } else {
- return UNKNOWN;
- };
- break;
- case VER_PLATFORM_WIN32_WINDOWS:
- if (DEBUG)
- printf("VERSION Non NT: Maj %i Min %i\n",osvi.dwMajorVersion,osvi.dwMinorVersion);
- if(osvi.dwMajorVersion==4){
- if (osvi.dwMinorVersion==10)
- return WIN98;
- if (osvi.dwMinorVersion==90)
- return WINME;
- } else {
- return UNKNOWN;
- }
- break;
- default:
- if (DEBUG)
- printf("VERSION UNKNOWN: Maj %i Min %i\n",osvi.dwMajorVersion,osvi.dwMinorVersion);
- return UNKNOWN;
- }
- return UNKNOWN;
-}
-
-/*
- * Returns the type of Removable Drive
- * Returns
- * org_eclipse_update_configuration_LocalSystemInfo_VOLUME_FLOPPY_3
- * org_eclipse_update_configuration_LocalSystemInfo_VOLUME_FLOPPY_5
- * org_eclipse_update_configuration_LocalSystemInfo_VOLUME_REMOVABLE
- */
-jlong getFloppy(TCHAR driveLetter[]){
-
- TCHAR floppyPath[8];
- HANDLE handle;
- DISK_GEOMETRY geometry[20];
- DWORD dw;
- jlong UNKNOWN = org_eclipse_update_configuration_LocalSystemInfo_VOLUME_REMOVABLE;
-
- sprintf(floppyPath, "\\\\.\\%c:", driveLetter[0]);
- if (DEBUG)
- printf("Path %s\n",floppyPath);
- // BUG 25719
- SetErrorMode( SEM_FAILCRITICALERRORS );
- handle=CreateFile(floppyPath,0,FILE_SHARE_READ,NULL,OPEN_ALWAYS,0,NULL);
- if (handle==INVALID_HANDLE_VALUE){
- if (DEBUG)
- printf("Invalid Handle %s\n",floppyPath);
- return UNKNOWN;
- } else {
- if(DeviceIoControl(handle,
- IOCTL_DISK_GET_MEDIA_TYPES,0,0,
- geometry,sizeof(geometry),&dw,0)
- && dw>0) {
- switch(geometry[0].MediaType){
- case F5_160_512:
- case F5_180_512:
- case F5_320_512:
- case F5_320_1024:
- case F5_360_512:
- case F5_1Pt2_512:
- if (DEBUG)
- printf("Found 5 1/4 Drive\n");
- return org_eclipse_update_configuration_LocalSystemInfo_VOLUME_FLOPPY_5;
- case F3_720_512:
- case F3_1Pt44_512:
- case F3_2Pt88_512:
- case F3_20Pt8_512:
- if (DEBUG)
- printf("Found 3 1/2 Drive\n");
- return org_eclipse_update_configuration_LocalSystemInfo_VOLUME_FLOPPY_3;
- default:
- return UNKNOWN;
- }
- }
- }
- return UNKNOWN;
-}
-
-/*
- * Returns the UNC name of a remote drive
- * (\\Machine\path\path1\path2$)
- * returns NULL if an error occurs
- */
- jstring getRemoteNetworkName(TCHAR driveLetter[],JNIEnv * jnienv){
-
- unsigned long size =256;
- TCHAR buf[256];
- TCHAR drivePath[2];
- DWORD err;
- jstring result = NULL;
-
- // always return NULL as UNICODE not implemented
- // how can we get the label of a remote network name as UNICODE char ?
- return result;
-
- sprintf(drivePath, "%c:", driveLetter[0]);
- err = WNetGetConnection(drivePath,buf,&size);
-
- if (err==WN_SUCCESS){
- result = WindowsTojstring(jnienv,buf);
- } else {
- if (DEBUG)
- printf("Error WNEtGetConnection %i",err);
- }
- return result;
- }
-
-
-// JNI METHODS
-// ---------------
-
-/*
- * Class: org_eclipse_update_configuration_LocalSystemInfo
- * Method: nativeGetFreeSpace
- * Signature: (Ljava/io/File;)J
- */
-JNIEXPORT jlong JNICALL Java_org_eclipse_update_configuration_LocalSystemInfo_nativeGetFreeSpace(
- JNIEnv * jnienv,
- jclass javaClass,
- jobject file) {
-
- // to retrive the String
- jclass cls;
- jmethodID id;
- jobject obj;
-
- // java.io.File.getAbsolutePath()
- const TCHAR * lpDirectoryName;
-
- // Windows Parameters
- __int64 i64FreeBytesAvailableToCaller;
- __int64 i64TotalNumberOfBytes;
- __int64 i64TotalNumberOfFreeBytes;
-
- // the result
- jlong result = org_eclipse_update_configuration_LocalSystemInfo_SIZE_UNKNOWN;
-
- // first, obtain the Path from the java.io.File parameter
- cls = jnienv -> GetObjectClass(file);
- id = jnienv -> GetMethodID(cls, "getAbsolutePath", "()Ljava/lang/String;");
- obj = jnienv -> CallObjectMethod(file, id);
- lpDirectoryName = jnienv -> GetStringUTFChars((jstring) obj, 0);
- if (DEBUG)
- printf("Directory: [%s]\n",lpDirectoryName);
-
- if (int win = (int)getWindowsVersion()<0 && NOWIN95){
- // windows 95 or other
- if (DEBUG)
- printf("Unsupported Windows: %i\n",win);
- return result;
- }
-
- int err = GetDiskFreeSpaceEx(
- lpDirectoryName,
- (PULARGE_INTEGER) & i64FreeBytesAvailableToCaller,
- (PULARGE_INTEGER) & i64TotalNumberOfBytes,
- (PULARGE_INTEGER) & i64TotalNumberOfFreeBytes);
-
- if (err) {
- result = (jlong) i64FreeBytesAvailableToCaller;
- }
-
- return result;
-}
-
-/*
- * Class: org_eclipse_update_configuration_LocalSystemInfo
- * Method: nativeGetLabel
- * Signature: (Ljava/io/File;)Ljava/lang/String;
- */
-JNIEXPORT jstring JNICALL Java_org_eclipse_update_configuration_LocalSystemInfo_nativeGetLabel(
- JNIEnv * jnienv,
- jclass javaClass,
- jobject file) {
-
- // to retrive the String
- jclass cls;
- jmethodID id;
- jobject obj;
-
- // java.io.File.getAbsolutePath()
- const TCHAR * lpDirectoryName;
-
- // obtain the String from the parameter
- cls = jnienv -> GetObjectClass(file);
- id = jnienv -> GetMethodID(cls, "getAbsolutePath", "()Ljava/lang/String;");
- obj = jnienv -> CallObjectMethod(file, id);
- lpDirectoryName = jnienv -> GetStringUTFChars((jstring) obj, 0);
- if (DEBUG)
- printf("Directory: [%s]\n",lpDirectoryName);
-
- //
- jstring result = NULL;
- int floppy;
-
- if (int win = (int)getWindowsVersion()<0 && NOWIN95){
- // windows 95 or other
- if (DEBUG)
- printf("Unsupported Windows: %i\n",win);
- return result;
- }
-
- // Make sure we have a String of the Form: <letter>:
- if (':' == lpDirectoryName[1]) {
- TCHAR driveLetter[4]; // i.e. -> C:\\
- memcpy(driveLetter, lpDirectoryName, 2);
- strcpy(driveLetter + 2, "\\");
- switch (GetDriveType(driveLetter)) {
- case DRIVE_REMOTE :
- // check name of machine and path of remote
- if (DEBUG)
- printf("Remote Drive");
- result = getRemoteNetworkName(driveLetter,jnienv);
- break;
- default :
- if (DEBUG)
- printf("Another Drive at %s", driveLetter);
- result = getLabel(driveLetter,jnienv);
- break;
- }
- }
-
- return result;
-}
-
-/*
- * Class: org_eclipse_update_configuration_LocalSystemInfo
- * Method: nativeGetType
- * Signature: (Ljava/io/File;)I
- */
-JNIEXPORT jint JNICALL Java_org_eclipse_update_configuration_LocalSystemInfo_nativeGetType(
- JNIEnv * jnienv,
- jclass javaClass,
- jobject file) {
-
- // to retrive the String
- jclass cls;
- jmethodID id;
- jobject obj;
-
- // java.io.File.getAbsolutePath()
- const TCHAR * lpDirectoryName;
-
- // obtain the String from the parameter
- cls = jnienv -> GetObjectClass(file);
- id = jnienv -> GetMethodID(cls, "getAbsolutePath", "()Ljava/lang/String;");
- obj = jnienv -> CallObjectMethod(file, id);
- lpDirectoryName = jnienv -> GetStringUTFChars((jstring) obj, 0);
- if (DEBUG)
- printf("Directory: [%s]\n",lpDirectoryName);
-
- int result = org_eclipse_update_configuration_LocalSystemInfo_VOLUME_UNKNOWN;
- if (int win = (int)getWindowsVersion()<0 && NOWIN95){
- // windows 95 or other
- if (DEBUG)
- printf("Unsupported Windows: %i\n",win);
- return result;
- }
-
- // Make sure we have a String of the Form: <letter>:
- if (':' == lpDirectoryName[1]) {
- TCHAR driveLetter[4]; //C:\\
- memcpy(driveLetter, lpDirectoryName, 2);
- strcpy(driveLetter + 2, "\\");
-
- switch (GetDriveType(driveLetter)) {
- case DRIVE_REMOVABLE :
- // check if floppy 3.5, floppy 5.25
- // or other removable device (USB,PCMCIA ...)
- if (DEBUG)
- printf("Removable Device");
- result = getFloppy(driveLetter);
- break;
- case DRIVE_CDROM :
- result = org_eclipse_update_configuration_LocalSystemInfo_VOLUME_CDROM;
- break;
- case DRIVE_FIXED :
- result = org_eclipse_update_configuration_LocalSystemInfo_VOLUME_FIXED;
- break;
- case DRIVE_REMOTE :
- result = org_eclipse_update_configuration_LocalSystemInfo_VOLUME_REMOTE;
- break;
- case DRIVE_NO_ROOT_DIR :
- result = org_eclipse_update_configuration_LocalSystemInfo_VOLUME_INVALID_PATH;
- break;
- case DRIVE_RAMDISK :
- result = org_eclipse_update_configuration_LocalSystemInfo_VOLUME_RAMDISK;
- break;
- case DRIVE_UNKNOWN :
- default :
- result = org_eclipse_update_configuration_LocalSystemInfo_VOLUME_UNKNOWN;
- break;
- }
- } else {
- result = org_eclipse_update_configuration_LocalSystemInfo_VOLUME_INVALID_PATH;
- }
-
- return result;
-}
-
-/*
- * Class: org_eclipse_update_configuration_LocalSystemInfo
- * Method: nativeListMountPoints
- * Signature: ()[Ljava/lang/String;
- */
-JNIEXPORT jobjectArray JNICALL Java_org_eclipse_update_configuration_LocalSystemInfo_nativeListMountPoints(
- JNIEnv * jnienv,
- jclass javaClass) {
-
- //
- DWORD logDrives;
- UINT drive;
- TCHAR driveName[100];
- jobjectArray returnArray;
- int nDrive = 0;
-
- //
- jclass stringClass;
- jobject empty;
- int index = 0;
- jobject str;
-
-
- logDrives = GetLogicalDrives();
- for (drive = 0; drive < 32; drive++) {
- if (logDrives & (1 << drive)) {
- nDrive++;
- }
- }
-
- stringClass = jnienv -> FindClass("java/lang/String");
- empty = jnienv -> NewStringUTF("");
- returnArray = jnienv -> NewObjectArray(nDrive, stringClass, empty);
-
- if (int win = (int)getWindowsVersion()<0 && NOWIN95){
- // windows 95 or other
- if (DEBUG)
- printf("Unsupported Windows: %i\n",win);
- return NULL;
- }
-
- for (drive = 0; drive < 32; drive++) {
- if (logDrives & (1 << drive)) {
- sprintf(driveName, "%c:\\", drive + 'A');
- str = jnienv -> NewStringUTF(driveName);
- jnienv -> SetObjectArrayElement(returnArray, index, str);
- index++;
- }
- }
-
- return returnArray;
-}
-
diff --git a/update/org.eclipse.update.core.win32/src/update.h b/update/org.eclipse.update.core.win32/src/update.h
deleted file mode 100644
index 35673d169..000000000
--- a/update/org.eclipse.update.core.win32/src/update.h
+++ /dev/null
@@ -1,79 +0,0 @@
-/* DO NOT EDIT THIS FILE - it is machine generated */
-
-/*******************************************************************************
- * Copyright (c) 2000, 2002 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-#include <jni.h>
-/* Header for class org_eclipse_update_configuration_LocalSystemInfo */
-
-#ifndef _Included_org_eclipse_update_configuration_LocalSystemInfo
-#define _Included_org_eclipse_update_configuration_LocalSystemInfo
-#ifdef __cplusplus
-extern "C" {
-#endif
-#undef org_eclipse_update_configuration_LocalSystemInfo_SIZE_UNKNOWN
-#define org_eclipse_update_configuration_LocalSystemInfo_SIZE_UNKNOWN -1L
-#undef org_eclipse_update_configuration_LocalSystemInfo_VOLUME_UNKNOWN
-#define org_eclipse_update_configuration_LocalSystemInfo_VOLUME_UNKNOWN -1L
-#undef org_eclipse_update_configuration_LocalSystemInfo_VOLUME_INVALID_PATH
-#define org_eclipse_update_configuration_LocalSystemInfo_VOLUME_INVALID_PATH -2L
-#undef org_eclipse_update_configuration_LocalSystemInfo_VOLUME_REMOVABLE
-#define org_eclipse_update_configuration_LocalSystemInfo_VOLUME_REMOVABLE 1L
-#undef org_eclipse_update_configuration_LocalSystemInfo_VOLUME_FIXED
-#define org_eclipse_update_configuration_LocalSystemInfo_VOLUME_FIXED 2L
-#undef org_eclipse_update_configuration_LocalSystemInfo_VOLUME_REMOTE
-#define org_eclipse_update_configuration_LocalSystemInfo_VOLUME_REMOTE 3L
-#undef org_eclipse_update_configuration_LocalSystemInfo_VOLUME_CDROM
-#define org_eclipse_update_configuration_LocalSystemInfo_VOLUME_CDROM 4L
-#undef org_eclipse_update_configuration_LocalSystemInfo_VOLUME_RAMDISK
-#define org_eclipse_update_configuration_LocalSystemInfo_VOLUME_RAMDISK 5L
-#undef org_eclipse_update_configuration_LocalSystemInfo_VOLUME_FLOPPY_5
-#define org_eclipse_update_configuration_LocalSystemInfo_VOLUME_FLOPPY_5 6L
-#undef org_eclipse_update_configuration_LocalSystemInfo_VOLUME_FLOPPY_3
-#define org_eclipse_update_configuration_LocalSystemInfo_VOLUME_FLOPPY_3 7L
-/* Inaccessible static: listeners */
-/* Inaccessible static: hasNatives */
-/*
- * Class: org_eclipse_update_configuration_LocalSystemInfo
- * Method: nativeGetFreeSpace
- * Signature: (Ljava/io/File;)J
- */
-JNIEXPORT jlong JNICALL Java_org_eclipse_update_configuration_LocalSystemInfo_nativeGetFreeSpace
- (JNIEnv *, jclass, jobject);
-
-/*
- * Class: org_eclipse_update_configuration_LocalSystemInfo
- * Method: nativeGetLabel
- * Signature: (Ljava/io/File;)Ljava/lang/String;
- */
-JNIEXPORT jstring JNICALL Java_org_eclipse_update_configuration_LocalSystemInfo_nativeGetLabel
- (JNIEnv *, jclass, jobject);
-
-/*
- * Class: org_eclipse_update_configuration_LocalSystemInfo
- * Method: nativeGetType
- * Signature: (Ljava/io/File;)I
- */
-JNIEXPORT jint JNICALL Java_org_eclipse_update_configuration_LocalSystemInfo_nativeGetType
- (JNIEnv *, jclass, jobject);
-
-/*
- * Class: org_eclipse_update_configuration_LocalSystemInfo
- * Method: nativeListMountPoints
- * Signature: ()[Ljava/lang/String;
- */
-JNIEXPORT jobjectArray JNICALL Java_org_eclipse_update_configuration_LocalSystemInfo_nativeListMountPoints
- (JNIEnv *, jclass);
-
-#ifdef __cplusplus
-}
-
-#endif
-#endif
diff --git a/update/org.eclipse.update.core/.classpath b/update/org.eclipse.update.core/.classpath
deleted file mode 100644
index 484824984..000000000
--- a/update/org.eclipse.update.core/.classpath
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
- <classpathentry kind="src" path="src"/>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/update/org.eclipse.update.core/.cvsignore b/update/org.eclipse.update.core/.cvsignore
deleted file mode 100644
index c5e82d745..000000000
--- a/update/org.eclipse.update.core/.cvsignore
+++ /dev/null
@@ -1 +0,0 @@
-bin \ No newline at end of file
diff --git a/update/org.eclipse.update.core/.options b/update/org.eclipse.update.core/.options
deleted file mode 100644
index 7bf619710..000000000
--- a/update/org.eclipse.update.core/.options
+++ /dev/null
@@ -1,9 +0,0 @@
-org.eclipse.update.core/debug=true
-org.eclipse.update.core/debug/warning=false
-org.eclipse.update.core/debug/parsing=false
-org.eclipse.update.core/debug/install=false
-org.eclipse.update.core/debug/configuration=false
-org.eclipse.update.core/debug/type=false
-org.eclipse.update.core/debug/web=false
-org.eclipse.update.core/debug/installhandler=false
-org.eclipse.update.core/debug/reconciler=false
diff --git a/update/org.eclipse.update.core/.project b/update/org.eclipse.update.core/.project
deleted file mode 100644
index 4a0c6a274..000000000
--- a/update/org.eclipse.update.core/.project
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.update.core</name>
- <comment></comment>
- <projects>
- <project>org.eclipse.core.boot</project>
- <project>org.eclipse.core.runtime</project>
- <project>org.eclipse.update.configurator</project>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.jdt.core.javabuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.ManifestBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.SchemaBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.eclipse.jdt.core.javanature</nature>
- <nature>org.eclipse.pde.PluginNature</nature>
- </natures>
-</projectDescription>
diff --git a/update/org.eclipse.update.core/Scrapbook.jpage b/update/org.eclipse.update.core/Scrapbook.jpage
deleted file mode 100644
index c2633aea0..000000000
--- a/update/org.eclipse.update.core/Scrapbook.jpage
+++ /dev/null
@@ -1,431 +0,0 @@
- java.util.Enumeration enum = System.getProperties().keys();
- String key = null;
- while (enum.hasMoreElements()){
- key = (String)enum.nextElement();
- System.out.print(key);
- for (int i =0;i<(30-key.length());i++)System.out.print(" ");
- System.out.println("->"+System.getProperty(key));
- }
-
-
-new java.net.URL("file://C:/temp/org.eclipse.update.core.feature1_1.0.0/org.eclipse.update.core.feature1.plugin1_1.1.1.jar").openStream()
-
-(new java.io.File("C:\\chris chris\hello\\")).mkdirs();
-
-java.net.URL a = new java.net.URL("http","www.oti.com","/feature/blah.jar");
-java.net.URL b = new java.net.URL("jar",null,a.toExternalForm()+"!/hello.txt");
-b
-
-new java.net.URL("file",null,System.getProperty("java.io.tmpdir"));
-new java.net.URL("file",null,System.getProperty("user.home"));
-
-String tempDir = "c:\\TEMP\\features2.jar";
-java.net.URL TEMP_SITE = new java.net.URL("file",null,tempDir);
-java.net.URL file = new java.net.URL("jar",null,TEMP_SITE.toExternalForm()+"!/feature.xml");
-file.openStream();
-file
-
-java.io.File f = new java.io.File("c:\\temp\\xtf\\file.jar");
-f.mkdirs()
-
-java.util.Locale.getDefault()
-java.util.ResourceBundle
-
-java.net.URL url = new java.net.URL("file",null,"C:\\path"+java.io.File.separator);
-url.getPath().endsWith("/");
-url
-
-java.net.URL url = new java.net.URL("http://machine:8080/path space/file.abc#hello");
-java.net.URL url2 = new java.net.URL(url,"/ ");
-url2.getPath()
-
-java.lang.ClassLoader l = new java.net.URLClassLoader(new java.net.URL[] {new java.net.URL("file",null,"c:\\oti\\wsw205\\eclipse\\install\\features\\org.eclipse.help.feature_1.0.4/") }, null);
-java.util.ResourceBundle bundle = java.util.ResourceBundle.getBundle("feature", java.util.Locale.getDefault(), l);
-bundle
-
-String[] ss = {"a", "b"};
-java.util.List list = new java.util.ArrayList(0);
-list.addAll(java.util.Arrays.asList(ss));
-list.add("c");
-list.size();
-
-java.util.List list = new java.util.ArrayList(0);
-list.add("1");
-list.add("2");
-list.add("3");
-list.add("4");
-list.add("5");
-list.add("6");
-list.add("7");
-while (list.size()>5){
- list.remove(0);
-}
-list.get(0)
-
-
-org.eclipse.update.internal.security.KeyStores k = new org.eclipse.update.internal.security.KeyStores();
-while (k.hasNext()){
- org.eclipse.update.internal.security.KeystoreHandle handle = (org.eclipse.update.internal.security.KeystoreHandle) k.next();
- System.out.println("KeyStore:"+handle.getLocation()+":"+handle.getType());
-}
-
-int i = (13/3);
-i
-
-*****************************************
-OLD Feature Code
-
-
- /**
- */
- private void downloadArchivesLocally(ISite tempSite, String[] archiveIDToInstall, IProgressMonitor monitor) throws CoreException, IOException {
-
- URL sourceURL;
- String newFile;
- URL newURL;
-
- if (monitor != null) {
- monitor.beginTask("Download archives bundles to Temporary Space", archiveIDToInstall.length);
- }
- for (int i = 0; i < archiveIDToInstall.length; i++) {
-
- // transform the id by asking the site to map them to real URL inside the SITE
- if (getSite() != null) {
- sourceURL = getSite().getSiteContentProvider().getArchivesReferences(archiveIDToInstall[i]);
- if (monitor != null) {
- monitor.subTask("..." + archiveIDToInstall[i]);
- }
- // the name of the file in the temp directory
- // should be the regular plugins/pluginID_ver as the Temp site is OUR site
- newFile = Site.DEFAULT_PLUGIN_PATH + archiveIDToInstall[i];
- newURL = UpdateManagerUtils.resolveAsLocal(sourceURL, newFile, monitor);
-
- // transfer the possible mapping to the temp site
- ((Site) tempSite).addArchive(new URLEntry(archiveIDToInstall[i], newURL));
- if (monitor != null) {
- monitor.worked(1);
- if (monitor.isCanceled()) {
- throw CANCEL_EXCEPTION;
- }
- }
- }
- }
-
- // the site of this feature now becomes the TEMP directory
- // FIXME: make sure there is no other issue
- // like asking for stuff that hasn't been copied
- // or reusing this feature
- // of having an un-manageable temp site
-
- this.setSite(tempSite);
-
- }
-
- /**
- */
- private void downloadDataLocally(IFeature targetFeature, INonPluginEntry[] dataToInstall, IProgressMonitor monitor) throws CoreException, IOException {
-
- URL sourceURL;
- // any other data
- INonPluginEntry[] entries = getNonPluginEntries();
- if (entries != null) {
- if (monitor != null) {
- monitor.beginTask("Installing Other Data information", dataToInstall.length);
- if (monitor.isCanceled()) {
- throw CANCEL_EXCEPTION;
- }
- }
-
- for (int j = 0; j < entries.length; j++) {
- String name = dataToInstall[j].getIdentifier();
- if (monitor != null) {
- monitor.subTask("..." + name);
- }
-
- // the id is URL format with "/"
- String dataEntryId = Site.DEFAULT_FEATURE_PATH + getIdentifier().toString() + "/" + name;
- // transform the id by asking the site to map them to real URL inside the SITE
- if (getSite() != null) {
- sourceURL = getSite().getSiteContentProvider().getArchivesReferences(dataEntryId);
- ((Site) targetFeature.getSite()).storeFeatureInfo(getIdentifier(), name, sourceURL.openStream());
- if (monitor != null) {
- monitor.worked(1);
- if (monitor.isCanceled()) {
- throw CANCEL_EXCEPTION;
- }
- }
- }// getSite==null
- }
- }
- }
-
-
- /**
- * Method install.
- * @param targetFeature
- * @param monitor
- * @throws CoreException
- */
- public void old_install(IFeature targetFeature, IProgressMonitor monitor) throws CoreException {
-
- IPluginEntry[] sourceFeaturePluginEntries = getPluginEntries();
- IPluginEntry[] targetSitePluginEntries = targetFeature.getSite().getPluginEntries();
- Site tempSite = (Site) SiteManager.getTempSite();
-
- // determine list of plugins to install
- // find the intersection between the two arrays of IPluginEntry...
- // The one teh site contains and teh one the feature contains
- IPluginEntry[] pluginsToInstall = intersection(sourceFeaturePluginEntries, targetSitePluginEntries);
-
- // private abstract - Determine list of content references id /archives id /bundles id that
- // map the list of plugins to install
- String[] archiveIDToInstall = getContentReferenceToInstall(pluginsToInstall);
-
- try {
- // download and install data bundles
- // before we set the site of teh feature to the TEMP site
- INonPluginEntry[] dataEntries = getNonPluginEntries();
- if (dataEntries.length > 0) {
- downloadDataLocally(targetFeature, dataEntries, monitor);
- }
-
- // optmization, may be private to implementation
- // copy *blobs/content references/archives/bundles* in TEMP space
- if (((Site) getSite()).optimize()) {
- if (archiveIDToInstall != null) {
- downloadArchivesLocally(tempSite, archiveIDToInstall, monitor);
- }
- }
-
- // obtain the list of *Streamable Storage Unit*
- // from the archive
- if (monitor != null) {
- int total = pluginsToInstall == null ? 1 : pluginsToInstall.length + 1;
- monitor.beginTask("Install feature " + getLabel(), total);
- }
- if (pluginsToInstall != null) {
- InputStream inStream = null;
- for (int i = 0; i < pluginsToInstall.length; i++) {
- if (monitor != null) {
- monitor.subTask("Installing plug-in: " + pluginsToInstall[i]);
- if (monitor.isCanceled()) {
- throw CANCEL_EXCEPTION;
- }
- }
-
- open(pluginsToInstall[i]);
- String[] names = getStorageUnitNames(pluginsToInstall[i]);
- if (names != null) {
- for (int j = 0; j < names.length; j++) {
- if ((inStream = getInputStreamFor(pluginsToInstall[i], names[j])) != null)
- targetFeature.store(pluginsToInstall[i], names[j], inStream);
- }
- }
- close(pluginsToInstall[i]);
- if (monitor != null) {
- monitor.worked(1);
- if (monitor.isCanceled()) {
- throw CANCEL_EXCEPTION;
- }
- }
-
- }
- }
-
- // install the Feature info
- InputStream inStream = null;
- String[] names = getStorageUnitNames(this);
- if (names != null) {
- openFeature();
- if (monitor != null) {
- monitor.subTask("Installing Feature information");
- if (monitor.isCanceled()) {
- throw CANCEL_EXCEPTION;
- }
- }
-
- for (int j = 0; j < names.length; j++) {
- if ((inStream = getInputStreamFor(this, names[j])) != null)
- ((Site) targetFeature.getSite()).storeFeatureInfo(getIdentifier(), names[j], inStream);
- }
- closeFeature();
- if (monitor != null) {
- monitor.worked(1);
- if (monitor.isCanceled()) {
- throw CANCEL_EXCEPTION;
- }
- }
-
- }
-
- } catch (IOException e) {
- String id = UpdateManagerPlugin.getPlugin().getDescriptor().getUniqueIdentifier();
- IStatus status = new Status(IStatus.ERROR, id, IStatus.OK, "Error during Install", e);
- throw new CoreException(status);
- } finally {
- //do not clean up TEMP drive
- // as other feature may be there... clean up when exiting the plugin
- }
- }
-
-
- /**
- * @see IPluginContainer#store(IPluginEntry, String, InputStream)
- */
- public void store(IPluginEntry pluginEntry, String contentKey, InputStream inStream) throws CoreException {
- // check if pluginEntry already exists before passing to the site
- // anything else ?
- boolean found = false;
- int i = 0;
- IPluginEntry[] entries = getPluginEntries();
- while (i < entries.length && !found) {
- if (entries[i].equals(pluginEntry)) {
- found = true;
- }
- i++;
- }
- if (!found) {
- String id = UpdateManagerPlugin.getPlugin().getDescriptor().getUniqueIdentifier();
- IStatus status = new Status(IStatus.ERROR, id, IStatus.OK, "The plugin:" + pluginEntry.getIdentifier().toString() + " is not part of the plugins of the feature:" + this.getIdentifier().toString(), null);
- throw new CoreException(status);
- }
- getSite().store(pluginEntry, contentKey, inStream);
- }
-
- /**
- * perform pre processing before opening a plugin archive
- * @param entry the plugin about to be opened
- */
- protected void open(IPluginEntry entry) {
- };
-
- /**
- * perform post processing to close a plugin archive
- * @param entry the plugin about to be closed
- */
- protected void close(IPluginEntry entry) throws IOException {
- };
-
- /**
- * perform pre processing before opening the feature archive
- */
- protected void openFeature() {
- };
-
- /**
- * perform post processing to close a feature archive
- */
- public void closeFeature() throws IOException {
- };
-
-
- /**
- * return the list of FILE to be transfered for a Plugin
- */
- protected abstract String[] getStorageUnitNames(IPluginEntry pluginEntry) throws CoreException;
-
- /**
- * return the list of FILE to be transfered from within the Feature
- */
- protected abstract String[] getStorageUnitNames(IFeature feature) throws CoreException;
-
- /**
- * return the Stream of the FILE to be transfered for a Plugin
- */
- protected abstract InputStream getInputStreamFor(IPluginEntry pluginEntry, String name) throws CoreException;
-
- /**
- * return the Stream of FILE to be transfered from within the Feature
- */
- protected abstract InputStream getInputStreamFor(IFeature feature, String name) throws IOException, CoreException;
-
- /**
- * returns the list of archive to transfer/install
- * in order to install the list of plugins
- *
- * @param pluginsToInstall list of plugin to install
- */
- protected abstract String[] getContentReferenceToInstall(IPluginEntry[] pluginsToInstall);
-
-
- /**
- * remove myself...
- */
- public void old_remove(IProgressMonitor monitor) throws CoreException {
-
- // remove the feature and the plugins if they are not used and not activated
-
- // get the plugins from the feature
- IPluginEntry[] pluginsToRemove = ((SiteLocal) SiteManager.getLocalSite()).getDeltaPluginEntries(this);
-
- try {
-
- // obtain the list of *Streamable Storage Unit*
- // from the archive
- if (monitor != null) {
- int total = pluginsToRemove == null ? 1 : pluginsToRemove.length + 1;
- monitor.beginTask("Uninstall feature " + getLabel(), total);
- }
- if (pluginsToRemove != null) {
- for (int i = 0; i < pluginsToRemove.length; i++) {
- if (monitor != null) {
- monitor.subTask("Removing plug-in: " + pluginsToRemove[i]);
- if (monitor.isCanceled()) {
- throw CANCEL_EXCEPTION;
- }
- }
-
- remove(pluginsToRemove[i]);
-
- if (monitor != null) {
- monitor.worked(1);
- if (monitor.isCanceled()) {
- throw CANCEL_EXCEPTION;
- }
- }
-
- }
- }
-
- // remove the Feature info
- String[] names = getStorageUnitNames(this);
- if (names != null) {
- if (monitor != null) {
- monitor.subTask("Removing Feature information");
- if (monitor.isCanceled()) {
- throw CANCEL_EXCEPTION;
- }
- }
-
- ((Site) this.getSite()).removeFeatureInfo(getIdentifier());
-
- closeFeature();
- if (monitor != null) {
- monitor.worked(1);
- if (monitor.isCanceled()) {
- throw CANCEL_EXCEPTION;
- }
- }
-
- }
-
- } catch (IOException e) {
- String id = UpdateManagerPlugin.getPlugin().getDescriptor().getUniqueIdentifier();
- IStatus status = new Status(IStatus.ERROR, id, IStatus.OK, "Error during Uninstall", e);
- throw new CoreException(status);
- }
- }
-
- System.getProperty("java.io.tmpdir")(java.lang.String) /tmp
-
- true^false
- true^true
-
-
-org.eclipse.core.runtime.IPath p1= (new org.eclipse.core.runtime.Path("/path1/path2/*.txt"));
-org.eclipse.core.runtime.IPath p2= (new org.eclipse.core.runtime.Path("/path1/path2/a.txt"));
-p1.equals(p2);
-
-
-org.eclipse.update.internal.core.URLEncoder.encode(new java.net.URL("http://www.ourwebsite.com/servlet/update?jar=somefeaturejarfile"));(java.net.URL) http://www.ourwebsite.com/servlet/update?jar=somefeaturejarfile
-
diff --git a/update/org.eclipse.update.core/about.html b/update/org.eclipse.update.core/about.html
deleted file mode 100644
index 9db411aab..000000000
--- a/update/org.eclipse.update.core/about.html
+++ /dev/null
@@ -1,30 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<title>About</title>
-<meta http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<p>20th June, 2002</p>
-<h3>License</h3>
-<p>Eclipse.org makes available all content in this plug-in (&quot;Content&quot;). Unless otherwise indicated below, the Content is provided to you under the terms and conditions of the
-Common Public License Version 1.0 (&quot;CPL&quot;). A copy of the CPL is available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>.
-For purposes of the CPL, &quot;Program&quot; will mean the Content.</p>
-
-<h3>Contributions</h3>
-
-<p>If this Content is licensed to you under the terms and conditions of the CPL, any Contributions, as defined in the CPL, uploaded, submitted, or otherwise
-made available to Eclipse.org, members of Eclipse.org and/or the host of Eclipse.org web site, by you that relate to such
-Content are provided under the terms and conditions of the CPL and can be made available to others under the terms of the CPL.</p>
-
-<p>If this Content is licensed to you under license terms and conditions other than the CPL (&quot;Other License&quot;), any modifications, enhancements and/or
-other code and/or documentation (&quot;Modifications&quot;) uploaded, submitted, or otherwise made available to Eclipse.org, members of Eclipse.org and/or the
-host of Eclipse.org, by you that relate to such Content are provided under terms and conditions of the Other License and can be made available
-to others under the terms of the Other License. In addition, with regard to Modifications for which you are the copyright holder, you are also
-providing the Modifications under the terms and conditions of the CPL and such Modifications can be made available to others under the terms of
-the CPL.</p>
-
-</body>
-</html> \ No newline at end of file
diff --git a/update/org.eclipse.update.core/build.properties b/update/org.eclipse.update.core/build.properties
deleted file mode 100644
index 8ee535c54..000000000
--- a/update/org.eclipse.update.core/build.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-###############################################################################
-# Copyright (c) 2000, 2003 IBM Corporation and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Common Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/cpl-v10.html
-#
-# Contributors:
-# IBM Corporation - initial API and implementation
-###############################################################################
-source.updatecore.jar = src/
-bin.includes = plugin.xml,\
- plugin.properties,\
- *.jar,\
- about.html,\
- .options,\
- os/
-src.includes = about.html,\
- schema/
diff --git a/update/org.eclipse.update.core/plugin.properties b/update/org.eclipse.update.core/plugin.properties
deleted file mode 100644
index ee432efb8..000000000
--- a/update/org.eclipse.update.core/plugin.properties
+++ /dev/null
@@ -1,16 +0,0 @@
-###############################################################################
-# Copyright (c) 2000, 2003 IBM Corporation and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Common Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/cpl-v10.html
-#
-# Contributors:
-# IBM Corporation - initial API and implementation
-###############################################################################
-pluginName= Install/Update Core
-providerName= Eclipse.org
-fragmentNameWin= Install/Update Core for Windows
-fragmentNameLinux= Install/Update Core for Linux
-
-
diff --git a/update/org.eclipse.update.core/plugin.xml b/update/org.eclipse.update.core/plugin.xml
deleted file mode 100644
index 198f3e34b..000000000
--- a/update/org.eclipse.update.core/plugin.xml
+++ /dev/null
@@ -1,86 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.0"?>
-<plugin
- id="org.eclipse.update.core"
- name="%pluginName"
- version="3.0.0"
- provider-name="%providerName"
- class="org.eclipse.update.internal.core.UpdateCore">
-
- <runtime>
- <library name="updatecore.jar">
- <export name="*"/>
- <packages prefixes="org.eclipse.update"/>
- </library>
- </runtime>
- <requires>
- <import plugin="org.eclipse.core.runtime"/>
- <import plugin="org.eclipse.update.configurator"/>
- </requires>
-
-
- <extension-point id="featureTypes" name="Install/Update Concrete Feature Type Implementation Factory" schema="schema/featureTypes.exsd"/>
- <extension-point id="siteTypes" name="Install/Update Concrete Site Type Implementation Factory" schema="schema/siteTypes.exsd"/>
- <extension-point id="installHandlers" name="Install/Update Global Install Handlers" schema="schema/installHandlers.exsd"/>
- <!-- The deltaHandler extension point is deprecated. Do not use it -->
- <extension-point id="deltaHandler" name="Install/Update Delta Handler"/>
-
- <extension
- id="preferenceInitializer"
- point="org.eclipse.core.runtime.preferences">
- <initializer class="org.eclipse.update.internal.core.UpdatePreferencesInitializer"/>
- </extension>
-
- <extension
- id="packaged"
- point="org.eclipse.update.core.featureTypes">
- <feature-factory
- class="org.eclipse.update.internal.core.FeaturePackagedFactory">
- </feature-factory>
- </extension>
- <extension
- id="installed"
- point="org.eclipse.update.core.featureTypes">
- <feature-factory
- class="org.eclipse.update.internal.core.FeatureExecutableFactory">
- </feature-factory>
- </extension>
- <extension
- id="http"
- point="org.eclipse.update.core.siteTypes">
- <site-factory
- class="org.eclipse.update.internal.core.SiteURLFactory">
- </site-factory>
- </extension>
- <extension
- id="file"
- point="org.eclipse.update.core.siteTypes">
- <site-factory
- class="org.eclipse.update.internal.core.SiteFileFactory">
- </site-factory>
- </extension>
- <extension
- id="DefaultInstallHandler"
- point="org.eclipse.update.core.installHandlers">
- <install-handler
- class="org.eclipse.update.internal.core.DefaultInstallHandler">
- </install-handler>
- </extension>
- <extension
- id="DeltaInstallHandler"
- point="org.eclipse.update.core.installHandlers">
- <install-handler
- class="org.eclipse.update.internal.core.DeltaInstallHandler">
- </install-handler>
- </extension>
- <extension
- id="standaloneUpdate"
- point="org.eclipse.core.runtime.applications">
- <application>
- <run
- class="org.eclipse.update.standalone.StandaloneUpdateApplication">
- </run>
- </application>
- </extension>
-
-</plugin>
diff --git a/update/org.eclipse.update.core/preferences.ini b/update/org.eclipse.update.core/preferences.ini
deleted file mode 100644
index 7936e7fcd..000000000
--- a/update/org.eclipse.update.core/preferences.ini
+++ /dev/null
@@ -1,8 +0,0 @@
-# The port number on which the sever listens for http requests.
-# If the port is 0 and arbitrary port is picked by the system.
-
-# Defines the policy url that contains directives for redirecting
-# updates to different update sites.
-#updatePolicyURL=
-
-
diff --git a/update/org.eclipse.update.core/schema/featureTypes.exsd b/update/org.eclipse.update.core/schema/featureTypes.exsd
deleted file mode 100644
index 7129a6aa1..000000000
--- a/update/org.eclipse.update.core/schema/featureTypes.exsd
+++ /dev/null
@@ -1,119 +0,0 @@
-<?xml version='1.0' encoding='UTF-8'?>
-<!-- Schema file written by PDE -->
-<schema targetNamespace="org.eclipse.update.core">
-<annotation>
- <appInfo>
- <meta.schema plugin="org.eclipse.update.core" id="featureTypes" name="Feature Type Factory"/>
- </appInfo>
- <documentation>
- The platform update mechanism supports pluggable feature type
-implementations. A new feature type can be registered in order
-to support
-alternate packaging and verification schemes.
-&lt;p&gt;
-The &lt;code&gt;featureTypes&lt;/code&gt;
-extension point allows alternate feature implementations to be
-registered using a symbolic type identifier. Whenever the
-type is referenced using this identifier, the supplied factory
-is used to create the correct concrete feature implementation.
-&lt;/p&gt;
- </documentation>
- </annotation>
-
- <element name="extension">
- <complexType>
- <sequence>
- <element ref="feature-factory" minOccurs="1" maxOccurs="unbounded"/>
- </sequence>
- <attribute name="point" type="string" use="required">
- <annotation>
- <documentation>
- must be specified as &lt;b&gt;org.eclipse.update.core.featureTypes&lt;/b&gt;
- </documentation>
- </annotation>
- </attribute>
- <attribute name="id" type="string">
- <annotation>
- <documentation>
- must be specified. Identifies the new feature type
- </documentation>
- </annotation>
- </attribute>
- <attribute name="name" type="string">
- <annotation>
- <documentation>
- optional displayable label for the new feature type
- </documentation>
- </annotation>
- </attribute>
- </complexType>
- </element>
-
- <element name="feature-factory">
- <complexType>
- <attribute name="class" type="string" use="required">
- <annotation>
- <documentation>
- fully qualified name of the factory class for the identified feature type
- </documentation>
- <appInfo>
- <meta.attribute kind="java" basedOn="org.eclipse.update.configuration.IInstallDeltaHandler"/>
- </appInfo>
- </annotation>
- </attribute>
- </complexType>
- </element>
-
- <annotation>
- <appInfo>
- <meta.section type="examples"/>
- </appInfo>
- <documentation>
- The following is an example of new feature type registration:
-&lt;p&gt;
-&lt;pre&gt;
- &lt;extension
- id=&quot;custom&quot;
- point=&quot;org.eclipse.update.core.featureTypes&quot;
- name=&quot;Custom packaged feature&quot;&gt;
- &lt;feature-factory
- class=&quot;com.xyz.update.CustomFeatureFactory&quot;&gt;
- &lt;/feature-factory&gt;
- &lt;/extension&gt;
-&lt;/pre&gt;
-&lt;/p&gt;
- </documentation>
- </annotation>
-
- <annotation>
- <appInfo>
- <meta.section type="apiInfo"/>
- </appInfo>
- <documentation>
- Registered factory classes must implement
-&lt;code&gt;&lt;b&gt;org.eclipse.update.core.IFeatureFactory&lt;/b&gt;&lt;/code&gt;
- </documentation>
- </annotation>
-
- <annotation>
- <appInfo>
- <meta.section type="implementation"/>
- </appInfo>
- <documentation>
- The platform supplies two standard implementations of feature
-types. One representing the default packaged feature type, and
-the other representing an installed feature type.
- </documentation>
- </annotation>
-
- <annotation>
- <appInfo>
- <meta.section type="copyright"/>
- </appInfo>
- <documentation>
- Copyright (c) 2002, 2003 IBM Corporation and others.
-All rights reserved. This program and the accompanying materials are made available under the terms of the Common Public License v1.0 which accompanies this distribution, and is available at &lt;a href=&quot;http://www.eclipse.org/legal/cpl-v10.html&quot;&gt;http://www.eclipse.org/legal/cpl-v10.html&lt;/a&gt;.
- </documentation>
- </annotation>
-
-</schema>
diff --git a/update/org.eclipse.update.core/schema/installHandlers.exsd b/update/org.eclipse.update.core/schema/installHandlers.exsd
deleted file mode 100644
index 28dd8328b..000000000
--- a/update/org.eclipse.update.core/schema/installHandlers.exsd
+++ /dev/null
@@ -1,110 +0,0 @@
-<?xml version='1.0' encoding='UTF-8'?>
-<!-- Schema file written by PDE -->
-<schema targetNamespace="org.eclipse.update.core">
-<annotation>
- <appInfo>
- <meta.schema plugin="org.eclipse.update.core" id="installHandlers" name="Global Install Handlers"/>
- </appInfo>
- <documentation>
- Extension point for registering global install handlers. Global
-install handlers can be referenced by features
-(using the &lt;code&gt;&amp;lt;feature&amp;gt; &amp;lt;install-handler&amp;gt;&lt;/code&gt;
-tags) without having to include a copy of the handler code as
-part of the downloadable feature.
- </documentation>
- </annotation>
-
- <element name="extension">
- <complexType>
- <sequence>
- <element ref="install-handler" minOccurs="1" maxOccurs="unbounded"/>
- </sequence>
- <attribute name="point" type="string" use="required">
- <annotation>
- <documentation>
- must be specified as &lt;b&gt;org.eclipse.update.core.installHandlers&lt;/b&gt;
- </documentation>
- </annotation>
- </attribute>
- <attribute name="id" type="string">
- <annotation>
- <documentation>
- must be specified. Identifies the new install handler
- </documentation>
- </annotation>
- </attribute>
- <attribute name="name" type="string">
- <annotation>
- <documentation>
- optional displayable label for the new install handler
- </documentation>
- </annotation>
- </attribute>
- </complexType>
- </element>
-
- <element name="install-handler">
- <complexType>
- <attribute name="class" type="string" use="required">
- <annotation>
- <documentation>
- fully qualified name of the handler implementation class for the identified
-install handler
- </documentation>
- </annotation>
- </attribute>
- </complexType>
- </element>
-
- <annotation>
- <appInfo>
- <meta.section type="examples"/>
- </appInfo>
- <documentation>
- The following is an example of new global install handler registration:
-&lt;p&gt;
-&lt;pre&gt;
- &lt;extension
- id=&quot;custom&quot;
- point=&quot;org.eclipse.update.core.installHandlers&quot;
- name=&quot;Custom install handler&quot;&gt;
- &lt;install-handler
- class=&quot;com.xyz.update.CustomInstallHandler&quot;&gt;
- &lt;/install-handler&gt;
- &lt;/extension&gt;
-&lt;/pre&gt;
-&lt;/p&gt;
- </documentation>
- </annotation>
-
- <annotation>
- <appInfo>
- <meta.section type="apiInfo"/>
- </appInfo>
- <documentation>
- Registered install handler classes must implement
-&lt;code&gt;org.eclipse.update.core.IInstallHandler&lt;/code&gt; interface.
-Implementers should extend base class &lt;code&gt;org.eclipse.update.core.BaseInstallHandler&lt;/code&gt;.
- </documentation>
- </annotation>
-
- <annotation>
- <appInfo>
- <meta.section type="implementation"/>
- </appInfo>
- <documentation>
- The platform supplies a simple install handler that is registered as &lt;code&gt;org.eclipse.update.core.DefaultInstallHandler&lt;/code&gt;. If used, it will copy any non-plug-in data entries provided with the feature into the feature installation directory.
- </documentation>
- </annotation>
-
- <annotation>
- <appInfo>
- <meta.section type="copyright"/>
- </appInfo>
- <documentation>
- Copyright (c) 2002, 2003 IBM Corporation and others.
-All rights reserved. This program and the accompanying materials are made available under the terms of the Common Public License v1.0 which accompanies this distribution, and is available at &lt;a href=&quot;http://www.eclipse.org/legal/cpl-v10.html&quot;&gt;http://www.eclipse.org/legal/cpl-v10.html&lt;/a&gt;.
- </documentation>
- </annotation>
-
-</schema>
diff --git a/update/org.eclipse.update.core/schema/siteTypes.exsd b/update/org.eclipse.update.core/schema/siteTypes.exsd
deleted file mode 100644
index 5748954fc..000000000
--- a/update/org.eclipse.update.core/schema/siteTypes.exsd
+++ /dev/null
@@ -1,116 +0,0 @@
-<?xml version='1.0' encoding='UTF-8'?>
-<!-- Schema file written by PDE -->
-<schema targetNamespace="org.eclipse.update.core">
-<annotation>
- <appInfo>
- <meta.schema plugin="org.eclipse.update.core" id="siteTypes" name="Site Type Factory"/>
- </appInfo>
- <documentation>
- The platform update mechanism supports pluggable site type
-implementations. A new site type can be registered in order
-to support alternate site layout schemes.
-&lt;p&gt;
-The &lt;code&gt;siteTypes&lt;/code&gt;
-extension point allows alternate site implementations to be
-registered using a symbolic type identifier. Whenever the
-type is referenced using this identifier, the supplied factory
-is used to create the correct concrete site implementation.
-&lt;/p&gt;
- </documentation>
- </annotation>
-
- <element name="extension">
- <complexType>
- <sequence>
- <element ref="site-factory" minOccurs="1" maxOccurs="unbounded"/>
- </sequence>
- <attribute name="point" type="string" use="required">
- <annotation>
- <documentation>
- must be specified as &lt;b&gt;org.eclipse.update.core.siteTypes&lt;/b&gt;
- </documentation>
- </annotation>
- </attribute>
- <attribute name="id" type="string">
- <annotation>
- <documentation>
- must be specified. Identifies the new site type
- </documentation>
- </annotation>
- </attribute>
- <attribute name="name" type="string">
- <annotation>
- <documentation>
- optional displayable label for the new site type
- </documentation>
- </annotation>
- </attribute>
- </complexType>
- </element>
-
- <element name="site-factory">
- <complexType>
- <attribute name="class" type="string" use="required">
- <annotation>
- <documentation>
- fully qualified name of the factory class for the identified
-site type
- </documentation>
- </annotation>
- </attribute>
- </complexType>
- </element>
-
- <annotation>
- <appInfo>
- <meta.section type="examples"/>
- </appInfo>
- <documentation>
- The following is an example of new site type registration.
-&lt;p&gt;
-&lt;pre&gt;
- &lt;extension
- id=&quot;custom&quot;
- point=&quot;org.eclipse.update.core.siteTypes&quot;
- name=&quot;Custom site&quot;&gt;
- &lt;site-factory
- class=&quot;com.xyz.update.CustomSiteFactory&quot;&gt;
- &lt;/site-factory&gt;
- &lt;/extension&gt;
-&lt;/pre&gt;
-&lt;/p&gt;
- </documentation>
- </annotation>
-
- <annotation>
- <appInfo>
- <meta.section type="apiInfo"/>
- </appInfo>
- <documentation>
- Registered factory classes must implement
-&lt;code&gt;&lt;b&gt;org.eclipse.update.core.ISiteFactory&lt;/b&gt;&lt;/code&gt;
- </documentation>
- </annotation>
-
- <annotation>
- <appInfo>
- <meta.section type="implementation"/>
- </appInfo>
- <documentation>
- The platform supplies two standard implementations of site
-types. One representing the default update server type, and
-the other representing the local file system site.
- </documentation>
- </annotation>
-
- <annotation>
- <appInfo>
- <meta.section type="copyright"/>
- </appInfo>
- <documentation>
- Copyright (c) 2002, 2003 IBM Corporation and others.
-All rights reserved. This program and the accompanying materials are made available under the terms of the Common Public License v1.0 which accompanies this distribution, and is available at &lt;a href=&quot;http://www.eclipse.org/legal/cpl-v10.html&quot;&gt;http://www.eclipse.org/legal/cpl-v10.html&lt;/a&gt;.
- </documentation>
- </annotation>
-
-</schema>
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IActivity.java b/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IActivity.java
deleted file mode 100644
index 103152f7a..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IActivity.java
+++ /dev/null
@@ -1,259 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.configuration;
-
-import java.util.*;
-
-import org.eclipse.core.runtime.*;
-
-/**
- * Install activity.
- * Represents a record of an installation action performed
- * on a particular installation configuration.
- * <p>
- * This interface is not intended to be implemented by clients.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.configuration.IInstallConfiguration
- * @since 2.0
- */
-public interface IActivity extends IAdaptable {
-
- /**
- * Indicates feature installation action
- *
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int ACTION_FEATURE_INSTALL = 1;
-
- /**
- * Indicates feature removal (uninstallation) action
- *
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int ACTION_FEATURE_REMOVE = 2;
-
- /**
- * Indicates an addition of a site to a configuration
- *
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int ACTION_SITE_INSTALL = 3;
-
- /**
- * Indicates removal of a site from a configuration
- *
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int ACTION_SITE_REMOVE = 4;
-
- /**
- * Indicates feature unconfiguration action
- *
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int ACTION_UNCONFIGURE = 5;
-
- /**
- * Indicates feature configuration action
- *
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int ACTION_CONFIGURE = 6;
-
- /**
- * Indicates reverting to a prior configuration state
- *
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int ACTION_REVERT = 7;
-
- /**
- * Indicates reconcilliation with changes made directly to the site
- * installation directory
- *
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int ACTION_RECONCILIATION = 8;
-
- /**
- * Indicates adding the configuration to a preserved state
- *
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int ACTION_ADD_PRESERVED = 9;
-
- /**
- * Indicates the action completed cussessfully
- *
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int STATUS_OK = 0;
-
- /**
- * Indicates the action did not complete successfully
- *
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int STATUS_NOK = 1;
-
- /**
- * Returns the action code for this activity
- *
- * @see #ACTION_FEATURE_INSTALL
- * @see #ACTION_FEATURE_REMOVE
- * @see #ACTION_SITE_INSTALL
- * @see #ACTION_SITE_REMOVE
- * @see #ACTION_UNCONFIGURE
- * @see #ACTION_CONFIGURE
- * @see #ACTION_REVERT
- * @see #ACTION_RECONCILIATION
- * @return action code, as defined in this interface
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public int getAction();
-
- /**
- * Returns the displayable label for this action
- *
- * @return diplayable label for action
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public String getLabel();
-
- /**
- * Returns the creation date of this activity
- *
- * @return activity date
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public Date getDate();
-
- /**
- * Returns the activity completion status
- *
- * @see #STATUS_OK
- * @see #STATUS_NOK
- * @return completion status, as defined in this interface
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public int getStatus();
-
- /**
- * Returns the installation configuration that was the result of
- * this action
- *
- * @return installation configuration
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public IInstallConfiguration getInstallConfiguration();
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IConfiguredSite.java b/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IConfiguredSite.java
deleted file mode 100644
index d8d004eac..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IConfiguredSite.java
+++ /dev/null
@@ -1,372 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.configuration;
-
-import org.eclipse.core.runtime.*;
-import org.eclipse.update.core.*;
-
-/**
- * Configured Site.
- * Represents an installation site "filtered" by configuration information.
- * Configured site is the target of the feature update operations (install
- * feature, remove feature, configure feature, unconfigure feature).
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @since 2.0
- */
-public interface IConfiguredSite extends IAdaptable {
-
- /**
- * Returns the underlying "unfiltered" site.
- *
- * @return the underlying site
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public ISite getSite();
-
- /**
- * Indicates whether updates can be applied to the site.
- *
- * <code>IStatus.isOk()</code> return <code>true</code> if
- * the site can be updated, <code>false</code> otherwise.
- *
- * If updates cannot be aplied, the status contains the error message, and
- * the possible exception.
- *
- * @see IStatus
- * @return an IStatus
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public IStatus verifyUpdatableStatus();
-
- /**
- * Indicates whether updates can be applied to the site.
- *
- * A configuration site is tagged a non-updatable by reading
- * the platform configuration for this site.
- *
- * @return <code>true</code> if the site can be updated,
- * <code>false</code> otherwise
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public boolean isUpdatable();
-
- /**
- * Install the specified feature on this site.
- *
- * @param feature feature to install
- * @param verificationListener verification listener, or <code>null</code>
- * @param monitor progress monitor, or <code>null</code>
- * @exception CoreException
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public IFeatureReference install(IFeature feature, IVerificationListener verificationListener, IProgressMonitor monitor) throws CoreException;
-
- /**
- * Install the specified feature on this site.
- * Only the specified optional features will be installed
- *
- * @param feature feature to install
- * @param optionalFeatures optional features to install
- * @param verificationListener verification listener, or <code>null</code>
- * @param monitor progress monitor, or <code>null</code>
- * @exception CoreException
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public IFeatureReference install(IFeature feature, IFeatureReference[] optionalFeatures, IVerificationListener verificationListener, IProgressMonitor monitor) throws CoreException;
-
-
- /**
- * Remove (uninstall) the specified feature from this site
- *
- * @param feature feature to remove
- * @param monitor progress monitor, or <code>null</code>
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void remove(IFeature feature, IProgressMonitor monitor) throws CoreException;
-
- /**
- * Indicates if the specified feature is "broken". A feature is considered
- * to be broken in the context of this site, if some of the plug-ins
- * referenced by the feature are not installed on this site.
- *
- * The status code is <code>IStatus.ERROR</code> if the feature is considered
- * broken. The Status may contain the reason why the feature is broken.
- * The status code is <code>IStatus.OK</code> if the feature is not considered
- * broken.
- *
- * @param feature the feature
- * @return the status for this feature on this configured site
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public IStatus getBrokenStatus(IFeature feature);
-
- /**
- * Indicates if the specified feature is configured on this site.
- *
- * @param feature the feature
- * @return <code>true</code> if the feature is configured,
- * <code>false</code> otherwise
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public boolean isConfigured(IFeature feature);
-
- /**
- * Configure the specified feature on this site. The configured
- * feature will be included on next startup.
- *
- * @param feature the feature
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void configure(IFeature feature) throws CoreException;
-
- /**
- * Unconfigure the specified feature from this site. The unconfigured
- * feature will be omitted on the next startup.
- *
- * @param feature the feature
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public boolean unconfigure(IFeature feature) throws CoreException;
-
- /**
- * Return references to features configured on this site.
- *
- * @return an array of feature references, or an empty array.
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public IFeatureReference[] getConfiguredFeatures();
-
- /**
- * Return all features installed on this site (configured as well
- * as unconfigured). Note, that if the site requires reconciliation,
- * the result may not match the result of the corresponding method
- * on the underlying site.
- *
- * @see ISite#getFeatureReferences()
- * @return an array of site feature references, or an empty array.
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public IFeatureReference[] getFeatureReferences();
-
- /**
- * Returns the install configuration object this site is part of.
- *
- * @return install configuration object
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public IInstallConfiguration getInstallConfiguration();
-
- /**
- * Adds a change listener to the configured site.
- *
- * @param listener the listener to add
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void addConfiguredSiteChangedListener(IConfiguredSiteChangedListener listener);
-
- /**
- * Removes a change listener from the configured site.
- *
- * @param listener the listener to remove
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void removeConfiguredSiteChangedListener(IConfiguredSiteChangedListener listener);
-
- /**
- * Indicates if the site is an extension site.
- *
- * @return <code>true</code> if the site is an extension site,
- * <code>false</code> otherwise
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public boolean isExtensionSite();
-
- /**
- * Indicates if the site is a product site.
- *
- * @return <code>true</code> if the site is a product site,
- * <code>false</code> otherwise
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public boolean isProductSite();
-
- /**
- * Indicates if the site is a private site.
- * This does not check if this private site belongs to the
- * product that is running.
- *
- * @return <code>true</code> if the site is a private site,
- * <code>false</code> otherwise
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @deprecated private site are considered the same as extension site (3.0)
- */
- public boolean isPrivateSite();
-
- /**
- * Indicates if the site has been linked by a native
- * installer.
- *
- * @return <code>true</code> if the site is a natively linked site,
- * <code>false</code> otherwise
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public boolean isNativelyLinked() throws CoreException;
-
- /**
- * Sets if the site is enabled
- *
- * @parem <code>true</code> if the site is enable, <code>false</code>
- * otherwise
- * @since 2.1
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void setEnabled(boolean value);
-
- /**
- * Indicates if the site is enabled.
- * If a site is not enable, all teh features are considered disabled.
- *
- * @return <code>true</code> if the site is enable, <code>false</code>
- * otherwise
- * @since 2.1
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public boolean isEnabled();
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IConfiguredSiteChangedListener.java b/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IConfiguredSiteChangedListener.java
deleted file mode 100644
index 13634c1da..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IConfiguredSiteChangedListener.java
+++ /dev/null
@@ -1,83 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.configuration;
-
-import org.eclipse.update.core.*;
-
-/**
- * Configuration change listener. *
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @since 2.0
- */
-public interface IConfiguredSiteChangedListener {
-
- /**
- * Indicates the specified feature was installed.
- *
- * @param feature the feature
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void featureInstalled(IFeature feature);
-
- /**
- * Indicates the specified feature was removed (uninstalled)
- *
- * @param feature the feature
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void featureRemoved(IFeature feature);
-
- /**
- * Indicates the specified feature was configured.
- *
- * @param feature the feature
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void featureConfigured(IFeature feature);
-
- /**
- * Indicates the specified feature was unconfigured.
- *
- * @param feature the feature
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void featureUnconfigured(IFeature feature);
-}
-
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IInstallConfiguration.java b/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IInstallConfiguration.java
deleted file mode 100644
index 5d0a37d54..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IInstallConfiguration.java
+++ /dev/null
@@ -1,234 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.configuration;
-
-import java.io.*;
-import java.util.*;
-
-import org.eclipse.core.runtime.*;
-
-/**
- * Installation configuration.
- * Represents a specific configuration of a number of sites as a point
- * in time. Maintains a record of the specific activities that resulted
- * in this configuration. Current installation configuration is
- * the configuration the platform was started with.
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @since 2.0
- */
-public interface IInstallConfiguration extends IAdaptable {
-
- /**
- * Indicates if this is the current configuration
- *
- * @return <code>true</code> if this is the current configuration,
- * <code>false</code> otherwise
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public boolean isCurrent();
-
- /**
- * Return the sites that are part of this configuration.
- *
- * @return an array of configured sites, or an empty array.
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public IConfiguredSite[] getConfiguredSites();
-
- /**
- * Create a new installation site, based on a local file
- * system directory. Note, the site is not added to the
- * configuration as a result of this call.
- *
- * @param directory file directory
- * @return new site
- * @exception CoreException
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public IConfiguredSite createConfiguredSite(File directory) throws CoreException;
-
- /**
- * Create a new linked site, based on a local file
- * system directory. Note, the site is not added to the
- * configuration as a result of this call.
- * The linked site is only created if the directory is an
- * already existing extension site and if it is not already
- * natively linked to the local site.
- *
- * @param directory file directory
- * @return new linked site
- * @exception CoreException
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public IConfiguredSite createLinkedConfiguredSite(File directory) throws CoreException;
-
- /**
- * Adds the specified site to this configuration.
- *
- * @param site new site
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void addConfiguredSite(IConfiguredSite site);
-
- /**
- * Removes the specified site from this configuration.
- *
- * @param site site to remove
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void removeConfiguredSite(IConfiguredSite site);
-
- /**
- * Adds a configuration change listener.
- *
- * @param listener the listener
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void addInstallConfigurationChangedListener(IInstallConfigurationChangedListener listener);
-
- /**
- * Removes a configuration change listener.
- *
- * @param listener the listener
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void removeInstallConfigurationChangedListener(IInstallConfigurationChangedListener listener);
-
- /**
- * Return the list of activities that resulted in this configuration.
- * There is always at least one activity
- *
- * @return an array of activities
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public IActivity[] getActivities();
-
- /**
- * Retrun the date the configuration was created.
- *
- * @return create date
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public Date getCreationDate();
-
- /**
- * Return the configuration label.
- *
- * @return the configuration label. If the configuration label was not
- * explicitly set, a default label is generated based on the creation
- * date
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public String getLabel();
-
- /**
- * Sets the configuration label.
- *
- * @param label the label
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void setLabel(String label);
-
- /**
- * Returns an integer that represents a time stamp created at the beginning of a new configuration time line.
- * Time line is started when configuration state is created by a full file system reconciliation. All configurations
- * subsequently created will have the same time line until the next full reconciliation. Certain operations
- * (e.g. revert) make sense only between objects that belong to the same time line.
- *
- * @since 2.0.2
- * @return the time stamp of the full system reconciliation
- *
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public long getTimeline();
-
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IInstallConfigurationChangedListener.java b/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IInstallConfigurationChangedListener.java
deleted file mode 100644
index 070a87439..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IInstallConfigurationChangedListener.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.configuration;
-
-/**
- * Configuration change listener.
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @since 2.0
- */
-public interface IInstallConfigurationChangedListener {
-
- /**
- * Indicates the specified site was added to the configuration
- *
- * @param site the site
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- void installSiteAdded(IConfiguredSite site);
-
- /**
- * Indicates the specified site was removed from the configuration
- *
- * @param site the site
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- void installSiteRemoved(IConfiguredSite site);
-
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IInstallDeltaHandler.java b/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IInstallDeltaHandler.java
deleted file mode 100644
index c5cb17926..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IInstallDeltaHandler.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.configuration;
-
-/**
- * Install Delta Handler.
- * Presents the changes the reconciler found to the user
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @since 2.0
- * @deprecated Do not use this interface. The extension point deltaHandler has been deprecated.
- */
-public interface IInstallDeltaHandler{
-
- /**
- * Sets the list of session delta to present to the user
- *
- * @param deltas an Array of <code>ISessionDelta</code>
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void init(ISessionDelta[] deltas);
-
- /**
- * Prompt the user to configure or unconfigure
- * new features found during reconciliation
- *
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void open();
-
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/ILocalSite.java b/update/org.eclipse.update.core/src/org/eclipse/update/configuration/ILocalSite.java
deleted file mode 100644
index 07cac155f..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/ILocalSite.java
+++ /dev/null
@@ -1,269 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.configuration;
-
-import org.eclipse.core.runtime.*;
-import org.eclipse.update.core.*;
-
-/**
- * Local Site.
- * Represents the local installation. It consists of the current
- * configuration and the configuration history. A local site
- * manages the number of configuration histories kept. It also allows
- * specific configuration histories to be saved.
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @since 2.0
- */
-public interface ILocalSite extends IAdaptable {
-
- /**
- * Return the current configuration.
- *
- * @return current configuration
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- IInstallConfiguration getCurrentConfiguration();
-
- /**
- * Return configuration history.
- *
- * @return an array of configurations, or an empty array.
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public IInstallConfiguration[] getConfigurationHistory();
-
- /**
- * Reverts the local site to use the specified configuration.
- * The result of this operation is a new configuration that
- * contains the same configured features as the specified configuration.
- * The new configuration becomes the current configuration.
- *
- * @param configuration configuration state to revert to
- * @param monitor progress monitor
- * @param handler problem handler
- * @exception CoreException
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void revertTo(
- IInstallConfiguration configuration,
- IProgressMonitor monitor,
- IProblemHandler handler)
- throws CoreException;
-
- /**
- * Creates a new configuration containing the same state as the
- * specified configuration. The new configuration is not added to
- * this lical site.
- *
- * @return cloned configuration
- * @exception CoreException
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public IInstallConfiguration cloneCurrentConfiguration() throws CoreException;
-
- /**
- * Adds the specified configuration to this local site.
- * The new configuration becomes the current one.
- *
- * @param config the configuration
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void addConfiguration(IInstallConfiguration config);
-
- /**
- * Saves the local site state
- *
- * @exception CoreException
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @return true if a restart is needed. This return code was added in 3.0.
- */
- public boolean save() throws CoreException;
-
- /**
- * Indicates how many configuration histories should be maintained.
- * Histories beyond the specified count are automatically deleted.
- *
- * @return number of past configurations to keep as history
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public int getMaximumHistoryCount();
-
- /**
- * Sets the number of past configurations to keep in history
- *
- * @param history number of configuration to keep
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void setMaximumHistoryCount(int history);
-
- /**
- * Adds a site change listener
- *
- * @param listener the listener
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void addLocalSiteChangedListener(ILocalSiteChangedListener listener);
-
- /**
- * Removes a site listener
- *
- * @param listener the listener
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void removeLocalSiteChangedListener(ILocalSiteChangedListener listener);
-
- /**
- * Save the specified configuration. Saved configurations are
- * not deleted based on the history count. They must be explicitly
- * removed.
- *
- * @param configuration the configuration to save
- * @return the preserved configuration or <code>null</code> if the configuration to save is <code>null</code>
- * @exception CoreException
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public IInstallConfiguration addToPreservedConfigurations(IInstallConfiguration configuration)
- throws CoreException;
-
- /**
- * Removes the specified configuration from the list of previously
- * saved configurations.
- *
- * @param configuration the configuration to remove
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void removeFromPreservedConfigurations(IInstallConfiguration configuration);
-
- /**
- * Return the list of saved configurations
- *
- * @return an array of configurations, or an empty array.
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public IInstallConfiguration[] getPreservedConfigurations();
-
- /**
- * Indicates if the 'state' of the specified feature and its children features.
- *
- * A feature is considered to be 'unhappy' in the context of this site,
- * if some of the plug-ins referenced by the feature, or any of its children,
- * are not installed on this site.
- *
- * A feature is considered to be 'happy' in the context of a local site
- * if all the plug-ins referenced by the feature, or any of its children,
- * are installed on the site and no other version of any of the plug-ins
- * are installed on any other site of the local site.
- *
- * A feature is considered to be 'ambiguous' in the context of a local site
- * if all the plug-ins referenced by the feature, or any of its children,
- * are installed on the site and other version of any of the plug-ins
- * are installed on any other site of the local site.
- *
- * @param feature the feature
- * @see IFeature#STATUS_HAPPY
- * @see IFeature#STATUS_UNHAPPY
- * @see IFeature#STATUS_AMBIGUOUS
- * @return the state of the feature
- * @exception CoreException
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public IStatus getFeatureStatus(IFeature feature) throws CoreException ;
-
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/ILocalSiteChangedListener.java b/update/org.eclipse.update.core/src/org/eclipse/update/configuration/ILocalSiteChangedListener.java
deleted file mode 100644
index 9e1162af1..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/ILocalSiteChangedListener.java
+++ /dev/null
@@ -1,52 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.configuration;
-
-/**
- * Local site change listener.
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @since 2.0
- */
-public interface ILocalSiteChangedListener {
-
- /**
- * Indicates the current configuration has changed.
- *
- * @param configuration the current cunfiguration
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void currentInstallConfigurationChanged(IInstallConfiguration configuration);
-
- /**
- * Indicates the specified configuration was removed.
- *
- * @param configuration the configuration
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void installConfigurationRemoved(IInstallConfiguration configuration);
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/ILocalSystemInfoListener.java b/update/org.eclipse.update.core/src/org/eclipse/update/configuration/ILocalSystemInfoListener.java
deleted file mode 100644
index 25ab62cee..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/ILocalSystemInfoListener.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.configuration;
-
-
-
-/**
- * Local system change listener interface.
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see LocalSystemInfo#addInfoListener(ILocalSystemInfoListener)
- * @see LocalSystemInfo#removeInfoListener(ILocalSystemInfoListener)
- * @see LocalSystemInfo#fireSystemInfoChanged(IVolume,int)
- * @since 2.0
- */
-public interface ILocalSystemInfoListener {
-
- /**
- * Volume change notification.
- * Called each time there are relevant volume changes
- * detected. This specifically includes changes to the
- * file system structure as a result of removable drive/ media
- * operations (eg. CD insertion), and changes to volume
- * mount structure.
- * @param volume volume of the changed file
- * system structure. Any current paths beyond
- * the specified 'root' file of the volume are assumed to be invalidated.
- * @param changeType type of the change that occured.
- * @see LocalSystemInfo#VOLUME_ADDED
- * @see LocalSystemInfo#VOLUME_REMOVED
- * @see LocalSystemInfo#VOLUME_CHANGED
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void systemInfoChanged(IVolume volume, int changeType);
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IProblemHandler.java b/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IProblemHandler.java
deleted file mode 100644
index 361e9e80b..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IProblemHandler.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.configuration;
-
-/**
- * Generic problem handler. Used to report status from specific
- * install operations. The methods implemented by this interface
- * are callbacks from the update support to the caller of the update
- * methods.
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @since 2.0
- */
-public interface IProblemHandler {
-
- /**
- * Report problem.
- *
- * @param problemText problem text
- * @return <code>true</code> if the operation should continue,
- * <code>false</code> if the operation should be cancelled
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- boolean reportProblem(String problemText);
-
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/ISessionDelta.java b/update/org.eclipse.update.core/src/org/eclipse/update/configuration/ISessionDelta.java
deleted file mode 100644
index 48f04d287..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/ISessionDelta.java
+++ /dev/null
@@ -1,149 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.configuration;
-
-import java.util.*;
-
-import org.eclipse.core.runtime.*;
-import org.eclipse.update.core.*;
-
-/**
- * Installation Change.
- * Represents the changes the reconciler found.
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @since 2.0
- * @deprecated Do not use this interface
- */
-public interface ISessionDelta extends IAdaptable {
-
- /**
- * Indicates a processing type to enable the features
- *
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public int ENABLE = 1;
-
- /**
- * Indicates a processing type to disable the features
- *
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public int DISABLE = 2;
-
- /**
- * Returns the list of Features found during reconciliation
- *
- * @return an array of feature references, or an empty array
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public IFeatureReference[] getFeatureReferences();
-
- /**
- * Returns the date the reconciliation occured
- *
- * @return the date of the reconciliation
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public Date getDate();
-
- /**
- * Returns the type of the processing type
- * that will affect all the associated features.
- *
- * @return the processing type
- * @see ISessionDelta#ENABLE
- * @see ISessionDelta#DISABLE
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public int getType();
-
- /**
- * Process all the feature references of the
- * Session Delta.
- * Removes the Session Delta from the file system after processing it.
- *
- * @param progressMonitor the progress monitor
- * @throws CoreException if an error occurs.
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void process(IProgressMonitor progressMonitor) throws CoreException;
-
- /**
- * Process the selected feature references of the Session Delta.
- * Removes the Session Delta from the file system after processing it.
- *
- * @param selected list of selected feature references to be processed
- * @param monitor the progress monitor
- * @throws CoreException if an error occurs.
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void process(IFeatureReference [] selected, IProgressMonitor monitor) throws CoreException;
-
- /**
- * Removes the Session Delta from the file system without processing it.
- *
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public void delete();
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IVolume.java b/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IVolume.java
deleted file mode 100644
index defd2a38e..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/IVolume.java
+++ /dev/null
@@ -1,104 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.configuration;
-
-import java.io.*;
-
-import org.eclipse.core.runtime.*;
-
-/**
- * Local Volume Info.
- * Represents local file system information for a specific volume.
- * <p>
- * This interface is not intended to be implemented by clients.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.configuration.LocalSystemInfo
- * @since 2.0
- */
-public interface IVolume extends IAdaptable {
-
- /**
- * Returns the available free space on this volume.
- * Returns the amount of free space available to this
- * user on the volume. The
- * method takes into account any space quotas or other
- * native mechanisms that may restrict space usage
- * on a given volume.
- * @return the amount of free space available (in units
- * of Kbyte), or an indication the size is not known
- * @see LocalSystemInfo#SIZE_UNKNOWN
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public long getFreeSpace();
-
- /**
- * returns volume label.
- * Returns the label of the volume.
- * @return volume label (as string), or <code>null</code> if
- * the label cannot be determined.
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public String getLabel();
-
- /**
- * Returns volume type.
- * Returns the type of the volume.
- * @return volume type
- * @see LocalSystemInfo#VOLUME_UNKNOWN
- * @see LocalSystemInfo#VOLUME_INVALID_PATH
- * @see LocalSystemInfo#VOLUME_REMOVABLE
- * @see LocalSystemInfo#VOLUME_FIXED
- * @see LocalSystemInfo#VOLUME_REMOTE
- * @see LocalSystemInfo#VOLUME_CDROM
- * @see LocalSystemInfo#VOLUME_FLOPPY_3
- * @see LocalSystemInfo#VOLUME_FLOPPY_5
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public int getType();
-
- /**
- * Returns the volume path.
- * Returns the path that represents the mount point of the volume.
- * @return mount point file
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public File getFile();
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/LocalSystemInfo.java b/update/org.eclipse.update.core/src/org/eclipse/update/configuration/LocalSystemInfo.java
deleted file mode 100644
index f716d9ba3..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/LocalSystemInfo.java
+++ /dev/null
@@ -1,432 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.configuration;
-
-import java.io.*;
-import java.util.*;
-
-import org.eclipse.update.internal.core.*;
-
-/**
- * Utility class providing local file system information.
- * The class attempts to load a native library implementation
- * of its methods. If successful, the method calls are delegated
- * to the native implementation. Otherwise a default non-native
- * implementation is used. *
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see ILocalSystemInfoListener
- * @since 2.0
- */
-public class LocalSystemInfo {
-
- /**
- * Indicates the amount of available free space is not known
- *
- * @see LocalSystemInfo#getFreeSpace(File)
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final long SIZE_UNKNOWN = -1;
-
- /**
- * Indicates the volume type is not known
- *
- * @see LocalSystemInfo#getType(File)
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int VOLUME_UNKNOWN = -1;
-
- /**
- * Indicates the volume could not be determined from path
- *
- * @see LocalSystemInfo#getType(File)
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int VOLUME_INVALID_PATH = -2;
-
- /**
- * Indicates the volume is removable (other than floppy disk)
- *
- * @see LocalSystemInfo#getType(File)
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int VOLUME_REMOVABLE = 1;
-
- /**
- * Indicates the volume is fixed (hard drive)
- *
- * @see LocalSystemInfo#getType(File)
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int VOLUME_FIXED = 2;
-
- /**
- * Indicates a remote (network) volume
- *
- * @see LocalSystemInfo#getType(File)
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int VOLUME_REMOTE = 3;
-
- /**
- * Indicates a cdrom volume (compact disc)
- *
- * @see LocalSystemInfo#getType(File)
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int VOLUME_CDROM = 4;
-
- /**
- * Indicates a ramdisk volume (memory)
- *
- * @see LocalSystemInfo#getType(File)
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int VOLUME_RAMDISK = 5;
-
- /**
- * Indicates the volume is removable (floppy disk 5 1/4)
- *
- * @see LocalSystemInfo#getType(File)
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int VOLUME_FLOPPY_5 = 6;
-
- /**
- * Indicates the volume is removable (floppy disk 3 1/2)
- *
- * @see LocalSystemInfo#getType(File)
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int VOLUME_FLOPPY_3 = 7;
-
- /**
- * Indicates a new volume has been added
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int VOLUME_ADDED = 0;
-
- /**
- * Indicates a volume has been removed
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int VOLUME_REMOVED = 1;
-
- /**
- * Indicates a volume has been changed
- * @since 2.0
- * <p>
- * <b>Note:</b> This field is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static final int VOLUME_CHANGED = 2;
-
-
- private static ArrayList listeners = new ArrayList();
- private static boolean hasNatives = false;
- static {
- try {
- System.loadLibrary("update"); //$NON-NLS-1$
- hasNatives = true;
- } catch (UnsatisfiedLinkError e) {
- UpdateCore.warn("Unable to load native library 'update'."); //$NON-NLS-1$
- hasNatives = false;
- }
- }
-
- /**
- * Determines available free space on a volume.
- * Returns the amount of free space available to this
- * user on the volume containing the specified path. The
- * method takes into account any space quotas or other
- * native mechanisms that may restrict space usage
- * on a given volume.
- * @param path file path. May contain path elements beyond
- * the volume "root"
- * @return the amount of free space available (in units
- * of Kbyte), or an indication the size is not known
- * @see LocalSystemInfo#SIZE_UNKNOWN
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static long getFreeSpace(File path) {
- if (hasNatives) {
- try {
- long bytes = nativeGetFreeSpace(path);
- return (bytes!=0)?bytes/1024:0;
- } catch (UnsatisfiedLinkError e) {
- }
- }
- return SIZE_UNKNOWN;
- }
-
-
- /**
- * Lists the file system volume.
- * @return array of volume representing mount
- * points, or <code>null</code> if none found
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static IVolume[] getVolumes() {
- String[] mountPoints = listMountPoints();
- Volume[] vol = new Volume[0];
- if (mountPoints!=null){
- vol = new Volume[mountPoints.length];
- for (int i = 0; i < mountPoints.length; i++) {
- File root = new File(mountPoints[i]);
- String label = getLabel(root);
- int type = getType(root);
- long size = getFreeSpace(root);
- vol[i] = new Volume(root,label,type,size);
- vol[i].markReadOnly();
- }
- } else {
- UpdateCore.warn("Unable to find mount points"); //$NON-NLS-1$
- // fallback
- File [] roots = File.listRoots();
- if (roots.length == 1) {
- // just one root - skip it
- File root = roots[0];
- roots = root.listFiles();
- }
- vol = new Volume[roots.length];
- for (int i = 0; i < roots.length; i++) {
- vol[i] = new Volume(roots[i],null,LocalSystemInfo.VOLUME_UNKNOWN,LocalSystemInfo.SIZE_UNKNOWN);
- vol[i].markReadOnly();
- }
- }
- return vol;
- }
-
-
- /**
- * Add local system change listener.
- * Allows a listener to be added for monitoring changes
- * in the local system information. The listener is notified
- * each time there are relevant volume changes
- * detected. This specifically includes changes to the
- * list of volumes as a result of removable drive/ media
- * operations (eg. CD insertion, removal), and changes to volume
- * mount structure.
- * @param listener change listener
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static void addInfoListener(ILocalSystemInfoListener listener) {
- if (!listeners.contains(listener))
- listeners.add(listener);
- }
-
- /**
- * Remove local system change listener
- * @param listener change listener
- * @since 2.0
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static void removeInfoListener(ILocalSystemInfoListener listener) {
- listeners.remove(listener);
- }
-
- /**
- * Notify listeners of change.
- *
- * @param volume the volume representing the
- * change file system structure. Any current paths beyond
- * the specified "root" file of the volume are assumed to be invalidated.
- * @param changeType type of the change that occured.
- * @see LocalSystemInfo#VOLUME_ADDED
- * @see LocalSystemInfo#VOLUME_REMOVED
- * @see LocalSystemInfo#VOLUME_CHANGED
- * <p>
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- */
- public static void fireSystemInfoChanged(IVolume volume, int changeType) {
- for (int i=0; i< listeners.size(); i++) {
- ((ILocalSystemInfoListener)listeners.get(i)).systemInfoChanged(volume,changeType);
- }
- }
-
- /*
- * Determines volume label.
- * Returns the label of the volume containing the specified
- * path.
- * @param path file path. May contain path elements beyond
- * the volume "root"
- * @return volume label (as string), or <code>null</code> if
- * the label cannot be determined.
- * @since 2.0
- */
- private static String getLabel(File path) {
- if (hasNatives) {
- try {
- return nativeGetLabel(path);
- } catch (UnsatisfiedLinkError e) {
- }
- }
- return null;
- }
-
- /*
- * Determines volume type.
- * Returns the type of the volume containing the specified
- * path.
- * @param path file path. May contain path elements beyond
- * the volume "root"
- * @return volume type
- * @see LocalSystemInfo#VOLUME_UNKNOWN
- * @see LocalSystemInfo#VOLUME_INVALID_PATH
- * @see LocalSystemInfo#VOLUME_REMOVABLE
- * @see LocalSystemInfo#VOLUME_FIXED
- * @see LocalSystemInfo#VOLUME_REMOTE
- * @see LocalSystemInfo#VOLUME_CDROM
- * @see LocalSystemInfo#VOLUME_FLOPPY_3
- * @see LocalSystemInfo#VOLUME_FLOPPY_5
- * @since 2.0
- */
- private static int getType(File path) {
- if (hasNatives) {
- try {
- return nativeGetType(path);
- } catch (UnsatisfiedLinkError e) {
- }
- }
- return VOLUME_UNKNOWN;
- }
-
- /*
- * Lists the file system mount points.
- * @return array of absolute file paths representing mount
- * points, or <code>null</code> if none found
- * @since 2.0
- */
- private static String[] listMountPoints() {
- if (hasNatives) {
- try {
- String[] mountPoints = nativeListMountPoints();
- return mountPoints;
- } catch (UnsatisfiedLinkError e) {
- }
- }
- return null;
- }
-
- /*
- * Native implementations.
- */
- private static native long nativeGetFreeSpace(File path);
- private static native String nativeGetLabel(File path);
- private static native int nativeGetType(File path);
- private static native String[] nativeListMountPoints();
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/package.html b/update/org.eclipse.update.core/src/org/eclipse/update/configuration/package.html
deleted file mode 100644
index e76be03d6..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/configuration/package.html
+++ /dev/null
@@ -1,25 +0,0 @@
-<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
-<html>
-<head>
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
- <meta name="Author" content="IBM">
- <meta name="GENERATOR" content="Mozilla/4.72 [en] (Windows NT 5.0; U) [Netscape]">
- <title>Package-level Javadoc</title>
-</head>
-<body>
-Provides support for accessing local installation
-information.
-<h2>
-Package Specification</h2>
-This package contains interfaces for accessing and manipulating the local
-system installation and configuration information. In general, users extending
-the update support&nbsp; by writing additional feature and site implementation
-do not need to make use of interfaces defined in this package.
-<p>
-<b>Note:</b> This package is part of an interim API that is still under development and expected to
-change significantly before reaching stability. It is being made 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.
-</p>
-</body>
-</html>
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/ArchiveReference.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/ArchiveReference.java
deleted file mode 100644
index d97c4be71..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/ArchiveReference.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import org.eclipse.update.core.model.*;
-
-/**
- * Convenience implementation of a site archive.
- * <p>
- * This class may be instantiated or subclassed by clients.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.IArchiveReference
- * @see org.eclipse.update.core.model.ArchiveReferenceModel
- * @since 2.0
- */
-public class ArchiveReference
- extends ArchiveReferenceModel
- implements IArchiveReference {
-
- /**
- * Constructor for ArchiveReference
- * @since 2.0
- */
- public ArchiveReference() {
- super();
- }
-
- /**
- * @see Object#toString()
- * @since 2.0
- */
- public String toString() {
- String result = "IArchiveReference: "; //$NON-NLS-1$
- result =
- result
- + ((getPath() == null)
- ? getURL().toExternalForm()
- : getPath() + " : " + getURL().toExternalForm()); //$NON-NLS-1$
- return result;
- }
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/BaseFeatureFactory.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/BaseFeatureFactory.java
deleted file mode 100644
index 634bc891c..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/BaseFeatureFactory.java
+++ /dev/null
@@ -1,135 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import java.net.*;
-
-import org.eclipse.core.runtime.*;
-import org.eclipse.update.core.model.*;
-
-/**
- * Base implementation of a feature factory.
- * The factory is responsible for constructing the correct
- * concrete implementation of the model objects for each particular
- * feature type. This class creates model objects that correspond
- * to the concrete implementation classes provided in this package.
- * The actual feature creation method is subclass responsibility.
- * <p>
- * This class must be subclassed by clients.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.IFeatureFactory
- * @see org.eclipse.update.core.model.FeatureModelFactory
- * @since 2.0
- */
-public abstract class BaseFeatureFactory extends FeatureModelFactory implements IFeatureFactory {
-
- /**
- *
- * @deprecated implement createFeature(URL, ISite, IProgressMonitor) instead
- * @see IFeatureFactory#createFeature(URL,ISite)
- * @since 2.0
- */
- public IFeature createFeature(URL url, ISite site) throws CoreException {
- return createFeature(url, site, null);
- }
-
- /**
- * Create feature. Implementation of this method must be provided by
- * subclass
- *
- * @see IFeatureFactory#createFeature(URL,ISite,IProgressMonitor)
- * @since 2.0
- */
- public abstract IFeature createFeature(URL url, ISite site, IProgressMonitor monitor) throws CoreException;
-
- /**
- * Create a concrete implementation of feature model.
- *
- * @see Feature
- * @return feature model
- * @since 2.0
- */
- public FeatureModel createFeatureModel() {
- return new Feature();
- }
-
- /**
- * Create a concrete implementation of included feature reference model.
- *
- * @see IncludedFeatureReference
- * @return feature model
- * @since 2.1
- */
- public IncludedFeatureReferenceModel createIncludedFeatureReferenceModel() {
- return new IncludedFeatureReference();
- }
-
- /**
- * Create a concrete implementation of install handler model.
- *
- * @see InstallHandlerEntry
- * @return install handler entry model
- * @since 2.0
- */
- public InstallHandlerEntryModel createInstallHandlerEntryModel() {
- return new InstallHandlerEntry();
- }
-
- /**
- * Create a concrete implementation of import dependency model.
- *
- * @see Import
- * @return import dependency model
- * @since 2.0
- */
- public ImportModel createImportModel() {
- return new Import();
- }
-
- /**
- * Create a concrete implementation of plug-in entry model.
- *
- * @see PluginEntry
- * @return plug-in entry model
- * @since 2.0
- */
- public PluginEntryModel createPluginEntryModel() {
- return new PluginEntry();
- }
-
- /**
- * Create a concrete implementation of non-plug-in entry model.
- *
- * @see NonPluginEntry
- * @return non-plug-in entry model
- * @since 2.0
- */
- public NonPluginEntryModel createNonPluginEntryModel() {
- return new NonPluginEntry();
- }
-
- /**
- * Create a concrete implementation of annotated URL model.
- *
- * @see URLEntry
- * @return annotated URL model
- * @since 2.0
- */
- public URLEntryModel createURLEntryModel() {
- return new URLEntry();
- }
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/BaseInstallHandler.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/BaseInstallHandler.java
deleted file mode 100644
index be4920f0e..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/BaseInstallHandler.java
+++ /dev/null
@@ -1,251 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import org.eclipse.core.runtime.*;
-
-/**
- * Base implementation of an install handler.
- * This is a convenience implementation of an install handler with
- * null implementation of its methods. It allows subclasses to selectively
- * implement only the methods required for their installation tasks.
- * <p>
- * This class should be subclassed by clients.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.IInstallHandler
- * @since 2.0
- */
-
-public class BaseInstallHandler implements IInstallHandler {
-
- /**
- * Update action type
- *
- * @see IInstallHandler#HANDLER_ACTION_INSTALL
- * @see IInstallHandler#HANDLER_ACTION_CONFIGURE
- * @see IInstallHandler#HANDLER_ACTION_UNCONFIGURE
- * @see IInstallHandler#HANDLER_ACTION_UNINSTALL
- * @since 2.0
- */
- protected int type;
-
- /**
- * The target of the action
- * @since 2.0
- */
- protected IFeature feature;
-
- /**
- * Model entry that defines this handler
- *
- * @since 2.0
- */
- protected IInstallHandlerEntry entry;
-
- /**
- * Optional progress monitor, can be <code>null</code>
- *
- * @since 2.0
- */
- protected InstallMonitor monitor;
-
- /**
- * Plug-in entries downloaded
- *
- * @see IInstallHandler#HANDLER_ACTION_INSTALL
- * @since 2.0
- */
- protected IPluginEntry[] pluginEntries;
-
- /**
- * Non-plug-in entries downloaded
- *
- * @see IInstallHandler#HANDLER_ACTION_INSTALL
- * @since 2.0
- */
- protected INonPluginEntry[] nonPluginEntries;
-
- /**
- * Indicates if handler has been initialized
- *
- * @since 2.0
- */
- protected boolean initialized = false;
-
- /**
- * Initialize the install handler.
- *
- * @see IInstallHandler#initialize(int, IFeature, IInstallHandlerEntry, InstallMonitor)
- * @since 2.0
- */
- public void initialize(
- int type,
- IFeature feature,
- IInstallHandlerEntry entry,
- InstallMonitor monitor)
- throws CoreException {
-
- if (this.initialized)
- return;
- else {
- if (feature == null)
- throw new IllegalArgumentException();
- this.type = type;
- this.feature = feature;
- this.entry = entry;
- this.monitor = monitor;
- this.initialized = true;
- }
- }
-
- /**
- * Called at the start of the install action.
- *
- * @see IInstallHandler#installInitiated
- * @since 2.0
- */
- public void installInitiated() throws CoreException {
- }
-
- /**
- * Called after files corresponding to plug-in entries have been downloaded,
- * but before they are actully unpacked and installed.
- *
- * @see IInstallHandler#pluginsDownloaded(IPluginEntry[])
- * @since 2.0
- */
- public void pluginsDownloaded(IPluginEntry[] plugins) throws CoreException {
-
- this.pluginEntries = plugins;
- }
-
- /**
- * Called after files corresponding to non-plug-in entries have been
- * downloaded.
- *
- * @see IInstallHandler#nonPluginDataDownloaded(INonPluginEntry[], IVerificationListener)
- * @since 2.0
- */
- public void nonPluginDataDownloaded(
- INonPluginEntry[] nonPluginData,
- IVerificationListener listener)
- throws CoreException {
-
- this.nonPluginEntries = nonPluginData;
- }
-
- /**
- * Called after the feature files and any downloaded plug-ins have
- * been installed.
- *
- * @see IInstallHandler#completeInstall(IFeatureContentConsumer)
- * @since 2.0
- */
- public void completeInstall(IFeatureContentConsumer consumer)
- throws CoreException {
- }
-
- /**
- * Called at the end of the install action.
- *
- * @see IInstallHandler#installCompleted(boolean)
- * @since 2.0
- */
- public void installCompleted(boolean success) throws CoreException {
- }
-
- /**
- * Called at the start of the configure action.
- *
- * @see IInstallHandler#configureInitiated()
- * @since 2.0
- */
- public void configureInitiated() throws CoreException {
- }
-
- /**
- * Called after the feature has been configured.
- *
- * @see IInstallHandler#completeConfigure()
- * @since 2.0
- */
- public void completeConfigure() throws CoreException {
- }
-
- /**
- * Called at the end of the configure action.
- *
- * @see IInstallHandler#configureCompleted(boolean)
- * @since 2.0
- */
- public void configureCompleted(boolean success) throws CoreException {
- }
-
- /**
- * Called at the start of the unconfigure action.
- *
- * @see IInstallHandler#unconfigureInitiated()
- * @since 2.0
- */
- public void unconfigureInitiated() throws CoreException {
- }
-
- /**
- * Called after the feature has been unconfigured.
- *
- * @see IInstallHandler#completeUnconfigure()
- * @since 2.0
- */
- public void completeUnconfigure() throws CoreException {
- }
-
- /**
- * Called at the end of the unconfigure action.
- *
- * @see IInstallHandler#unconfigureCompleted(boolean)
- * @since 2.0
- */
- public void unconfigureCompleted(boolean success) throws CoreException {
- }
-
- /**
- * Called at the start of the uninstall action.
- *
- * @see IInstallHandler#uninstallInitiated()
- * @since 2.0
- */
- public void uninstallInitiated() throws CoreException {
- }
-
- /**
- * Called after the feature has been uninstalled.
- *
- * @see IInstallHandler#completeUninstall()
- * @since 2.0
- */
- public void completeUninstall() throws CoreException {
- }
-
- /**
- * Called at the end of the uninstall action.
- *
- * @see IInstallHandler#uninstallCompleted(boolean)
- * @since 2.0
- */
- public void uninstallCompleted(boolean success) throws CoreException {
- }
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/BaseSiteFactory.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/BaseSiteFactory.java
deleted file mode 100644
index 7ad6ca700..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/BaseSiteFactory.java
+++ /dev/null
@@ -1,148 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import java.io.*;
-import java.net.*;
-import java.util.*;
-
-import org.eclipse.core.runtime.*;
-import org.eclipse.update.core.model.*;
-import org.eclipse.update.internal.core.*;
-
-/**
- * Base implementation of a site factory.
- * The factory is responsible for constructing the correct
- * concrete implementation of the model objects for each particular
- * site type. This class creates model objects that correspond
- * to the concrete implementation classes provided in this package.
- * The actual site creation method is subclass responsibility.
- * <p>
- * This class must be subclassed by clients.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.ISiteFactory
- * @see org.eclipse.update.core.model.SiteModelFactory
- * @since 2.0
- */
-public abstract class BaseSiteFactory extends SiteModelFactory implements ISiteFactory {
-
-
- /**
- * Create site. Implementation of this method must be provided by
- * subclass
- *
- * @see ISiteFactory#createSite(URL)
- * @since 2.0
- */
- public abstract ISite createSite(URL url) throws CoreException, InvalidSiteTypeException;
-
- /**
- * Helper method to access resouce bundle for site. The default
- * implementation attempts to load the appropriately localized
- * site.properties file.
- *
- * @param url base URL used to load the resource bundle.
- * @return resource bundle, or <code>null</code>.
- * @since 2.0
- */
- protected ResourceBundle getResourceBundle(URL url) {
- ResourceBundle bundle = null;
-
- try {
- url = UpdateManagerUtils.asDirectoryURL(url);
- ClassLoader l = new URLClassLoader(new URL[] { url }, null);
- bundle = ResourceBundle.getBundle(Site.SITE_FILE, Locale.getDefault(), l);
- } catch (MissingResourceException e) {
- UpdateCore.warn(e.getLocalizedMessage() + ":" + url.toExternalForm()); //$NON-NLS-1$
- } catch (MalformedURLException e) {
- UpdateCore.warn(Policy.bind("BaseSiteFactory.CannotRetriveParentDirectory", url.toExternalForm())); //$NON-NLS-1$
- }
-
- return bundle;
- }
-
- /**
- * Create a concrete implementation of site model.
- *
- * @see Site
- * @return site model
- * @since 2.0
- */
- public SiteModel createSiteMapModel() {
- return new Site();
- }
-
-
- /**
- * Create a concrete implementation of feature reference model.
- *
- * @see FeatureReference
- * @return feature reference model
- * @since 2.0
- */
- public SiteFeatureReferenceModel createFeatureReferenceModel() {
- return new SiteFeatureReference();
- }
-
- /**
- * Create a concrete implementation of archive reference model.
- *
- * @see ArchiveReference
- * @return archive reference model
- * @since 2.0
- */
- public ArchiveReferenceModel createArchiveReferenceModel() {
- return new ArchiveReference();
- }
-
-
- /**
- * Create a concrete implementation of annotated URL model.
- *
- * @see URLEntry
- * @return annotated URL model
- * @since 2.0
- */
- public URLEntryModel createURLEntryModel() {
- return new URLEntry();
- }
-
-
- /**
- * Create a concrete implementation of category model.
- *
- * @see Category
- * @return category model
- * @since 2.0
- */
- public CategoryModel createSiteCategoryModel() {
- return new Category();
- }
-
- /**
- * Open a stream on a URL.
- * manages a time out if the connection is locked or fails
- *
- * @param resolvedURL
- * @return InputStream
- */
- protected InputStream openStream(URL resolvedURL) throws IOException {
- Response response = UpdateCore.getPlugin().get(resolvedURL);
- return response.getInputStream();
- }
-
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/Category.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/Category.java
deleted file mode 100644
index 8fcc12ff2..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/Category.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import org.eclipse.update.core.model.*;
-
-/**
- * Convenience implementation of feature category definition.
- * <p>
- * This class may be instantiated or subclassed by clients.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.ICategory
- * @see org.eclipse.update.core.model.CategoryModel
- * @since 2.0
- */
-public class Category extends CategoryModel implements ICategory {
-
- /**
- * Default Constructor
- */
- public Category() {
- }
-
- /**
- * Constructor
- */
- public Category(String name, String label) {
- setName(name);
- setLabel(label);
- }
-
- /**
- * Retrieve the detailed category description
- * @see ICategory#getDescription()
- */
- public IURLEntry getDescription() {
- return (IURLEntry) getDescriptionModel();
- }
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/ContentReference.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/ContentReference.java
deleted file mode 100644
index 78a39fc1f..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/ContentReference.java
+++ /dev/null
@@ -1,334 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import java.io.*;
-import java.net.*;
-
-import org.eclipse.update.internal.core.*;
-import org.eclipse.update.internal.core.URLEncoder;
-
-/**
- * Content reference implements a general access wrapper
- * to feature and site content. The reference specifies
- * a "symbolic" path identifier for the content, and the actual
- * reference as a file, or a URL.
- * <p>
- * This class may be instantiated or subclassed by clients.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.JarContentReference
- * @see org.eclipse.update.core.JarEntryContentReference
- * @since 2.0
- */
-public class ContentReference {
-
- /**
- * Unknown size indication
- * @since 2.0
- */
- public static final long UNKNOWN_SIZE = -1;
-
- /**
- * Default executable permission when installing a content reference
- * Will add executable bit if necessary
- *
- * @since 2.0.1
- */
- public static final int DEFAULT_EXECUTABLE_PERMISSION = -1;
-
- private static final String FILE_URL_PROTOCOL = "file"; //$NON-NLS-1$
-
- private String id;
- private URL url; // reference is either URL reference *OR*
- private File file; // local file reference
- private Response response;
- private int permission;
- private long length;
-
- // <true> if a copy of a Contentreferenec in a temp local directory
- private boolean tempLocal = false;
-
- private long lastModified;
-
- /*
- * do not allow default contruction
- */
- private ContentReference() {
- }
-
- /**
- * Create content reference from URL.
- *
- * @param id "symbolic" path identifier
- * @param url actual referenced URL
- * @since 2.0
- */
- public ContentReference(String id, URL url) {
- this.id = (id == null ? "" : id); //$NON-NLS-1$
- this.url = url; // can be null
- this.file = null;
- }
-
- /**
- * Create content reference from file.
- *
- * @param id "symbolic" path identifier
- * @param file actual referenced file
- * @since 2.0
- */
- public ContentReference(String id, File file) {
- this.id = (id == null ? "" : id); //$NON-NLS-1$
- this.file = file; // can be null
- this.url = null;
- }
-
- /**
- * A factory method to create a content reference of
- * the same type.
- *
- * @param id "symbolic" path identifier
- * @param file actual referenced file
- * @return content reference of the same type
- * @since 2.0
- */
- public ContentReference createContentReference(String id, File file) {
- return new ContentReference(id, file,true);
- }
- /**
- *
- */
- private ContentReference(String id, File file, boolean b) {
- this(id,file);
- setTempLocal(b);
- }
-
- /**
- * Retrieves the "symbolic" path identifier for the reference.
- *
- * @return "symbolic" path identifier
- * @since 2.0
- */
- public String getIdentifier() {
- return id;
- }
-
- /**
- * Creates an input stream for the reference.
- *
- * @return input stream
- * @exception IOException unable to create stream
- * @since 2.0
- */
- public InputStream getInputStream() throws IOException {
- if (file != null)
- return new FileInputStream(file);
- else if (url != null) {
- if (response == null) {
- URL resolvedURL = URLEncoder.encode(url);
- response = UpdateCore.getPlugin().get(resolvedURL);
- UpdateManagerUtils.checkConnectionResult(response,resolvedURL);
- }
- InputStream is=response.getInputStream();
- length=response.getContentLength();
- return is;
- } else
- throw new IOException(Policy.bind("ContentReference.UnableToCreateInputStream", this.toString())); //$NON-NLS-1$
- }
- /**
- * Creates an input stream for the reference.
- *
- * @return input stream
- * @exception IOException unable to create stream
- * @since 2.0
- */
- InputStream getPartialInputStream(long offset) throws IOException {
- if (url != null && "http".equals(url.getProtocol())) { //$NON-NLS-1$
- URL resolvedURL = URLEncoder.encode(url);
- response = UpdateCore.getPlugin().get(resolvedURL);
- if(response instanceof HttpResponse)
- ((HttpResponse)response).setOffset(offset);
- UpdateManagerUtils.checkConnectionResult(response,resolvedURL);
- InputStream is = response.getInputStream();
- length=offset + response.getContentLength();
- return is;
- } else
- throw new IOException(Policy.bind("ContentReference.UnableToCreateInputStream", this.toString())); //$NON-NLS-1$
- }
-
- /**
- * Returns the size of the referenced input, if it can be determined.
- *
- * @return input size, or @see #UNKNOWN_SIZE if size cannot be determined.
- * @since 2.0
- */
- public long getInputSize() throws IOException {
- if (length>0)
- return length;
- if (file != null)
- return file.length();
- else if (url != null) {
- if (response == null) {
- URL resolvedURL = null;
- try {
- resolvedURL = URLEncoder.encode(url);
- response = UpdateCore.getPlugin().get(resolvedURL);
- } catch (IOException e) {
- return ContentReference.UNKNOWN_SIZE;
- }
- UpdateManagerUtils.checkConnectionResult(response,resolvedURL);
- }
- long size = response.getContentLength();
- return size == -1 ? ContentReference.UNKNOWN_SIZE : size;
- } else
- return ContentReference.UNKNOWN_SIZE;
- }
-
- /**
- * Indicates whether the reference is a local file reference.
- *
- * @return <code>true</code> if the reference is local,
- * otherwise <code>false</code>
- * @since 2.0
- */
- public boolean isLocalReference() {
- /*if (file != null)
- return true;
- else if (url != null)
- return FILE_URL_PROTOCOL.equals(url.getProtocol());
- else
- return false;*/
- // only temp files are considered local
- return tempLocal;
- }
-
- /**
- * Returns the content reference as a file. Note, that this method
- * <b>does not</b> cause the file to be downloaded if it
- * is not already local.
- *
- * @return reference as file
- * @exception IOException reference cannot be returned as file
- * @since 2.0
- */
- public File asFile() throws IOException {
- if (file != null)
- return file;
-
- if (url != null && FILE_URL_PROTOCOL.equals(url.getProtocol())) {
- File result = new File(url.getFile());
- if (result.exists())
- return result;
- else
- throw new IOException(Policy.bind("ContentReference.FileDoesNotExist", this.toString())); //$NON-NLS-1$
- }
-
- throw new IOException(Policy.bind("ContentReference.UnableToReturnReferenceAsFile", this.toString())); //$NON-NLS-1$
- }
-
- /**
- * Returns the content reference as a URL.
- *
- * @return reference as URL
- * @exception IOException reference cannot be returned as URL
- * @since 2.0
- */
- public URL asURL() throws IOException {
- if (url != null)
- return url;
-
- if (file != null)
- return file.toURL();
-
- throw new IOException(Policy.bind("ContentReference.UnableToReturnReferenceAsURL", this.toString())); //$NON-NLS-1$
- }
-
- /**
- * Return string representation of this reference.
- *
- * @return string representation
- * @since 2.0
- */
- public String toString() {
- if (file != null)
- return file.getAbsolutePath();
- else
- return url.toExternalForm();
- }
- /**
- * Returns the permission for this file.
- *
- * @return the content reference permission
- * @see #DEFAULT_EXECUTABLE_PERMISSION
- * @since 2.0.1
- */
- public int getPermission() {
- return permission;
- }
-
- /**
- * Sets the permission of this content reference.
- *
- * @param permission The permission to set
- */
- public void setPermission(int permission) {
- this.permission = permission;
- }
-
- /**
- * Sets if a content reference is considered local
- *
- * @param tempLocal <code>true</code> if the file is considered local
- */
- protected void setTempLocal(boolean tempLocal) {
- this.tempLocal = tempLocal;
- }
-
- /**
- * Sets the timestamp the content was last modified.
- * @param timestamp
- * @since 3.0
- */
- public void setLastModified(long timestamp) {
- this.lastModified = timestamp;
- }
-
- /**
- * Returns the timestamp when the content was last modified
- * @return
- * @since 3.0
- */
- public long getLastModified() {
- if (lastModified == 0) {
- if (file != null)
- lastModified = file.lastModified();
- else if (url != null) {
- if (response == null) {
- try {
- URL resolvedURL = URLEncoder.encode(url);
- response = UpdateCore.getPlugin().get(resolvedURL);
- } catch (MalformedURLException e) {
- // return 0
- } catch (IOException e) {
- // return 0
- }
- }
- lastModified = response.getLastModified();
- }
- }
- return lastModified;
- }
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/Feature.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/Feature.java
deleted file mode 100644
index c4114a3b6..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/Feature.java
+++ /dev/null
@@ -1,1128 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import java.net.*;
-import java.util.*;
-
-import org.eclipse.core.runtime.*;
-import org.eclipse.update.core.model.*;
-import org.eclipse.update.internal.core.*;
-
-/**
- * Convenience implementation of a feature.
- * <p>
- * This class may be instantiated or subclassed by clients.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.IFeature
- * @see org.eclipse.update.core.model.FeatureModel
- * @since 2.0
- */
-public class Feature extends FeatureModel implements IFeature {
-
- /**
- * Simple file name of the default feature manifest file
- * @since 2.0
- */
- public static final String FEATURE_FILE = "feature"; //$NON-NLS-1$
-
- /**
- * File extension of the default feature manifest file
- * @since 2.0
- */
- public static final String FEATURE_XML = FEATURE_FILE + ".xml"; //$NON-NLS-1$
-
- private ISite site; // feature site
- private IFeatureContentProvider featureContentProvider; // content provider
- private List /*of IFeatureReference*/
- includedFeatureReferences;
-
- //PERF: new instance variable
- private VersionedIdentifier versionId;
-
- private InstallAbortedException abortedException = null;
-
- /**
- * Feature default constructor
- *
- * @since 2.0
- */
- public Feature() {
- }
-
- /**
- * Compares two features for equality
- *
- * @param object feature object to compare with
- * @return <code>true</code> if the two features are equal,
- * <code>false</code> otherwise
- * @since 2.0
- */
- public boolean equals(Object object) {
- if (!(object instanceof IFeature))
- return false;
- IFeature f = (IFeature) object;
- return getVersionedIdentifier().equals(f.getVersionedIdentifier());
- }
-
- /**
- * Returns the feature identifier.
- *
- * @see IFeature#getVersionedIdentifier()
- * @since 2.0
- */
- public VersionedIdentifier getVersionedIdentifier() {
- if (versionId != null)
- return versionId;
-
- String id = getFeatureIdentifier();
- String ver = getFeatureVersion();
- if (id != null && ver != null) {
- try {
- versionId = new VersionedIdentifier(id, ver);
- return versionId;
- } catch (Exception e) {
- UpdateCore.warn(
- "Unable to create versioned identifier:" + id + ":" + ver); //$NON-NLS-1$ //$NON-NLS-2$
- }
- }
-
- versionId = new VersionedIdentifier(getURL().toExternalForm(), null);
- return versionId;
- }
-
- /**
- * Returns the site this feature is associated with.
- *
- * @see IFeature#getSite()
- * @since 2.0
- */
- public ISite getSite() {
- return site;
- }
-
- /**
- * Returns the feature URL.
- *
- * @see IFeature#getURL()
- * @since 2.0
- */
- public URL getURL() {
- IFeatureContentProvider contentProvider = null;
- try {
- contentProvider = getFeatureContentProvider();
- } catch (CoreException e) {
- UpdateCore.warn("No content Provider", e); //$NON-NLS-1$
- }
- return (contentProvider != null) ? contentProvider.getURL() : null;
- }
-
- /**
- * Returns an information entry referencing the location of the
- * feature update site.
- *
- * @see IFeature#getUpdateSiteEntry()
- * @since 2.0
- */
- public IURLEntry getUpdateSiteEntry() {
- return (IURLEntry) getUpdateSiteEntryModel();
- }
-
- /**
- * Return an array of information entries referencing locations of other
- * update sites.
- *
- * @see IFeature#getDiscoverySiteEntries()
- * @since 2.0
- */
- public IURLEntry[] getDiscoverySiteEntries() {
- URLEntryModel[] result = getDiscoverySiteEntryModels();
- if (result.length == 0)
- return new IURLEntry[0];
- else
- return (IURLEntry[]) result;
- }
-
- /**
- * Returns and optional custom install handler entry.
- *
- * @see IFeature#getInstallHandlerEntry()
- * @since 2.0
- */
- public IInstallHandlerEntry getInstallHandlerEntry() {
- return (IInstallHandlerEntry) getInstallHandlerModel();
- }
-
- /**
- * Returns the feature description.
- *
- * @see IFeature#getDescription()
- * @since 2.0
- */
- public IURLEntry getDescription() {
- return (IURLEntry) getDescriptionModel();
- }
-
- /**
- * Returns the copyright information for the feature.
- *
- * @see IFeature#getCopyright()
- * @since 2.0
- */
- public IURLEntry getCopyright() {
- return (IURLEntry) getCopyrightModel();
- }
-
- /**
- * Returns the license information for the feature.
- *
- * @see IFeature#getLicense()
- * @since 2.0
- */
- public IURLEntry getLicense() {
- return (IURLEntry) getLicenseModel();
- }
-
- /**
- * Return optional image for the feature.
- *
- * @see IFeature#getImage()
- * @since 2.0
- */
- public URL getImage() {
- return getImageURL();
- }
-
- /**
- * Return a list of plug-in dependencies for this feature.
- *
- * @see IFeature#getRawImports()
- * @since 2.0
- */
- public IImport[] getRawImports() {
- ImportModel[] result = getImportModels();
- if (result.length == 0)
- return new IImport[0];
- else
- return (IImport[]) result;
- }
-
- /**
- * Install the contents of this feature into the specified target feature.
- * This method is a reference implementation of the feature installation
- * protocol. Other concrete feature implementation that override this
- * method need to implement this protocol.
- *
- * @see IFeature#install(IFeature, IVerificationListener, IProgressMonitor)
- * @since 2.0
- */
- public IFeatureReference install(
- IFeature targetFeature,
- IVerificationListener verificationListener,
- IProgressMonitor progress)
- throws InstallAbortedException, CoreException {
- // call other API with all optional features, or setup variable meaning install all
- return install(targetFeature, null, verificationListener, progress);
- }
-
- /**
- * Install the contents of this feature into the specified target feature.
- * This method is a reference implementation of the feature installation
- * protocol. Other concrete feature implementation that override this
- * method need to implement this protocol.
- *
- * @see IFeature#install(IFeature, IVerificationListener, IProgressMonitor)
- * @since 2.0
- */
- public IFeatureReference install(
- IFeature targetFeature,
- IFeatureReference[] optionalfeatures,
- IVerificationListener verificationListener,
- IProgressMonitor progress)
- throws InstallAbortedException, CoreException {
-
- //DEBUG
- debug("Installing...:" + getURL().toExternalForm()); //$NON-NLS-1$
- ErrorRecoveryLog recoveryLog = ErrorRecoveryLog.getLog();
-
- // make sure we have an InstallMonitor
- InstallMonitor monitor;
- if (progress == null)
- monitor = new InstallMonitor(new NullProgressMonitor());
- else if (progress instanceof InstallMonitor)
- monitor = (InstallMonitor) progress;
- else
- monitor = new InstallMonitor(progress);
-
- // Setup optional install handler
- InstallHandlerProxy handler =
- new InstallHandlerProxy(
- IInstallHandler.HANDLER_ACTION_INSTALL,
- this,
- this.getInstallHandlerEntry(),
- monitor);
- boolean success = false;
- Throwable originalException = null;
- abortedException = null;
-
- // Get source feature provider and verifier.
- // Initialize target variables.
- IFeatureContentProvider provider = getFeatureContentProvider();
- IVerifier verifier = provider.getVerifier();
- IFeatureReference result = null;
- IFeatureReference alreadyInstalledFeature = null;
- IFeatureContentConsumer consumer = null;
- IPluginEntry[] targetSitePluginEntries = null;
-
- try {
- // determine list of plugins to install
- // find the intersection between the plugin entries already contained
- // on the target site, and plugin entries packaged in source feature
- IPluginEntry[] sourceFeaturePluginEntries = getPluginEntries();
- ISite targetSite = targetFeature.getSite();
- if (targetSite == null) {
- debug("The site to install in is null"); //$NON-NLS-1$
- targetSitePluginEntries = new IPluginEntry[0];
- } else {
- targetSitePluginEntries = targetSite.getPluginEntries();
- }
- IPluginEntry[] pluginsToInstall =
- UpdateManagerUtils.diff(
- sourceFeaturePluginEntries,
- targetSitePluginEntries);
- INonPluginEntry[] nonPluginsToInstall = getNonPluginEntries();
-
- IFeatureReference[] children = getIncludedFeatureReferences();
- if (optionalfeatures != null) {
- children =
- UpdateManagerUtils.optionalChildrenToInstall(
- children,
- optionalfeatures);
- }
-
- // determine number of monitor tasks
- // 2 tasks for the feature jar (download/verify + install)
- // + 2*n tasks for plugin entries (download/verify + install for each)
- // + 1*m tasks per non-plugin data entry (download for each)
- // + 1 task for custom non-plugin entry handling (1 for all combined)
- // + 5*x tasks for children features (5 subtasks per install)
- int taskCount =
- 2
- + 2 * pluginsToInstall.length
- + nonPluginsToInstall.length
- + 1
- + 5 * children.length;
- monitor.beginTask("", taskCount); //$NON-NLS-1$
- SubProgressMonitor subMonitor = null;
-
- // start log
- recoveryLog.open(ErrorRecoveryLog.START_INSTALL_LOG);
-
- // Start the installation tasks
- handler.installInitiated();
-
- // Download and verify feature archive(s)
- ContentReference[] references =
- provider.getFeatureEntryArchiveReferences(monitor);
- verifyReferences(
- verifier,
- references,
- monitor,
- verificationListener,
- true);
- monitorWork(monitor, 1);
-
- // Download and verify plugin archives
- for (int i = 0; i < pluginsToInstall.length; i++) {
- references = provider.getPluginEntryArchiveReferences(
- pluginsToInstall[i], monitor);
- verifyReferences(verifier, references, monitor,
- verificationListener, false);
- monitorWork(monitor, 1);
- }
-
- handler.pluginsDownloaded(pluginsToInstall);
-
- // Download non-plugin archives. Verification handled by optional install handler
- for (int i = 0; i < nonPluginsToInstall.length; i++) {
- references =
- provider.getNonPluginEntryArchiveReferences(
- nonPluginsToInstall[i],
- monitor);
- monitorWork(monitor, 1);
- }
- handler.nonPluginDataDownloaded(
- nonPluginsToInstall,
- verificationListener);
-
- // All archives are downloaded and verified. Get ready to install
- consumer = targetFeature.getFeatureContentConsumer();
-
- // install the children feature
- // check if they are optional, and if they should be installed [2.0.1]
- for (int i = 0; i < children.length; i++) {
- IFeature childFeature = null;
- try {
- childFeature = children[i].getFeature(null);
- } catch (CoreException e) {
- UpdateCore.warn(null, e);
- }
- if (childFeature != null) {
- subMonitor = new SubProgressMonitor(monitor, 5);
- ((Site) targetSite).install(// need to cast
- childFeature,
- optionalfeatures,
- consumer,
- verifier,
- verificationListener,
- subMonitor);
- }
- }
-
- // Install plugin files
- for (int i = 0; i < pluginsToInstall.length; i++) {
- // if another feature has already installed this plugin, skip it
- if (InstallRegistry.getInstance().isPluginJustInstalled(pluginsToInstall[i])) {
- monitor.worked(1);
- continue;
- }
- IContentConsumer pluginConsumer =
- consumer.open(pluginsToInstall[i]);
- // TODO consumer.open returns either
- // SiteFilePackedPluginContentConsumer or SiteFilePluginContentConsumer
- // and they are fed either
- // PluginEntryArchiveReference or PluginEntryContentReferences
- // it would be better to have one that is given PluginEntryArchiveReference
- // but it would break external IContentConsumers
-
- if(pluginsToInstall[i] instanceof PluginEntryModel && !((PluginEntryModel)pluginsToInstall[i]).isUnpack()){
- // plugin can run from a jar
- references = provider.getPluginEntryArchiveReferences(
- pluginsToInstall[i], monitor);
- } else{
- // plugin must be unpacked
- references =
- provider.getPluginEntryContentReferences(
- pluginsToInstall[i],
- monitor);
- }
-
- String msg = ""; //$NON-NLS-1$
- subMonitor = new SubProgressMonitor(monitor, 1);
- VersionedIdentifier pluginVerId =
- pluginsToInstall[i].getVersionedIdentifier();
- String pluginID =
- (pluginVerId == null) ? "" : pluginVerId.getIdentifier(); //$NON-NLS-1$
- msg = Policy.bind("Feature.TaskInstallPluginFiles", pluginID); //$NON-NLS-1$
-
- for (int j = 0; j < references.length; j++) {
- setMonitorTaskName(
- subMonitor,
- msg + references[j].getIdentifier());
- pluginConsumer.store(references[j], subMonitor);
- }
-
- InstallRegistry.registerPlugin(pluginsToInstall[i]);
- if (monitor.isCanceled())
- abort();
- }
-
- // check if we need to install feature files [16718]
- // store will throw CoreException if another feature is already
- // installed in the same place
- alreadyInstalledFeature = featureAlreadyInstalled(targetSite);
- // 18867
- if (alreadyInstalledFeature == null) {
- //Install feature files
- references = provider.getFeatureEntryContentReferences(monitor);
-
- String msg = ""; //$NON-NLS-1$
- subMonitor = new SubProgressMonitor(monitor, 1);
- msg = Policy.bind("Feature.TaskInstallFeatureFiles"); //$NON-NLS-1$
-
- for (int i = 0; i < references.length; i++) {
- setMonitorTaskName(
- subMonitor,
- msg + " " + references[i].getIdentifier()); //$NON-NLS-1$
- consumer.store(references[i], subMonitor);
- }
- InstallRegistry.registerFeature(this);
- } else {
- monitor.worked(1);
- }
-
- if (monitor.isCanceled())
- abort();
-
- // call handler to complete installation (eg. handle non-plugin entries)
- handler.completeInstall(consumer);
- monitorWork(monitor, 1);
-
- // indicate install success
- success = true;
-
- } catch (InstallAbortedException e) {
- abortedException = e;
- } catch (CoreException e) {
- originalException = e;
- } finally {
- Exception newException = null;
- try {
- if (consumer != null) {
- if (success) {
- result = consumer.close();
- if (result == null) {
- result = alreadyInstalledFeature; // 18867
- if (result != null
- && optionalfeatures != null
- && optionalfeatures.length > 0) {
- // reinitialize as new optional children may have been installed
- reinitializeFeature(result);
- }
- }
- // close the log
- recoveryLog.close(ErrorRecoveryLog.END_INSTALL_LOG);
- } else {
- consumer.abort();
- }
- }
- handler.installCompleted(success);
- // if abort is done, no need for the log to stay
- recoveryLog.delete();
- } catch (CoreException e) {
- newException = e;
- }
-
- // original exception wins unless it is InstallAbortedException
- // and an error occured during abort
- if (originalException != null) {
- throw Utilities.newCoreException(
- Policy.bind("InstallHandler.error", this.getLabel()), //$NON-NLS-1$
- originalException);
- }
-
- if (newException != null)
- throw Utilities.newCoreException(
- Policy.bind("InstallHandler.error", this.getLabel()), //$NON-NLS-1$
- newException);
-
- if (abortedException != null) {
- throw abortedException;
- }
-
- }
- return result;
- }
-
- /**
- * Returns an array of plug-in entries referenced by this feature
- *
- * @see IFeature#getPluginEntries()
- * @since 2.0
- */
- public IPluginEntry[] getRawPluginEntries() {
- PluginEntryModel[] result = getPluginEntryModels();
- if (result.length == 0)
- return new IPluginEntry[0];
- else
- return (IPluginEntry[]) result;
- }
-
- /*
- * Method filter.
- * @param result
- * @return IPluginEntry[]
- */
- private IPluginEntry[] filterPluginEntry(IPluginEntry[] all) {
- List list = new ArrayList();
- if (all != null) {
- for (int i = 0; i < all.length; i++) {
- if (UpdateManagerUtils.isValidEnvironment(all[i]))
- list.add(all[i]);
- }
- }
-
- IPluginEntry[] result = new IPluginEntry[list.size()];
- if (!list.isEmpty()) {
- list.toArray(result);
- }
-
- return result;
- }
-
- /**
- * Returns the count of referenced plug-in entries.
- *
- * @see IFeature#getPluginEntryCount()
- * @since 2.0
- */
- public int getPluginEntryCount() {
- return getPluginEntries().length;
- }
-
- /**
- * Returns an array of non-plug-in entries referenced by this feature
- *
- * @see IFeature#getNonPluginEntries()
- * @since 2.0
- */
- public INonPluginEntry[] getRawNonPluginEntries() {
- NonPluginEntryModel[] result = getNonPluginEntryModels();
- if (result.length == 0)
- return new INonPluginEntry[0];
- else
- return (INonPluginEntry[]) result;
- }
-
- /**
- * Returns the count of referenced non-plug-in entries.
- *
- * @see IFeature#getNonPluginEntryCount()
- * @since 2.0
- */
- public int getNonPluginEntryCount() {
- return getNonPluginEntryModels().length;
- }
-
- /**
- * Returns an array of feature references included by this feature
- *
- * @return an erray of feature references, or an empty array.
- * @since 2.0
- */
- public IIncludedFeatureReference[] getRawIncludedFeatureReferences()
- throws CoreException {
- if (includedFeatureReferences == null)
- initializeIncludedReferences();
-
- if (includedFeatureReferences.size() == 0)
- return new IncludedFeatureReference[0];
-
- return (IIncludedFeatureReference[]) includedFeatureReferences.toArray(
- arrayTypeFor(includedFeatureReferences));
- }
- /**
- * Returns the download size of the feature, if it can be determined.
- *
- * @see IFeature#getDownloadSize()
- * @since 2.0
- */
- public long getDownloadSize() {
- try {
- Set allPluginEntries = new HashSet();
- Set allNonPluginEntries = new HashSet();
-
- IPluginEntry[] plugins = getPluginEntries();
- allPluginEntries.addAll(Arrays.asList(plugins));
- INonPluginEntry[] nonPlugins = getNonPluginEntries();
- allNonPluginEntries.addAll(Arrays.asList(nonPlugins));
-
- IFeatureReference[] children = getIncludedFeatureReferences();
- for (int i = 0; i < children.length; i++) {
- plugins = children[i].getFeature(null).getPluginEntries();
- allPluginEntries.addAll(Arrays.asList(plugins));
- nonPlugins = children[i].getFeature(null).getNonPluginEntries();
- allNonPluginEntries.addAll(Arrays.asList(nonPlugins));
- }
-
- IPluginEntry[] totalPlugins =
- new IPluginEntry[allPluginEntries.size()];
- INonPluginEntry[] totalNonPlugins =
- new INonPluginEntry[allNonPluginEntries.size()];
- if (allPluginEntries.size() != 0) {
- allPluginEntries.toArray(totalPlugins);
- }
- if (allNonPluginEntries.size() != 0) {
- allNonPluginEntries.toArray(totalNonPlugins);
- }
-
- return getFeatureContentProvider().getDownloadSizeFor(
- totalPlugins,
- totalNonPlugins);
-
- } catch (CoreException e) {
- UpdateCore.warn(null, e);
- return ContentEntryModel.UNKNOWN_SIZE;
- }
- }
-
- /**
- * Returns the install size of the feature, if it can be determined.
- *
- * @see IFeature#getInstallSize()
- * @since 2.0
- */
- public long getInstallSize() {
- try {
- Set allPluginEntries = new HashSet();
- Set allNonPluginEntries = new HashSet();
-
- IPluginEntry[] plugins = getPluginEntries();
- allPluginEntries.addAll(Arrays.asList(plugins));
- INonPluginEntry[] nonPlugins = getNonPluginEntries();
- allNonPluginEntries.addAll(Arrays.asList(nonPlugins));
-
- IFeatureReference[] children = getIncludedFeatureReferences();
- for (int i = 0; i < children.length; i++) {
- plugins = children[i].getFeature(null).getPluginEntries();
- allPluginEntries.addAll(Arrays.asList(plugins));
- nonPlugins = children[i].getFeature(null).getNonPluginEntries();
- allNonPluginEntries.addAll(Arrays.asList(nonPlugins));
- }
-
- IPluginEntry[] totalPlugins =
- new IPluginEntry[allPluginEntries.size()];
- INonPluginEntry[] totalNonPlugins =
- new INonPluginEntry[allNonPluginEntries.size()];
- if (allPluginEntries.size() != 0) {
- allPluginEntries.toArray(totalPlugins);
- }
- if (allNonPluginEntries.size() != 0) {
- allNonPluginEntries.toArray(totalNonPlugins);
- }
-
- return getFeatureContentProvider().getInstallSizeFor(
- totalPlugins,
- totalNonPlugins);
-
- } catch (CoreException e) {
- UpdateCore.warn(null, e);
- return ContentEntryModel.UNKNOWN_SIZE;
- }
- }
-
- /**
- * Returns the content provider for this feature.
- *
- * @see IFeature#getFeatureContentProvider()
- * @since 2.0
- */
- public IFeatureContentProvider getFeatureContentProvider()
- throws CoreException {
- if (featureContentProvider == null) {
- throw Utilities.newCoreException(
- Policy.bind(
- "Feature.NoContentProvider", //$NON-NLS-1$
- getVersionedIdentifier().toString()),
- null);
- }
- return this.featureContentProvider;
- }
-
- /**
- * Returns the content consumer for this feature.
- *
- * @see IFeature#getFeatureContentConsumer()
- * @since 2.0
- */
- public IFeatureContentConsumer getFeatureContentConsumer()
- throws CoreException {
- throw new UnsupportedOperationException();
- }
-
- /**
- * Sets the site for this feature.
- *
- * @see IFeature#setSite(ISite)
- * @since 2.0
- */
- public void setSite(ISite site) throws CoreException {
- if (this.site != null) {
- String featureURLString =
- (getURL() != null) ? getURL().toExternalForm() : ""; //$NON-NLS-1$
- throw Utilities.newCoreException(
- Policy.bind("Feature.SiteAlreadySet", featureURLString), //$NON-NLS-1$
- null);
- }
- this.site = site;
- }
-
- /**
- * Sets the content provider for this feature.
- *
- * @see IFeature#setFeatureContentProvider(IFeatureContentProvider)
- * @since 2.0
- */
- public void setFeatureContentProvider(IFeatureContentProvider featureContentProvider) {
- this.featureContentProvider = featureContentProvider;
- featureContentProvider.setFeature(this);
- }
-
- /**
- * Return the string representation of this fetaure
- *
- * @return feature as string
- * @since 2.0
- */
- public String toString() {
- String URLString =
- (getURL() == null)
- ? Policy.bind("Feature.NoURL") //$NON-NLS-1$
- : getURL().toExternalForm();
-
- String verString =
- Policy.bind(
- "Feature.FeatureVersionToString", //$NON-NLS-1$
- URLString,
- getVersionedIdentifier().toString());
- String label = getLabel() == null ? "" : getLabel(); //$NON-NLS-1$
- return verString + " [" + label + "]"; //$NON-NLS-1$ //$NON-NLS-2$
- }
-
- /*
- * Installation has been cancelled, abort and revert
- */
- private void abort() throws CoreException {
- String msg = Policy.bind("Feature.InstallationCancelled"); //$NON-NLS-1$
- throw new InstallAbortedException(msg, null);
- }
-
- /*
- * Initializes includes feature references
- * If the included feature reference is found on the site, add it to the List
- * Otherwise attempt to instanciate it using the same type as this feature and
- * using the default location on the site.
- */
- private void initializeIncludedReferences() throws CoreException {
- includedFeatureReferences = new ArrayList();
-
- IIncludedFeatureReference[] nestedFeatures = getFeatureIncluded();
- if (nestedFeatures.length == 0)
- return;
-
- ISite site = getSite();
- if (site == null)
- return;
-
- for (int i = 0; i < nestedFeatures.length; i++) {
- IIncludedFeatureReference include = nestedFeatures[i];
- IIncludedFeatureReference newRef =
- getPerfectIncludeFeature(site, include);
- includedFeatureReferences.add(newRef);
- }
- }
-
- /*
- *
- */
- private IIncludedFeatureReference getPerfectIncludeFeature(
- ISite site,
- IIncludedFeatureReference include)
- throws CoreException {
-
- // [20367] no site, cannot initialize nested references
- ISiteFeatureReference[] refs = site.getFeatureReferences();
- VersionedIdentifier identifier = include.getVersionedIdentifier();
-
- // too long to compute if not a file system
- // other solution would be to parse feature.xml
- // when parsing file system to create archive features/FeatureId_Ver.jar
- if ("file".equals(site.getURL().getProtocol())) { //$NON-NLS-1$
- // check if declared on the Site
- if (refs != null) {
- for (int ref = 0; ref < refs.length; ref++) {
- if (refs[ref] != null) {
- VersionedIdentifier id =
- refs[ref].getVersionedIdentifier();
- if (identifier.equals(id)) {
- // found a ISiteFeatureReference that matches our IIncludedFeatureReference
- IncludedFeatureReference newRef =
- new IncludedFeatureReference(refs[ref]);
- newRef.isOptional(include.isOptional());
- if (include instanceof FeatureReferenceModel)
- newRef.setLabel(
- ((FeatureReferenceModel) include)
- .getLabel());
- newRef.setSearchLocation(
- include.getSearchLocation());
- return newRef;
- }
- }
- }
- }
- }
-
- // instanciate by mapping it based on the site.xml
- // in future we may ask for a factory to create the feature ref
- IncludedFeatureReference newRef = new IncludedFeatureReference(include);
- newRef.setSite(getSite());
- IFeatureReference parentRef = getSite().getFeatureReference(this);
- if (parentRef instanceof FeatureReference) {
- newRef.setType(((FeatureReference) parentRef).getType());
- }
- String featureID =
- Site.DEFAULT_FEATURE_PATH + identifier.toString() + ".jar"; //$NON-NLS-1$
- URL featureURL =
- getSite().getSiteContentProvider().getArchiveReference(featureID);
- newRef.setURL(featureURL);
- newRef.setFeatureIdentifier(identifier.getIdentifier());
- newRef.setFeatureVersion(identifier.getVersion().toString());
- try {
- newRef.resolve(getSite().getURL(), null);
- // no need to get the bundle
- return newRef;
- } catch (Exception e) {
- throw Utilities.newCoreException(
- Policy.bind(
- "Feature.UnableToInitializeFeatureReference", //$NON-NLS-1$
- identifier.toString()),
- e);
- }
- }
-
- /*
- *
- */
- private void debug(String trace) {
- //DEBUG
- if (UpdateCore.DEBUG && UpdateCore.DEBUG_SHOW_INSTALL) {
- UpdateCore.debug(trace);
- }
- }
-
- /*
- *
- */
- private void setMonitorTaskName(
- IProgressMonitor monitor,
- String taskName) {
- if (monitor != null)
- monitor.setTaskName(taskName);
- }
-
- /*
- *
- */
- private void monitorWork(IProgressMonitor monitor, int tick)
- throws CoreException {
- if (monitor != null) {
- monitor.worked(tick);
- if (monitor.isCanceled()) {
- abort();
- }
- }
- }
-
- /*
- *
- */
- private void verifyReferences(
- IVerifier verifier,
- ContentReference[] references,
- InstallMonitor monitor,
- IVerificationListener verificationListener,
- boolean isFeature)
- throws CoreException {
- IVerificationResult vr = null;
- if (verifier != null) {
- for (int j = 0; j < references.length; j++) {
- vr = verifier.verify(this, references[j], isFeature, monitor);
- if (vr != null) {
- if (verificationListener == null)
- return;
-
- int result = verificationListener.prompt(vr);
-
- if (result == IVerificationListener.CHOICE_ABORT) {
- String msg = Policy.bind("JarVerificationService.CancelInstall"); //$NON-NLS-1$
- Exception e = vr.getVerificationException();
- throw new InstallAbortedException(msg, e);
- }
- if (result == IVerificationListener.CHOICE_ERROR) {
- throw Utilities
- .newCoreException(
- Policy.bind(
- "JarVerificationService.UnsucessfulVerification"), //$NON-NLS-1$
- vr.getVerificationException());
- }
- }
- }
- }
- }
-
- /*
- * returns reference if the same feature is installed on the site
- * [18867]
- */
- private IFeatureReference featureAlreadyInstalled(ISite targetSite) {
-
- ISiteFeatureReference[] references = targetSite.getFeatureReferences();
- IFeatureReference currentReference = null;
- for (int i = 0; i < references.length; i++) {
- currentReference = references[i];
- // do not compare URL
- try {
- if (this.equals(currentReference.getFeature(null)))
- return currentReference; // 18867
- } catch (CoreException e) {
- UpdateCore.warn(null, e);
- }
- }
-
- UpdateCore.warn(
- "ValidateAlreadyInstalled:Feature " //$NON-NLS-1$
- + this
- + " not found on site:" //$NON-NLS-1$
- + this.getURL());
- return null;
- }
-
- /*
- * re initialize children of the feature, invalidate the cache
- * @param result FeatureReference to reinitialize.
- */
- private void reinitializeFeature(IFeatureReference referenceToReinitialize) {
-
- if (referenceToReinitialize == null)
- return;
-
- if (UpdateCore.DEBUG && UpdateCore.DEBUG_SHOW_CONFIGURATION)
- UpdateCore.debug(
- "Re initialize feature reference:" + referenceToReinitialize); //$NON-NLS-1$
-
- IFeature feature = null;
- try {
- feature = referenceToReinitialize.getFeature(null);
- if (feature != null && feature instanceof Feature) {
- ((Feature) feature).initializeIncludedReferences();
- }
- // bug 24981 - recursively go into hierarchy
- // only if site if file
- ISite site = referenceToReinitialize.getSite();
- if (site == null)
- return;
- URL url = site.getURL();
- if (url == null)
- return;
- if ("file".equals(url.getProtocol())) { //$NON-NLS-1$
- IFeatureReference[] included =
- feature.getIncludedFeatureReferences();
- for (int i = 0; i < included.length; i++) {
- reinitializeFeature(included[i]);
- }
- }
- } catch (CoreException e) {
- UpdateCore.warn("", e); //$NON-NLS-1$
- }
- }
-
- /**
- * @see org.eclipse.update.core.IFeature#getRawIncludedFeatureReferences()
- */
- public IIncludedFeatureReference[] getIncludedFeatureReferences()
- throws CoreException {
- return filterFeatures(getRawIncludedFeatureReferences());
- }
-
- /*
- * Method filterFeatures.
- * Also implemented in Site
- *
- * @param list
- * @return List
- */
- private IIncludedFeatureReference[] filterFeatures(IIncludedFeatureReference[] allIncluded) {
- List list = new ArrayList();
- if (allIncluded != null) {
- for (int i = 0; i < allIncluded.length; i++) {
- IIncludedFeatureReference included = allIncluded[i];
- if (UpdateManagerUtils.isValidEnvironment(included))
- list.add(included);
- else {
- if (UpdateCore.DEBUG && UpdateCore.DEBUG_SHOW_WARNINGS) {
- UpdateCore.warn(
- "Filtered out feature reference:" + included); //$NON-NLS-1$
- }
- }
- }
- }
-
- IIncludedFeatureReference[] result =
- new IIncludedFeatureReference[list.size()];
- if (!list.isEmpty()) {
- list.toArray(result);
- }
-
- return result;
- }
-
- /**
- * @see org.eclipse.update.core.IFeature#getRawNonPluginEntries()
- */
- public INonPluginEntry[] getNonPluginEntries() {
- return filterNonPluginEntry(getRawNonPluginEntries());
- }
-
- /**
- * Method filterPluginEntry.
- * @param all
- * @return INonPluginEntry[]
- */
- private INonPluginEntry[] filterNonPluginEntry(INonPluginEntry[] all) {
- List list = new ArrayList();
- if (all != null) {
- for (int i = 0; i < all.length; i++) {
- if (UpdateManagerUtils.isValidEnvironment(all[i]))
- list.add(all[i]);
- }
- }
-
- INonPluginEntry[] result = new INonPluginEntry[list.size()];
- if (!list.isEmpty()) {
- list.toArray(result);
- }
-
- return result;
- }
-
- /**
- * @see org.eclipse.update.core.IFeature#getRawPluginEntries()
- */
- public IPluginEntry[] getPluginEntries() {
- return filterPluginEntry(getRawPluginEntries());
- }
-
- /**
- * @see org.eclipse.update.core.IFeature#getImports()
- */
- public IImport[] getImports() {
- return filterImports(getRawImports());
- }
-
- /**
- * Method filterImports.
- * @param all
- * @return IImport[]
- */
- private IImport[] filterImports(IImport[] all) {
- List list = new ArrayList();
- if (all != null) {
- for (int i = 0; i < all.length; i++) {
- if (UpdateManagerUtils.isValidEnvironment(all[i]))
- list.add(all[i]);
- }
- }
-
- IImport[] result = new IImport[list.size()];
- if (!list.isEmpty()) {
- list.toArray(result);
- }
-
- return result;
- }
-
-} \ No newline at end of file
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/FeatureContentProvider.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/FeatureContentProvider.java
deleted file mode 100644
index 4b186a436..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/FeatureContentProvider.java
+++ /dev/null
@@ -1,588 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import java.io.*;
-import java.net.*;
-import java.util.*;
-
-import org.eclipse.core.runtime.*;
-import org.eclipse.update.core.model.*;
-import org.eclipse.update.internal.core.*;
-
-/**
- * Base implementation of a feature content provider. This class provides a set
- * of helper methods useful for implementing feature content providers. In
- * particular, methods dealing with downloading and caching of feature files.
- * <p>
- * This class must be subclassed by clients.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.IFeatureContentProvider
- * @since 2.0
- */
-public abstract class FeatureContentProvider
- implements IFeatureContentProvider {
-
- private static final boolean SWITCH_COPY_LOCAL = true;
-
- /**
- *
- */
- public class FileFilter {
-
- private IPath filterPath = null;
-
- /**
- * Constructor for FileFilter.
- */
- public FileFilter(String filter) {
- super();
- this.filterPath = new Path(filter);
- }
-
- /**
- * returns true if the name matches the rule
- */
- public boolean accept(String name) {
-
- if (name == null)
- return false;
-
- // no '*' pattern matching
- // must be equals
- IPath namePath = new Path(name);
- if (filterPath.lastSegment().indexOf('*') == -1) {
- return filterPath.equals(namePath);
- }
-
- // check same file extension if extension exists (a.txt/*.txt)
- // or same file name (a.txt,a.*)
- String extension = filterPath.getFileExtension();
- if (!extension.equals("*")) { //$NON-NLS-1$
- if (!extension.equalsIgnoreCase(namePath.getFileExtension()))
- return false;
- } else {
- IPath noExtension = filterPath.removeFileExtension();
- String fileName = noExtension.lastSegment();
- if (!fileName.equals("*")) { //$NON-NLS-1$
- if (!namePath.lastSegment().startsWith(fileName))
- return false;
- }
- }
-
- // check same path
- IPath p1 = namePath.removeLastSegments(1);
- IPath p2 = filterPath.removeLastSegments(1);
- return p1.equals(p2);
- }
-
- }
-
- private URL base;
- private IFeature feature;
- private File tmpDir; // local work area for each provider
- public static final String JAR_EXTENSION = ".jar"; //$NON-NLS-1$
-
- private static final String DOT_PERMISSIONS = "permissions.properties"; //$NON-NLS-1$
- private static final String EXECUTABLES = "permissions.executable"; //$NON-NLS-1$
-
- // lock
- private final static Object lock = new Object();
-
- // hashtable of locks
- private static Hashtable locks = new Hashtable();
-
- /**
- * Feature content provider constructor
- *
- * @param base
- * feature URL. The interpretation of this URL is specific to
- * each content provider.
- * @since 2.0
- */
- public FeatureContentProvider(URL base) {
- this.base = base;
- this.feature = null;
- }
-
- /**
- * Returns the feature url.
- *
- * @see IFeatureContentProvider#getURL()
- */
- public URL getURL() {
- return base;
- }
-
- /**
- * Returns the feature associated with this content provider.
- *
- * @see IFeatureContentProvider#getFeature()
- */
- public IFeature getFeature() {
- return feature;
- }
-
- /**
- * Sets the feature associated with this content provider.
- *
- * @see IFeatureContentProvider#setFeature(IFeature)
- */
- public void setFeature(IFeature feature) {
- this.feature = feature;
- }
-
- /**
- * Returns the specified reference as a local file system reference. If
- * required, the file represented by the specified content reference is
- * first downloaded to the local system
- *
- * @param ref
- * content reference
- * @param monitor
- * progress monitor, can be <code>null</code>
- * @exception IOException
- * @exception CoreException
- * @since 2.0
- */
- public ContentReference asLocalReference(
- ContentReference ref,
- InstallMonitor monitor)
- throws IOException, CoreException {
-
- // check to see if this is already a local reference
- if (ref.isLocalReference())
- return ref;
-
- // check to see if we already have a local file for this reference
- String key = ref.toString();
-
- // need to synch as another thread my have created the file but
- // is still copying into it
- File localFile = null;
- FileFragment localFileFragment = null;
- Object keyLock = null;
- synchronized (lock) {
- if (locks.get(key) == null)
- locks.put(key, key);
- keyLock = locks.get(key);
- }
-
- synchronized (keyLock) {
- localFile = Utilities.lookupLocalFile(key);
- if (localFile != null) {
- // check if the cached file is still valid (no newer version on
- // server)
- if (UpdateManagerUtils
- .isSameTimestamp(ref.asURL(), localFile.lastModified()))
- return ref.createContentReference(
- ref.getIdentifier(),
- localFile);
- }
-
- if (localFile == null) {
- localFileFragment =
- UpdateManagerUtils.lookupLocalFileFragment(key);
- }
- //
- // download the referenced file into local temporary area
- InputStream is = null;
- OutputStream os = null;
- long bytesCopied = 0;
- long inputLength = 0;
- boolean success = false;
- if (monitor != null) {
- monitor.saveState();
- monitor.setTaskName(
- Policy.bind("FeatureContentProvider.Downloading")); //$NON-NLS-1$
- monitor.subTask(ref.getIdentifier() + " "); //$NON-NLS-1$
- monitor.setTotalCount(ref.getInputSize());
- monitor.showCopyDetails(true);
- }
-
- try {
- if (localFileFragment != null
- && "http".equals(ref.asURL().getProtocol())) { //$NON-NLS-1$
- localFile = localFileFragment.getFile();
- try {
- // get partial input stream
- is =
- ref.getPartialInputStream(
- localFileFragment.getSize());
- inputLength = ref.getInputSize()-localFileFragment.getSize();
- // get output stream to append to file fragment
- os =
- new BufferedOutputStream(
- new FileOutputStream(localFile, true));
- } catch (IOException e) {
- try {
- if (is != null)
- is.close();
- } catch (IOException ioe) {
- }
- is = null;
- os = null;
- localFileFragment = null;
- }
- }
- if (is == null) {
- // must download from scratch
- localFile =
- Utilities.createLocalFile(getWorkingDirectory(), null);
- try {
- is = ref.getInputStream();
- inputLength = ref.getInputSize();
- } catch (IOException e) {
- throw Utilities.newCoreException(
- Policy.bind(
- "FeatureContentProvider.UnableToRetrieve", //$NON-NLS-1$
- new Object[] { ref }),
- e);
- }
-
- try {
- os =
- new BufferedOutputStream(
- new FileOutputStream(localFile));
- } catch (FileNotFoundException e) {
- throw Utilities.newCoreException(
- Policy.bind(
- "FeatureContentProvider.UnableToCreate", //$NON-NLS-1$
- new Object[] { localFile }),
- e);
- }
- }
-
- Date start = new Date();
- if (localFileFragment != null) {
- bytesCopied = localFileFragment.getSize();
- if (monitor != null) {
- monitor.incrementCount(bytesCopied);
- }
- }
-
- // Transfer as many bytes as possible from input to output stream
- long offset = UpdateManagerUtils.copy(is, os, monitor, inputLength);
- if (offset != -1) {
- bytesCopied += offset;
- if (bytesCopied > 0) {
- // preserve partially downloaded file
- UpdateManagerUtils.mapLocalFileFragment(
- key,
- new FileFragment(localFile, bytesCopied));
- }
- if (monitor.isCanceled()) {
- String msg = Policy.bind("Feature.InstallationCancelled"); //$NON-NLS-1$
- throw new InstallAbortedException(msg, null);
- } else {
- throw new FeatureDownloadException(
- Policy.bind(
- "FeatureContentProvider.ExceptionDownloading", //$NON-NLS-1$
- new Object[] { getURL().toExternalForm()}),
- new IOException());
- }
- } else {
- UpdateManagerUtils.unMapLocalFileFragment(key);
- }
-
- Date stop = new Date();
- long timeInseconds = (stop.getTime() - start.getTime()) / 1000;
- // time in milliseconds /1000 = time in seconds
- InternalSiteManager.downloaded(
- ref.getInputSize(),
- (timeInseconds),
- ref.asURL());
-
- success = true;
-
- // file is downloaded succesfully, map it
- Utilities.mapLocalFile(key, localFile);
- } catch (ClassCastException e) {
- throw Utilities.newCoreException(
- Policy.bind(
- "FeatureContentProvider.UnableToCreate", //$NON-NLS-1$
- new Object[] { localFile }),
- e);
- } finally {
- //Do not close IS if user cancel,
- //closing IS will read the entire Stream until the end
- if (success && is != null)
- try {
- is.close();
- } catch (IOException e) {
- }
- if (os != null)
- try {
- os.close(); // should flush buffer stream
- } catch (IOException e) {
- }
-
- if (success || bytesCopied > 0) {
- // set the timestamp on the temp file to match the remote
- // timestamp
- localFile.setLastModified(ref.getLastModified());
- }
- if (monitor != null)
- monitor.restoreState();
- }
- locks.remove(key);
- } // end lock
- ContentReference reference =
- ref.createContentReference(ref.getIdentifier(), localFile);
- return reference;
- }
-
- /**
- * Returns the specified reference as a local file. If required, the file
- * represented by the specified content reference is first downloaded to
- * the local system
- *
- * @param ref
- * content reference
- * @param monitor
- * progress monitor, can be <code>null</code>
- * @exception IOException
- * @exception CoreException
- * @since 2.0
- */
- public File asLocalFile(ContentReference ref, InstallMonitor monitor)
- throws IOException, CoreException {
- File file = ref.asFile();
- if (file != null && !SWITCH_COPY_LOCAL)
- return file;
- ContentReference localRef = asLocalReference(ref, monitor);
- file = localRef.asFile();
- return file;
- }
-
- /**
- * Returns working directory for this content provider
- *
- * @return working directory
- * @exception IOException
- * @since 2.0
- */
- protected File getWorkingDirectory() throws IOException {
- if (tmpDir == null)
- tmpDir = Utilities.createWorkingDirectory();
- return tmpDir;
- }
-
- /**
- * Returns the total size of all archives required for the specified
- * plug-in and non-plug-in entries (the "packaging" view).
- *
- * @see IFeatureContentProvider#getDownloadSizeFor(IPluginEntry[],
- * INonPluginEntry[])
- */
- public long getDownloadSizeFor(
- IPluginEntry[] pluginEntries,
- INonPluginEntry[] nonPluginEntries) {
- long result = 0;
-
- // if both are null or empty, return UNKNOWN size
- if ((pluginEntries == null || pluginEntries.length == 0)
- && (nonPluginEntries == null || nonPluginEntries.length == 0)) {
- return ContentEntryModel.UNKNOWN_SIZE;
- }
-
- // loop on plugin entries
- long size = 0;
- if (pluginEntries != null)
- for (int i = 0; i < pluginEntries.length; i++) {
- size = ((PluginEntryModel) pluginEntries[i]).getDownloadSize();
- if (size == ContentEntryModel.UNKNOWN_SIZE) {
- return ContentEntryModel.UNKNOWN_SIZE;
- }
- result += size;
- }
-
- // loop on non plugin entries
- if (nonPluginEntries != null)
- for (int i = 0; i < nonPluginEntries.length; i++) {
- size =
- ((NonPluginEntryModel) nonPluginEntries[i])
- .getDownloadSize();
- if (size == ContentEntryModel.UNKNOWN_SIZE) {
- return ContentEntryModel.UNKNOWN_SIZE;
- }
- result += size;
- }
-
- return result;
- }
-
- /**
- * Returns the total size of all files required for the specified plug-in
- * and non-plug-in entries (the "logical" view).
- *
- * @see IFeatureContentProvider#getInstallSizeFor(IPluginEntry[],
- * INonPluginEntry[])
- */
- public long getInstallSizeFor(
- IPluginEntry[] pluginEntries,
- INonPluginEntry[] nonPluginEntries) {
- long result = 0;
-
- // if both are null or empty, return UNKNOWN size
- if ((pluginEntries == null || pluginEntries.length == 0)
- && (nonPluginEntries == null || nonPluginEntries.length == 0)) {
- return ContentEntryModel.UNKNOWN_SIZE;
- }
-
- // loop on plugin entries
- long size = 0;
- if (pluginEntries != null)
- for (int i = 0; i < pluginEntries.length; i++) {
- size = ((PluginEntryModel) pluginEntries[i]).getInstallSize();
- if (size == ContentEntryModel.UNKNOWN_SIZE) {
- return ContentEntryModel.UNKNOWN_SIZE;
- }
- result += size;
- }
-
- // loop on non plugin entries
- if (nonPluginEntries != null)
- for (int i = 0; i < nonPluginEntries.length; i++) {
- size =
- ((NonPluginEntryModel) nonPluginEntries[i])
- .getInstallSize();
- if (size == ContentEntryModel.UNKNOWN_SIZE) {
- return ContentEntryModel.UNKNOWN_SIZE;
- }
- result += size;
- }
-
- return result;
- }
-
- /**
- * Returns the path identifier for a plugin entry. <code>plugins/&lt;pluginId>_&lt;pluginVersion>.jar</code>
- *
- * @return the path identifier
- */
- protected String getPathID(IPluginEntry entry) {
- return Site.DEFAULT_PLUGIN_PATH
- + entry.getVersionedIdentifier().toString()
- + JAR_EXTENSION;
- }
-
- /**
- * Returns the path identifer for a non plugin entry. <code>features/&lt;featureId>_&lt;featureVersion>/&lt;dataId></code>
- *
- * @return the path identifier
- */
- protected String getPathID(INonPluginEntry entry) {
- String nonPluginBaseID =
- Site.DEFAULT_FEATURE_PATH
- + feature.getVersionedIdentifier().toString()
- + "/"; //$NON-NLS-1$
- return nonPluginBaseID + entry.getIdentifier();
- }
-
- /**
- * Sets the permission of all the ContentReferences Check for the
- * .permissions contentReference and use it to set the permissions of other
- * ContentReference
- */
- protected void validatePermissions(ContentReference[] references) {
-
- if (references == null || references.length == 0)
- return;
-
- Map permissions = getPermissions(references);
- if (permissions.isEmpty())
- return;
-
- for (int i = 0; i < references.length; i++) {
- ContentReference contentReference = references[i];
- String id = contentReference.getIdentifier();
- Object value = null;
- if ((value = matchesOneRule(id, permissions)) != null) {
- Integer permission = (Integer) value;
- contentReference.setPermission(permission.intValue());
- }
- }
- }
-
- /**
- * Returns the value of the matching rule or <code>null</code> if none
- * found. A rule is matched if the id is equals to a key, or if the id is
- * resolved by a key. if the id is <code>/path/file.txt</code> it is
- * resolved by <code>/path/*</code> or <code>/path/*.txt</code>
- *
- * @param id
- * the identifier
- * @param permissions
- * list of rules
- * @return Object the value of the matcing rule or <code>null</code>
- */
- private Object matchesOneRule(String id, Map permissions) {
-
- Set keySet = permissions.keySet();
- Iterator iter = keySet.iterator();
- while (iter.hasNext()) {
- FileFilter rule = (FileFilter) iter.next();
- if (rule.accept(id)) {
- return permissions.get(rule);
- }
- }
-
- return null;
- }
-
- /*
- * returns the permission MAP
- */
- private Map getPermissions(ContentReference[] references) {
-
- Map result = new HashMap();
- // search for .permissions
- boolean notfound = true;
- ContentReference permissionReference = null;
- for (int i = 0; i < references.length && notfound; i++) {
- ContentReference contentReference = references[i];
- if (DOT_PERMISSIONS.equals(contentReference.getIdentifier())) {
- notfound = false;
- permissionReference = contentReference;
- }
- }
- if (notfound)
- return result;
-
- Properties prop = new Properties();
- try {
- prop.load(permissionReference.getInputStream());
- } catch (IOException e) {
- UpdateCore.warn("", e); //$NON-NLS-1$
- }
-
- String executables = prop.getProperty(EXECUTABLES);
- if (executables == null)
- return result;
-
- StringTokenizer tokenizer = new StringTokenizer(executables, ","); //$NON-NLS-1$
- Integer defaultExecutablePermission =
- new Integer(ContentReference.DEFAULT_EXECUTABLE_PERMISSION);
- while (tokenizer.hasMoreTokens()) {
- FileFilter filter = new FileFilter(tokenizer.nextToken());
- result.put(filter, defaultExecutablePermission);
- }
-
- return result;
- }
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/FeatureReference.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/FeatureReference.java
deleted file mode 100644
index dba2ac8b3..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/FeatureReference.java
+++ /dev/null
@@ -1,288 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import java.net.*;
-
-import org.eclipse.core.runtime.*;
-import org.eclipse.update.core.model.*;
-import org.eclipse.update.internal.core.*;
-
-/**
- * Convenience implementation of a feature reference.
- * <p>
- * This class may be instantiated or subclassed by clients.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.IFeatureReference
- * @see org.eclipse.update.core.model.FeatureReferenceModel
- * @since 2.0
- */
-public class FeatureReference extends FeatureReferenceModel implements IFeatureReference, IPlatformEnvironment {
-
- private VersionedIdentifier versionId;
-
- //PERF: new instance variable
- private IFeature exactFeature;
-
- /**
- * Feature reference default constructor
- */
- public FeatureReference() {
- super();
- }
-
- /**
- * Constructor FeatureReference.
- * @param ref the reference to copy
- */
- public FeatureReference(IFeatureReference ref) {
- super((FeatureReferenceModel) ref);
- try {
- setURL(ref.getURL());
- } catch (CoreException e) {
- UpdateCore.warn("", e); //$NON-NLS-1$
- }
- }
-
- /**
- * Constructor FeatureReference.
- * @param ref the reference to copy
- */
- public FeatureReference(FeatureReferenceModel ref) {
- super(ref);
- try {
- setURL(ref.getURL());
- } catch (CoreException e) {
- UpdateCore.warn("", e); //$NON-NLS-1$
- }
- }
-
- /**
- * Returns the feature this reference points to
- * @return the feature on the Site
- * @deprecated use getFeaure(IProgressMonitor)
- */
- public IFeature getFeature() throws CoreException {
- return getFeature(null);
- }
-
- /**
- * Returns the feature this reference points to
- * @return the feature on the Site
- */
- public IFeature getFeature(IProgressMonitor monitor) throws CoreException {
-
- if (exactFeature != null)
- return exactFeature;
- exactFeature = getFeature(this,monitor);
- return exactFeature;
- }
-
- /**
- * Returns the feature the reference points to
- * @param ref the feature reference
- * @return the feature on the Site
- */
- protected IFeature getFeature(IFeatureReference ref,IProgressMonitor monitor) throws CoreException {
-
- IFeature feature = null;
- URL refURL = ref.getURL();
- feature = createFeature(refURL,monitor);
- return feature;
- }
-
- /*
- * create an instance of a concrete feature corresponding to this reference
- */
- private IFeature createFeature(URL url,IProgressMonitor monitor) throws CoreException {
- String type = getType();
- ISite site = getSite();
- // if the site exists, use the site factory
- if (site != null) {
- return site.createFeature(type, url, monitor);
- }
-
- IFeatureFactory factory = FeatureTypeFactory.getInstance().getFactory(type);
- return factory.createFeature(url, site, monitor);
- }
-
- /**
- * Returns the update site for the referenced feature
- *
- * @see IFeatureReference#getSite()
- * @since 2.0
- */
- public ISite getSite() {
- return (ISite) getSiteModel();
- }
-
- /**
- * Sets the feature reference URL.
- * This is typically performed as part of the feature reference creation
- * operation. Once set, the url should not be reset.
- *
- * @see IFeatureReference#setURL(URL)
- * @since 2.0
- */
- public void setURL(URL url) throws CoreException {
- if (url != null) {
- setURLString(url.toExternalForm());
- try {
- resolve(url, null);
- } catch (MalformedURLException e) {
- throw Utilities.newCoreException(Policy.bind("FeatureReference.UnableToResolveURL", url.toExternalForm()), e); //$NON-NLS-1$
- }
- }
- }
-
- /**
- * Associates a site with the feature reference.
- * This is typically performed as part of the feature reference creation
- * operation. Once set, the site should not be reset.
- *
- * @see IFeatureReference#setSite(ISite)
- * @since 2.0
- */
- public void setSite(ISite site) {
- setSiteModel((SiteModel) site);
- }
-
- /**
- * Returns the feature identifier.
- *
- * @see IFeatureReference#getVersionedIdentifier()
- * @since 2.0
- */
- public VersionedIdentifier getVersionedIdentifier() {
-
- if (versionId != null)
- return versionId;
-
- String id = getFeatureIdentifier();
- String ver = getFeatureVersion();
- if (id != null && ver != null) {
- try {
- versionId = new VersionedIdentifier(id, ver);
- return versionId;
- } catch (Exception e) {
- UpdateCore.warn("Unable to create versioned identifier:" + id + ":" + ver); //$NON-NLS-1$ //$NON-NLS-2$
- }
- }
-
- // we need the exact match or we may have an infinite loop
- versionId = new VersionedIdentifier(getURL().toExternalForm(), null);
- try {
- versionId = getFeature(null).getVersionedIdentifier();
- } catch (CoreException e) {
- UpdateCore.warn("", e); //$NON-NLS-1$
- }
- return versionId;
- }
-
- /**
- * @see org.eclipse.update.core.IFeatureReference#getName()
- */
- public String getName() {
- if (super.getLabel() != null)
- return super.getLabel();
- try {
- return getFeature(null).getLabel();
- } catch (CoreException e) {
- return getVersionedIdentifier().toString();
- }
- }
-
- /**
- * Get optional operating system specification as a comma-separated string.
- *
- * @return the operating system specification string, or <code>null</code>.
- * @since 2.1
- */
- public String getOS() {
- if (super.getOS() == null && getURL()!=null)
- try {
- return getFeature(null).getOS();
- } catch (CoreException e) {
- return null;
- }
- return super.getOS();
- }
-
- /**
- * Get optional windowing system specification as a comma-separated string.
- *
- * @return the windowing system specification string, or <code>null</code>.
- * @since 2.1
- */
- public String getWS() {
- if (super.getWS() == null && getURL()!=null)
- try {
- return getFeature(null).getWS();
- } catch (CoreException e) {
- return null;
- }
- return super.getWS();
- }
-
- /**
- * Get optional system architecture specification as a comma-separated string.
- *
- * @return the system architecture specification string, or <code>null</code>.
- * @since 2.1
- */
- public String getOSArch() {
- if (super.getOSArch() == null && getURL()!=null)
- try {
- return getFeature(null).getOSArch();
- } catch (CoreException e) {
- return null;
- }
- return super.getOSArch();
- }
-
- /**
- * Get optional locale specification as a comma-separated string.
- *
- * @return the locale specification string, or <code>null</code>.
- * @since 2.1
- */
- public String getNL() {
- if (super.getNL() == null && getURL()!=null)
- try {
- return getFeature(null).getNL();
- } catch (CoreException e) {
- return null;
- }
- return super.getNL();
- }
-
- /**
- * Returns <code>true</code> if this feature is patching another feature,
- * <code>false</code> otherwise
- * @return boolean
- */
- public boolean isPatch() {
- if (super.getPatch() == null)
- try {
- return getFeature(null).isPatch();
- } catch (CoreException e) {
- return false;
- }
- return "true".equalsIgnoreCase(super.getPatch()); //$NON-NLS-1$
- }
-
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/IArchiveReference.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/IArchiveReference.java
deleted file mode 100644
index ba777c789..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/IArchiveReference.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import java.net.*;
-
-import org.eclipse.core.runtime.*;
-
-/**
- * Site archive interface.
- * Site archive is a representation of a packaged archive (file) located
- * on an update site. It allows a "symbolic" path used to identify
- * a plug-in or non-plug-in feature entry to be explicitly mapped
- * to a specific URL.
- * <p>
- * Clients may implement this interface. However, in most cases clients should
- * directly instantiate or subclass the provided implementation of this
- * interface.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.ArchiveReference
- * @since 2.0
- */
-public interface IArchiveReference extends IAdaptable {
-
- /**
- *
- * @return the archive "symbolic" path, or <code>null</code>
- * @since 2.0
- */
- public String getPath();
-
- /**
- * Retrieve the site archive URL
- *
- * @return the archive URL, or <code>null</code>
- * @since 2.0
- */
- public URL getURL();
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/ICategory.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/ICategory.java
deleted file mode 100644
index 21f464524..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/ICategory.java
+++ /dev/null
@@ -1,64 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import org.eclipse.core.runtime.*;
-
-/**
- * Feature category definition.
- * A site can organize its features into categories. Categories
- * can be further organized into hierarchies. Each category name
- * is a composed of the name of its parent and a simple identifier
- * separated by a slash ("/"). For example <code>tools/utilities/print</code>
- * defines a category that is a child of <code>tools/utilities</code> and
- * grandchild of <code>tools</code>.
- * <p>
- * Clients may implement this interface. However, in most cases clients should
- * directly instantiate or subclass the provided implementation of this
- * interface.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.Category
- * @since 2.0
- */
-public interface ICategory extends IAdaptable{
-
- /**
- * Retrieve the name of the category. The name can be a simple
- * token (root category) or a number of slash-separated ("/")
- * tokens.
- *
- * @return the category name
- * @since 2.0
- */
- public String getName();
-
- /**
- * Retrieve the displayable label for the category
- *
- * @return displayable category label, or <code>null</code>
- * @since 2.0
- */
- public String getLabel();
-
- /**
- * Retrieve the detailed category description
- *
- * @return category description, or <code>null</code>
- * @since 2.0
- */
- public IURLEntry getDescription();
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/IContentConsumer.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/IContentConsumer.java
deleted file mode 100644
index 2c5bf4e2c..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/IContentConsumer.java
+++ /dev/null
@@ -1,57 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import org.eclipse.core.runtime.*;
-
-/**
- * Generic content consumer.
- * A generic content consumer is used to store plug-in and non-plug-in files
- * for a feature.
- * <p>
- * Clients may implement this interface. However, in most cases clients
- * will only use the content consumer provided by the feature type(s)
- * implemented by the platform.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.IFeatureContentConsumer
- * @since 2.0
- */
-public interface IContentConsumer {
-
- /**
- * Stores a file.
- *
- * @see IFeatureContentConsumer#open(IPluginEntry)
- * @see IFeatureContentConsumer#open(INonPluginEntry)
- * @param contentReference reference to the file to store
- * @param monitor progress monitor, can be <code>null</code>
- * @exception CoreException
- * @since 2.0
- */
- public void store(ContentReference contentReference, IProgressMonitor monitor)
- throws CoreException;
-
- /**
- * Indicates successful completion of the store operations for this
- * consumer
- *
- * @exception CoreException
- * @since 2.0
- */
- public void close() throws CoreException;
-
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/IFeature.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/IFeature.java
deleted file mode 100644
index 2dd17cb8d..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/IFeature.java
+++ /dev/null
@@ -1,479 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.update.core;
-
-import java.net.*;
-
-import org.eclipse.core.runtime.*;
-import org.eclipse.update.core.model.*;
-
-/**
- * Feature defines the packaging "container" for a group of related plug-ins,
- * plug-in fragments, and optionally non-plug-in files.
- * <p>
- * Features are treated purely as an installation and packaging construct.
- * They do not play a role during Eclipse plug-in execution.
- * They are simply an inclusive "manifest" of the plug-ins, fragments
- * and other files that make up that feature. If features are logically made
- * up of plug-ins from "sub-features", the top-level feature "manifest"
- * must be fully resolved at packaging time.
- * </p>
- * <p>
- * Clients may implement this interface. However, in most cases clients should
- * directly instantiate or subclass the provided implementation of this
- * interface.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.Feature
- * @since 2.0
- */
-public interface IFeature extends IAdaptable, IPlatformEnvironment {
-
- /**
- * Indicates a 'happy' feature
- * A feature is considered to be 'happy' in the context of a local site
- * if all the plug-ins referenced by the feature are installed on the site and no other
- * version of any of the plug-ins are installed on any other site of the local site.
- *
- * @see org.eclipse.update.configuration.IConfiguredSite#getBrokenStatus(IFeature)
- * @since 2.0
- */
- public static final int STATUS_HAPPY = 0;
-
- /**
- * Indicates a 'happy' feature
- * A feature is considered to be 'ambiguous' in the context of a local site
- * if all the plug-ins referenced by the feature are installed on the site and other
- * version of any of the plug-ins are installed on any other site of the local site.
- *
- * @see org.eclipse.update.configuration.IConfiguredSite#getBrokenStatus(IFeature)
- */
- public static final int STATUS_AMBIGUOUS = 1;
-
- /**
- * Indicates an 'unhappy' feature
- * A feature is considered to be 'unhappy' in the context of this site,
- * if some of the plug-ins referenced by the feature are not installed on this site.
- *
- * @see org.eclipse.update.configuration.IConfiguredSite#getBrokenStatus(IFeature)
- * @since 2.0
- */
- public static final int STATUS_UNHAPPY = 2;
-
-
- /**
- * Indicates a disable feature
- *
- * @see org.eclipse.update.configuration.IConfiguredSite#getBrokenStatus(IFeature)
- * @since 2.0.2
- */
- public static final int STATUS_DISABLED = -1;
-
- /**
- * Indicates the one-click update will search the
- * location of the nesting root feature.
- *
- * @since 2.0.1
- */
- public static final int SEARCH_LOCATION_DEFAULT = 0;
-
- /**
- * Indicates the one-click update will search the
- * location defined by the feature.
- *
- * @since 2.0.1
- */
- public static final int SEARCH_LOCATION_FEATURE = 1;
-
- /**
- * Indicates the one-click update will search both the
- * location of the nesting root feature and the
- * location defined by the feature.
- *
- * @since 2.0.1
- */
- public static final int SEARCH_LOCATION_BOTH = 2;
-
-
- /**
- * Returns the feature identifier.
- *
- * @return the feature identifier.
- * @since 2.0
- */
- public VersionedIdentifier getVersionedIdentifier();
-
- /**
- * Returns the site this feature is associated with.
- *
- * @return the site for this feature
- * @since 2.0
- */
- public ISite getSite();
-
- /**
- * Returns the displayable label of the feature.
- *
- * @return feature label, or <code>null</code>.
- * @since 2.0
- */
- public String getLabel();
-
- /**
- * Returns the feature URL.
- * This is the URL that was used to create the feature. The interpretation
- * of the URL is dependent on the concrete feature implementation. *
- * @return feature URL
- * @since 2.0
- */
- public URL getURL();
-
- /**
- * Returns an information entry referencing the location of the
- * feature update site. The update site can be accessed to obtain
- * feature updates for this feature.
- *
- * @return update site entry, or <code>null</code>.
- * @since 2.0
- */
- public IURLEntry getUpdateSiteEntry();
-
- /**
- * Return an array of information entries referencing locations of other
- * update sites. This mechanism can be used by features to distribute
- * location information about general update sites to clients.
- *
- * @return an array of site entries, or an empty array.
- * @since 2.0
- */
- public IURLEntry[] getDiscoverySiteEntries();
-
- /**
- * Returns a displayable label identifying the provider of this feature
- *
- * @return provider label, or <code>null</code>.
- * @since 2.0
- */
- public String getProvider();
-
- /**
- * Returns and optional custom install handler entry.
- *
- * @return install handler entry, or <code>null</code> if
- * none was specified
- * @since 2.0
- */
- public IInstallHandlerEntry getInstallHandlerEntry();
-
- /**
- * Returns the feature description.
- *
- * @return feature rescription, or <code>null</code>.
- * @since 2.0
- */
- public IURLEntry getDescription();
-
- /**
- * Returns the copyright information for the feature.
- *
- * @return copyright information, or <code>null</code>.
- * @since 2.0
- */
- public IURLEntry getCopyright();
-
- /**
- * Returns the license information for the feature.
- *
- * @return feature license, or <code>null</code>.
- * @since 2.0
- */
- public IURLEntry getLicense();
-
- /**
- * Return optional image for the feature.
- *
- * @return the URL pointing to the image, , or <code>null</code>.
- * @since 2.0
- */
- public URL getImage();
-
- /**
- * Return a list of plug-in dependencies for this feature. A plug-in
- * dependency is a reference to a plug-in required for feature execution
- * that is not packaged as part of the feature.
- * filtered by the operating system, windowing system and architecture system
- * set in <code>Sitemanager</code>
- *
- * @return the list of required plug-in dependencies, or an empty array.
- * @since 2.0
- */
- public IImport[] getImports();
-
- /**
- * Return a list of plug-in dependencies for this feature. A plug-in
- * dependency is a reference to a plug-in required for feature execution
- * that is not packaged as part of the feature.
- * No filtering occurs
- *
- * @return the list of required plug-in dependencies, or an empty array.
- * @since 2.1
- */
- public IImport[] getRawImports();
-
- /**
- * Return the identifier of the primary plugin associated to this feature
- * or <code>null</code> if the feature is not a primary feature.
- * If the primary plugin id is not specified and the feature is a primary
- * feature, returns the feature identifier.
- *
- * @return the identifier of the associated primary plugin or <code>null</code>
- * @since 2.1
- */
- public String getPrimaryPluginID();
-
-
- /**
- * Install the contents of this feature into the specified target feature.
- * All optional features will be installed
- *
- * @param targetFeature
- * @param verificationListener
- * @param monitor
- * @exception InstallAbortedException when the user cancels the install
- * @exception CoreException
- * @since 2.0
- */
- public IFeatureReference install(
- IFeature targetFeature,
- IVerificationListener verificationListener,
- IProgressMonitor monitor)
- throws InstallAbortedException,CoreException;
-
- /**
- * Install the contents of this feature into the specified target feature.
- * Only the listed optional features will be installed.
- *
- * @param targetFeature
- * @param optionalFeatures the optional features to be installed
- * @param verificationListener
- * @param monitor
- * @exception InstallAbortedException when the user cancels the install
- * @exception CoreException
- * @since 2.0.1
- */
- public IFeatureReference install(
- IFeature targetFeature,
- IFeatureReference[] optionalFeatures,
- IVerificationListener verificationListener,
- IProgressMonitor monitor)
- throws InstallAbortedException,CoreException;
-
- /**
- * Returns an array of feature references included by this feature
- * filtered by the operating system, windowing system and architecture system
- * set in <code>Sitemanager</code>
- *
- * @return an erray of feature references, or an empty array.
- * @since 2.0
- */
- public IIncludedFeatureReference[] getIncludedFeatureReferences() throws CoreException;
-
- /**
- * Returns an array of feature references included by this feature
- * No filtering occurs
- *
- * @return an erray of feature references, or an empty array.
- * @since 2.0
- */
- public IIncludedFeatureReference[] getRawIncludedFeatureReferences() throws CoreException;
-
- /**
- * Returns an array of plug-in entries referenced by this feature
- * filtered by the operating system, windowing system and architecture system
- * set in <code>Sitemanager</code>
- *
- * @return an erray of plug-in entries, or an empty array.
- * @since 2.0
- */
- public IPluginEntry[] getPluginEntries();
-
- /**
- * Returns an array of plug-in entries referenced by this feature
- * No filtering occurs
- *
- * @return an erray of plug-in entries, or an empty array.
- * @since 2.1
- */
- public IPluginEntry[] getRawPluginEntries();
-
- /**
- * Returns the count of referenced plug-in entries.
- *
- * @return plug-in entry count
- * @since 2.0
- */
- public int getPluginEntryCount();
-
- /**
- * Returns an array of non-plug-in entries referenced by this feature
- * filtered by the operating system, windowing system and architecture system
- * set in <code>Sitemanager</code>
- *
- * @return an erray of non-plug-in entries, or an empty array.
- * @since 2.0
- */
- public INonPluginEntry[] getNonPluginEntries();
-
- /**
- * Returns an array of non-plug-in entries referenced by this feature
- * No filtering occurs
- *
- * @return an erray of non-plug-in entries, or an empty array.
- * @since 2.1
- */
- public INonPluginEntry[] getRawNonPluginEntries();
-
- /**
- * Returns the count of referenced non-plug-in entries.
- *
- * @return non-plug-in entry count
- * @since 2.0
- */
- public int getNonPluginEntryCount();
-
- /**
- * Returns the download size of the feature, if it can be determined.
- *
- * @see org.eclipse.update.core.model.ContentEntryModel#UNKNOWN_SIZE
- * @return download size of the feature in KiloBytes, or an indication
- * the size could not be determined
- * @since 2.0
- */
- public long getDownloadSize();
-
- /**
- * Returns the install size of the feature, if it can be determined.
- *
- * @see org.eclipse.update.core.model.ContentEntryModel#UNKNOWN_SIZE
- * @return install size of the feature in KiloBytes, or an indication
- * the size could not be determined
- * @since 2.0
- */
- public long getInstallSize();
-
- /**
- * Indicates whether the feature can be used as a primary feature.
- *
- * @return <code>true</code> if this is a primary feature,
- * otherwise <code>false</code>
- * @since 2.0
- */
- public boolean isPrimary();
-
- /**
- * Indicates whether the feature must be processed alone during installation
- * and configuration. Features that are not exclusive can be installed in a
- * batch.
- *
- * @return <code>true</code> if feature requires exclusive processing,
- * <code>false</code> otherwise.
- * @since 2.1
- */
- public boolean isExclusive();
-
- /**
- * Returns an optional identifier of an application to be used when
- * starting up the platform with this feature as the primary feature.
- * The application identifier must represent a valid application registered
- * in the <code>org.eclipse.core.runtime.applications</code> extension point.
- *
- * @return application identifier, or <code>null</code>
- * @since 2.0
- */
- public String getApplication();
-
- /**
- * Returns an optional identifier of a colocation affinity feature.
- *
- * @return feature identifier, or <code>null</code>.
- * @since 2.0
- */
- public String getAffinityFeature();
-
- /**
- * Returns the content provider for this feature. A content provider
- * is an abstraction of each feature internal packaging structure.
- * It allows the feature content to be accessed in a standard way
- * regardless of the internal packaging. All concrete features
- * need to be able to return a content provider.
- *
- * @return feature content provider
- * @exception CoreException
- * @since 2.0
- */
- public IFeatureContentProvider getFeatureContentProvider()
- throws CoreException;
-
- /**
- * Returns the content consumer for this feature. A content consumer
- * is an abstraction of each feature internal packaging mechanism.
- * It allows content to be stored into a feature in a standard way
- * regardless of the packaging mechanism used. Only concrete features
- * that support storing need to implement a content consumer. The platform
- * implements at least one feature type supporting content consumer.
- * This is the feature type representing a locally-installed
- * feature.
- *
- * @return feature content consumer
- * @exception CoreException
- * @exception UnsupportedOperationException
- * @since 2.0
- */
- public IFeatureContentConsumer getFeatureContentConsumer()
- throws CoreException;
-
- /**
- * Sets the site for this feature. This is typically performed as part
- * of the feature creation operation. Once set, the site
- * should not be reset.
- *
- * @param site the site
- * @throws CoreException site for this feature is already set
- * @since 2.0
- */
- public void setSite(ISite site) throws CoreException;
-
- /**
- * Sets the content provider for this feature. This is typically
- * performed as part of the feature creation operation. Once set, the
- * provider should not be reset.
- *
- * @param featureContentProvider content provider
- * @since 2.0
- */
- public void setFeatureContentProvider(IFeatureContentProvider featureContentProvider);
-
- /**
- * Returns <code>true</code> if this feature is patching another feature,
- * <code>false</code> otherwise
- * @return boolean
- * @since 2.1
- */
- public boolean isPatch();
-
-
-} \ No newline at end of file
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/IFeatureContentConsumer.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/IFeatureContentConsumer.java
deleted file mode 100644
index 7ae37f747..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/IFeatureContentConsumer.java
+++ /dev/null
@@ -1,165 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import org.eclipse.core.runtime.*;
-
-/**
- * Feature content consumer.
- * A feature content consumer is an abstraction of each feature internal
- * packaging mechanism. It allows content to be stored into a feature in
- * a standard way regardless of the packaging mechanism used. Only concrete
- * features that support storing need to implement a content consumer.
- * The platform implements at least one feature type supporting content
- * consumer. This is the feature type representing a locally-installed
- * feature.
- * <p>
- * A feature content consumer delegates the storage of plug-in and
- * non-plug-in files to a generic content consumer.
- * </p>
- * <p>
- * Clients may implement this interface. However, in most cases clients
- * will only use the feature content consumer provided by the feature type(s)
- * implemented by the platform.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.IContentConsumer
- * @since 2.0
- */
-public interface IFeatureContentConsumer {
-
-
- /**
- * Store a feature file.
- * Note that only the feature definition files should be stored using
- * this method. Plug-in files and non-plug-in data files should be
- * stored using the content consumers corresponding to their respective
- * entries.
- *
- * @see #open(IPluginEntry)
- * @see #open(INonPluginEntry)
- * @param contentReference content reference to feature file
- * @param monitor progress monitor, can be <code>null</code>
- * @exception CoreException
- * @since 2.0
- */
- public void store(ContentReference contentReference, IProgressMonitor monitor)
- throws CoreException;
-
- /**
- * Opens a generic content consumer for the specified plug-in entry.
- * Plug-in files corresponding to this entry should be stored
- * using this content consumer.
- *
- * @param pluginEntry plug-in entry
- * @return generic content consumer for the entry
- * @exception CoreException
- * @since 2.0
- */
- public IContentConsumer open(IPluginEntry pluginEntry) throws CoreException;
-
- /**
- * Opens a generic content consumer for the specified non-plug-in entry.
- * Non-plug-in files corresponding to this entry should be stored
- * using this content consumer.
- *
- * @param nonPluginEntry non-plug-in entry
- * @return generic content consumer for the entry
- * @exception CoreException
- * @since 2.0
- */
- public IContentConsumer open(INonPluginEntry nonPluginEntry)
- throws CoreException;
-
- /**
- * Closes this content consumer. This indicates a successful completion
- * of the store operations. The content consumer commits any changes
- * made by this consumer.
- *
- * @return reference to the newly populated feature
- * @exception CoreException
- * @since 2.0
- */
- public IFeatureReference close() throws CoreException;
-
- /**
- * Closes this content consumer, indicating the store operations should
- * be aborted. The content consumer attempts to back out any changes
- * made by this content consumer.
- *
- * @exception CoreException
- * @since 2.0
- */
- public void abort() throws CoreException;
-
- /**
- * Sets the feature for this content consumer.
- * In general, this method should only be called as part of
- * feature creation. Once set, the feature should not be reset.
- *
- * @param feature feature for this content consumer
- * @since 2.0
- */
- public void setFeature(IFeature feature);
-
- /**
- * Returns the feature for this content consumer.
- *
- * @return the feature for this content consumer
- * @since 2.0
- */
- public IFeature getFeature();
-
- /**
- * Sets the parent for this content consumer.
- * In general, this method should only be called as part of
- * feature creation. Once set, the feature should not be reset.
- *
- * @param parent parent feature content consumer.
- * @since 2.0
- */
- public void setParent(IFeatureContentConsumer parent);
-
- /**
- * Returns the feature content consumer that opened
- * this feature content consumer, or <code>null</code>
- * if this feature content consumer is a root feature
- * content consumer.
- *
- * @return the parent feature content consumer, or null.
- * @since 2.0
- */
- public IFeatureContentConsumer getParent();
-
- /**
- * Link the content consumer of the feature as a child
- * content consumer
- *
- * @param feature the child feature.
- * @throws CoreException
- * @since 2.0
- */
- public void addChild(IFeature feature) throws CoreException;
-
- /**
- * Returns the feature content consumers that
- * this feature content consumer opened
- *
- * @return an array of feature content consumer, or en empty array.
- * @since 2.0
- */
- public IFeatureContentConsumer[] getChildren();
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/IFeatureContentProvider.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/IFeatureContentProvider.java
deleted file mode 100644
index 0580b0d4f..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/IFeatureContentProvider.java
+++ /dev/null
@@ -1,268 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import java.net.*;
-
-import org.eclipse.core.runtime.*;
-
-/**
- * Feature content provider.
- * A feature content provider is an abstraction of each feature internal
- * packaging structure. It allows the feature content to be accessed in
- * a standard way regardless of the internal packaging. All concrete feature
- * implementations need to implement a feature content provider.
- * <p>
- * There are two ways of looking at a feature content:
- * <ol>
- * <li>the "logical" view, which is a representation of the actual files that
- * make up the feature. These include any files that describe the feature
- * itself, files that are the actual implementation of referenced plug-ins,
- * and files that are the non-plug-in data files associated with the feature
- * <li>the "packaged" view, which is a set of related archive files that
- * contain the "logical" files.
- * </ol>
- * It is the responsibility of a feature content provider to manage the
- * mapping between the "packaged" and "logical" views.
- * </p>
- * <p>
- * Clients may implement this interface. However, in most cases clients should
- * directly instantiate or subclass the provided implementation of this
- * interface.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.FeatureContentProvider
- * @since 2.0
- */
-public interface IFeatureContentProvider {
-
- /**
- * Returns the feature url.
- * The exact interpretation of this URL is specific to each content
- * provider. Typically, the URL is a reference to a file that can be
- * used directly, or indirectly, to determine the content of the feature.
- *
- * @return feature url
- * @since 2.0
- */
- public URL getURL();
-
- /**
- * Returns a content reference to the feature manifest. The feature manifest
- * is an xml file, whose format is specified by the platform. Typically
- * a feature will contain the manifest as one of the packaged files.
- * For features that do not contain the manifest, or contain a manifest
- * that does not follow the specified format, this method returns
- * a reference to a computed manifest in the appropriate platform
- * format.
- *
- * @param monitor progress monitor, can be <code>null</code>
- * @return feature manifest reference, or <code>null</code> if the manifest cannot be found.
- * @since 2.0
- */
- public ContentReference getFeatureManifestReference(InstallMonitor monitor)
- throws CoreException;
-
- /**
- * Returns an array of content references of all the "packaged"
- * archives that make up this feature.
- * <p>
- * The number of returned references is dependent on each feature
- * content provider (i.e is dependent on the packaging mechanism used
- * by the particular feature type).
- * </p>
- *
- * @param monitor progress monitor, can be <code>null</code>
- * @return an array of references, or an empty array if no references
- * are found
- * @exception CoreException
- * @since 2.0
- */
- public ContentReference[] getArchiveReferences(InstallMonitor monitor)
- throws CoreException;
-
- /**
- * Returns an array of content references of the "packaged"
- * archives that contain the feature descriptive information.
- * <p>
- * In general, the feature descriptive information should be packaged
- * separately from the "bulk" of the actual feature content.
- * The feature entry archive(s) must be downloaded from an update
- * site in order to present information about the feature to the
- * client. Consequently, keeping the number and size of the feature
- * entry archive(s) to a minimum will speed up the responsiveness of the
- * user interface.
- * </p>
- * <p>
- * The number of returned references is dependent on each feature
- * content provider (i.e is dependent on the packaging mechanism used
- * by the particular feature type).
- * </p>
- *
- * @see IFeatureContentProvider#getFeatureEntryContentReferences(InstallMonitor)
- * @param monitor progress monitor, can be <code>null</code>
- * @return an array of references, or an empty array if no references
- * are found
- * @exception CoreException
- * @since 2.0
- */
- public ContentReference[] getFeatureEntryArchiveReferences(InstallMonitor monitor)
- throws CoreException;
-
- /**
- * Returns an array of content references of the "packaged"
- * archives that contain the files for the specified plug-in entry.
- * <p>
- * The number of returned references is dependent on each feature
- * content provider (i.e is dependent on the packaging mechanism used
- * by the particular feature type).
- * </p>
- *
- * @see IFeatureContentProvider#getPluginEntryContentReferences(IPluginEntry, InstallMonitor)
- * @param pluginEntry plug-in entry
- * @param monitor progress monitor, can be <code>null</code>
- * @return an array of references, or an empty array if no references
- * are found
- * @exception CoreException
- * @since 2.0
- */
- public ContentReference[] getPluginEntryArchiveReferences(
- IPluginEntry pluginEntry,
- InstallMonitor monitor)
- throws CoreException;
-
- /**
- * Returns an array of content references of the "packaged"
- * archives that contain the files for the specified non-plug-in entry.
- * <p>
- * The number of returned references is dependent on each feature
- * content provider (i.e is dependent on the packaging mechanism used
- * by the particular feature type).
- * </p>
- * <p>
- * Note, that the platform does not interpret non-plug-in entries in any
- * way, other that performing any required downloads. Non-plug-in entries
- * are handled by custom install handlers that must be specified for
- * the feature. Consequently, this interface does not make a distinction
- * between the "logical" and "packaged" views for non-plug-in entries.
- * The "packaged" view (returning references to the non-plug-in archives)
- * is the only one supported. It is the responsibility of the custom install
- * handler to understand the "logical" view of non-plug-in archives.
- * </p>
- *
- * @param monitor progress monitor, can be <code>null</code>
- * @return an array of references, or an empty array if no references
- * are found
- * @exception CoreException
- * @since 2.0
- */
- public ContentReference[] getNonPluginEntryArchiveReferences(
- INonPluginEntry nonPluginEntry,
- InstallMonitor monitor)
- throws CoreException;
-
- /**
- * Returns an array of content references to the feature definition files
- * (i.e the "logical" view of the files defining the feature). These
- * are the files required to present information about the feature to the
- * client, and in general, should not contain references to plug-in and
- * non-plug-in files.
- *
- * @see IFeatureContentProvider#getFeatureEntryArchiveReferences(InstallMonitor)
- * @param monitor progress monitor, can be <code>null</code>
- * @return an array of ContentReference or an empty array if no references are found
- * @exception CoreException when an error occurs
- * @since 2.0
- */
- public ContentReference[] getFeatureEntryContentReferences(InstallMonitor monitor)
- throws CoreException;
-
- /**
- * Returns an array of content references to the files implementing
- * the specified plug-in. (i.e the "logical" view of the plug-in).
- *
- * @see IFeatureContentProvider#getPluginEntryArchiveReferences(IPluginEntry, InstallMonitor)
- * @param monitor progress monitor, can be <code>null</code>
- * @return an array of ContentReference or an empty array if no references are found
- * @exception CoreException
- * @since 2.0
- */
- public ContentReference[] getPluginEntryContentReferences(
- IPluginEntry pluginEntry,
- InstallMonitor monitor)
- throws CoreException;
-
- /**
- * Returns the total size of all archives required for the
- * specified plug-in and non-plug-in entries (the "packaging" view).
- *
- * @param pluginEntries an array of plug-in entries
- * @param nonPluginEntries an array of non-plug-in entries
- * @return total download size, or an indication that size could not be
- * determined
- * @see org.eclipse.update.core.model.ContentEntryModel#UNKNOWN_SIZE
- * @since 2.0
- */
- public long getDownloadSizeFor(
- IPluginEntry[] pluginEntries,
- INonPluginEntry[] nonPluginEntries);
-
- /**
- * Returns the total size of all files required for the
- * specified plug-in and non-plug-in entries (the "logical" view).
- *
- * @param pluginEntries an array of plug-in entries
- * @param nonPluginEntries an array of non-plug-in entries
- * @return total download size, or an indication that size could not be
- * determined
- * @see org.eclipse.update.core.model.ContentEntryModel#UNKNOWN_SIZE
- * @since 2.0
- */
- public long getInstallSizeFor(
- IPluginEntry[] pluginEntries,
- INonPluginEntry[] nonPluginEntries);
-
- /**
- * Returns the verifier for this feature.
- * If provided, the verifier is called at various point during
- * installation processing to verify downloaded archives. The
- * type of verification provided is dependent on the content
- * provider implementation.
- *
- * @return verifier
- * @exception CoreException
- * @since 2.0
- */
- public IVerifier getVerifier() throws CoreException;
-
- /**
- * Returns the feature associated with this content provider.
- *
- * @return feature for this content provider
- * @since 2.0
- */
- public IFeature getFeature();
-
- /**
- * Sets the feature associated with this content provider.
- * In general, this method should only be called as part of
- * feature creation. Once set, the feature should not be reset.
- *
- * @param feature feature for this content provider
- * @since 2.0
- */
- public void setFeature(IFeature feature);
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/IFeatureFactory.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/IFeatureFactory.java
deleted file mode 100644
index a402ecf65..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/IFeatureFactory.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import java.net.*;
-
-import org.eclipse.core.runtime.*;
-
-/**
- * Feature factory interface.
- * A feature factory is used to construct new instances of concrete
- * features.
- * <p>
- * Clients may implement this interface. However, in most cases clients should
- * directly instantiate or subclass the provided implementation of this
- * interface.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.BaseFeatureFactory
- * @since 2.0
- */
-public interface IFeatureFactory {
-
- /**
- * Returns a feature defined by the supplied URL. The feature
- * is associated with the specified site.
- * <p>
- * The actual interpretation of the URL is feature-type specific.
- * In most cases the URL will point to some feature-specific
- * file that can be used (directly or indirectly) to construct
- * the feature object.
- * </p>
- * @param url URL interpreted by the feature
- * @param site site to be associated with the feature
- * @return concrete feature object
- * @exception CoreException
- * @deprecated use createFeature(URL, ISite, IProgressMonitor) instead
- * @since 2.0
- */
- public IFeature createFeature(URL url, ISite site) throws CoreException;
-
- /**
- * Returns a feature defined by the supplied URL. The feature
- * is associated with the specified site.
- * <p>
- * The actual interpretation of the URL is feature-type specific.
- * In most cases the URL will point to some feature-specific
- * file that can be used (directly or indirectly) to construct
- * the feature object.
- * </p>
- * @param url URL interpreted by the feature
- * @param site site to be associated with the feature
- * @return concrete feature object
- * @exception CoreException
- * @since 2.1
- */
- public IFeature createFeature(URL url, ISite site, IProgressMonitor monitor) throws CoreException;
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/IFeatureReference.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/IFeatureReference.java
deleted file mode 100644
index 8b7e18b6a..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/IFeatureReference.java
+++ /dev/null
@@ -1,120 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import java.net.*;
-
-import org.eclipse.core.runtime.*;
-
-/**
- * Feature reference.
- * A reference to a feature.
- * <p>
- * Clients may implement this interface. However, in most cases clients should
- * directly instantiate or subclass the provided implementation of this
- * interface.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.FeatureReference
- * @since 2.0
- */
-public interface IFeatureReference extends IAdaptable,IPlatformEnvironment {
-
- /**
- * Returns the referenced feature URL.
- *
- * @return feature URL
- * @since 2.0
- */
- public URL getURL();
-
- /**
- * Returns the update site for the referenced feature
- *
- * @return feature site
- * @since 2.0
- */
- public ISite getSite();
-
- /**
- * Returns the label for the referenced feature
- *
- * @return the label
- * @since 2.1
- */
- public String getName();
-
-
- /**
- * Returns the referenced feature.
- * This is a factory method that creates the full feature object.
- *
- * @return the referenced feature
- * @deprecated use getFeature(IProgressMonitor) instead
- * @since 2.0
- */
- public IFeature getFeature() throws CoreException;
-
- /**
- * Returns the referenced feature.
- * This is a factory method that creates the full feature object.
- *
- * @param monitor the progress monitor
- * @return the referenced feature
- * @since 2.1
- */
- public IFeature getFeature(IProgressMonitor monitor) throws CoreException;
-
-
- /**
- * Returns the feature identifier.
- *
- * @return the feature identifier.
- * @exception CoreException
- * @since 2.0
- */
- public VersionedIdentifier getVersionedIdentifier() throws CoreException;
-
- /**
- * Sets the feature reference URL.
- * This is typically performed as part of the feature reference creation
- * operation. Once set, the url should not be reset.
- *
- * @param url reference URL
- * @since 2.0
- */
- public void setURL(URL url) throws CoreException;
-
- /**
- * Associates a site with the feature reference.
- * This is typically performed as part of the feature reference creation
- * operation. Once set, the site should not be reset.
- *
- * @param site site for the feature reference
- * @since 2.0
- */
- public void setSite(ISite site);
-
- /**
- * Returns <code>true</code> if this feature is patching another feature,
- * <code>false</code> otherwise
- * @return boolean
- * @since 2.1
- */
- public boolean isPatch();
-
-
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/IImport.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/IImport.java
deleted file mode 100644
index 638f6423c..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/IImport.java
+++ /dev/null
@@ -1,94 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-
-import org.eclipse.core.runtime.*;
-
-/**
- * Plug-in dependency entry.
- * Describes a feture dependency on a particular plug-in. The dependency
- * can specify a specific plug-in version and a matching rule for
- * satisfying the dependency.
- * <p>
- * Clients may implement this interface. However, in most cases clients should
- * directly instantiate or subclass the provided implementation of this
- * interface.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.Import
- * @since 2.0
- */
-public interface IImport extends IAdaptable, IUpdateConstants, IPlatformEnvironment {
-
- /**
- * The import relates to a plugin
- * @since 2.0.2
- */
- public static final int KIND_PLUGIN = 0;
-
- /**
- * The import relates to a feature
- * @since 2.0.2
- */
- public static final int KIND_FEATURE = 1;
-
- /**
- * Returns an identifier of the dependent plug-in.
- *
- * @return plug-in identifier
- * @since 2.0
- */
- public VersionedIdentifier getVersionedIdentifier();
-
- /**
- * Returns the matching rule for the dependency.
- *
- * @return matching rule
- * @since 2.0
- */
- public int getRule();
-
- /**
- * Returns the matching rule for the dependency identifier.
- *
- * @return matching id rule
- * @since 2.1
- */
- public int getIdRule();
-
- /**
- * Returns the dependency kind
- *
- * @see #KIND_PLUGIN
- * @see #KIND_FEATURE
- * @return KIND_PLUGIN if the dependency relates to a plugin,
- * KIND_FEATURE if the dependency relates to a feature.
- */
- public int getKind();
-
- /**
- * Returns the patch mode. If the import is in patch mode,
- * the referenced feature is considered a patch target,
- * and the feature that owns the import is patch carrier.
- * Patch carrier and patched feature are linked in a
- * distinct way: if a patched feature is disabled,
- * all the patches are disabled with it.
- * @return true if the element represents a patch
- * reference, false otherwise.
- */
- public boolean isPatch();
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/IIncludedFeatureReference.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/IIncludedFeatureReference.java
deleted file mode 100644
index 7f02be8e1..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/IIncludedFeatureReference.java
+++ /dev/null
@@ -1,128 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import org.eclipse.core.runtime.*;
-import org.eclipse.update.configuration.*;
-
-
-
-/**
- * Included Feature reference.
- * A reference to a included feature.
- * <p>
- * Clients may implement this interface. However, in most cases clients should
- * directly instantiate or subclass the provided implementation of this
- * interface.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.FeatureReference
- * @since 2.0.1
- */
-public interface IIncludedFeatureReference extends IFeatureReference, IAdaptable {
-
- /**
- * Returns the referenced feature.
- * This is a factory method that creates the full feature object.
- * equivalent to getFeature(false,null);
- *
- * @return the referenced feature
- * @deprecated use getFeature(IProgressMonitor)
- * @since 2.0
- */
- public IFeature getFeature() throws CoreException;
-
- /**
- * Returns the referenced feature.
- * This is a factory method that creates the full feature object.
- *
- * @param perfectMatch <code>true</code> if the perfect match feature feature should be returned
- * <code>false</code> if the best match feature should be returned.
- * @param configuredSite the configured site to search for the Feature. If
- * the configured site is <code>null</code> the search will be done in the current configured site.
- * @return the referenced feature
- * instead
- * @since 2.0.2
- * <b>Note:</b> This method is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * @deprecated use getFeature(IProgressMonitor)
- */
- public IFeature getFeature(boolean perfectMatch,IConfiguredSite configuredSite) throws CoreException;
-
- /**
- * Returns the referenced feature.
- * This is a factory method that creates the full feature object.
- *
- * @param perfectMatch <code>true</code> if the perfect match feature feature should be returned
- * <code>false</code> if the best match feature should be returned.
- * @param configuredSite the configured site to search for the Feature. If
- * the configured site is <code>null</code> the search will be done in the current configured site.
- * @param monitor the progress monitor
- * @return the referenced feature
- * @since 2.1
- * <b>Note:</b> This method is part of an interim API that is still under
- * development and expected to change significantly before reaching
- * stability. It is being made 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.
- * @deprecated use getFeature(IProgressMonitor)
- */
- public IFeature getFeature(boolean perfectMatch,IConfiguredSite configuredSite, IProgressMonitor monitor) throws CoreException;
-
-
- /**
- * Returns <code>true</code> if the feature is optional, <code>false</code> otherwise.
- *
- * @return boolean
- * @since 2.0.1
- */
- public boolean isOptional();
-
- /**
- * Returns the matching rule for this included feature.
- * The rule will determine the ability of the included feature to move version
- * without causing the overall feature to appear broken.
- *
- * The default is <code>RULE_PERFECT</code>
- *
- * @see IUpdateConstants#RULE_PERFECT
- * @see IUpdateConstants#RULE_EQUIVALENT
- * @see IUpdateConstants#RULE_COMPATIBLE
- * @see IUpdateConstants#RULE_GREATER_OR_EQUAL
- * @return int representation of feature matching rule.
- * @since 2.0.2
- * @deprecated since 3.0 included feature version is exactly specified
- */
- public int getMatch();
-
- /**
- * Returns the search location for this included feature.
- * The location will be used to search updates for this feature.
- *
- * The default is <code>SEARCH_ROOT</code>
- *
- * @see IUpdateConstants#SEARCH_ROOT
- * @see IUpdateConstants#SEARCH_SELF
- * @return int representation of feature searching rule.
- * @since 2.0.2
- */
-
- public int getSearchLocation();
-
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/IInstallHandler.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/IInstallHandler.java
deleted file mode 100644
index b7bc77755..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/IInstallHandler.java
+++ /dev/null
@@ -1,244 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import org.eclipse.core.runtime.*;
-
-/**
- * Custom install handler.
- * Custom install handlers can optionally be associated with a feature.
- * The actual install handler implementation can be physically delivered
- * as part of the feature package, or can already be installed on the client
- * machine and registered via the <code>org.eclipse.update.core.installHandlers</code>
- * extension point. The install handler methods are called at predetermined
- * point during update actions.
- * <p>
- * Clients may implement this interface. However, in most cases clients should
- * directly subclass the provided implementation of this interface.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.BaseInstallHandler
- * @since 2.0
- */
-public interface IInstallHandler {
-
- /**
- * Indicates the handler is being initialized for feature install.
- * @since 2.0
- */
- public static final int HANDLER_ACTION_INSTALL = 1;
-
- /**
- * Indicates the handler is being initialized for feature configure.
- * @since 2.0
- */
- public static final int HANDLER_ACTION_CONFIGURE = 2;
-
- /**
- * Indicates the handler is being initialized for feature unconfigure.
- * @since 2.0
- */
- public static final int HANDLER_ACTION_UNCONFIGURE = 3;
-
- /**
- * Indicates the handler is being initialized for feature uninstall.
- * @since 2.0
- */
- public static final int HANDLER_ACTION_UNINSTALL = 4;
-
- /**
- * Initialize the install handler.
- * Install handlers are always constructed using the default constructor.
- * The are initialized immediately following construction.
- *
- * @param type update action type
- * @param feature the target of the action
- * @param entry model entry that defines this handler
- * @param monitor optional progress monitor, can be <code>null</code>
- * @exception CoreException
- * @since 2.0
- */
- public void initialize(
- int type,
- IFeature feature,
- IInstallHandlerEntry entry,
- InstallMonitor monitor)
- throws CoreException;
-
- /**
- * Called at the start of the install action. At this point, no install
- * processing has taken place.
- *
- * @see #HANDLER_ACTION_INSTALL
- * @exception CoreException terminates the action
- * @since 2.0
- */
- public void installInitiated() throws CoreException;
-
- /**
- * Called after files corresponding to plug-in entries have been downloaded,
- * but before they are actully unpacked and installed.
- *
- * @see #HANDLER_ACTION_INSTALL
- * @param plugins downloaded plug-in entries. Note this may be a subset
- * of the plug-ins actually references by the feature.
- * @exception CoreException terminates the action
- * @since 2.0
- */
- public void pluginsDownloaded(IPluginEntry[] plugins) throws CoreException;
-
- /**
- * Called after files corresponding to non-plug-in entries have been
- * downloaded. The custom install handler can perform any custom
- * verification of the non-plug-in entries (these are not interpreted
- * in any way by the platform (beyond downloading)).
- *
- * @see #HANDLER_ACTION_INSTALL
- * @param nonPluginData downloaded non-plug-in entries.
- * @param listener verification listener, may be <code>null</code>.
- * @exception CoreException terminates the action
- * @since 2.0
- */
- public void nonPluginDataDownloaded(
- INonPluginEntry[] nonPluginData,
- IVerificationListener listener)
- throws CoreException;
-
- /**
- * Called after the feature files and any downloaded plug-ins have
- * been installed. Typically this is the point where the custom
- * install handler can install any non-plug-in entries (these are not
- * interpreted in any way by the platform (beyond downloading)).
- *
- * @see #HANDLER_ACTION_INSTALL
- * @param consumer content consumer for the feature. The install handler
- * can choose to use this consumer to install the non-plug-in data,
- * or can handle the data in any other way. If using the consumer,
- * the install handler should only call
- * @see IFeatureContentConsumer#store(ContentReference, IProgressMonitor)
- * and @see IFeatureContentConsumer#open(INonPluginEntry)
- * methods of the consumer.
- * @exception CoreException terminates the action
- * @since 2.0
- */
- public void completeInstall(IFeatureContentConsumer consumer)
- throws CoreException;
-
- /**
- * Called at the end of the install action.
- *
- * @see #HANDLER_ACTION_INSTALL
- * @param success indicates action success.
- * @exception CoreException terminates the action
- * @since 2.0
- */
- public void installCompleted(boolean success) throws CoreException;
-
- /**
- * Called at the start of the configure action
- *
- * @see #HANDLER_ACTION_CONFIGURE
- * @exception CoreException terminates the action
- * @since 2.0
- */
- public void configureInitiated() throws CoreException;
-
- /**
- * Called after the feature has been configured. The install handler
- * should perform any completion tasks. No arguments are passed
- * to the method. If needed, the install handler can use arguments
- * passed on the initialization call.
- *
- * @see #HANDLER_ACTION_CONFIGURE
- * @exception CoreException terminates the action
- * @since 2.0
- */
- public void completeConfigure() throws CoreException;
-
- /**
- * Called at the end of the configure action.
- *
- * @see #HANDLER_ACTION_CONFIGURE
- * @param success indicates action success.
- * @exception CoreException terminates the action
- * @since 2.0
- */
- public void configureCompleted(boolean success) throws CoreException;
-
- /**
- * Called at the start of the unconfigure action
- *
- * @see #HANDLER_ACTION_UNCONFIGURE
- * @exception CoreException terminates the action
- * @since 2.0
- */
- public void unconfigureInitiated() throws CoreException;
-
- /**
- * Called after the feature has been unconfigured. The install handler
- * should perform any completion tasks. No arguments are passed
- * to the method. If needed, the install handler can use arguments
- * passed on the initialization call.
- *
- * @see #HANDLER_ACTION_UNCONFIGURE
- * @exception CoreException terminates the action
- * @since 2.0
- */
- public void completeUnconfigure() throws CoreException;
-
- /**
- * Called at the end of the unconfigure action.
- *
- * @see #HANDLER_ACTION_UNCONFIGURE
- * @param success indicates action success.
- * @exception CoreException terminates the action
- * @since 2.0
- */
- public void unconfigureCompleted(boolean success) throws CoreException;
-
- /**
- * Called at the start of the uninstall action
- *
- * @see #HANDLER_ACTION_UNINSTALL
- * @exception CoreException terminates the action
- * @since 2.0
- */
- public void uninstallInitiated() throws CoreException;
-
- /**
- * Called after the feature has been uninstalled. The install handler
- * should perform any completion tasks. No arguments are passed
- * to the method. If needed, the install handler can use arguments
- * passed on the initialization call. Note, that at this point
- * the feature files and any unreferenced plug-ins have been
- * removed.
- *
- * @see #HANDLER_ACTION_UNINSTALL
- * @exception CoreException terminates the action
- * @since 2.0
- */
- public void completeUninstall() throws CoreException;
-
- /**
- * Called at the end of the uninstall action.
- *
- * @see #HANDLER_ACTION_UNINSTALL
- * @param success indicates action success.
- * @exception CoreException terminates the action
- * @since 2.0
- */
- public void uninstallCompleted(boolean success) throws CoreException;
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/IInstallHandlerEntry.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/IInstallHandlerEntry.java
deleted file mode 100644
index b39231c79..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/IInstallHandlerEntry.java
+++ /dev/null
@@ -1,76 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import java.net.*;
-
-import org.eclipse.core.runtime.*;
-
-/**
- * Install handler entry.
- * Associates an optional custom install handler with the feature.
- * Install handlers must implement the IInstallHandler interface.
- * <p>
- * Clients may implement this interface. However, in most cases clients should
- * directly instantiate or subclass the provided implementation of this
- * interface.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.InstallHandlerEntry
- * @see org.eclipse.update.core.IInstallHandler
- * @since 2.0
- */
-public interface IInstallHandlerEntry extends IAdaptable {
-
- /**
- * Returns optional URL used for browser-triggered installation handling.
- *
- * @return url
- * @since 2.0
- */
- public URL getURL();
-
- /**
- * Returns optional name of a library containing the install
- * handler classes. If specified, the referenced library
- * must be contained in the feature archive.
- *
- * @return install handler library name
- * @since 2.0
- */
- public String getLibrary();
-
- /**
- * Returns install handler name.
- * It is interpreted depending on the value of the library
- * specification. If library is not specified, the name
- * is intepreted as an identifier of a "global" install
- * handler registered in the <code>org.eclipse.update.core.installHandlers</code>
- * extension point. If library is specified, the name is interpreted
- * as a fully qualified name of a class contained in the
- * library. In both cases, the resulting class must
- * implement IInstallHandler. The class is dynamically loaded and
- * called at specific points during feature processing.
- * The handler has visibility to the API classes from the update plug-in,
- * and plug-ins required by the update plugin.
- *
- * @see IInstallHandler
- * @return handler name
- * @since 2.0
- */
- public String getHandlerName();
-
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/INonPluginEntry.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/INonPluginEntry.java
deleted file mode 100644
index 1ff05f6eb..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/INonPluginEntry.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import org.eclipse.core.runtime.*;
-
-/**
- * Non-plug-in entry defines an arbitrary non-plug-in data file packaged
- * as part of a feature. Non-plug-in entries are not interpreted by the
- * platform (other than being downloaded as part of an install action).
- * They require a custom install handler to be specified as part of the
- * feature. Note, that defining a non-plug-in entry does not necessarily
- * indicate the non-plug-in file is packaged together with any other
- * feature files. The actual packaging details are determined by the
- * feature content provider for the feature.
- * <p>
- * Clients may implement this interface. However, in most cases clients should
- * directly instantiate or subclass the provided implementation of this
- * interface.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.NonPluginEntry
- * @see org.eclipse.update.core.FeatureContentProvider
- * @since 2.0
- */
-public interface INonPluginEntry extends IPlatformEnvironment, IAdaptable {
-
- /**
- * Returns the identifier of this data entry.
- *
- * @return data entry identifier
- * @since 2.0
- */
- public String getIdentifier();
-
- /**
- * Returns the download size of the entry, if it can be determined.
- *
- * @see org.eclipse.update.core.model.ContentEntryModel#UNKNOWN_SIZE
- * @return download size of the feature in KiloBytes, or an indication
- * the size could not be determined
- * @since 2.0
- */
- public long getDownloadSize();
-
- /**
- * Returns the install size of the feature, if it can be determined.
- *
- * @see org.eclipse.update.core.model.ContentEntryModel#UNKNOWN_SIZE
- * @return install size of the feature in KiloBytes, or an indication
- * the size could not be determined
- * @since 2.0
- */
- public long getInstallSize();
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/IPlatformEnvironment.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/IPlatformEnvironment.java
deleted file mode 100644
index 2b17aba3a..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/IPlatformEnvironment.java
+++ /dev/null
@@ -1,102 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import org.eclipse.core.runtime.*;
-
-/**
- * Plug-in entry defines a packaging reference from a feature to a plug-in.
- * It indicates that the referenced plug-in is to be considered as
- * part of the feature. Note, that this does not necessarily indicate
- * that the plug-in files are packaged together with any other
- * feature files. The actual packaging details are determined by the
- * feature content provider for the feature.
- * <p>
- * Clients may implement this interface. However, in most cases clients should
- * directly instantiate or subclass the provided implementation of this
- * interface.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.PluginEntry
- * @see org.eclipse.update.core.FeatureContentProvider
- * @since 2.0
- */
-public interface IPlatformEnvironment extends IAdaptable {
-
-
- /**
- * Returns optional operating system specification.
- * A comma-separated list of os designators defined by the platform.
- * Indicates this entry should only be installed on one of the specified
- * os systems. If this attribute is not specified, or is <code>*</code>, the
- * entry can be installed on all systems (portable implementation). If the
-
- * This information is used as a hint by the installation and update
- * support.
- *
- * @return the operating system specification, or <code>null</code>.
- * @since 2.0
- */
- public String getOS();
-
- /**
- * Returns optional system architecture specification.
- * A comma-separated list of arch designators defined by the platform.
- * Indicates this entry should only be installed on one of the specified
- * systems. If this attribute is not specified, or is <code>*</code>, the
- * entry can be installed on all systems (portable implementation).
- *
- * This information is used as a hint by the installation and update
- * support.
- *
- * @return system architecture specification, or <code>null</code>.
- * @since 2.0
- */
- public String getWS();
-
- /**
- * Returns optional system architecture specification.
- * A comma-separated list of arch designators defined by the platform.
- * Indicates this entry should only be installed on one of the specified
- * systems. If this attribute is not specified, or is <code>*</code>, the
- * entry can be installed on all systems (portable implementation).
- *
- * This information is used as a hint by the installation and update
- * support.
- *
- * @return system architecture specification, or <code>null</code>.
- * @since 2.0
- */
- public String getOSArch();
-
- /**
- * Returns optional locale specification.
- * A comma-separated list of locale designators defined by Java.
- * Indicates this entry should only be installed on a system running
- * with a compatible locale (using Java locale-matching rules).
- * If this attribute is not specified, or is <code>*</code>, the entry can
- * be installed on all systems (language-neutral implementation).
- *
- * This information is used as a hint by the installation and update
- * support.
- *
- * @return the locale specification, or <code>null</code>.
- * @since 2.0
- */
- public String getNL();
-
-
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/IPluginEntry.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/IPluginEntry.java
deleted file mode 100644
index d695a9d4a..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/IPluginEntry.java
+++ /dev/null
@@ -1,86 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import org.eclipse.core.runtime.*;
-
-/**
- * Plug-in entry defines a packaging reference from a feature to a plug-in.
- * It indicates that the referenced plug-in is to be considered as
- * part of the feature. Note, that this does not necessarily indicate
- * that the plug-in files are packaged together with any other
- * feature files. The actual packaging details are determined by the
- * feature content provider for the feature.
- * <p>
- * Clients may implement this interface. However, in most cases clients should
- * directly instantiate or subclass the provided implementation of this
- * interface.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.PluginEntry
- * @see org.eclipse.update.core.FeatureContentProvider
- * @since 2.0
- */
-public interface IPluginEntry extends IPlatformEnvironment,IAdaptable {
-
- /**
- * Returns the identifier of this plugin entry
- *
- * @return plugin entry identifier
- * @since 2.0
- */
- public VersionedIdentifier getVersionedIdentifier();
-
- /**
- * Returns an indication whethyer this entry represents a fragment.
- *
- * @return <code>true</code> if the entry represents a plug-in fragment,
- * <code>false</code> if the entry represents a plug-in
- * @since 2.0
- */
- public boolean isFragment();
-
- /**
- * Returns the download size of the entry, if it can be determined.
- *
- * @see org.eclipse.update.core.model.ContentEntryModel#UNKNOWN_SIZE
- * @return download size of the feature in KiloBytes, or an indication
- * the size could not be determined
- * @since 2.0
- */
- public long getDownloadSize();
-
- /**
- * Returns the install size of the feature, if it can be determined.
- *
- * @see org.eclipse.update.core.model.ContentEntryModel#UNKNOWN_SIZE
- * @return install size of the feature in KiloBytes, or an indication
- * the size could not be determined
- * @since 2.0
- */
- public long getInstallSize();
-
- /**
- * Sets the identifier of this plugin entry.
- * This is typically performed as part of the plug-in entry creation
- * operation. Once set, the identifier should not be reset.
- *
- * @param identifier plugin entry identifier
- * @since 2.0
- */
- public void setVersionedIdentifier(VersionedIdentifier identifier);
-
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/ISite.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/ISite.java
deleted file mode 100644
index 78c7db152..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/ISite.java
+++ /dev/null
@@ -1,328 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-import java.net.*;
-
-import org.eclipse.core.runtime.*;
-import org.eclipse.update.configuration.*;
-import org.eclipse.update.core.model.*;
-
-/**
- * Site represents a location containing some number of features (packaged
- * or installed). Sites are treated purely as an installation and packaging
- * construct. They do not play a role during Eclipse plug-in execution.
- * <p>
- * Clients may implement this interface. However, in most cases clients should
- * directly instantiate or subclass the provided implementation of this
- * interface.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.Site
- * @since 2.0
- */
-public interface ISite extends IAdaptable {
-
- /**
- * Default type for an installed feature. Different concrete feature
- * implementations can be registered together with their corresponding type
- * using the <code>org.eclipse.update.core.featureTypes</code>
- * extension point.
- *
- * @since 2.0
- */
- public static final String DEFAULT_INSTALLED_FEATURE_TYPE = "org.eclipse.update.core.installed"; //$NON-NLS-1$
-
- /**
- * Default type for a packaged feature. Different concrete feature
- * implementations can be registered together with their corresponding type
- * using the <code>org.eclipse.update.core.featureTypes</code>
- * extension point.
- *
- * @since 2.0
- */
- public static final String DEFAULT_PACKAGED_FEATURE_TYPE = "org.eclipse.update.core.packaged"; //$NON-NLS-1$
-
- /**
- * If we are unable to access a site, the returned CoreException will contain
- * this return code.
- *
- * @since 2.0.1
- */
- public static final int SITE_ACCESS_EXCEPTION = 42;
-
- /**
- * Returns the site URL
- *
- * @return site URL
- * @since 2.0
- */
- public URL getURL();
-
- /**
- * Return the site type. Different concrete site implementations can be
- * registered together with their corresponding type using the
- * <code>org.eclipse.update.core.siteTypes</code> extension point.
- *
- * @return site type, or <code>null</code>.
- * @since 2.0
- */
- public String getType();
-
- /**
- * Returns the site description.
- *
- * @return site description, or <code>null</code>.
- * @since 2.0
- */
- public IURLEntry getDescription();
-
- /**
- * Returns an array of categories defined by the site.
- *
- * @return array of site categories, or an empty array.
- * @since 2.0
- */
- public ICategory[] getCategories();
-
- /**
- * Returns the named site category.
- *
- * @param name category name
- * @return named category, or <code>null</code> ifit does not exist
- * @since 2.0
- */
- public ICategory getCategory(String name);
-
- /**
- * Returns an array of references to features on this site.
- *
- * @return an array of feature references, or an empty array.
- * @since 2.0
- */
- public ISiteFeatureReference[] getFeatureReferences();
-
- /**
- * Returns an array of references to features on this site.
- * No filtering occurs.
- *
- * @return an array of feature references, or an empty array..
- * @since 2.1
- */
- public ISiteFeatureReference[] getRawFeatureReferences();
-
- /**
- * Returns a reference to the specified feature if
- * it is installed on this site.
- * filtered by the operating system, windowing system and architecture
- * system set in <code>Sitemanager</code>
- *
- * @param feature feature
- * @return feature reference, or <code>null</code> if this feature
- * cannot be located on this site.
- * @since 2.0
- */
- public ISiteFeatureReference getFeatureReference(IFeature feature);
-
- /**
- * Returns an array of plug-in and non-plug-in archives located
- * on this site
- *
- * @return an array of archive references, or an empty array if there are
- * no archives known to this site. Note, that an empty array does not
- * necessarily indicate there are no archives accessible on this site.
- * It simply indicates the site has no prior knowledge of such archives.
- * @since 2.0
- */
- public IArchiveReference[] getArchives();
-
- /**
- * Returns the content provider for this site. A content provider
- * is an abstraction of each site organization. It allows the
- * content of the site to be accessed in a standard way
- * regardless of the organization. All concrete sites
- * need to be able to return a content provider.
- *
- * @return site content provider
- * @exception CoreException
- * @since 2.0
- */
- public ISiteContentProvider getSiteContentProvider() throws CoreException;
-
- /**
- * Returns the default type for a packaged feature supported by this site
- *
- * @return feature type, as registered in the
- * <code>org.eclipse.update.core.featureTypes</code> extension point.
- * @since 2.0
- */
- public String getDefaultPackagedFeatureType();
-
- /**
- * Returns an array of entries corresponding to plug-ins installed
- * on this site.
- *
- * @return array of plug-in entries,or an empty array.
- * @since 2.0
- */
- public IPluginEntry[] getPluginEntries();
-
- /**
- * Returns the number of plug-ins installed on this site
- *
- * @return number of installed plug-ins
- * @since 2.0
- */
- public int getPluginEntryCount();
-
- /**
- * Adds a new plug-in entry to this site.
- *
- * @param pluginEntry plug-in entry
- * @since 2.0
- */
- public void addPluginEntry(IPluginEntry pluginEntry);
-
- /**
- * Returns an array of entries corresponding to plug-ins that are
- * installed on this site and are referenced only by the specified
- * feature. These are plug-ins that are not shared with any other
- * feature.
- *
- * @param feature feature
- * @return an array of plug-in entries, or an empty array.
- * @exception CoreException
- * @since 2.0
- */
- public IPluginEntry[] getPluginEntriesOnlyReferencedBy(IFeature feature) throws CoreException;
-
- /**
- * Returns the size of the files that need to be downloaded in order
- * to install the specified feature on this site, if it can be determined.
- * This method takes into account any plug-ins that are already
- * available on this site.
- *
- * @see org.eclipse.update.core.model.ContentEntryModel#UNKNOWN_SIZE
- * @param feature candidate feature
- * @return download size of the feature in KiloBytes, or an indication
- * the size could not be determined
- * @since 2.0
- */
- public long getDownloadSizeFor(IFeature feature);
-
- /**
- * Returns the size of the files that need to be installed
- * for the specified feature on this site, if it can be determined.
- * This method takes into account any plug-ins that are already
- * installed on this site.
- *
- * @see org.eclipse.update.core.model.ContentEntryModel#UNKNOWN_SIZE
- * @param feature candidate feature
- * @return install size of the feature in KiloBytes, or an indication
- * the size could not be determined
- * @since 2.0
- */
- public long getInstallSizeFor(IFeature feature);
-
- /**
- * Installs the specified feature on this site.
- *
- * @param feature feature to install
- * @param verificationListener install verification listener
- * @param monitor install monitor, can be <code>null</code>
- * @exception InstallAbortedException when the user cancels the install
- * @exception CoreException
- * @since 2.0
- */
- public IFeatureReference install(IFeature feature, IVerificationListener verificationListener, IProgressMonitor monitor) throws InstallAbortedException, CoreException;
-
- /**
- * Installs the specified feature on this site.
- * Only optional features passed as parameter will be installed.
- *
- * @param feature feature to install
- * @param optionalfeatures list of optional features to be installed
- * @param verificationListener install verification listener
- * @param monitor install monitor, can be <code>null</code>
- * @exception InstallAbortedException when the user cancels the install
- * @exception CoreException
- * @since 2.0
- */
- public IFeatureReference install(IFeature feature, IFeatureReference[] optionalfeatures, IVerificationListener verificationListener, IProgressMonitor monitor) throws InstallAbortedException, CoreException;
-
- /**
- * Removes (uninstalls) the specified feature from this site. This method
- * takes into account plug-in entries referenced by the specified fetaure
- * that continue to be required by other features installed on this site.
- *
- * @param feature feature to remove
- * @param monitor progress monitor
- * @exception CoreException
- * @since 2.0
- */
- public void remove(IFeature feature, IProgressMonitor monitor) throws CoreException;
-
- /**
- * Sets the site content provider. This is typically performed
- * as part of the site creation operation. Once set, the
- * provider should not be reset.
- *
- * @param siteContentProvider site content provider
- * @since 2.0
- */
- public void setSiteContentProvider(ISiteContentProvider siteContentProvider);
-
- /**
- * Returns the <code>IConfiguredSite</code> for this site in the current
- * configuration or <code>null</code> if none found.
- *
- * @since 2.0.2
- */
- public IConfiguredSite getCurrentConfiguredSite();
-
- /**
- * Creates a new feature object. The feature must exist on this site
- * or a core exception will be thrown. Concrete implementations
- * may elect to cache instances, in which case subsequent calls
- * to create a feature with the same URL will
- * return the same instance.
- * param type the feature type that will be used to select the factory. If
- * <code>null</code> is passed, default feature type will be used.
- * param url URL of the feature archive as listed in the site.
- * return newly created feature object, or a cached value if
- * caching is implemented by this site.
- * @deprecated use createFeature(String,URL,IProgressMonitor) instead
- * @since 2.0.2
- */
- IFeature createFeature(String type, URL url) throws CoreException;
-
- /**
- * Creates a new feature object. The feature must exist on this site
- * or a core exception will be thrown. Concrete implementations
- * may elect to cache instances, in which case subsequent calls
- * to create a feature with the same URL will
- * return the same instance.
- * param type the feature type that will be used to select the factory. If
- * <code>null</code> is passed, default feature type will be used.
- * param url URL of the feature archive as listed in the site.
- * return newly created feature object, or a cached value if
- * caching is implemented by this site.
- * @param monitor the progress monitor
- * @since 2.1
- */
- IFeature createFeature(String type, URL url,IProgressMonitor monitor) throws CoreException;
-
-
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/ISiteContentProvider.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/ISiteContentProvider.java
deleted file mode 100644
index 0f9e8e42e..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/ISiteContentProvider.java
+++ /dev/null
@@ -1,78 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import java.net.*;
-
-import org.eclipse.core.runtime.*;
-
-/**
- * Site content provider.
- * A site content provider is an abstraction of each site internal
- * organization. It allows the site content to be accessed in
- * a standard way regardless of the internal organization. All concrete site
- * implementations need to implement a site content provider.
- * <p>
- * Clients may implement this interface. However, in most cases clients should
- * directly instantiate or subclass the provided implementation of this
- * interface.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.SiteContentProvider
- * @since 2.0
- */
-
-public interface ISiteContentProvider {
-
- /**
- * Returns the URL of this site
- *
- * @return site URL
- * @since 2.0
- */
- public URL getURL();
-
-
- /**
- * Returns a URL for the identified archive
- *
- * @param id archive identifier
- * @return archive URL, or <code>null</code>.
- * @exception CoreException
- * @since 2.0
- */
- public URL getArchiveReference(String id) throws CoreException;
-
- /**
- * Returns the site for this provider
- *
- * @return provider site
- * @since 2.0
- */
- public ISite getSite();
-
- /**
- * Sets the site for this provider.
- * In general, this method should only be called as part of
- * site creation. Once set, the site should not be reset.
- *
- * @param site provider site
- * @since 2.0
- */
- public void setSite(ISite site);
-}
-
-
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/ISiteFactory.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/ISiteFactory.java
deleted file mode 100644
index 714252bec..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/ISiteFactory.java
+++ /dev/null
@@ -1,56 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import java.net.*;
-
-import org.eclipse.core.runtime.*;
-import org.eclipse.update.core.model.*;
-
-/**
- * Site factory interface.
- * A site factory is used to construct new instances of concrete
- * sites.
- * <p>
- * Clients may implement this interface. However, in most cases clients should
- * directly instantiate or subclass the provided implementation of this
- * interface.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.BaseSiteFactory
- * @since 2.0
- */
-
-public interface ISiteFactory {
-
- /**
- * Returns a site defined by the supplied URL.
- * <p>
- * The actual interpretation of the URL is site-type specific.
- * In most cases the URL will point to some site-specific
- * file that can be used (directly or indirectly) to construct
- * the site object.
- * </p>
- * @param url URL interpreted by the site
- * @return site object
- * @exception CoreException
- * @exception InvalidSiteTypeException the referenced site type is
- * not a supported type for this factory
- * @since 2.0
- */
- public ISite createSite(URL url)
- throws CoreException, InvalidSiteTypeException;
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/ISiteFactoryExtension.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/ISiteFactoryExtension.java
deleted file mode 100644
index 7ff5fd931..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/ISiteFactoryExtension.java
+++ /dev/null
@@ -1,59 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import java.net.*;
-
-import org.eclipse.core.runtime.*;
-import org.eclipse.update.core.model.*;
-
-/**
- * <p>
- * This is an extension to the standard ISiteFactory interface.
- * If a factory implements this interface and is handling
- * URL connections, a progress monitor can be passed to
- * allow canceling of frozen connections.
- * </p>
- * <p>Input stream is obtained from the connection on
- * a separate thread. When connection is canceled,
- * the thread is still active. It is allowed to terminate
- * when the connection times out on its own.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.BaseSiteFactory
- * @since 2.1
- */
-
-public interface ISiteFactoryExtension {
- /**
- * Returns a site defined by the supplied URL.
- * <p>
- * The actual interpretation of the URL is site-type specific.
- * In most cases the URL will point to some site-specific
- * file that can be used (directly or indirectly) to construct
- * the site object.
- * </p>
- * @param url URL interpreted by the site
- * @param monitor a progress monitor that can be canceled
- * @return site object
- * @exception CoreException
- * @exception InvalidSiteTypeException the referenced site type is
- * not a supported type for this factory
- * @since 2.0
- */
- public ISite createSite(URL url, IProgressMonitor monitor)
- throws CoreException, InvalidSiteTypeException;
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/ISiteFeatureReference.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/ISiteFeatureReference.java
deleted file mode 100644
index d549edd40..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/ISiteFeatureReference.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import org.eclipse.core.runtime.*;
-
-/**
- * Site Feature reference.
- * A reference to a feature on a particular update site.
- * <p>
- * Clients may implement this interface. However, in most cases clients should
- * directly instantiate or subclass the provided implementation of this
- * interface.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.SiteFeatureReference
- * @since 2.1
- */
-public interface ISiteFeatureReference extends IFeatureReference, IAdaptable {
-
- /**
- * Returns an array of categories the referenced feature belong to.
- *
- * @return an array of categories, or an empty array
- * @since 2.1
- */
- public ICategory[] getCategories();
-
- /**
- * Adds a category to the referenced feature.
- *
- * @param category new category
- * @since 2.1
- */
- public void addCategory(ICategory category);
-
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/IURLEntry.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/IURLEntry.java
deleted file mode 100644
index cf1345bd8..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/IURLEntry.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-import java.net.*;
-
-import org.eclipse.core.runtime.*;
-
-/**
- * URL entry is an annotated URL object. It allows descriptive text to be
- * associated with a URL. When used as description object, the annotation
- * typically corresponds to short descriptive text, with the URL reference
- * pointing to full browsable description.
- * <p>
- * Clients may implement this interface. However, in most cases clients should
- * directly instantiate or subclass the provided implementation of this
- * interface.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.URLEntry
- * @since 2.0
- */
-public interface IURLEntry extends IAdaptable {
-
- public static final int UPDATE_SITE = 0;
- public static final int WEB_SITE = 1;
-
- /**
- * Returns the URL annotation or <code>null</code> if none
- *
- * @return url annotation or <code>null</code> if none
- * @since 2.0
- */
- public String getAnnotation();
-
- /**
- * Returns the actual URL.
- *
- * @return url.
- * @since 2.0
- */
- public URL getURL();
-
- /**
- * Returns the type of the URLEntry
- *
- * @see #UPDATE_SITE
- * @see #WEB_SITE
- * @return type
- * @since 2.0
- */
- public int getType();
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/IUpdateConstants.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/IUpdateConstants.java
deleted file mode 100644
index b406ba2ab..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/IUpdateConstants.java
+++ /dev/null
@@ -1,83 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-
-/**
- * Manages a list of static constants.
- *
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @since 2.0.2
- */
-public interface IUpdateConstants {
-
- /**
- * No matching rule specified
- * @since 2.0
- */
- public static final int RULE_NONE = 0;
-
- /**
- * Dependency can be satisfied only with plug-in version matching
- * exactly the specified version.
- * @since 2.0
- */
- public static final int RULE_PERFECT = 1;
-
- /**
- * Dependency can be satisfied only with plug-in version that is
- * equivalent to the specified version (same major and minor version
- * identifier, greater than or equal service identifier).
- * @since 2.0
- */
- public static final int RULE_EQUIVALENT = 2;
-
- /**
- * Dependency can be satisfied only with plug-in version that is
- * compatible with the specified version (either is equivalent,
- * or greater minor identifier (but same major identifier)).
- * @since 2.0
- */
- public static final int RULE_COMPATIBLE = 3;
-
- /**
- * Dependency can be satisfied only with plug-in version that is
- * greater or equal to the specified version.
- * @since 2.0
- */
- public static final int RULE_GREATER_OR_EQUAL = 4;
-
- /**
- * Dependency can be satisfied only if the required identifier
- * is a prefix of the specified identifier.
- * @since 2.1
- */
- public static final int RULE_PREFIX = 1;
-
- /**
- * The search location for updates is defined by the root feature.
- * @since 2.0.2
- */
- public static final int SEARCH_ROOT = 1<<1;
-
- /**
- * The search location for updates is defined by this feature.
- * @since 2.0.2
- */
- public static final int SEARCH_SELF = 1<<2;
-
-
-}
diff --git a/update/org.eclipse.update.core/src/org/eclipse/update/core/IVerificationListener.java b/update/org.eclipse.update.core/src/org/eclipse/update/core/IVerificationListener.java
deleted file mode 100644
index 439186e76..000000000
--- a/update/org.eclipse.update.core/src/org/eclipse/update/core/IVerificationListener.java
+++ /dev/null
@@ -1,79 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2003 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Common Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.update.core;
-
-/**
- * Verification listener. This interface abstract the user interaction
- * that may be required as a result of feature installation. In particular,
- * as feature archives are downloaded and verified, the user may need to
- * indicate whether to accept any one of the archives, or abort the
- * installation.
- * <p>
- * Clients may implement this interface.
- * </p>
- * <p>
- * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
- * change significantly before reaching stability. It is being made 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.
- * </p>
- * @see org.eclipse.update.core.IVerificationResult
- * @see org.eclipse.update.core.IVerifier
- * @since 2.0
- */
-
-public interface IVerificationListener {
-
- /**
- * Indicate the action that resulted in this notification should be aborted.
- *
- * @since 2.0
- */
- public static final int CHOICE_ABORT = 0;
-
- /**
- * Indicate there was an error in processing the request.
- * The action that resulted in this notification should be aborted.
- *
- * @since 2.0
- */
- public static final int CHOICE_ERROR = 1;
-
- /**
- * Indicate that the target of the verification should be accepted,
- * but the information supplied with the verification result
- * should be trusted only for this request.
- *
- * @since 2.0
- */
- public static final int CHOICE_INSTALL_TRUST_ONCE = 2;
-
- /**
- * Indicate that the target of the verification should be accepted,
- * and the information supplied with the verification result
- * should be trusted for this request, and subsequent requests.
- *
- * @since 2.0
- */
- public static final int CHOICE_INSTALL_TRUST_ALWAYS = 3;
-
- /**
- * Determine if we should continue with the current action