package fr.univ.nantes.processor;

import spoon.processing.AbstractProcessor;
import spoon.reflect.code.CtCodeSnippetStatement;
import spoon.reflect.declaration.CtMethod;

/**
 * @author Alexis Giraudet
 * @author Thomas Minier
 */
public class MethodCallTreeProcessor extends AbstractProcessor<CtMethod> {
    @Override
    public void process(CtMethod method) {
        ;
    }
}

@@ -103,19 +103,8 @@
 e.Ct
-CodeSnippet
 Stat
@@ -110,16 +110,16 @@
 tement;%0A
+
 import s
@@ -350,16 +350,16 @@
 ) %7B%0A
-
         
 ;%0A  
@@ -354,16 +354,652 @@
         
+System.out.println(method.getParent().getSignature() + %22: %22 + method.getSignature());%0A        String enterCode = %22fr.univ.nantes.logger.LogWriter.enterMethod(%5C%22%22 + method.getParent().getSignature() + %22: %22 + method.getSignature() + %22%5C%22); try %7B//%22;%0A        String leaveCode = %22%7D finally %7B fr.univ.nantes.logger.LogWriter.leaveMethod(); %7D//%22;%0A        CtStatement enterStatement = getFactory().Code().createCodeSnippetStatement(enterCode);%0A        CtStatement leaveStatement = getFactory().Code().createCodeSnippetStatement(leaveCode);%0A        method.getBody().insertBegin(enterStatement);%0A        method.getBody().insertEnd(leaveStatement)
 ;%0A    %7D%0A

implement processor