• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Discovering where a method was called from within the method
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Discovering where a method was called from within the method


  • Subject: Re: Discovering where a method was called from within the method
  • From: "I. Savant" <email@hidden>
  • Date: Thu, 20 Apr 2006 08:41:28 -0400


If it's your own code, how about setting a breakpoint on the targeted method and running it in the debugger? Every time it's called, you'll see the stack trace for it and can click it to go directly to the point in code that called it.


  Or you could use XCode's Find In Project (Cmd-Shift-F) ...

Unless I'm missing the point of your question, the above two are probably your best means.

--
I.S.


On Apr 20, 2006, at 4:34 AM, Philip Dow wrote:

I imagine something like this has been addressed before, but I don't know what to search for as I'm not sure what this is called. Maybe a stack trace? The scenario is as follows:

I am changing a custom object's variable from an NSData object to an NSAttributedString object. I have accessors and setters for both. Everywhere else in the program, I need to update the code to access the new attributed string methods rather than those for the data object.

Because I can convert an attributed string to rtfd data, I can still call the methods that had been using the data object and just convert from the string on the fly. This makes it possible to update my code slowly and carefully. However, I need to know when the data accessors and setters are being called. Knowing where they are used, I can eventually fade them out completely.

Is it possible from within those methods find out what other objects and methods are calling them? I need something similar to a crash report.

-Phil


_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
40gmail.com


This email sent to email@hidden

_______________________________________________ Do not post admin requests to the list. They will be ignored. Cocoa-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
  • Follow-Ups:
    • Re: Discovering where a method was called from within the method
      • From: William Bumgarner <email@hidden>
    • Re: Discovering where a method was called from within the method
      • From: Philip Dow <email@hidden>
References: 
 >Discovering where a method was called from within the method (From: Philip Dow <email@hidden>)

  • Prev by Date: Re: how do I drag into tableViews?
  • Next by Date: Re: Localization
  • Previous by thread: Re: Discovering where a method was called from within the method
  • Next by thread: Re: Discovering where a method was called from within the method
  • Index(es):
    • Date
    • Thread