Examples of extractClassifiedSourceCodeChanges()


Examples of ch.uzh.ifi.seal.changedistiller.distilling.Distiller.extractClassifiedSourceCodeChanges()

        return !nameL.equals(nameR);
    }

    private void extractChanges(Node left, Node right, StructureEntityVersion rootEntity) {
        Distiller distiller = fDistillerFactory.create(rootEntity);
        distiller.extractClassifiedSourceCodeChanges(left, right);
    }

    private void processRemainingDiffs(StructureEntityVersion clazz, List<RefactoringCandidate> candidates) {
        for (RefactoringCandidate candidate : candidates) {
            if (!candidate.isRefactoring()) {
View Full Code Here

Examples of ch.uzh.ifi.seal.changedistiller.distilling.Distiller.extractClassifiedSourceCodeChanges()

        JavaCompilation compilation = CompilationUtils.compileFile(TEST_DATA + "TestLeft.java");
        Node rootLeft = convertMethodBody("foo", compilation);
        Node rootRight = convertMethodBody("foo", compilation);
        StructureEntityVersion structureEntity = new StructureEntityVersion(JavaEntityType.METHOD, "foo", 0);
        Distiller distiller = getDistiller(structureEntity);
        distiller.extractClassifiedSourceCodeChanges(rootLeft, rootRight);
        assertThat(structureEntity.getSourceCodeChanges().isEmpty(), is(true));
    }

    @Test
    public void changedMethodBodyShouldHaveChanges() throws Exception {
View Full Code Here

Examples of ch.uzh.ifi.seal.changedistiller.distilling.Distiller.extractClassifiedSourceCodeChanges()

        JavaCompilation compilationRight = CompilationUtils.compileFile(TEST_DATA + "TestRight.java");
        Node rootLeft = convertMethodBody("foo", compilationLeft);
        Node rootRight = convertMethodBody("foo", compilationRight);
        StructureEntityVersion structureEntity = new StructureEntityVersion(JavaEntityType.METHOD, "foo", 0);
        Distiller distiller = getDistiller(structureEntity);
        distiller.extractClassifiedSourceCodeChanges(rootLeft, rootRight);
        assertThat(structureEntity.getSourceCodeChanges().size(), is(11));
    }

}
View Full Code Here

Examples of ch.uzh.ifi.seal.changedistiller.distilling.Distiller.extractClassifiedSourceCodeChanges()

        distill(leftMethod, rightMethod);
    }

    private void distill(Node leftMethod, Node rightMethod) {
        Distiller distiller = getDistiller(structureEntity);
        distiller.extractClassifiedSourceCodeChanges(leftMethod, rightMethod);
    }

}
View Full Code Here

Examples of ch.uzh.ifi.seal.changedistiller.distilling.Distiller.extractClassifiedSourceCodeChanges()

        JavaCompilation compilation = CompilationUtils.compileFile(TEST_DATA + "TestLeft.java");
        Node rootLeft = convertMethodDeclaration("foo", compilation);
        Node rootRight = convertMethodDeclaration("foo", compilation);
        StructureEntityVersion structureEntity = new StructureEntityVersion(JavaEntityType.METHOD, "foo", 0);
        Distiller distiller = getDistiller(structureEntity);
        distiller.extractClassifiedSourceCodeChanges(rootLeft, rootRight);
        assertThat(structureEntity.getSourceCodeChanges().isEmpty(), is(true));
    }

    @Test
    public void changedMethodShouldHaveChanges() throws Exception {
View Full Code Here

Examples of ch.uzh.ifi.seal.changedistiller.distilling.Distiller.extractClassifiedSourceCodeChanges()

        JavaCompilation compilationRight = CompilationUtils.compileFile(TEST_DATA + "TestRight.java");
        Node rootLeft = convertMethodDeclaration("foo", compilationLeft);
        Node rootRight = convertMethodDeclaration("foo", compilationRight);
        StructureEntityVersion structureEntity = new StructureEntityVersion(JavaEntityType.METHOD, "foo", 0);
        Distiller distiller = getDistiller(structureEntity);
        distiller.extractClassifiedSourceCodeChanges(rootLeft, rootRight);
        assertThat(structureEntity.getSourceCodeChanges().size(), is(2));
    }

    @Test
    public void changedFieldShouldHaveChanges() throws Exception {
View Full Code Here

Examples of ch.uzh.ifi.seal.changedistiller.distilling.Distiller.extractClassifiedSourceCodeChanges()

      JavaCompilation compilationRight = CompilationUtils.compileFile(TEST_DATA + "TestRight.java");
      Node rootLeft = convertFieldDeclaration("arrayField", compilationLeft);
      Node rootRight = convertFieldDeclaration("arrayField", compilationRight);
      StructureEntityVersion structureEntity = new StructureEntityVersion(JavaEntityType.FIELD, "arrayField", 0);
      Distiller distiller = getDistiller(structureEntity);
      distiller.extractClassifiedSourceCodeChanges(rootLeft, rootRight);
     
      List<SourceCodeChange> changes = structureEntity.getSourceCodeChanges();
      assertThat(changes.size(), is(1));
     
      SourceCodeChange singleChange = changes.get(0);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.