1. Welcome to the new MacRumors forums. See our announcement and read our FAQ

A question about SplitViewController

Discussion in 'iPhone/iPad Programming' started by mikezang, Aug 21, 2010.

  1. macrumors 6502a

    When we create a new project with SplitViewController template, there is some code as below in DetailViewController.m
    @interface DetailViewController ()
    @property (nonatomic, retain) UIPopoverController *popoverController;
    - (void)configureView;
    I want to know why this property is not defined in DetailViewController.h.
  2. Moderator


    Staff Member

    Apple intend it to be private to that class: no external instance should be setting/getting it. Not sure why Apple have made that decision but there you go...
  3. macrumors 68030


    That is the standard idiom for making methods private, since Objective-C doesn't have a private keyword that works for methods in the class declaration.

    This is a class extension. See the Objective-C 2.0 Language guide for more on class extensions.

    And, as robbie mentions, the intention is to make the popover property and the configureView method private.

Share This Page