Open hangpm opened 6 years ago
Hi, you may have to change the ASTExtractor.properties file, so that the BLOCK is not in the list of elements that are omitted. By doing so, I was able to get a complete AST for the code you posted
Hi, sorry for my broken English. I might not give enough information in the last comment that I didn't customize any properties at all and I used parseFile(). Also the findOpinion method in the output file is below.
<MethodDeclaration>
<Modifier>public</Modifier>
<SimpleType>
<SimpleName>ResultObject</SimpleName>
</SimpleType>
<SimpleName>findOpinion</SimpleName>
<SingleVariableDeclaration>
<SimpleType>
<SimpleName>String</SimpleName>
</SimpleType>
<SimpleName>sentence</SimpleName>
</SingleVariableDeclaration>
<Block>{
}
</Block>
</MethodDeclaration>
On the other hand, I switched to parseString() instead of parseFile() right after I open this issue, and it turned out OK. Now I see your comment, but unfortunately changing omitted list is not work for me.
I try to parse a file written in java below. But in the output xml file, all the statements inside findOpinion() and methods defined after findOpinion() are nowhere to be found. Is this issue due to some kinds of constraint or do I miss any configurtions?