使用kotlin compiler库解析ktolin文件
String content = "package com.example.myapplication
import com.test.Component
class Tecshkrfdnjklllfjlst : Component() {
}";
实现一个插件,使用PsiFileFactory.getInstance(project)createFileFromText("test.kt",KotlinLanguage.INSTANCE, content)
生成的KtFile,解析不到class
请先登录再写评论。