Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Swift warm up NSUUID

Johnlin
September 04, 2018

Swift warm up NSUUID

Johnlin

September 04, 2018
Tweet

More Decks by Johnlin

Other Decks in Programming

Transcript

  1. UUID1 • timestamp (60 bit) + clock_seq(14bit) + version(6bit) +

    MAC address(48bit) = 128bit • ࣌ؒੋኺ 1582/10/15T00:00 ։࢝ࢉʢެ㑕։࢝೔)ɼ 㑌100 ns ࢉҰݸᄸҐ
  2. UUID 䉰಍ • timestamp (60 bit) + clock_seq(14bit) + version(6bit)

    + MAC address(48bit) = 128bit • ࡏಉҰ୆ػث্ɼ100 ಸඵ㚎ᬋػతൣᅴ୞༗ 14 bit ༗త࣌ީ။㗞ੜҰᒬతUUIDɼ᜝ҝ䉰಍
  3. UUID1 䉰಍ • timestamp (60 bit) + clock_seq(14bit) + version(6bit)

    + MAC address(48bit) = 128bit • ࡏಉҰ୆ػث্ɼ100 ಸඵ㚎ᬋػతൣᅴ୞༗ 14 bit ༗త࣌ީ။㗞ੜҰᒬతUUIDɼ᜝ҝ䉰಍ • ౟༻ੜ೔ዬ࿦ɼ100 ಸඵ㚎㗞ੜ 18 ݸ UUID ब༗ 1 % తػ཰။䉰಍ɼෆଠద߹շ଎࢖༻
  4. UUID4 • Swift 㚎ݐత NSUUID & UUID ୞༗ UUID4 •

    random (122 bit) + version (6bit) = 128 bit • 䉰಍తػ཰খ኷ଟ • 㗞ੜ 103 ஹݸ UUID4 ။༗ 10ԯ෼೭Ұతػ཰။䉰 ಍
  5. Q&A