android - start listening @node but do not load data until data added -
i'm using firebase database store data. know how use firebase database. in project i've activity displays list of notices faculties students , clicking on list item open activity chat room. in activity student can ask question related given notice.
now, in first list activity i've added on text view displays total number of chat messages particular notice. works when load data database initially. want change number of chat messages dynamically. so, need listnen @ chat_cnt node update value of message_cnt text view , problem is big list can not use child_added each , every notice item , if use value_event listener load data unnecessarily @ start.
the code little bit big cannot post here. i've described problem.
any answer appreciated, thanks. sorry english :)
Comments
Post a Comment