android - How to change the name of a Kotlin property to match the field to on Firebase database -


i want change name of field kotlin property pointing on firebase database.

for instance:

i have property count in kotlin

var count: int 

but name on firebase items_count. i've tried using: when try using

@propertyname("items_count") var count: int 

but doesn't work.

i achieved using:

@set:propertyname("items_count") @get:propertyname("items_count") var count: int 

Comments

Popular posts from this blog

Is there a better way to structure post methods in Class Based Views -

reflection - How to access the object-members of an object declaration in kotlin -

php - Doctrine Query Builder Error on Join: [Syntax Error] line 0, col 87: Error: Expected Literal, got 'JOIN' -