Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for detectModelVersion (0.08 sec)

  1. impl/maven-cli/src/test/java/org/apache/maven/cling/invoker/mvnup/goals/ModelVersionUtilsTest.java

                        .artifactId("test")
                        .version("1.0.0")
                        .build();
    
                Document document = Document.of(pomXml);
                String result = ModelVersionUtils.detectModelVersion(document);
                assertEquals("4.0.0", result);
            }
    
            @ParameterizedTest(name = "for {0}")
            @ValueSource(strings = {"4.0.0", "4.1.0", "4.2.0"})
    Registered: Sun Dec 28 03:35:09 UTC 2025
    - Last Modified: Tue Nov 18 18:03:26 UTC 2025
    - 19.6K bytes
    - Viewed (0)
  2. impl/maven-cli/src/main/java/org/apache/maven/cling/invoker/mvnup/goals/ModelVersionUtils.java

         * Uses both the modelVersion element and namespace URI for detection.
         *
         * @param pomDocument the POM document (domtrip Document)
         * @return the detected model version
         */
        public static String detectModelVersion(Document pomDocument) {
            Editor editor = new Editor(pomDocument);
            Element root = editor.root();
            if (root == null) {
                return MODEL_VERSION_4_0_0;
            }
    
    Registered: Sun Dec 28 03:35:09 UTC 2025
    - Last Modified: Tue Nov 18 18:03:26 UTC 2025
    - 9.5K bytes
    - Viewed (0)
  3. impl/maven-cli/src/main/java/org/apache/maven/cling/invoker/mvnup/goals/InferenceStrategy.java

                Path pomPath = entry.getKey();
                Document pomDocument = entry.getValue();
                processedPoms.add(pomPath);
    
                String currentVersion = ModelVersionUtils.detectModelVersion(pomDocument);
                context.info(pomPath + " (current: " + currentVersion + ")");
                context.indent();
    
                try {
    Registered: Sun Dec 28 03:35:09 UTC 2025
    - Last Modified: Tue Nov 18 18:03:26 UTC 2025
    - 27.6K bytes
    - Viewed (0)
  4. impl/maven-cli/src/main/java/org/apache/maven/cling/invoker/mvnup/goals/ModelUpgradeStrategy.java

                Path pomPath = entry.getKey();
                Document pomDocument = entry.getValue();
                processedPoms.add(pomPath);
    
                String currentVersion = ModelVersionUtils.detectModelVersion(pomDocument);
                context.info(pomPath + " (current: " + currentVersion + ")");
                context.indent();
    
                try {
                    if (currentVersion.equals(targetModelVersion)) {
    Registered: Sun Dec 28 03:35:09 UTC 2025
    - Last Modified: Tue Nov 18 18:03:26 UTC 2025
    - 16.6K bytes
    - Viewed (0)
Back to top