android - Parse an xml once for use across many activities -
i'm working saxparser parse xml. problem is, have few screens or activities coded. @ moment, every time transition new activity button press example, new activity needs parse xml on again, can populate screen specific content.
is there way in parse xml once through life of program?
thank you.
sure, parse once , store want remember in variables.
more completely, create class (or classes) classes represent properties same information in xml document. constructor of class take xml argument, parse it, , populate properties.
hope helps.
Comments
Post a Comment