How can I declare a property with a custom setter, but without getter in Kotlin? In Anko for example they do it like this:
var myProperty: Type
@Deprecated(AnkoInternals.NO_GETTER, level = DeprecationLevel.ERROR)
get() = AnkoInternals.noGetter()
set(value) { field = value; /* setter logic */ }
But it looks a bit hacky to me. Is this a right way to do so? If yes, then what about the case when a project doesn't have Anko dependency?
P.S. Let me be clear - I want to have no getter at all, rather than private getter