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 -

Python Tornado package error when running server -

Qt QGraphicsScene is not accessable from QGraphicsView (on Qt 5.6.1) -