getName

abstract fun getName(): String(source)

The object's name.

Must be constant for the life of the object.

Implementations should not declare a toString that returns anything other than this name. Gradle derives the name from this method wherever it needs one, but renders the object with toString() in diagnostics, so the two disagreeing produces output that contradicts the behavior it describes. This is easy to miss on an enum, which inherits a toString() returning name.

Return

The name. Never null.

Since

1.0