This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ grep -ri wireless * | |
DTDeviceKitBase/DTDKRemoteDeviceConnection.h: _Bool _wireless; | |
DTDeviceKitBase/DTDKRemoteDeviceConnection.h:@property(readonly, getter=isWireless) _Bool wireless; // @synthesize wireless=_wireless; | |
DTDeviceKitBase/DTDKRemoteDeviceToken.h: DTDKRemoteDeviceConnection *_primaryWirelessConection; | |
DTDeviceKitBase/DTDKRemoteDeviceToken.h:+ (id)keyPathsForValuesAffectingHasWirelessConnection; | |
DTDeviceKitBase/DTDKRemoteDeviceToken.h:@property(retain, nonatomic) DTDKRemoteDeviceConnection *primaryWirelessConection; // @synthesize primaryWirelessConection=_primaryWirelessConection; | |
DTDeviceKitBase/DTDKRemoteDeviceToken.h:- (id)takeWirelessPowerAssertionWithName:(id)arg1 deatils:(id)arg2 andTimeout:(double)arg3; | |
DTDeviceKitBase/DTDKRemoteDeviceToken.h:- (id)wirelessInstrumentsServer; | |
DTDeviceKitBase/DTDKRemoteDeviceToken.h:- (void)disableWireless; | |
DTDeviceKitBase/DTDKRemoteDeviceToken.h:- (id)enableWireless; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
erase_sim: | |
./reset_sim.sh 2>/dev/null; true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Note: This must be used in an Xcode project that contains a bridging header | |
// that includes <asl.h> | |
import Foundation | |
/// Provides high-level methods to access the raw data in | |
/// an ASL message. | |
struct SystemLogEntry { | |
/// Key-value pairs read from ASL message | |
let data: [String : String] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
struct User { | |
let id: Int | |
let name: String | |
let email: String? | |
} | |
extension User: JSONDecodable { | |
static func create(id: Int, name: String, email: String?) -> User { | |
return User(id: id, name: name, email: email) | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
infix operator ??= { | |
associativity right | |
precedence 90 | |
assignment | |
} | |
func ??= <T>(inout variable: T?, expr: @autoclosure () -> T) { | |
if variable == nil { | |
variable = expr() | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Taken from the commercial iOS PDF framework http://pspdfkit.com. | |
// Copyright (c) 2014 Peter Steinberger, PSPDFKit GmbH. All rights reserved. | |
// Licensed under MIT (http://opensource.org/licenses/MIT) | |
// | |
// You should only use this in debug builds. It doesn't use private API, but I wouldn't ship it. | |
// PLEASE DUPE rdar://27192338 (https://openradar.appspot.com/27192338) if you would like to see this in UIKit. | |
#import <objc/runtime.h> | |
#import <objc/message.h> |
NewerOlder