Proxy implementation in iOS development, ios development proxy implementation

Source: Internet
Author: User

Proxy implementation in iOS development, ios development proxy implementation
Proxy implementation in iOS development

The reason why I want to send this text today: When I am chatting with my colleagues today, he told me that the block provided to him in the project is sometimes hard to understand, so I try to use a proxy to write it, well, if you're tired, write a proxy demo first to prevent him from reading it later.
Today, I will not write a demo for my example. I will cut out the required fragments from the project and give them some advice.
The purpose of using proxy in the same city is to operate in one place and implement it in another place. This is a simple proxy.
First, we need to follow a protocol in the. h of your custom class.
Then define the Protocol
These are all implemented in self. h.
Then we implemented it in our own. m.
Here I call the proxy when btn is clicked. Here, everything in our class has been implemented, and then let's see how to implement it in the controller.
First, call this class.
Then follow the agreement
Call later implementation
Finally, call the proxy method.
 

Related Article

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.