iOS Learning Notes (2)

Source: Internet
Author: User

Listen to certain events of the control

Proxy mode is used to "decouple " The program directly

Tables can display very rich data, in order to achieve this effect, set the table " data source "

@required The methods that must be implemented

@optional Optional implementation method, and do not force implementation , if implemented can get special effect, if not implemented, also does not affect the normal operation of the program

ability to increase the flexibility of controls

Agent Stage Summary

1. comply with the agreement, pre-defined methods, not implemented, specific implementation of the agent responsible for the work

< control's name +datasource> defined data-related methods

The name of the < control +delegate> defines an event-related method that is typically used to listen for control events

2. proxy Methods

1> method names start with the name of the control ( without the class prefix ) , so you can quickly find the protocol method you need.

2> The first parameter is self--- means that in the protocol method, you can directly access the properties of an object, or call a method /c21>

3> The return value of the proxy method- controller sends data to the control (delegate)

Code block Storage Path

~/library/developer/xcode/userdata/codesnippets

Replace the contents of the folder with a new computer.

iOS Learning Note (2)

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.