/** * Return hash code identifying an absolute installation path * @return hash code as String */ private String getInstallDirHash() { // compute an install dir hash to prevent configuration area collisions with other eclipse installs String installProperty = equinoxConfig.getConfiguration(PROP_INSTALL_AREA); URL installURL = buildURL(installProperty, true); if (installURL == null) return ""; //$NON-NLS-1$ File installDir = new File(installURL.getFile()); int hashCode; try { hashCode = installDir.getCanonicalPath().hashCode(); } catch (IOException ioe) { // fall back to absolute path hashCode = installDir.getAbsolutePath().hashCode(); } if (hashCode < 0) hashCode = -(hashCode); String installDirHash = String.valueOf(hashCode); return installDirHash; }
/** * Return hash code identifying an absolute installation path * @return hash code as String */ private String getInstallDirHash() { // compute an install dir hash to prevent configuration area collisions with other eclipse installs String installProperty = equinoxConfig.getConfiguration(PROP_INSTALL_AREA); URL installURL = buildURL(installProperty, true); if (installURL == null) return ""; //$NON-NLS-1$ File installDir = new File(installURL.getPath()); int hashCode; try { hashCode = installDir.getCanonicalPath().hashCode(); } catch (IOException ioe) { // fall back to absolute path hashCode = installDir.getAbsolutePath().hashCode(); } if (hashCode < 0) hashCode = -(hashCode); String installDirHash = String.valueOf(hashCode); return installDirHash; }
/** * Return hash code identifying an absolute installation path * @return hash code as String */ private String getInstallDirHash() { // compute an install dir hash to prevent configuration area collisions with other eclipse installs String installProperty = equinoxConfig.getConfiguration(PROP_INSTALL_AREA); URL installURL = buildURL(installProperty, true); if (installURL == null) return ""; //$NON-NLS-1$ File installDir = new File(installURL.getPath()); int hashCode; try { hashCode = installDir.getCanonicalPath().hashCode(); } catch (IOException ioe) { // fall back to absolute path hashCode = installDir.getAbsolutePath().hashCode(); } if (hashCode < 0) hashCode = -(hashCode); String installDirHash = String.valueOf(hashCode); return installDirHash; }
/** * Return hash code identifying an absolute installation path * @return hash code as String */ private String getInstallDirHash() { // compute an install dir hash to prevent configuration area collisions with other eclipse installs String installProperty = equinoxConfig.getConfiguration(PROP_INSTALL_AREA); URL installURL = buildURL(installProperty, true); if (installURL == null) return ""; //$NON-NLS-1$ File installDir = new File(installURL.getFile()); int hashCode; try { hashCode = installDir.getCanonicalPath().hashCode(); } catch (IOException ioe) { // fall back to absolute path hashCode = installDir.getAbsolutePath().hashCode(); } if (hashCode < 0) hashCode = -(hashCode); String installDirHash = String.valueOf(hashCode); return installDirHash; }
/** * Return hash code identifying an absolute installation path * @return hash code as String */ private String getInstallDirHash() { // compute an install dir hash to prevent configuration area collisions with other eclipse installs String installProperty = equinoxConfig.getConfiguration(PROP_INSTALL_AREA); URL installURL = buildURL(installProperty, true); if (installURL == null) return ""; //$NON-NLS-1$ File installDir = new File(installURL.getFile()); int hashCode; try { hashCode = installDir.getCanonicalPath().hashCode(); } catch (IOException ioe) { // fall back to absolute path hashCode = installDir.getAbsolutePath().hashCode(); } if (hashCode < 0) hashCode = -(hashCode); String installDirHash = String.valueOf(hashCode); return installDirHash; }
/** * Return hash code identifying an absolute installation path * @return hash code as String */ private String getInstallDirHash() { // compute an install dir hash to prevent configuration area collisions with other eclipse installs String installProperty = equinoxConfig.getConfiguration(PROP_INSTALL_AREA); URL installURL = buildURL(installProperty, true); if (installURL == null) return ""; //$NON-NLS-1$ File installDir = new File(installURL.getFile()); int hashCode; try { hashCode = installDir.getCanonicalPath().hashCode(); } catch (IOException ioe) { // fall back to absolute path hashCode = installDir.getAbsolutePath().hashCode(); } if (hashCode < 0) hashCode = -(hashCode); String installDirHash = String.valueOf(hashCode); return installDirHash; }
URL installURL = buildURL(installProperty, true); if (installURL == null) return null;
URL installURL = buildURL(installProperty, true); if (installURL == null) return null;
URL installURL = buildURL(installProperty, true); if (installURL == null) return null;
URL installURL = buildURL(installProperty, true); if (installURL == null) return null;
URL installURL = buildURL(installProperty, true); if (installURL == null) return null;
URL installURL = buildURL(installProperty, true); if (installURL == null) return null;
location = location.substring(0, idx) + getInstallDirHash() + location.substring(idx + INSTALL_HASH_PLACEHOLDER.length()); URL url = buildURL(location, true); BasicLocation result = null; if (url != null) {
location = location.substring(0, idx) + getInstallDirHash() + location.substring(idx + INSTALL_HASH_PLACEHOLDER.length()); URL url = buildURL(location, true); BasicLocation result = null; if (url != null) {
location = location.substring(0, idx) + getInstallDirHash() + location.substring(idx + INSTALL_HASH_PLACEHOLDER.length()); URL url = buildURL(location, true); BasicLocation result = null; if (url != null) {
location = location.substring(0, idx) + getInstallDirHash() + location.substring(idx + INSTALL_HASH_PLACEHOLDER.length()); URL url = buildURL(location, true); BasicLocation result = null; if (url != null) {
location = location.substring(0, idx) + getInstallDirHash() + location.substring(idx + INSTALL_HASH_PLACEHOLDER.length()); URL url = buildURL(location, true); BasicLocation result = null; if (url != null) {
location = location.substring(0, idx) + getInstallDirHash() + location.substring(idx + INSTALL_HASH_PLACEHOLDER.length()); URL url = buildURL(location, true); BasicLocation result = null; if (url != null) {
URL defaultLocation = temp == null ? null : temp.getURL(); if (defaultLocation == null) defaultLocation = buildURL(new File(System.getProperty(PROP_USER_HOME), "user").getAbsolutePath(), true); //$NON-NLS-1$ userLocation = buildLocation(PROP_USER_AREA, defaultLocation, "", false, false, null); //$NON-NLS-1$ defaultLocation = temp == null ? null : temp.getURL(); if (defaultLocation == null) defaultLocation = buildURL(new File(System.getProperty(PROP_USER_DIR), "workspace").getAbsolutePath(), true); //$NON-NLS-1$ instanceLocation = buildLocation(PROP_INSTANCE_AREA, defaultLocation, "", false, false, INSTANCE_DATA_AREA_PREFIX); //$NON-NLS-1$ if (defaultLocation == null && equinoxConfig.getConfiguration(PROP_CONFIG_AREA) == null) defaultLocation = buildURL(computeDefaultConfigurationLocation(), true); configurationLocation = buildLocation(PROP_CONFIG_AREA, defaultLocation, "", false, false, null); //$NON-NLS-1$
URL defaultLocation = temp == null ? null : temp.getURL(); if (defaultLocation == null) defaultLocation = buildURL(new File(System.getProperty(PROP_USER_HOME), "user").getAbsolutePath(), true); //$NON-NLS-1$ userLocation = buildLocation(PROP_USER_AREA, defaultLocation, "", false, false, null); //$NON-NLS-1$ defaultLocation = temp == null ? null : temp.getURL(); if (defaultLocation == null) defaultLocation = buildURL(new File(System.getProperty(PROP_USER_DIR), "workspace").getAbsolutePath(), true); //$NON-NLS-1$ instanceLocation = buildLocation(PROP_INSTANCE_AREA, defaultLocation, "", false, false, INSTANCE_DATA_AREA_PREFIX); //$NON-NLS-1$ if (defaultLocation == null && equinoxConfig.getConfiguration(PROP_CONFIG_AREA) == null) defaultLocation = buildURL(computeDefaultConfigurationLocation(), true); configurationLocation = buildLocation(PROP_CONFIG_AREA, defaultLocation, "", false, false, null); //$NON-NLS-1$