0

I am stuck with a flow where I am updating my adapter list variable from inside of the click event attached with view and I am putting my values in modal class on create of the activity. but when I come back from my activity the modal is created again but I need to restore a value. please help.

MYactivity.java

LiveFeedModel liveFeedModel = new LiveFeedModel(feedId,videoUrl,
                        "1.5k",cameraIp,cameraName,livecount);

Modal class:

public class LiveFeedModel {

private String feedId;
private String videoUrl;
private String viewers;
private boolean is30mincomplete = true;

changing Value of is30mincomplete every half hour from inside adapter.

liveFeed.setis30mincomplete(false);

but when I come out from my activity and goes back to it new modal is created and my last setis30mincomplete is not saved. but I want to reuse the old value of this variable.

Harish Chauhan
  • 103
  • 1
  • 1
  • 9

0 Answers0