我定义了一个enum类来实现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中会出现错误,我该如何解决这个问题呢?