【发布时间】:2017-11-17 02:24:23
【问题描述】:
我定义了一个实现 Neo4j 的RelationshipType 的枚举类:
enum class MyRelationshipType : RelationshipType {
// ...
}
我收到以下错误:
Inherited platform declarations clash: The following declarations have the same JVM signature (name()Ljava/lang/String;): fun <get-name>(): String fun name(): String
我了解Enum 类中的name() 方法和RelationshipType 接口中的name() 方法具有相同的签名。不过这在 Java 中不是问题,那么为什么在 Kotlin 中会出现错误,我该如何解决呢?
【问题讨论】: