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

The SDK directory does not exist (ubuntu 16.04) (react native) -

python - How to clone or copy a list? -

string - Using python and postgres, variables within execute function? -