ios - NSUserdefault and core data -


what nsuserdefault ? , how can used store peristent data of app . please clear doubt on when use them , how can useful performance wise ?

with nsuserdefaults class, can save settings , properties related application or user data.
example, save profile image set user or default color scheme application. objects saved in known ios “defaults system”. ios defaults system available throughout of code in app, , data saved defaults system persist through application sessions. means if user closes application or reboots phone, saved data still available next time open app.

performance

the nsuserdefaults class caches values internally lookup extremely fast. overhead of [nsuserdefaults standarduserdefaults] vs instance variable small wouldn't notice if did 5 million times in code.


Comments

Popular posts from this blog

html - Outlook 2010 Anchor (url/address/link) -

javascript - Why does running this loop 9 times take 100x longer than running it 8 times? -

Getting gateway time-out Rails app with Nginx + Puma running on Digital Ocean -