• 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: Capturing Message as Invocation Object
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Capturing Message as Invocation Object


  • Subject: Re: Capturing Message as Invocation Object
  • From: Ryan Bates <email@hidden>
  • Date: Tue, 16 Mar 2004 11:58:53 -0800

Thanks a ton! It didn't occur to me to override forwardInvocation: in order to capture the message. The only downside is you cannot capture methods which the class implements, but that shouldn't be a problem for what I'm doing.

Ryan

On Mar 16, 2004, at 11:46 AM, Allan Odgaard wrote:

On 16. Mar 2004, at 20:14, Ryan Bates wrote:

NSUndoManager has the incredibly convenient ability to capture a message as an NSInvocation object using the "prepareWithInvocationTarget:" method. What is NSUndoManager doing under the hood?

It probably implements (NSObject):

- (void)forwardInvocation:(NSInvocation *)anInvocation

Overridden by subclasses to forward messages to other objects. When an object is sent a message for which it has no corresponding method, the runtime system gives the receiver an opportunity to delegate the message to another receiver. [...]
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.


  • Follow-Ups:
    • Re: Capturing Message as Invocation Object
      • From: Ondra Cada <email@hidden>
References: 
 >Capturing Message as Invocation Object (From: Ryan Bates <email@hidden>)
 >Re: Capturing Message as Invocation Object (From: Allan Odgaard <email@hidden>)

  • Prev by Date: Re: Capturing Message as Invocation Object
  • Next by Date: Using bindings with an NSArray of NSStrings ?
  • Previous by thread: Re: Capturing Message as Invocation Object
  • Next by thread: Re: Capturing Message as Invocation Object
  • Index(es):
    • Date
    • Thread