Android: restart remote service and bind it again -
i have remote service in android. it's binded list activity , sends messages it. service contins scheduled task in it. have preference: refresh interval service. want restart service when user changes refresh interval. butif in onsharedpreferencechanged() loose connection list activity. how can solve it? thanks.
i know can use broadcast reciever. there way?
i have remote service in android.
why? why not local service?
the service contins scheduled task in it.
why? why not use alarmmanager
, service isn't sitting around in ram, watching time pass?
all want restart service when user changes refresh interval.
why? why not change alarmmanager
schedule? if use local service, service can use sharedpreferences
, setonsharedpreferencechangelistener()
automatically notified of changes in refresh interval.
Comments
Post a Comment