Shangxuetang ios primary video material sharing
"Shangxuetang ios Elementary Video Tutorial" is Shangxuetang's complete set of video tutorials on Objective-C language from basic introduction to advanced proficiency. Objective-C is an essential language for iOS development. The course will provide in-depth coverage of Objective-C language. Detailed explanation, mainly explaining the basic syntax of Objective-C, object-oriented programming ideas, encapsulation (declaration and implementation of classes, getter and setter methods, properties), memory management, inheritance, polymorphism, classification, protocol, block, NSNumber, characters String, array, dictionary, date, file management, copy, etc.
Video playback address: http://www.php.cn/course/572.html
In the process of developing IOS Difficulties in:
1. In swift language? and! Question
I checked a lot of helpful webpages on the Internet, but they all had different opinions and I was confused. Fortunately, one webpage made it a little clearer.
To add my personal understanding, the swift language looks simple and elegant, but in fact it contains many mysteries. Why use it? and! , the purpose is to make the code clearer and provide the compiler with more clues to find more potential errors. It is a language released by Apple, which is in line with Apple's character. It requires you to clarify things before writing code, rather than leaving vague questions to the compiler to make decisions.
2. The logic of table view
Since the iOS system is not open source, if we want to implement the table function, we must install the predetermined routines of the system. There are several key points. The first one is its two agents, one of which is responsible for providing data. The so-called providing data is the two most important interface functions. The first one tells the system how many rows there are in the table, and the second one is responsible for providing data. It just tells the system what the data in each row is. The second one will be called multiple times. Suppose there are 10 rows in a page, then this interface function will be called 10 times. But not more than one page, because the system will only request data for the page currently seen by the user. If there are 100 pieces of data in the table, then it is implemented by discarding the old data and filling in the new data during the continuous scrolling process.
This is a proxy for the view, and the other proxy is for the controller, which is what the program does when the user clicks on an item in the table. The most commonly used one here is the didSelected interface function. Developers only need to write their own implementation code here. Be careful not to write into didDeselected. The function names here are easy to confuse. Deselected is the interface called when an item changes from selected to unselected. When I first wrote this, I always felt like something was wrong, but I found out later.
When using the customer type prototype, how to access the label object inside? The use of tags.
Common table examples, the cells in the table only have a maximum of 2 labels, but I need to put 5 labels in my project, so how do I operate these labels in the code? Since the interface is pulled in IB, the labels in the cell cannot be pulled into the code through ctrl drag. Later, I saw an example of setting a tag value for each label, and then using viewByTag
UILabel *name = [cell viewWithTag:TAG_NAME]; UILabel *singer = [cell viewWithTag:TAG_SINGER]; UILabel *code = [cell viewWithTag:TAG_CODE]; UILabel *lang = [cell viewWithTag:TAG_LANG]; UILabel *type = [cell viewWithTag:TAG_TYPE];
in the code to get the corresponding label.
Later I learned by chance that it can still be accessed directly, but it is more troublesome. It is to define the cell with a class first, and then manually create the label statement in the interface. At this time, You can pull the wire from the storyboard to the table view.
This issue is discussed on this page.
Improper configuration of the table can easily cause the app to crash, and you will often see:
Crash in this place: AppDelegate: UIResponder, UIApplicationDelegate
The information displayed by debug is :
*** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[UINavigationItem tableView:numberOfRowsInSection:]: unrecognized selector sent to instance 0x7fd9d1760d70'
The reason is actually that I saw in the storyboard that the data source of the table view was not associated, so I associated the data to the table myself. Many times this kind of crash means that the associated datasource is incorrect, so you can try disconnecting it first. According to my understanding, because this bottom layer cannot be seen, I can only guess that it is associated with this one and releases the other one. As a result, the useful object cannot be found, causing the system to crash. This is why many experienced players don't like to use storyboard, because it is difficult to control and some hidden things are difficult to discover. Although it is a little more troublesome to use code to implement the interface structure, it is better than knowing enough that it will be how it is written. At this stage, I still have to rely on graphics tools. One of the disadvantages of graphics is that the storyboards of the two projects are not comparable. There were some examples where I followed the tutorial step by step, but something went wrong. But the download teacher did a good job. The project is normal, and there is no difference when comparing the codes. The difference is in the storyboard. However, the differences in the storyboard are so big that there is no clue at all. Moreover, directly overwriting the other party's files with your own is full of errors.
In general, my skills are not deep enough. In the future, we need to lay a solid foundation in depth.
3. The logic of search bar
In the past, objects such as search bar and search display were separated. Later, Apple provided an integrated solution and also integrated search The algorithms are also encapsulated into objects, which is expected to simplify the work of developers. But for developers like me, it's just the opposite. On the contrary, the simplest search bar is more suitable for me, because I only need to run a search when the content of the search bar changes, and then refresh the table once. And if you call those bundled display controllers, you need to implement more protocols, and you also need to provide a table view controller that outputs the result display, which really makes me dizzy. Apple's official information also provides an implementation example, but this example itself is very complicated and involves multiple view controllers.
The method provided on this page is more suitable for me.
This is an official example. It is an approach led by Apple. They have eliminated the old approach and now recommend the use of ui search controller. However, it is not clear what the background reason for this change is? It doesn’t feel that useful.
4. Use IB to make the interface or implement it in code?
Using code to set the size of the control may cause problems when adapting to different screens. We have not yet studied how to do the auto resize part.
But using code to create an interface is not as difficult as imagined. In fact, you only need to treat the controls in the interface as objects. Create the object, set the object's familiarity, add the object to the view, and set Set the relevant delegate, and then it's OK.
The course teacher Guo Chongzhi is young and promising, and is more in line with the tastes of young people. His lectures are relatively relaxed and natural, making us feel relaxed and more able to listen.
The above is the detailed content of Shangxuetang ios primary video material sharing. For more information, please follow other related articles on the PHP Chinese website!

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics



Quark Netdisk and Baidu Netdisk are very convenient storage tools. Many users are asking whether these two softwares are interoperable? How to share Quark Netdisk to Baidu Netdisk? Let this site introduce to users in detail how to save Quark network disk files to Baidu network disk. How to save files from Quark Network Disk to Baidu Network Disk Method 1. If you want to know how to transfer files from Quark Network Disk to Baidu Network Disk, first download the files that need to be saved on Quark Network Disk, and then open the Baidu Network Disk client. , select the folder where the compressed file is to be saved, and double-click to open the folder. 2. After opening the folder, click "Upload" in the upper left corner of the window. 3. Find the compressed file that needs to be uploaded on your computer and click to select it.

1. First, we enter NetEase Cloud Music, and then click on the software homepage interface to enter the song playback interface. 2. Then in the song playback interface, find the sharing function button in the upper right corner, as shown in the red box in the figure below, click to select the sharing channel; in the sharing channel, click the "Share to" option at the bottom, and then select the first "WeChat Moments" allows you to share content to WeChat Moments.

Recently, Baidu Netdisk Android client has ushered in a new version 8.0.0. This version not only brings many changes, but also adds many practical functions. Among them, the most eye-catching is the enhancement of the folder sharing function. Now, users can easily invite friends to join and share important files in work and life, achieving more convenient collaboration and sharing. So how do you share the files you need to share with your friends? Below, the editor of this site will give you a detailed introduction. I hope it can help you! 1) Open Baidu Cloud APP, first click to select the relevant folder on the homepage, and then click the [...] icon in the upper right corner of the interface; (as shown below) 2) Then click [+] in the "Shared Members" column 】, and finally check all

Do you have the latest activation key for win7 enterprise edition? If you install the official win7 enterprise version, you will be prompted to activate it with the windows7 enterprise product key, otherwise it will not work properly. So the editor will share with you some win7 enterprise version activation passwords, let's take a look. Q3VMJ-TMJ3M-99RF9-CVPJ3-Q7VF3KGMPT-GQ6XF-DM3VM-HW6PR-DX9G8MT39G-9HYXX-J3V3Q-RPXJB-RQ6D79JBBV-7Q7P7-CTDB7-KYBKG-X8HHCP72QK-2Y3B8-YDHDV-29DQB-QKWWM6 JQ

Mango TV has various types of movies, TV series, variety shows and other resources, and users can freely choose to watch them. Mango TV members can not only watch all VIP dramas, but also set the highest definition picture quality to help users watch dramas happily. Below, the editor will bring you some free Mango TV membership accounts for users to use, hurry up and take a look Take a look. Mango TV latest member account free sharing 2023: Note: These are the latest member accounts collected, you can log in directly and use them, do not change the password at will. Account number: 13842025699 Password: qds373 Account number: 15804882888 Password: evr6982 Account number: 13330925667 Password: jgqae Account number: 1703

Title: To solve the problem that Discuz WeChat shares cannot be displayed, specific code examples are needed. With the development of the mobile Internet, WeChat has become an indispensable part of people's daily lives. In website development, in order to improve user experience and expand website exposure, many websites will integrate WeChat sharing functions, allowing users to easily share website content to Moments or WeChat groups. However, sometimes when using open source forum systems such as Discuz, you will encounter the problem that WeChat shares cannot be displayed, which brings certain difficulties to the user experience.

How to share wifi hotspot in win7 system? After our computer is connected to the network, it can also share the wireless network. Many users want to share their computer's network to their mobile phones for use. Many friends don’t know how to operate in detail. The editor below has compiled the steps on how to share wifi hotspots in win7 system. If you are interested, follow the editor and read on! Steps on how to share wifi hotspot in win7 system 1. In order to turn on wifi hotspot, you must first have a wireless network card. The laptop comes with it. If you have a PC, you can buy a portable wifi to share wifi, which will not be described here. First press the windows key on the keyboard to open the start menu

HP printers are essential printing equipment in many offices. Installing the printer driver on the computer can perfectly solve problems such as the printer being unable to connect. So how to install HP printer driver? The editor below will introduce you to two HP printer driver installation methods. The first method: download the driver from the official website 1. Search the HP China official website in the search engine, and in the support column, select [Software and Drivers]. 2. Select the [Printer] category, enter your printer model in the search box, and click [Submit] to find your printer driver. 3. Select the corresponding printer according to your computer system. For win10, select the driver for win10 system. 4. After downloading successfully, find it in the folder
