OC Learning Path----Agent Mode 2-Steps to use

Source: Internet
Author: User

Before you have written a personal opinion about proxy mode, let's summarize the steps to use proxy mode.

  

1. Find out who the agent is (delegate) 2. Define the proxy protocol, the naming convention for the Protocol name: control class name + Delegate 3. Define proxy methods Ø Proxy methods are generally defined as @optionalø proxy method names begin with the control name Ø The proxy method has at least 1 parameters, Pass the control itself out of the ø4. Set proxy (delegate) object (e.g. myview.delegate = XXXX;) Ø Proxy object complies with the Protocol O proxy Object implementation of the protocol inside the implementation of the method ø5. The proxy method that invokes the proxy object (delegate) at the right time, Notify the agent what's going on

(Determines whether the agent implements the proxy method before calling)

OC Learning Path----Agent Mode 2-Steps to use

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.