我需要分析 kotlin 文件代码,以检测关键字“data”和“?”。
问题是我没有找到任何像 JavaParser 这样的库。
我不需要强大的工具,只需要能够返回行数的东西。
任何想法?
我使用antlr4来做到这一点。我创建了一个开源库:https://github.com/sarahBuisson/kotlin-parser https://github.com/sarahBuisson/kotlin-parser
<dependency
<groupId>com.github.sarahbuisson</groupId>
<artifactId>kotlin-parser</artifactId>
</dependency>
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)