原文-----------------https://blog.csdn.net/m0_37814654/article/details/77740376                 https://blog.csdn.net/zyc729/article/details/77963555

错误:

Unable to parse template "Interface" Error message: This template did not produce a Java class or an interface

解决方案:

下面的图片显示地方添加:

#if (${PACKAGE_NAME} && ${PACKAGE_NAME} != "")package ${PACKAGE_NAME};#end
#parse("File Header.java")
public class ${NAME} {
}

为防止以后模板可能又被清空,找到Android studio存放文件的bin-->studio.exe.vmoptions,添加一段:-Djdk.util.zip.ensureTrailingSlash=false

然后保存 重启

解决Android studio无法创建Java类

 

相关文章:

  • 2022-01-01
  • 2022-01-16
  • 2022-01-21
  • 2021-12-20
  • 2022-12-23
  • 2021-05-08
  • 2021-07-02
  • 2022-01-25
猜你喜欢
  • 2021-07-07
  • 2021-11-22
  • 2021-07-17
  • 2022-12-23
  • 2021-07-15
  • 2021-11-24
  • 2022-12-23
相关资源
相似解决方案