-(void) Postnotificationname: (NSString *) AName object: (ID) anobject userInfo: (nsdictionary *) Auserinfo; This function is post a Notification, with a anobject, with a
DIC information, nothing to say, AnObject is to send the sender of this notification.
-(void) Addobserver: (ID) Observer selector: (SEL) aselector name: (NSString *) AName object: (ID) anobject; The main thing is to understand this function is not in place, has been passed the AnObject parameter is nil, this will accept all sender sent the message.
What to do if you need to accept a change message sent by a particular object. This is the use of the AnObject parameter.
The Postnotificationname function uses the same object as the AnObject parameter of the Addobserver function, and it is OK.
For example, I need to observe a picture of the get notification, when the picture is obtained, Postnotificationname AnObject is set to the image name, and the Observer calls Addobserver, also set AnObject as the image name, This will only receive notifications for the specified image. Otherwise, all the pictures will be notified to the observer, in the acquisition of images of excessive number of scenes, will affect the efficiency.