2016-05-09 cocoa 查看无线是否打开 可链接的wifi列表 1234567891011CWInterface *wifi = [CWWiFiClient sharedWiFiClient].interface; NSLog(@"interfaceName: %@", wifi.interfaceName);NSLog(@"ssid: %@", wifi.ssid);NSLog(@"powerOn: %@", @(wifi.powerOn)); NSSet<CWNetwork *> *result = [wifi scanForNetworksWithName:nil error:nil];NSLog(@"可连接的wifi列表");for (CWNetwork *each in result) { NSLog(@"--->%@",each.ssid);} Récent swift 通过 string 创建 object Ancien TextKit