Last active
January 21, 2021 16:32
-
-
Save pilot34/dd4bd51ad518e2b26064eecfe8fdd450 to your computer and use it in GitHub Desktop.
What is included into XCTApplicationLaunchMetric
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
@objc class AppDelegate: UIResponder, UIApplicationDelegate { | |
override init() { | |
debugPrint("AppDelegate.init") | |
super.init() | |
} | |
var window: UIWindow? | |
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool { | |
debugPrint("AppDelegate.didFinishLaunchingWithOptions") | |
let window = UIWindow(frame: UIScreen.main.bounds) | |
window.rootViewController = ViewController() | |
window.makeKeyAndVisible() | |
self.window = window | |
return true | |
} | |
func applicationDidBecomeActive(_ application: UIApplication) { | |
debugPrint("AppDelegate.applicationDidBecomeActive") | |
} | |
func applicationWillEnterForeground(_ application: UIApplication) { | |
debugPrint("AppDelegate.applicationWillEnterForeground") | |
} | |
} | |
class ViewController: UIViewController { | |
init() { | |
super.init(nibName: nil, bundle: nil) | |
debugPrint("ViewController.init") | |
} | |
required init?(coder: NSCoder) { | |
fatalError("init(coder:) has not been implemented") | |
} | |
override func loadView() { | |
self.view = View() | |
} | |
override func viewDidLoad() { | |
super.viewDidLoad() | |
debugPrint("ViewController.viewDidLoad") | |
} | |
override func viewWillAppear(_ animated: Bool) { | |
super.viewWillAppear(animated) | |
debugPrint("ViewController.viewWillAppear") | |
} | |
override func viewDidAppear(_ animated: Bool) { | |
super.viewDidAppear(animated) | |
debugPrint("ViewController.viewDidAppear") | |
} | |
override func viewWillLayoutSubviews() { | |
super.viewWillLayoutSubviews() | |
debugPrint("ViewController.viewWillLayoutSubviews") | |
} | |
override func viewDidLayoutSubviews() { | |
super.viewDidLayoutSubviews() | |
debugPrint("ViewController.viewDidLayoutSubviews") | |
} | |
} | |
class View: UIView { | |
init() { | |
super.init(frame: .zero) | |
debugPrint("View.init") | |
} | |
override func layoutSubviews() { | |
super.layoutSubviews() | |
debugPrint("View.layoutSubviews") | |
} | |
override func willMove(toWindow newWindow: UIWindow?) { | |
super.willMove(toWindow: newWindow) | |
debugPrint("View.willMoveToWindow") | |
} | |
override func layerWillDraw(_ layer: CALayer) { | |
super.layerWillDraw(layer) | |
debugPrint("View.layerWillDraw") | |
} | |
override func didMoveToWindow() { | |
super.didMoveToWindow() | |
debugPrint("View.didMoveToWindow") | |
} | |
override func didMoveToSuperview() { | |
super.didMoveToSuperview() | |
debugPrint("View.didMoveToWindow") | |
} | |
required init?(coder: NSCoder) { | |
fatalError("init(coder:) has not been implemented") | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment