ios - How UIViewController interact with Storyboard under the hood -


i'm new ios development , stupid question experienced guys...

when create new ios project in xcode, viewcontroller class , storyboard sets custom class viewcontroller. looks there "storyboard" class holding instance of viewcontroller, however, cannot find "storyboard" class defined.

even though know how create multiple subclasses of uiviewcontroller handle different views interaction following tutorials, still find uncomfortable associate these subclasses storyboard selecting them in storyboard panel. rather see "storyboard" class holding array of uiviewcontroller.

so question is, how these uiviewcontroller interact storyboard under hood?

thanks

roughly, happens follows:

  1. app launches.
  2. app loads storryboard.
  3. depending on app's navigation structure, app instantiates each view controller inside storyboard needed.

the storyboard contains detailed information on:

  • which custom subclass of uiviewcontroller, uinavigtioncontroller, etc. use instantiating each view controller in storyboard.

  • how map (connect) each if view controllers' subviews corresponding custom classes' outlets , actions.

but seriously, read apple's docs. it's there.


Comments

Popular posts from this blog

multithreading - Exception in Application constructor -

React Native allow user to reorder elements in a scrollview list -

windows - CertCreateCertificateContext returns CRYPT_E_ASN1_BADTAG / 8009310b -