IOS device to determine the latest stats code

Source: Internet
Author: User

-(nsstring*) devicename{    struct utsname systeminfo;        uname (&systeminfo );        nsstring* code = [NSString stringwithcstring:systeminfo.machine      & nbsp                                 ENCODING:N sutf8stringencoding];        static nsdictionary* Devicenamesbycode = nil;         if (!devicenamesbycode) {                Devicenamesbycode = @{ @ "i386"      :@ "Simulator",                      &NB Sp       @ "ipod1,1"  : @ "IPodTouch1",      //(Original)                               @ "ipod2,1"  : @ "IPODTOUCH2",     &NB sp;//(Second GeneratioN)                               @ "ipod3,1" &nbs P : @ "IPodTouch3",      //(third Generation)                   &N Bsp           @ "ipod4,1"  : @ "IPODTOUCH4",      //(fourth Generation)   &nbs P                         @ "iphone1,1": @ "iphone2g11", &N Bsp        //(Original)                       &NBSP ;       @ "iphone1,2": @ "Iphone3g12",          //(3G)         &NB Sp                     @ "iphone2,1": @ "Iphone3gs21",       & nbsp  //(3GS)                               @ "ipad1,1"  : @ "IPad",            //(Original)           &NBS P                   @ "ipad2,1"  : @ "iPad2",         &N bsp;//                            @ "ipad3,1"  : @ "IPad",            //(3rd Generation)             &NB Sp                 @ "iphone3,1": @ "iPhone431",//          &N Bsp                   @ "iphone3,2": @ "iPhone432",        &NBS P                      @ "iphone3,3": @ "iPhone433",    &nbsp ;                         @ "iphone4,1": @ "iphone4s41",//  & nbsp &nbsp                         @ "iphone4,2": @ "iPhone442",  &nbs P                         @ "iphone4,3": @ "iPhone443", &nbs P                             @ "iphone5,1": @ "IPhone55 1 ",        //(model A1428, At&t/canada)                 &N Bsp             @ "iphone5,2": @ "iPhone552",              &NBS P               @ "ipad3,4"  : @ "IPad"            //( 4th Generation                               @ " ipad2,5 " : @" Ipadmini ",      //(Original)                 &N Bsp             @ "iphone5,3": @ "iphone5c53",      //(model A1456, A1532 | GSM)                               @ "iphone5,4" : @ "iphone5c54",      //(model A1507, A1516, A1526 (China), A1529 | Global)                         IPhone6     @ "", 1 ": @" iphone5s61 ",      //(model A1433, A1533 | GSM)                               @ "iphone6,2" : @ "IPHONE5S62",      //(model A1457, A1518, A1528 (China), A1530 | Global                               @ "ipad4,1"  : @ "Ipadair",        //5th Generation ipad (ipad Air)-wifi                    &NBSp         @ "ipad4,2"  : @ "Ipadair",        //5th Generation ipad (ipad Air)- cellular                            @ "ipad4,4 " : @" Ipadmini ",      //(2nd Generation iPad Mini-wifi)                               @ "ipad4,5"  : @ "Ipadmini"        / /(2nd Generation iPad mini-cellular)                            };   }
Come on, boys, try it,!~.

IOS device to determine the latest stats code

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.