Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 11 for isAbsolute (0.09 sec)

  1. compat/maven-embedder/src/main/java/org/apache/maven/cli/ResolveFile.java

     */
    @Deprecated
    public class ResolveFile {
        public static File resolveFile(File file, String baseDirectory) {
            if (file == null) {
                return null;
            } else if (file.isAbsolute()) {
                return file;
            } else if (file.getPath().startsWith(File.separator)) {
                // drive-relative Windows path
                return file.getAbsoluteFile();
            } else {
    Registered: Sun Dec 28 03:35:09 UTC 2025
    - Last Modified: Fri Nov 08 08:49:11 UTC 2024
    - 1.4K bytes
    - Viewed (0)
  2. compat/maven-compat/src/main/java/org/apache/maven/project/path/DefaultPathTranslator.java

                return path;
            }
    
            if (path == null) {
                return null;
            }
    
            String s = stripBasedirToken(path);
    
            File file = new File(s);
            if (file.isAbsolute()) {
                // path was already absolute, just normalize file separator and we're done
                s = file.getPath();
            } else if (file.getPath().startsWith(File.separator)) {
    Registered: Sun Dec 28 03:35:09 UTC 2025
    - Last Modified: Fri Jun 06 14:28:57 UTC 2025
    - 7.2K bytes
    - Viewed (0)
  3. compat/maven-model-builder/src/main/java/org/apache/maven/model/path/DefaultPathTranslator.java

            if (path != null && basedir != null) {
                path = path.replace('\\', File.separatorChar).replace('/', File.separatorChar);
    
                File file = new File(path);
                if (file.isAbsolute()) {
                    // path was already absolute, just normalize file separator and we're done
                    result = file.getPath();
                } else if (file.getPath().startsWith(File.separator)) {
    Registered: Sun Dec 28 03:35:09 UTC 2025
    - Last Modified: Tue Feb 25 08:27:34 UTC 2025
    - 2.1K bytes
    - Viewed (0)
  4. impl/maven-core/src/main/java/org/apache/maven/configuration/BasedirBeanConfigurationPathTranslator.java

            this.basedir = basedir;
        }
    
        @Override
        public File translatePath(File path) {
            File result = path;
    
            if (path != null && basedir != null) {
                if (path.isAbsolute()) {
                    // path is already absolute, we're done
                } else if (path.getPath().startsWith(File.separator)) {
                    // drive-relative Windows path, don't align with base dir but with drive root
    Registered: Sun Dec 28 03:35:09 UTC 2025
    - Last Modified: Fri Jun 06 14:28:57 UTC 2025
    - 2.1K bytes
    - Viewed (0)
  5. api/maven-api-core/src/main/java/org/apache/maven/api/SourceRoot.java

         */
        @Nonnull
        default Path targetPath(@Nonnull Project project) {
            Optional<Path> targetPath = targetPath();
            // The test for `isAbsolute()` is a small optimization for avoiding the call to `getOutputDirectory(…)`.
            return targetPath.filter(Path::isAbsolute).orElseGet(() -> {
                Path base = project.getOutputDirectory(scope());
                return targetPath.map(base::resolve).orElse(base);
            });
    Registered: Sun Dec 28 03:35:09 UTC 2025
    - Last Modified: Fri Nov 07 13:11:07 UTC 2025
    - 14.2K bytes
    - Viewed (0)
  6. compat/maven-model-builder/src/main/java/org/apache/maven/model/profile/activation/FileProfileActivator.java

                        .setException(e));
                return false;
            }
    
            if (path == null) {
                return false;
            }
    
            File f = new File(path);
    
            if (!f.isAbsolute()) {
                return false;
            }
    
            boolean fileExists = f.exists();
    
            return missing ? !fileExists : fileExists;
        }
    
        @Override
    Registered: Sun Dec 28 03:35:09 UTC 2025
    - Last Modified: Tue Feb 25 08:27:34 UTC 2025
    - 4.4K bytes
    - Viewed (0)
  7. impl/maven-core/src/main/java/org/apache/maven/plugin/PluginParameterExpressionEvaluatorV4.java

            // TODO Copied from the DefaultInterpolator. We likely want to resurrect the PathTranslator or at least a
            // similar component for re-usage
            if (file != null) {
                if (file.isAbsolute()) {
                    // path was already absolute, just normalize file separator and we're done
                } else if (file.getPath().startsWith(File.separator)) {
    Registered: Sun Dec 28 03:35:09 UTC 2025
    - Last Modified: Fri Jan 24 17:29:44 UTC 2025
    - 9.8K bytes
    - Viewed (0)
  8. compat/maven-settings-builder/src/main/java/org/apache/maven/settings/building/DefaultSettingsBuilder.java

            String localRepository = userSettings.getLocalRepository();
            if (localRepository != null && !localRepository.isEmpty()) {
                File file = new File(localRepository);
                if (!file.isAbsolute() && file.getPath().startsWith(File.separator)) {
                    userSettings.setLocalRepository(file.getAbsolutePath());
                }
            }
    
            if (hasErrors(problems.getProblems())) {
    Registered: Sun Dec 28 03:35:09 UTC 2025
    - Last Modified: Wed Jul 23 17:27:08 UTC 2025
    - 9.5K bytes
    - Viewed (0)
  9. impl/maven-core/src/main/java/org/apache/maven/plugin/PluginParameterExpressionEvaluator.java

            // TODO Copied from the DefaultInterpolator. We likely want to resurrect the PathTranslator or at least a
            // similar component for re-usage
            if (file != null) {
                if (file.isAbsolute()) {
                    // path was already absolute, just normalize file separator and we're done
                } else if (file.getPath().startsWith(File.separator)) {
    Registered: Sun Dec 28 03:35:09 UTC 2025
    - Last Modified: Fri Jan 24 17:29:44 UTC 2025
    - 16.6K bytes
    - Viewed (0)
  10. compat/maven-compat/src/main/java/org/apache/maven/repository/legacy/LegacyRepositorySystem.java

            // for the local repository setting.
    
            File localRepository = new File(url.substring("file://".length()));
    
            if (!localRepository.isAbsolute()) {
                url = "file://" + localRepository.getCanonicalPath();
            }
    
            return url;
        }
    
        @Override
        public ArtifactResolutionResult resolve(ArtifactResolutionRequest request) {
    Registered: Sun Dec 28 03:35:09 UTC 2025
    - Last Modified: Fri Jun 06 14:28:57 UTC 2025
    - 31.2K bytes
    - Viewed (0)
Back to top