开发者

How to remove static variable value ,when will i close my activity

开发者 https://www.devze.com 2023-01-13 00:58 出处:网络
开发者_开发问答i want to clear variable value when will i close activity Thanks AllI think when you close your activity, the android OS will destroy any data associated with your application that isn
开发者_开发问答

i want to clear variable value when will i close activity

Thanks All


I think when you close your activity, the android OS will destroy any data associated with your application that isn't saved in a DB, and if you're worried about closing, then reopening the same activity, you can always assign default values to your variables upon creating them.. like

int x = 0;

sort of thing, this is always a good practice anyways! -M@

0

精彩评论

暂无评论...
验证码 换一张
取 消