Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 848609
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T06:58:13+00:00 2026-05-15T06:58:13+00:00

In cocoa-touch development… Use AppDelegate for delegate classes Create separate delegate class and locate

  • 0

In cocoa-touch development…

  1. Use AppDelegate for delegate classes
  2. Create separate delegate class and locate in new .h/.m for each class need to use delegate
  3. Use view controller classes(whenever such exist) to do that job for all
    classes managed by this controller

What would you recommend?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-15T06:58:14+00:00Added an answer on May 15, 2026 at 6:58 am

    Well it depends. The entire concept for delegate protocols exist so that you can have a lot of flexibility. Sometimes you take the simply default route but sometimes you need to be able to have a lot of different delegate classes.

    (1) App delegate — the app delegate should only be used for UIApplicationDelegateProtocol methods or delegates for actual properties of the delegate instance itself. In other words, if the app delegate doesn’t directly deal with an instance e.g. the application object, then the app delegate should serve as the instance’s delegate. Piling up extranous methods in the app delegate will muddle the app and make it snarlingly interconnected and difficult to debug and maintain.

    (2) Wholly separate delegate classes are usually used when you have (A) a large number of delegate protocols to implement or (B) you have the same protocol to implement for multiple instances but require a different behavior for each object’s delegate. E.g. you have several UITextFields each of which behave differently. You create as separate delegate class for each so that each text field has it’s own custom implementation of the delegate protocol’s methods.

    (3) Using the controller for delegates is the easiest, most logical and most modular way to go in the majority of cases. In many cases such as UI elements the delegate methods need an awareness of other UI elements which the controller can provide.

    In sum, never do (1) as a general parking place for any random delegate methods and default to (3) in the majority of cases.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 492k
  • Answers 492k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer This can be as simple as: int index = list.IndexOf(b);… May 16, 2026 at 10:22 am
  • Editorial Team
    Editorial Team added an answer Why not let Redemption create a profile for you? RDOSession.Logon… May 16, 2026 at 10:22 am
  • Editorial Team
    Editorial Team added an answer You can find out by p/invoking the Windows FileType() API… May 16, 2026 at 10:22 am

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Related Questions

I'm new to Cocoa/Cocoa Touch, and working through a development book. I've come across
I am new to iPhone application development so that i want to learn cocoa
I am trying to create a site-specific browser application. I've created a new Cocoa
In regards to iPhone development, how do you now when your using a Cocoa
I am trying to create a Cocoa wrapper around a Flash application. I've got
OK, I'm still quite new to Xcode/Cocoa etc, so please forgive me if this
I think over the last year and a half, while experimenting with Cocoa and
Actually I don't care too much about Mac OS X development. I want to
Hi I'm looking into iPhone development, and Objective-C is not be my preferred language.
I've been doing mobile app development for a long time (2001?), but the systems

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.