Resumo:
Instalar os pacotes abaixo:
- cocoapods (via gem)
- fastlane (via gem)
- xcodegen(via Make)
- Bundler (via gem)
Gerar projeto:
Resumo:
Instalar os pacotes abaixo:
Gerar projeto:
| import Foundation | |
| /// Predicatable is the protocol that all predicting objects conform. | |
| public protocol Predicatable: CustomStringConvertible { | |
| /// Returns a Boolean value indicating whether the specified object matches the conditions specified by the predicate. | |
| /// | |
| /// - Parameter object: The object against which to evaluate the predicate. | |
| /// - Returns: `true` if object matches the conditions specified by the predicate, otherwise `false`. | |
| func evaluate(with object: Any?) -> Bool |
| extension DispatchQueue { | |
| static var background: DispatchQueue { return DispatchQueue.global(qos: .background) } | |
| // Execute on main queue without deadlock | |
| static func performOnMainQueue(_ completion: @escaping () -> Void ) { | |
| if Thread.isMainThread { | |
| completion() | |
| } else { | |
| DispatchQueue.main.async(execute: { |
| sudo killall -9 com.apple.CoreSimulator.CoreSimulatorService |
| protocol UserABTestingProtocol { | |
| var userToken: String? { get set } | |
| var fullscreenFeature: ABFullscreenFeature { get } | |
| // Os outros foram deletados só pra ilustrar melhor | |
| } | |
| class ABFullscreenFeature: ABFeatureTestInteractor { | |
| enum Alternatives: String, CaseIterable { |
| import CoreLocation | |
| static func vCardURL(from coordinate: CLLocationCoordinate2D, with name: String?) -> URL { | |
| let vCardFileURL = URL(fileURLWithPath: NSTemporaryDirectory()).appendingPathComponent("vCard.loc.vcf") | |
| let vCardString = [ | |
| "BEGIN:VCARD", | |
| "VERSION:4.0", | |
| "FN:\(name ?? "Shared Location")", | |
| "item1.URL;type=pref:http://maps.apple.com/?ll=\(coordinate.latitude),\(coordinate.longitude)", |
| // | |
| // CURLDebug.swift | |
| // | |
| // Created by apple on 02/06/16. | |
| // Copyright © 2016 Rodrigo Reis. All rights reserved. | |
| // | |
| import Foundation | |
| extension UIView { | |
| var globalScreenPoint :CGPoint? { | |
| return self.superview?.convert(self.frame.origin, to: nil) | |
| } | |
| var globalScreenFrame :CGRect? { | |
| return self.superview?.convert(self.frame, to: nil) | |
| } | |
| } |