List of usage examples for org.eclipse.jdt.internal.compiler.parser Scanner getSource
public char[] getSource()
From source file:ch.uzh.ifi.seal.changedistiller.ast.java.JavaMethodBodyConverter.java
License:Apache License
/** * Initializes the method body converter. * /*from w ww . ja v a2 s. co m*/ * @param root * the root node of the tree to generate * @param methodRoot * the method AST root node, necessary for comment attachment * @param comments * to associate * @param scanner * the scanner with which the AST was created */ public void initialize(Node root, ASTNode methodRoot, List<Comment> comments, Scanner scanner) { fNodeStack.clear(); fLastAssociationCandidate.clear(); fLastCommentNodeTuples.clear(); fLastVisitedNode = methodRoot; fLastAddedNode = root; fNodeStack.push(root); fComments = comments; fScanner = scanner; fSource = String.valueOf(scanner.getSource()); }