Mastering UITableViews with Swift 4 and iOS 11 | DevTechie Interactive | Skillshare

Mastering UITableViews with Swift 4 and iOS 11

DevTechie Interactive, Learn new everyday

Mastering UITableViews with Swift 4 and iOS 11

DevTechie Interactive, Learn new everyday

Play Speed
  • 0.5x
  • 1x (Normal)
  • 1.25x
  • 1.5x
  • 2x
18 Lessons (3h 18m)
    • 1. Quick look at the course

    • 2. Introduction to TableViews

    • 3. TableView using Storyboard

    • 4. TableView using programmatic approach

    • 5. TableView with Sections

    • 6. TableView with Delete Functionality

    • 7. TableView with Edit Functionality

    • 8. TableView with Insert Functionality

    • 9. TableView with custom cell

    • 10. Tableview with programmatic custom cell

    • 11. TableView: Self sizing cells

    • 12. Static TableView for Settings or Form layout

    • 13. TableView with Search Functionality

    • 14. Advanced TableView: multiple swipe buttons

    • 15. Advanced TableView: Expand Collapse functionality

    • 16. Advanced TableView: Refresh Control

    • 17. Advanced TableView: Floating Button

    • 18. Advanced TableView: Empty table message

  • --
  • Beginner level
  • Intermediate level
  • Advanced level
  • All levels
  • Beg/Int level
  • Int/Adv level

Community Generated

The level is determined by a majority opinion of students who have reviewed this class. The teacher's recommendation is shown until at least 5 student responses are collected.





About This Class

What is UITableView?

Table views are among the most commonly used components of the UIKit framework and are an integral part of the user experience on the iOS platform. Table views are used across the platform from Settings app to News app. Table views do one thing and they do it very well, presenting an ordered list of items. The UITableView class is a good place to start journey through the UIKit framework, because it combines several key concepts of Cocoa Touch and UIKit, including views, protocols, and reusability. 

What will I learn?

You will learn various techniques to present your content with table views along with learning some nifty techniques in iOS framework itself. In each lesson we will create new tableview from scratch to learn something new about the tableview design and its inner workings. I am constantly working to put together new content to show you various new techniques.

What do I need?

You need mac and xcode 9.x or later to be installed in order to follow along. Basic knowledge of Swift and XCode will come handy. 

Meet Your Teacher

Teacher Profile Image

DevTechie Interactive

Learn new everyday


Class Ratings

Expectations Met?
  • Exceeded!
  • Yes
  • Somewhat
  • Not really
Reviews Archive

In October 2018, we updated our review system to improve the way we collect feedback. Below are the reviews written before that update.

Your creative journey starts here.

  • Unlimited access to every class
  • Supportive online creative community
  • Learn offline with Skillshare’s app

Why Join Skillshare?

Take award-winning Skillshare Original Classes

Each class has short lessons, hands-on projects

Your membership supports Skillshare teachers

Learn From Anywhere

Take classes on the go with the Skillshare app. Stream or download to watch on the plane, the subway, or wherever you learn best.



1. Quick look at the course: Hello, everyone. My name is Anoop. And today I'm very excited. Teoh present to you this a new Siri, this video series that I have created on details Uh uh, every single detail that you can think of about you. I love you. So we're gonna go through a journey creating ah, whole bunch of APS and, uh, learn about creating heartily agrees from basic to programmatic somebody sections with editing options and custom to use. And, uh, some of the things that we're gonna be doing is like, advanced Thinks like, basically providing a search where you can search your item in intellect and you'll be learning all these with this course eso, uh, covered in and subscribe and enrolled into the course. And if you if you feel that it doesn't work in 30 days, money back guarantee is always there. So, yeah, I hope you enjoy the video series. Uh, and, uh, you in the classroom. Thank you. 2. Introduction to TableViews: Hello and welcome to this new video series of mastering you I would use you guys might already know that their reviews are used throughout. I was work and there are several examples of that he can see in your day to day APS like your contacts, APP uses table views to show you all the contacts. And it has the search functionality as a list like, you know, the indexed table. And, uh, SL is your seven speech and a Z you can see, like, you know, this is another example off there, will you? But this has sections involved, and, uh, then you have your filtered results. So this is what we'll be creating. So we'll be creating a table view, search and affection, table view and various other examples. Now what our table views so terrible views on display list off items that can be scrolled up in town. So it's part off school view One of the subclass off school, are you? I scold you and it can be scrolled vertical direction on Lee. Now, if you're looking for multi direction either vertical or horizontal, then that is Ah, your collection of you. And that's the topic off like hold another series that we can actually begin talk like in details about. But this particular issues is about, do I table? So we're only gonna be seeing you radical views and various different ways to create. Are you writing now? Table of youth contains cells. Uh, that can be off for standard types or they can be customized based on the need of the app. And that's another thing that that fear we're gonna be looking at. So you're gonna be using one of these tender type out quite a lot. And then we're going to customize our regular create our own customized sale, and we're gonna look at different ways of formatting it along with out only how it so for a temple used to work, how it will have to conform to miracles. It's a u I t. Move you Tillerson's and, uh, you I table you delegate. Okay, so these two particles are provided in functionalities that you, as a developer, needs to needs to build in our to make they will work and in display of data. So let's get started. And, uh, in the next video, we'll create a very simple review and and see it in action. Thanks. And see you guys in next kill 3. TableView using Storyboard: Hello and welcome back. So today, uh, we're gonna start looking into, uh, basically creating a very simple there will be application. And in future videos, are we gonna expand upon basically doing more stuff with it? And to get started in a state, we're gonna create a very basic table view using the third board in the next tutorial allowed to show you how to create are the same two of you how? With the programmatic approach. All right, so let's first got just a plane app open. I just created. This happened. There is nothing that have added into it. So literally, like, find new and single view up. That's what it is. So before we actually get into according, let me drag and drop some of the images and confined, these images basically provided, along with the resource is So let me track these four folders and what his photos contained are basically some images in these air images for a different kind of fruits s. So we're going to be creating a fruits happy basically showing the list of fruits and there benefits and stuff. There are two sets off projects, so there's a fruit and There's a small food image and the Reggie's and a small already Brady's images. So So basically, all these images are re scaled 200 by 100. Um, and these air full size images for future videos. When we get to custom our cells and custom roads, we can actually use thes images to show details about the fruit. All right, so they have that less. First, let's create to up our helper matters, uh, to help glass. It's gonna help us basically, in this in this set up. So we're gonna call our 1st 1 food, okay? And this is gonna be a simple model Class settle. Let me try. Get down here. Okay. Hey, this is going to you like it. And class name is food, All right? And food is gonna have three properties so we can have our title off strain type, and then we have we'll have subtitles. That's gonna be strength type. It's all I'm not real happy. I mean, this is kind of beat image off the food, okay? And we can have a minute method. Um, and this in your method is going on, except title subtitle and, uh, right should So I signed self dot Title Golden State Self Subtitle Ethical Do Subtitle yourself dot image is he going to do? All right, so that is our first model glass. Now let's greet a class which is gonna help us out creating, Ah, a sample data. Basically. So it's gonna be our data sourced. That's what you use. And you call this fruits and Beattie's all right. Just kind of be again. You like it, class. Oops. Hey. All right, so, uh, this glass is gonna have to property. There's gonna be name to create our names, right? Strain and food item and food item is going to be off type food. Okay. And we're gonna have another in it. Better gonna accept. Name. Strange. Yeah. Food item temps. Um, I should paralyzed. Dishonest comes and this is going to be fought that become basically, it's a collection off food that's being passed to us. Yeah, the initial Isar on we're gonna say self dot name is equal to name. It's health dot Food items headed called food items. Thanks. So now we are going to create two off the static functions that are gonna return basically a set off fruits in a set off Reggie's. Okay, So I will actually create static function, and they call it fruit sect. Okay, fruits in, ladies, um, hands, It's gonna be another one. Static clunk. He's This is going to be your fruits that go. All right, So now let's create of able for our fruit items. It's gonna be in a raid off food, and yes. Hey, fruit tone, that append of okay, food. It's going to be It's any wiser. So any use, um apple? That's the first item. Win a copy. Some text. It's something about apple and Happel smell image that's been select. Okay, copy this. Pasted over and second food item is going to be apricot. Okay. Yeah. And going base, um, properties for epic art go places with apricot. Okay. Uh, and yes, copy. Excited. It's going the very have it. So basically what? We are doing it creating a collection off different food items, and we're creating our data. So is there a few watching me type of this stuff? What I've done is created these. How so? Let me based in rest of these. Okay, So these are all the other foot's out. I have a very fake, um, in our speech. Okay. Now, what we can do is we can create our turn type. We can return our fruit ready so we can say fruits is going to be a name, and this is set off. Oops. And, uh, fruits from Titan is our food. I okay, naturally. Are we gonna do the same thing for are ready guidance. So you copy and paste that and Okay, so we have personalities, treaties and radio. Okay. Now Oh, I mean, we can have these to set. I'll return to data, but for some, for examples of he also gonna need the both of these so you can create another method. Call static funk food items. Okay. And it is going to return. Um, basically, and ray off fruits and readies. Go. I'm going to return. Simply return an array that's going to call, um, fruits and ready dot Fruit items. Fruit set fruits and veggies dot How weighty set. All right, so, uh, that, uh, completes our data model, so let me drag it down here. So now we're ready for our pfosten Before we get to that, Let me do some clean up. So let me move and create a new folder. Create a new group without Porter, and this group is gonna called and it's going to be called helpers. You animal, These guys inside that helper, also these. Yeah, and that makes it a little bit queen. Gonna move this down here, okay? And create a new I hope gold is basic. They will be strong for, because you're gonna create a table using this story in part of this. All right, so let's elect or mean, that storyboard, he let's search table, but outside it, it will be done on the scene and then just start some constraints. So what we need to do is you need to have the steel of you getting hold covering the whole screen. Gonna say zero cross. All right, You know what we have done that how to do one more thing is how we should embed this into a navigation control. So select editor and, uh, go to embed in navigation controller. Go. Can we have that? And this is the several points that this is our initial screen. Okay, So must we have the navigation controller? Just keep this your title. How this mu controller title. This is going basic table. You story. Okay, So what you have done that less drag a sell out until you sell is basically the item that's going to be repeating over and over. Okay. And, um, if you look at the property window, you're gonna find that there are several different styles of representing the sale. So we have We have custom that we're gonna come back later on to do something custom that. But there's, um, revealed types like basic, uh, right details. So you have a detailed Aiken title? Um, then you have left detail in a table. Now, if you notice some things have this image are popping up basically right underneath when we select the style. And the reason is some of these styles, although they don't show. But they have on image view, so you can actually leverage that image to show our food item images. That's also let's, uh, let's create some Lester some properties and then create a properly, this of you. So the identifier, it's actually over a tow. Identify a cell. So we're gonna, uh, define it as identified. SL. And basically, this is something that Apple uses for any recommends for performance reasons because when you see a table view, it may contain hundreds off rose, and those 100 sufferers are not visible at the same time at max at same that at one point of moment you can only see then, uh, cells or are more than that, or less than that depending upon the sides of yourself. But you don't see all hundreds off thousands off like you know ourselves that that are there within the within the two of you. But you can actually always scroll up and down to see more content. Now, that's where this whole idea off reasonable cells coming where you can have a cell identify and Viniar Cell goes off the screen. It's actually recycled stuff. Initializing and you sell your old cell that's no longer visible is going to get really shy reassigned and gonna get edited. The bottom. Okay, so So it's it's a performance technique. Eso uh what all this recommended start aggregating NFL. You reuse that cell in Apple has made it super easy to do it, so we can actually look at how we can do that. Okay, so we have selected a subtitle type. And, uh, now what? We're going to do it. We are going to go in. Her people told her he lets clean up a little bit, but more days, and I'm gonna move this, Okay? So lets us create on ivy Applet. So select storyboard. Go to the assistant Edger drive or take control. Dag, drag control dragged over to your view controller and name it. They will table like that. Okay. And, uh, once you have done that, we can close this. Go back to the controller, and now we are going to start going something related to that. They will you to make it show the list of food items. Okay, the first thing we need to do is they will view has a contact off, providing basically creating a notion off delegations. So basically, they will be the two of you when it says, like, um, the view controller who was implementing it has the responsibility to become a data source delegates. So basically, the view control is going to be responsible for providing the data as well as I can become a delegate, which means some of the functionality is like, you know, or rose styling or selection and stuff. The controller takes the responsible responsibility for that. So So what we can do is we can say our table view is our pterosaurs itself. I will be dot delegate. It's self okay. Once we do that in compile the state terror their air says cannot time you controller to the type to the type you like. It will be And, uh, you toast. And the 2nd 1 it says cannot find control to you. Tree it. And the reason is saying that because we have not conformed to the ready with data source in your delegate. So let's do that so we can actually use extensions. Hard to do that. I have a gift too. Make it a little but clean coding style. So you I and why? Data source. Okay. All right. So now if you have that, we're gonna see another. The air states now that have you Comptroller does not conform to the protocol. You give your data, so we actually need to implement some of the methods that are required by that. You like utensils. So the first method is a number off the rose in section. So how many rows are there for the section. You come back to that point and the other one is self for row at index path. Okay, so number of floors in section basically this particular method asks, or or or controller actually provides the number off items on that. Begin the show in the table view. Uh, now, the old items that you feel view is gonna hope. And the 2nd 1 it self or red and expats. So this is basically one particular cell within that set. Okay, so we'll see. I can be will be more clear. 13 called it up. But before we called it out, let's create a variable where we can bring all the daytime to be gonna create. They called data, and this is gonna be a food type. It's gonna be an empty or initialization and band. We can say for item fruits and veggies start food items. Um, we're gonna penned everything that we get into the date. Okay, So, like him dot So that will create. So So if you remember, person readies had two different sets. Their fruits and vegetables. Now, what we're doing is we're basically creating a flattery instead of like having two different categories, we're gonna dump all those food items into one single away the girls. Just a simple implementation. We are not dealing with any segregation off types and stuff. Um, that's why you're doing it. But in later videos, you're going to see how really utilize those two different categories. OK, so once we have our our food item available, our data is available. Begin here for the for the number of rules in section we can say return data don't count and eso total number off items in the data. That's what it's gonna be the number of rules that we're gonna show and for seven forgo at in expats how we can say we will create a sell himself and, uh, they will view dot Did you? So this is the the item that is the line that all stalking old that apple makes it easy for you to reuse. Ah, cell basically what? This is it. This ensures that your app does not go out of the memory and you're not assigning extra memory for creating like thousands off cells that you're not showing. And every time if you're just showing then there's only gonna be memory for 10 cells. There's gonna be assigned. So that's the reason why we actually used Dick. Use reusable cell. Okay. And this identify is the identified that we set for the cells. So face if he's elected, sell things guy right here is how it knows that makes cell prototype beginning youth. Okay, once he had done that, begins a sale dot um, text label, that text. And either these are existing property. Because we have selected the type already in the storyboard. He can say our data index bath. Doc Rowe. So, basically, whatever is the current the role that you're looking at, right? That, uh, type. Okay, so that's gonna be a text detail text is going to be data index bath dot Who? Oh, don't subtitle sell thought image you dot commit his equal data index. Oh, starting makes okay. And we can return that cell. All right, so this about it, So let's select, uh, simulator and launch are apt. And c you pick works. Let's give it a moment. All right? So think like oh, okay. It took a little while to load. OK, so and you can see we have her image and name and subtitle showing up already nicely size a bit. Okay. So you can scroll. He's basically see all the arthritis. Hi. One optimization that I would actually else thinking to do is start off calling this this guy right here. You can call it item and say, like that, accepting all days because they item dot good has built and run to make sure everything is working Weight should be all right. So still still working. So that is the rap for are very basic overview. And in the next video, how are we going to see how we can create the same experience using programmatic approach? All right. Thanks again for watching and see us in next video. 4. TableView using programmatic approach: Hello and welcome back on. And in this video, we're going to be looking at creating date Will be using programmatic approach. All right, so let's get started. I'm going to create a new group. He's gonna name this as programmatic. Okay. Hey, entire gonna create a new file, basically in this table you control. So basically, what we're gonna be doing in this video is gonna be creating, um, a table view entirely in code. So we're gonna be according everything up to create our article. Okay, so let's get clean up we're doing Let's get that done. Okay, Once you have done that, you're gonna say you're I you controller basically needs to inherit from your controller. And and now we just need Teoh create our deal of you so we can say lady, you are Table. Were you I and we're gonna legally initialized this. Say that we that we go to you, okay? And we got there. So see, if you called yourself just like for you dot data dedicate. Can you call yourself dot translate? Frustrating is equal to false. So what this property does is basically it says that I have out of lay out in the world, so I don't want you ex corde in the IOS engine, dio used auto sizing mask and translated into into constraints. So what we're gonna be doing, basically, is where you're gonna be programmatically creating these constraints. Okay, So utterly up. This buggery citing mask, used to be the technique to create re sizable of use before utterly out came into the picture. But now we use constrains, and they ought to do the same thing. So any of you you create basically programmatically you just make sure you always marked this as false. Otherwise, you you're going to see ah whole bunch off constrain issues in your council when you create and they're not gonna look right. And it's a moving on a hobby in or jester in you sell, you say you will, so dot self So that's gonna be the cell. And it's reels identified. It's going to be called sale and within a return. Okay, Now let's create our extinction to conform. But you, why won't you delegate? No, I so so particles once we have plenty of time that we're going to see another air but to be gonna address that in a minute. That's for schooling. It a data, just like before type food. They were gonna slide that bread and empty. All right. OK, Now, um, we need to do his in our you did load. Just like before, you know, trade over food stain. Hi, ladies. Food items and gonna offend those into the data. Okay, figure two, Adam. Not of items. Okay, now it's time to add this. They will be into the view into our main view and then to find some constraints. So we're gonna say self thought for you dot Add some and it's going to be a table that's gonna be in, uh, people say in its layout constraint that activate. So this is how we actually provide the constraints using constrain anchor approach. So you say, table view dot leading anchor. So, basically, the leading side after table you it's going to be constrained equal to self dot that few dot lead. Thank you. The reason we're we're doing that because we won't actually make this day will be covered. The whole screen is a table of you dot are trailing constraint turning anchor. It start constraining is equal to So you dot Trailing banker. Okay. Same thing for Top Green. Same thing for the bottom. All right? Eso that actually going to cover our whole squeeze. Now let's go and provide some rights unless makes an extra space in methods that better are going to be are conforming to the terrace source Require methods. I mean, you like they will be your data source protocol. So number off rose in Texas, and we're gonna say return data thought count. So basically deserve the don't remember for us that we're gonna show and settled for grow at and expect. And this is going to be last cell that is going to be represented by the current item So they will dot de que So with that, enter fire. And this is going to be cell the same identify that we used here. So we're saying that the cell or I forget which in turn, this okay. And so dot textually walked a text. Haiti to data. All right, So Babel called Hatem. Yes. A data in Texas passed out, bro item dot Thanks. You made you makes going to talk. Intel fell. So, uh, detail Texas cold to fight something for that now one thing that you're going to notice and I want actually pointed out before you see it is this line right here showing the subtitle is not going to appear at the reason it's how because biting fold you want to move you when you create using problematic approach takes a very basic a very basic cell and just rendered stat. So you only see image and, uh, the the type Now and later videos. We're going to see how to create a custom self and basically through whatever you want to throw within that cell. But that's the That's the current interpretation. So let me show you by running it what I'm talking about, okay, He and you are Okay, so I forgot one more thing that we need to do. Basically, we need to come and first thing we need to do with me, actually, raise that mean so that is not our main entry point. And because they removed I mean it. We need to provide the entry point. So do this by defining which you are you controller are application is gonna launch from so gonna say window about you. I window, um, frame you ice cream dot main dot bounce. So basically, what happens is the reason we're doing all this. Because when we had to find a storyboard, the X code and the compatibles taking care off, creating a window and assigning a good view on everything. Now, since we have taken that out and we have taken the programmatic a boat, um, we are going to create all these things men. So we're gonna save window dot Lutfi controller is equals to Celeste. That's create a navigation controller. Because you want to wrap that the state will be into a navigation controller, and I'll show you what I'm guessing. Looks like. Um, so you can create a knave controller, do I? Navigation controller and empty Knapp control. Thought through you how, actually connects signed and weaken our route. We control is going to be programmatic. People told her. Okay. And our window doubt from you is going to be the left. Now all of you to do is window dark, make key invisible. This is how it's gonna basically show up as the main screen. Hey, uh, this one. So if you uh Yeah. Okay. So if you see how we have basic. But the thing is, we have created the whole thing. Youth in programmatic approach. Now what is the navigation control or so basically navigation controller is this navigation bar? It's a way to for your all your views to basically and bear inside. And I want improvised basically provides basic from shall be like, ah, way to like, you know, if you have multiple re controls, let's say you had a situation where you would select this row and it would go into a Dedham you control. Now you're gonna get back. You want to get back to it. Either you can create your own back button, our navigation controlled or takes care off You basically uh huh I'll bring your user back to the main screen. So that's that's what it does. Has like, you know, several other properties. And I guess I will create one of the short tutorial basically just around, of course, just around how you can basically create your own custom navigation interrogation controller and customize it. But yet that's actually a really basic. But if you want to check out more, look for a U. Y. Navigation controller documentation, and you should be able to find words about it. Okay. All right. So one thing they're missing, you are missing a title. So let's go and are problematic of you, controller. And add a title so we can say self title is equal to pro. Maddie. All right, so that we have the, uh, how problematic Way off Creating, uh, creating a table that they will draw. Okay, So from this video forward, how we gonna be using storyboard just to understand a little bit more? But, um, when we get to the point where we are actually creating a custom controller cuts himself at that time, we will be looking at again, looking at both approaches, creating that they were you, uh, custom cell using programmatic way and using a storyboard way. All right. So hope you guys enjoyed to sell, did you? And see you guys in, uh, next video. Thank you. 5. TableView with Sections: Hello and welcome back. And today how we are going to be continuing our journey for reviews. In this video, we will be creating a table views with sections. OK, so less creating a cook called this, they will be you with affections. He had, uh, create any file, and it's gonna be a storyboard pile. You gonna call table you with infections and, uh, create Abe, you controller. So And just to make sure this is gonna be you live you controller, not you, Control. Okay, We're gonna all this. They will be with section controller. Okay, lets go. Get next and, uh, create. Okay, now. Or you could be doing basically lets us to work on the story board and create our storyboard. So we are going to be dragging a Equador, and, uh, we're gonna be assigning missed class, too. They will, but section people okay? And let's go to the editor and in practice, do navigation controller like so. All right. And let's make this navigation control on its initial or a starting point. Uh, Ellis had this title to this, and Okay. All right. So what's he have done? That less track that they will be We could sing, okay to find this constraints game gonna be covering the whole screen. And, uh, that's dragger. So and select subtitle and a usable we use that enterprise is going to be self All right. Okay, so what were we doing? Basically, it's Regan will be creating. We're gonna be creating sections up data. So as you recall from our model class, we have do. That's a food. We have fruits and we have vegetables. Now, up until now, we were dumping everything into one single ray and showing it Now, in this one, we are going to be dividing them into their own groups. Now India will view Their do is you can do it. And those two approaches are basically okay. Select your meal can see style. The styles are there is a plane style and there is a good style, so essentially both of them work very similar. The only difference is the group style has the headers basically flowing with the school. So basically, they don't stick at the top, but with the plain style, the headers, When you define they actually stick at the top until the next sections next section cuts along. Okay, So I'll show you how the Sticky Header works. They had, uh, and yeah, and we'll see the difference. Basically. Okay, so once they have that, they will be set up. Let's go ahead. Create and outlets. I'm gonna show you a different approach of creating an outlet at this time test of aviation . So what you can do, you can always create, and I open it from the cold how we are. They will view and off type you I table and what you have done that you can go back to use for drag from the storyboard from your controller. Do your deal, correct. And u N C to up its one out. Let it stay with you. Another one is Okay, so you select the people you want that now, while we're here, let's see another approach of defining debut. They resolved and delegate. So if you drag from your table view to your people, tore Okay. You're gonna see different options this time. And these are Davis sores in delegates. So you can select Davis, and, uh, then you can gold right? One more time. You can select. Okay, Safe. You control drag. One more time, you're going to see both of them are selected. Okay, Now we have bound our table view their souls try to compile. Sure. Ok, okay. So now we can define the extension extension to this class Basically saying you are they will be delegate, and you are, and a source. Okay, Now we need to provide some methods. So before we actually provide, uh, the, uh, that before provide the matters number off Rose and, uh, and sell our creator Our data cost. Let's create our very well cold data. And this time it's going to be an array of fruits and veggies. Okay, In an theory, he, uh, itself don't data is equal to you. Fruits and veggies dot because they returns to thing. Okay, Now, if we had, if we had done justice, right? And, like, you know, try to show basically the count. Um, because we're dealing with sections this time. We also need to define their sections. So number of sections, how many sections are show? So now let's first defined sections. So there is a method called number off sections. It's a table view. It's a summit. Erred hand actually returns to your time and what we can say, it's getting in return data. Stop that data that count. And because we know that our food item contains two sections basically two types, two categories fruits and vegetables it's basically gonna return that count as too big unless we're going to see two sections. OK, now, like usual, we're gonna create number off roads in section and, um, create some space. Okay, here, I would be doing it. Basically, it's a returning. They did not count. You'll be saying self start data and the beauty is another property off and expat. How? Which is called section uh in expats. Oh, honey, it actually has a section. So he's a section. It's not indexed. It's a section dot com dot food items. Basically that So we are saying that a number off roles within that section and we're gonna return that count. So when Section zero is going to arrive, how are we going to return the number off fruits we have? And then in section one arrives, begin a return number off the vegetables that we have Pain are data. OK. Now, um, sell for ruit next path in this case, huh? This is gonna be slightly different as well on and we're gonna create, as you usually would create a cell. They will. You that. Thank you. Sell. That's reusable. So and that's gonna be so okay. And, uh, you don't say it. I don't think ese cold to data index that dot section So this gets the section that we are in currently and because they sound dot text labeled out text is equal to I didn't section dot And we cannot have Teoh go down to that particular item that we're looking at, uh, dot type Okay. So we can actually create and I don't Okay. Here, move This guy here. This way. We just have I sell doubt, detailed that text, basically do It's up total and sell. Don't they reads You doctor did people too. I thanks and in return. Okay, so let's run this and before we're actually really do change. The main interface says we're more get last time this time people like how do you view with section story work? And that's gonna be the starting point. Spending run. Okay, So as you can see, it's actually called him the programmatic Table Control or pickle to be forgot to comment. Disco Doubt from our absolute fidgets taking the priority relaunch. So this is our cable sexually. But if you notice there is no section I mean, everything is showing the way it waas Um, What happened? I hope Heather turned up. There's an extra information that we need to provide in that if a title for header in section and until we provide that, it's not gonna show us the title so less, um, let's take Let's take a look at what we need to return. So if you recall our food item now, let's go to person. Bodies of person rages as our able called name. That is a name that we can actually use, uh, for, uh, header section for the handle header title. So you can say data section It's Hillary provided I doubt name. There you go. Hey, what's the polite that you notice that we have our sections appear today? We go have fruits and we have visible We get. Now, I know you don't see like the stickiness that are starting or Celeste create. Um, let me something here for just for demo purposes, I'm gonna actually copy all these and paste it here. Okay? And I'm gonna put basis Gonna rerun, I just to create more growth. And what? We have more cells visible. You're going to see me scrolling and again See, for two, uh, complex sticky here, Um, And if you scroll down like sticks but s and as we start weightings showing up, actually, it pushes it away and you have all the vegetables. Okay. All right. So let me actually fixed this, that you don't want to have duplicate items and we want make sure we have all the unique, both awesome. Okay, so that actually, uh, wraps are this video. And, uh, this is how you can create hearty reviews with different sections there. Now, let's say if you have, like, more categories, what you can do, you can create more categories within from some person videos, and and then, um, I had, like, you know, have like, more sections. How within your table. So I'm highly Oakland recommend you doing that, experimenting any more factions just to get a better understanding at it. Have it. All right. So that's it for this video, and I'll see you guys in next video 6. TableView with Delete Functionality: welcome back. And today we're gonna be going to start looking some advanced functionalities that they will view. Like after they were gonna be working with a delete. So adding a delete functionality and in one of the next video way are going to be creating in edit. Our functionality basically haven't added functionality. Where are we going? To see another variation after, um, and one after that, eyes going to be augmenting the anything style for the day will be. And that one we're gonna learn how to create how to insert a new role within a section off the day will be OK, so without further ready, let's get started. I'm gonna create a new group here. I'm gonna call this. Oh, well, uh, affection. Don't worry. And I'm gonna copy. So I can actually great story bored with the same name. So let's clean this time aboard, okay? Yes, right. Delete. I told her. All right, let's go ahead and use you. Are you controller? Uh, we're gonna go toe editor. Many option in band in intellect. Navigation controller. Now, let's make this navigation controller as our the show people traveler. Okay, let's set the property for this You control on the plus, Basically. All right, Thanks. Okay, Uh, we should give it a title. Eso So you will be that we go. Okay. All right. So let's, uh, crag that they will be you. Time said it's constrains and I would hardly a command. No, you know, doing this process over and over. I know we can actually augment on our previous worship, but reason I'm doing it over and over. So it gives you a good idea off. Like, you know, basically creating it becomes your second nature to create people. Um, Okay, So Cliff's dragon, they will be self reacted reusable went into fire and select the type to subtitle. All right, once you have done that, let's go ahead and good controller move old and three steps and then create a night are people, you white people. You okay? And then we're gonna go storyboard in a drag from a straightforward selecting and what you can do. Basically, it's sort of that you can also come Teoh this last connection, inspector a tab. And then you would see all the variables here so we can actually drag this guy drop it. That made you the same connection. So what's he had done? That we are going to win this one? Uh oh. I always like to have that data, sums and delegates explicitly defined just because it makes it easy for me. Teoh, remember that they have actually defined its controller as the delegates and the results. OK, uh, and we don't forget that. So looks eat something sweet. Annexation. I will say. We'll see. Okay. Do I think on the A toast, right? Tell me. Okay. No, what we need to do, Basically, I need to say that Oh, before we actually defined number of roles as creator data. So data cough type groups just like same as the last two girls step. So that data person ready? Start being create number of sections. Car data dot Come and, uh, you say, but off Bose in section number of frozen section. How? Data section. Don't. Would I Stop, Count? Yeah. Now it's time to create a cell. But so so for Roy to next path. Sell you beautiful. Sell. Sell. You say so. That next level data Next six. What items? Next Bath Pro So in this. But I he called this a night, so dot detail. Thanks. That's subtitled That cell he meets sniffs out. Okay, so that in the last thing, it's a type of Let's create Title four Heather and section return data section. No, that's right. I want to make sure we're on it. Make sure like we are showing that you correctly okay, by so for the section delete. Okay, so we're seeing the right one now for charity is when we swipe with that right? You could see nothing happens. But if the swipe left test functionality that we're building on the show delete button are gonna delete the entire Oh, okay. So in honor for us to do that, what we need to do is you need to basically create our override a new basically provide functionality for a new our method or in the Methodist called commit heavy things fell. Okay. And what we need to do is you need to say there editing style, yes dot Delete. Then are you going to say that the adeptly then then we know that we are actually in the elite editing style. We're trying to do it now when you're trying to delete as I mean there is a it's a booster process. First you want to take care off your diesels, so say data index bath dot section dot food items remove at index path dot rule. So you remove that item that we actually doing a swipe gesture on and then you want reload that particular people you know, we can do this and, uh, running. I see it's actually gonna work, but there's it is a problem. I'll show you. Says you can see right to left and it shows that delete button and I can delete and that at the Rocca until you do cool fought in actually deletes it. Swipe it to the end. Delete. But it's actually very experts reason it's expensive because they're really loading the whole table. Well, when you are working with thousands and thousands off cells, that's actually not ideal to reload the whole table. So two of you were wiped a better approach for that. So it's four to provide. It's that elite rope Delete rose, and you can point the index paths for like Rose that you were gonna say, Do you want to delete the current index bat world and how we can actually anti animation. So if you notice the last implementation, it was rather disappearing, like all of us. But this is the least. Functionality is going to provide a nice and mission to that to meet operation. So I feel that Kate list really product. And, um, try to delete item for more time. And it's akin. Cities are actually collapsing. Uptight. You can, and you can try to lead us all. It's more and more from different sections, and this is a really functionality. All right, So I hope you guys enjoyed this video in the next video. We are going to be looking at another approach off the leading. So you're gonna keep just a little porch, and we're gonna create on editing style, Basically, which is which is another way off the leading multiple multiple walls. So yeah, so stained him. And I'll see you guys in the next video. Thanks for watching 7. TableView with Edit Functionality: Hello. And welcome back in town today, we are going to be looking at another approach for this delete functionality that we created last time. So this is our last app running and, uh, and you can see actually implemented delete spiked elite functionality. Okay, So what we're gonna be doing today, it's how we are going to be introducing editing, and that is going to be working as our foundation for the insert operation Assault. Okay, so let's create a new cook. We're gonna call this wind and it and basically they are going to be created. Okay, lets copy that queen. Storyboard. What? That. Have a go. And that's going to control her. Okay. All right. So but this one, I'm gonna do this same thing, but you do it real quick, so Okay, um, bad this navigation controller makeup Michel Qatar. Make sure that this actually set May people over. Okay, um because Prem's house, I find that so titled. Okay. For this one, I'm gonna actually copying something. That function says he has already know how to do all this stuff. We've been dissed company based station park simply copy and paste and then replace the extension methods. Yeah, and the last thing we need to do is you need to connect. Oh, yeah. Only to provide table it. Uh, All right, let's make sure build sand. Run. Yes, Quite panicked. And you will have to accept this, but let's see. Okay, so we know like Mr right on, because that title is not showing up, but just for completeness at the title here. Something a copy se but addict. Okay, What time? Correct. So we have our new we have this basic even tore it sections showing up our report, nor do basically is, you know, functionality there and be click a button somewhere here. The stable view interests into an edit mode, OK, and was the once we enter into the road, do several different things, like, you know, weaken. I had a new row into the under the table or weaken. Delete existing. Okay, so that was create that button. So, uh, so you are basically would be controller only already provides that functionality. All we need to do is we add that to the navigation controller so we can say navigation item Doubt. Right, Barbara night. And you can show to barbeque night time service. We have like right Barton in left Barber. So you didn't show either sites so reassuring White bar Burton Stein And we can say edit. But the night, um and what do that and run are up one more time You're gonna see a button China, and you click on this, but it just toggles between edit. And then now somehow we need to notify our rt will be that at the any button has been clicked. So we to enter into the and it mode into the editing room. And how was this done? We need to actually tell that to get out of, I think. OK, so that game is a very simple step. Hope need to do way. We need to override method called set editing. Okay, the first really called super tough set. Interesting. So we don't lose the from Sheltie that his bean set our or performed by the friend book, and then you want to our stuff. So you say if anything And say, I felt that table set anything to a true and you made it to anyway. And, uh, Els se South dock till you don't set testing faults Okay, Uh, so once once we have done that, are our table view is going to be basically entering that mode. But we need to We also have create this thing. Partiality. Bear Germany. Bennett, How in the delete button is pressed How re actually to leave the item and stuff. So let's go ahead and run. This has it. Let's see what it does. Okay, so we're going to click on the edit button and every conceit our table has actually entered in the morning. Yeah, well, this delete I can't showing up tragically conned any of Tito makes You can actually keep the leaving multiple items and all right, delete function that we built the last time is excellent. Working in. Once you're deleting all these roads, you click done and annexed. It goes back to Nana tip. Okay. All right. So that this was how sharp I want and what we're gonna be doing in the next video. Basically, when you click on the edit, gonna show an extra row here to insert you now inserting new rock can be Then these different rates you can have a button somewhere at the top are like, you know, floating button that when you press it adds a new rope. Are you can have a new an extra row or extra cell showing up within the section that can add a neuro into that section on? Are you gonna be doing just that approach because it teaches a bit more art of various different stuff to do with daily? It's so yeah, so stay tuned for that. And thanks again for watching this video you guys in the next video. 8. TableView with Insert Functionality: this is the new and welcome back. So what? Interested You know, what we're gonna be doing is how you gonna be looking at insert functionality. So this is, uh, like, another part that we're gonna extend edit functionalities to. So basically, if you remember from the last section, he created this edit functionality. When you are select edit, um, we show, uh, and re enter that they will be in this edit mode, and you can delete multiple items from that edit mode, and then you can click down what we want to do. Basically, in this one in this to drill is creating an extra row within the section. And when you tack on that road instead, off the leading, it's actually gonna add a new row. And that's how you can create insert items by affection. Partiality. All right, so without opportunity, let's get started. Just to give you guys a clean slate, I'm gonna actually create a new, uh, folder again. And, uh, they will be with insert your gonna call it can't up una Okay. Just very bored. And we're gonna create a re controller. Same name. All right. Let's create people door happy into a navigation. Make sure your TV show. Write the name. Hi. Tell you off screen title. So good, huh? In third. Now the copy The functionality from here. So when a copy all of this, hand out a copy of this. Okay? Copy this here. All right, I make a connection. Okay. Okay with you. All right. Now, select can start and lunch. Just make sure and everything is working properly. All right? So for functionality is intact. Now, lists get started with the edit. For one thing, we're gonna do it. They will be when he fault does not allow, um, a selection are during anything, but we wanna plow that for this toe work, all right? And the second thing we're gonna do, basically, is because this is an extra role. Um, we're gonna check if our table is in anything mode. And if it is then Beeville at that extra ourself account. So if anything true is equal to one fault, do you know? And we're gonna add that extra help into the number off rose and section. All right, Um, once we have done that, we're gonna modify our cell for Roy next path. I'm gonna create a condition saying index path. Dr. Row, If it's greater than a recall to our data index path, that section that food items are count. It's greater than that being said, basically greater than a record. So that means that the last cell and we are in editing mode, we're gonna do something. Otherwise, one with you are the whole operation. And what we want to do something is we don't actually say the title text is going to be ad that detail text. It's going. No. And, uh, he made it's going to be No. Okay, so if it's the last row, then we're gonna create add new. We're gonna, uh, like, you know, label it as add new item. Otherwise, we can now show the item itself. Okay. All right. So next is coming. Anything style How you know, changed here. So we have editing self delete now gonna add the editing style for, um insert. So anything fell? He called to that third, then? Oh, you do basically were created. Tell me food. Now they're safe. Your building of to do app or something. And you had a similar functionality. This is where you would ask you there to enter new daytime, you would added to your collection. But in our case for demo, we're going to create a dummy item. So saying new food and you near food description oranges select oranges for our image. We're gonna have this food into our collection section dot Put Adam start append new food. And what's our data cities updated? They're gonna let table. You know that I am. Actually, you're ready to insert throws at it expat in the index that if index path dot automatic animation. All right, so next thing we're gonna update the editing stuff. Okay? So anything style for when we are anything more years most here and we're in anything. Wrote what? We don't do it. Basically, we're gonna update at this new role into each section and because we're performing so many operations, like, you know, they're doing it at, like, on each section. We don't know how many sections they are. We want to batch are this operation together? So they will be provides a mechanic for just that call. Begin uptake in the counter parties and update when you're done updating and they will be is gonna badge all the operations together and update update the you I so far Heidi X and set and data got commemorated to be to give you an annual rate or the collection to get the index and item boat. And we'll create an expat with this information in next bath far Paro and the road is going to be set dot What? I can start count an idea X It's affection. All right, hands 1/4 5th and that we're gonna say two of you able u dot in third froze index that that Hi. Have you got to do the same thing for Mendieta getting out of the, um, out of the having stuff? But this time we're gonna delete um, Phil, basically removing that last line, add new items basically from the section because we don't want to show that in non editing mode. Right. So, uh, now one more thing that we need to do basically, uh, when you're looking at the petting more, this minus sign is Theo editing style. Now, when we add a new row, we don't want to save show this minus sign because it doesn't make sense. It should be something else, and they will be actually hence that for you, it's it's called anything, uh, style for roulette index path. And you're gonna say if the index bat dot a row is greater than equal to data index path dot section that would I don't not a count. If it's the last rule, basically, and is anything more that's true. In return, the style have insert. Otherwise, we returned mom as delete. Okay. All right, so now one more thing that we need to handle is, since we have allowed selection here during editing, we don't want to make that that selection happen. Basically, for any other role other than the last one. So you can actually handle that case. So you gonna say we'll select Rohit next back? We're gonna use this method, and we're gonna say if the index bath that row is greater than equal do again. Same condition, uh, in index bath dot section got food, items that count, and if anything, then we want to return. And next that otherwise I don't know. Okay. Now, uh, this is will select. So they've basically been user tries to select something other than the last rule, which is the Agnew item, then escort. Basically not. It's not going to select it Now we're gonna handle the selection part it bridges due to select. Go ahead and expats Hey, will say the same thing if Hey, give thing hand in, expat dot Ro, it's greater than equal to our data index pat dot section that food I don't stop count then , um you say they love you got de select on the index First runner, deflect the flow and then you wanna notify tell you that there is a new, um change and, uh, they could handle that in the change is off type insert for the all right. So for this and expat, how the I'd be missing brand. Um Okay, Yeah. So has an extra table view. Okay, so let's run the app that's your election, So Okay. Have you ever, uh you load it and click on edit? Hi. You can see we have a new heading you and look like Done. It disappears. So you're gonna click Add new and we're gonna keep heading the food. Anyone weekly Then those new items are there, but the last add new, but it's gone so you can do the same thing for your wait tables. And again, this can be something that's come, Tanika. We are from you. Simple depends upon what you do so and only functionality still works. Okay, so let's like them. And as you can see, our insert functionality to individual sex is it's a complete heart. So that's the boat for this video and to you guys in the next video. 9. TableView with custom cell: Hello and welcome back. So today we are going to be creating custom cell. So so far in this video series, we have a meanly used a prototype self that was given to us by the framework and were able to choose a different kind of styles. Basically many youth off the table. But you could choose any of thes style. But there's only so much functionality that these, um um, the pre defined fails can give you so we are going to be expanding upon. What can we do in our table view cells. So left. Create a new group. We're gonna call this table. You custom. So, um yeah, that's a tough. And, uh, you had a new file? I told you. Board custom tell storyboard. All right. And we're gonna create a We went over. So this is going to be table view 7000 the controller. All right. Okay, so let's clean up a bit. Okay. So Oh, he are back in our ah, three pork and left. Make some more room here and down into basically owner track a u I view controller and possible That's wrapped it in a navigation controller. Okay, Like so Let's make navigation controller Nischelle you controller. And that's search for two of you. All the step for just like what we did in previous videos. Okay. And, uh, able view with custom fell. All right? Now, uh, just like before, we are going to add a new tool yourself. But this time we are not. We're not going to select any of thes defined Selves, like basic right details. We gonna leave it that custom? You gonna give it up for you? That and fire and, uh, left design are fell. So basically, I just increased a bit. And the purpose off this prototype cell, if basically, it provides a template, the template A So you have seen in previous examples get repeated for different data items . So what we're designing here is a a template. So, uh, the thirst for revenge for you and we don't have any made for you. Um, okay. And we got we're gonna define its width and height to be 100 by 100. Um, reason I'm setting it 100 100 because my images are off the site and then I want to give leading leading constrain a Z eight I. So that spot it for this one. And what are you gonna do? We gonna set this particularly in center. Okay, now, let's set theme, image property. The content mode on this is going to be aspect fit. So her and we just aspect fit into the into the box. And if for fun for so we can actually see something going on here, we'll add an apple image, just like back by default the fickle evil and, uh, stick that label in here. I want to give it a bit off a different color. So this juice, this one and only agrees the size and make this a little bit bolt. Okay, so now it's time. First constraints. So owner said eight. Kate and hey, uh, okay, I think I might have sent it to OK, so that remove the constraints. Henry said it clear constraints. Okay, so, 888 So it's not constrained to the margin, but just actually constrained to the actual view. There you go, as better. And, uh, you're gonna drag another label and this label. We are going to degree the fight, and we're gonna give it a light gray color. Like so, um, hand b Bill said it's, um, strength to be eight all around, coasting to march in. All right, so you can see there is some conflict here. And if you look at what the constraints are, it's complaining that the content priority is because so said the content taking charity basically to 50 and to have to do and all that. All right, so we can actually, um, do something else about it. So what we need to do, basically, we need to say that are because since that we have Cuban, it's sitting in equal we wanna set of greater than or equal to the value. Okay, when what's gonna do? Basically, it's gonna make this label expand depending upon the size it needs in the other property that we need to set for that is this. So instead of flying one redefined line zero So the label expense across multiple, uh, multiple length. All right, so that's a lot for this one. Now, um, sure that we have our, uh, table, do you custom fell, be controller selected. And since we have defined this, a new type accustom time for the cell, we are actually are going to need a new path, and that class is going to be inheriting from you. I they will resell so less create that. So first of all, it's gonna be a subclass off you. I they will be felt, and we're gonna call it custom fail. They will be felt our custom things without better. Okay. All right. So what we could do is we can say that we have we can have pre outlets. Still, I'm gonna actually creative outlets here. Who are you make you and you are image for you at Ivy outlet. We bar Michael. You are level. Okay, now what we need to do, basically, we're gonna create a function. And, uh, I say so has no each life, there is a non option property. Okay. Going to remove the error? Basically, you need all your properties to be either an optional type or it need. There needs to be initialized. The foot was complaining about. All right, so we can create a funk set cell, okay? And we didn't supply food in this Food is our data model, and you're gonna say self talk title text is equal to food. Done title. I felt that subtitle Doctor is equal to food. That subtitle in South Dock Image You thought image is equal to food dot image and what we need to do is, since they are going to use teak, you fell. We need to actually, uh, prepare our fell to be reused. And this is just for for a good I use experience perspective. So your table does not retain any off old self. Stay down if it is missing, are this not loaded yet? Okay, so we're gonna set all these a lister, Neil. And now one thing that we need to do is be to go to the stable. You and we need to tell that cell it's the class type is custom. They will be self. I accept. And then you will start seeing all the outlier property that you have created like he made to you. It's the restaurant, so I'm gonna select that one title. It's another one. And then sometimes. Okay, so that's about it. For the custom felt. Now, let's go are in our table view controller and start creating some connections. Theater will be outlined. Ah, weak bladder table. View you white table view que From this plus one and really create data data, fruits and veggies. Very much less than if you're eight. Then se south out table. You don't delegate highs equal to self. I felt that we don't. Data source is equal. Teoh felt itself dot data if you call to Fruit saying that he stopped for that. Okay, let's make sure that this table actually implements are the required matters off. Uh, you are. They will be delegated your due date. So put that in extension, um, you are table, you delegate. You like people. You status of it. All right. The post. We need number affections. They return data dot com. Hi. Then we need a number off rose infection. So we're gonna say return data section dot food I don't count. Okay. Food items within that affection. And then you're gonna say, fell for row and in expats, and that's when you're going to be let cell if equal to table of you dot Thank you. Without any fire, it felt Oh, that the creative And, uh, we are going to be casting this one has customs table. You. I felt like, uh, I'm going to return itself. Basically, we're gonna call the cell doubt, set up set cells. And, uh, for the data item, you're gonna say data index bath dot section. So basically, we're going to that section food items and getting that particular food item there. The particular row is, and we're gonna take that food item and lead item that item difficult. It is. Supply this school, like so Okay. And last function that we need to I have lived here. It's titled Head of Section so we can see the titles and data and, uh, infection dot name. Like Hi exchanger people. Um, three heard and run the project. Okay, so we have our all right. So Okay, so we have another Stephen unwrapping option. Okay. Option open because of the Forgot to connect our table to our story, Lord So begins like the table. You and, uh, connect that outlet often. I see. Okay. Says you can see our table is showing up. And for some of the text, as you can basically see that it's actually automatically increasing the line and is showing basically multi Alan, multi line text, um, within the to yourself. Okay, so that's about it for desperate. You and hope you guys enjoyed it. In the next video, we're gonna be creating the same experience using the programmatic approach. So you're gonna be creating a custom. They will be a table view with custom cell, all programmatic approach. All right, I hope you guys in the studio. Thanks again for watching you guys in on Expedia. 10. Tableview with programmatic custom cell: Hello and welcome back. Hope you guys are doing great today. How we are going to be continuing our table view journey with programmatic, uh, custom cells. So let's go ahead and get started. I'm gonna create a new, uh, a new group. I call it programmatic. Um, custom, you control her, uh, table, you controller, Uh, and, uh, and a copy. Death. And I'm going to create a cocoa touch file. Gonna call and inherit from you. I've you, uh, controller, and, uh, you're gonna call it this. All right, click next. Create. Awesome. So let's do some cleaner. Still, we'd all be all the things that we don't need. Okay. All right. So if you remember last time the way we, uh, we did basically be created of able and clearly our data, and then we populated it having some constraint, and then, um, simply added a number off roads and sell for Rohit next path. Now, this time, um, we are going to be doing some of those things, but let's first create our custom cells. So I'm gonna create a class right here just to show I mean, you can create, like, a new class just like we did in last video. But I just want to show you, like, you know, that you're not bound to create, um, a new file for a class. You can put the classes in the same file. Um I mean, it's not recommended practice, but I think for demo or for a proof of concept perspective, it actually works out good. So, yeah, for this time, we're going to try out that variation. So let's create a class. We'll call it program Matic sale me and, uh, capital. And we are going to be inheriting from you. I table view self. All right, if, um, Chris create our private very well. That's gonna hold our food for current cell. So private are food data. Um, type it. It's gonna be a type food, and we're gonna set We're gonna use Did set. Um, observer. All right. The way did set works, if s anus. You set. Are you basically Ah, a fine. This full data. Whatever you write under this block, it's gonna get executed. So it's called, um, it makes thes at the property outside of people. All right, so let's create some from control. How that we're gonna serve o r make changes to so create private lazy You are image for you I'm gonna call it in your it's gonna be up type you I mean, to you I've begun any slice and hand say, let the physical tur image view and we're gonna return this you first thing we're gonna do is translate into false and the content mode. It's going to be dot scale have picked it. All right, that's it for this one. Let's make some room on the bottle. Okay? And that's created another one. I'm gonna call it Private Lady are title text, and it's gonna be you. I label cake call, execute herbal block, let you I that is equal to you. I label return B. I read up, translate. Okay. And, uh, read a number of lines. So there's the same property like this is how you set number of lines for the lib Mom. Setting it one explicitly but by default, this one. So you don't have to really save it. Um, reason I want to do it because I'm going to copy this thing, and I'm gonna say Subtitle Subtitle Text How are you? I label and number of lines are zero. All right, now how we are going to be calling, innit? Property. Basically, I'm going to use the default in it. And over that must be should call super just to make sure that feel that three work, Do whatever it wants to do. Reusable an identifier. OK, now, here we are going to be adding these views to the content view How, which is the view that it's gonna hold all the elements, and we're gonna constrain those than that. So let's take the Martian guide. Um, that we're gonna basically use to constrain our, um are abuse against, so layout margin guide margin guide Have you go? And we're gonna say contributed Add some you, uh, image of you content that adds a view title text and content. You don't add some of you Subtitle text Have you go? I left some constraints now and it's layout constrained. Start, activate. And we are going to say, uh, image for you because it's wet to a fixed value constrained equals 200. He makes readout height constrained, quote hundreds long. Give me you got leading anchor God constraint and we need the radiation that has a constant . So this is going to be margin guide got leading, so it's gonna be a kind of be appearing on the left side. We had distance are sent, basically applied as eight. Okay, you made for your dot center. Why? Basically gonna center it on the lie access and you're gonna constrain that to margin guide Got center. Why? Like so? So that's images. That's to the same thing for title text. Top constraint is going to be equal to, um margin guide dot top restraint Top inker. How? With constant eight cattle text that leaving anchor that constraint. And this is going to be from the image you because this is gonna be here next to the image . Okay, so next air so hard for us to put it next to the image you were gonna use image views trailing anchor and gonna make a constant artistic basically between them eight. Okay. And, uh, trailing. Uh, trailing hanker is going to be the margin two and a stretch. Death to margins. Kite trailing anchor and eight. I thought, um, actually, this is gonna be negative because it's going to How come it's gonna add It's going to subtract are trailing. So there were margin guides. Trailing is we want to subtract. Ate from that to make our label appear within the content. Otherwise, it's gonna go out your top That's trained for subtitle text. And this is going to be titled Tech Stock Bottom Thinker and eight. So tell text out leaning anchor Because trained, he made you that trailing anchor and eight And the subtitle text that Parliament anchor constrained, uh, topical strain. Go to the one with Constant. This is going to be margin guide that bottom and really negative weight from there. Okay? No, um, the excellent is complaining that we need to We need a required on its Leiser. So we just say, Fix it. This is not going to get cold, so we don't have to worry about providing a definition for accepting and leave it as it. And we got a function called set data, and this is there. We're gonna set our food data finding a celt out. Food data is equal to food. I think so. And we'll just override prepare for we use their phone just to make sure that our carving ourselves is being reused Our image of you and all the other properties are set to know for their ready for use. Like so. All right, Now we need to to basically need to come back to our server. And, um, when the food is said, basically, we need to set all the other properties. So again, say it would be Dr. Image is equal to food data that image become entitle text. Our text is equal to food data. That text title and subtitle text. Our text is equal to food data. Don't something thanks. So Okay, so once we have our, um, sale already Now this is the usual strips of you gonna basically go ahead and copy some functionality from here. Yes. You okay? I think this is the only thing that you can copy right now. Um what pressure? The other things begin. Just David up because our data exchange you're using Flat Ray for the previous example. But this time we are using fruit. Stand ready. The right, which has section and everything. Um dot They were you dot um, how crustless add. So with that data, um dot Be that adds up. You. I'm gonna, you know, defying title um, gonna call it programmatic sale sample and, uh, some constraints to bait. They will be you. This one is easy because we just gonna do leading training off, um, attached to the abuse. So self doctor, you don't leading viewed out. Trailing train helped out you dot training stable. You dot being training top you dot you dot bottom train so that you don't bottom anchor. All right, let's create our extension of this class and define your table. You're telling it. And in the photos letters extension are there few? I table. Why they you delegate a number of sections return data section. Oh, thank you. They are that count for this one. Number off frozen section is going to be turning data section dot What? Adam, don't go. So and, uh, south for a bow. Next. That's so table of you. Thank you, Phil. Oh, be. Actually, when we copied, we forgot about this one. So now that we have created our programmatic, so we need to register that instead of using your acting will be self. So you're gonna say just her program at excelled ourselves for the use. Identify. Still sell. So, um, there you go. We're gonna cast this one as programmatic now, but return it before we forget about returning it, and then they sell that set data, and this is going to be date out in next bath. That section Hot food items, index bath, not throw just to get to that. What? Glide. All right. Last but not least, we need the title for better infection. And this is going to be returned Data section. Dr. Nate. Okay, so, yeah, you're almost finished. Actually, we're finished with this. Let's make sure that the launch good. So I'm gonna leave this commented, and I'm gonna actually create another cop. And, uh, basically, you're gonna say this one is programmatic. Got something for you, so they will be controller. Have it. Let's make sure everything is correct. All right, So has built and front. All right, now, okay, we go. And as you can see, it's looking a bit awkward. The reason is, um, that are strains are basically set. How? I mean considers have said probably. But, um, there is a thing. Call auto automatically to think the hype for the south, so we basically have to provide that automatically adjusting adjustable height. So because different off thes have different values, they are going to be You think that different brands. Hi. So let's to pass less, make sure everything is working fine. Okay. Yeah. So you can see that the because our overlapping a little bit. All right. So let's take a look and see your can we do about it? Our reach, some title. Oh, actually, there's something that we forgot. Subtitle needs trailing anchor Doesn't have a trailing Ugur. Um, Okay, so in this turning Anchorage margin guide dot explaining incur. And it's his, um, negative weight, like so isn't it a comma and the auto of resizing cell? It's something that we're gonna have to cover another how video? Because it's a topic on its own. But as you can see now are ourselves are showing up. Okay. All right. So, uh, this is the same, but it for this video. And, um, in the next video, we are going to be looking at self adjusting our table themselves. So if we have different size of content, reasonable cells are gonna just herself. Right. So, uh, uh, I hope you guys enjoyed this video and, uh, thanks again for watching so see you guys in next year. 11. TableView: Self sizing cells: Hello and welcome back. Hope you guys are doing great today. We are going to be looking at self sizing. They will be cells. So, basically, with the devil of yourself, as the content grows, the the height off the cells are going to grow automatically. Uh, this feature was introduced in Ah, um, you I table view in IOS eight and has Bean on the greatest feature that safety a lot of time prior to this, you have to actually manually calculate the size dynamics at the wrong time. And basically, you resize yourself, so it saves a ton of time like No, just doing that automatically. Right? So we are going to be looking into that. So let's create a new folder. And, uh, I am going to create a storyboard with the same name, all right? And a vehicle troller? I think so. All right. And before we forget this update, let's comment. Are the the program it problematic? They'll be on select this table view as our main interface, like so Okay, best drag and drop M. But that's just the usual stuff. Um, and if you do it more often going to get taking to a rhythm and gonna, uh, gonna remember, like, Muslim stuff that he you have themselves. It's a great great practice to dio to create, uh, create how they will be overrun or just give to you other with more confidence. And he was clear. Find out more things about it as you as you do more often. Like I said, this table of youth one of the most commonly used control across the, uh, and in the hole I was there for, so Yeah, well, practice you have a better for you. So Okay, so you're gonna be be distract a, uh, a Fordyce up, and we're gonna create their size a bit. Oh, yes. Make it 128 and will you be doing? And this one is really create a made for you Hope size, 100 100. And then you can define this leading constrained to be eight around you and gonna center it except create a label. All right, and, uh, get another label. That and for this experiment, we're gonna try toe changed. The are the what do you say that the front to be like? Something that the sensibility feature can update Okay, so now this is interesting, because we have said, like all four constrains in the last video, we did a member state to line 20 But in last video, we did greater than recall to select this option. But let me show you another way to actually overcome this problem If you select three other day and go to its sizing property and, uh, in Greece, the content hugging like so at the second view is basically gonna take a take up the whole space. All right. So that that way you can actually result it suddenly out issue. And what we need to do is basically, instead of having a system fond, can I choose heading And, uh, but this one we're going to subheading like that. Okay, uh, and it's gonna make sense how, when we come back and basically uh huh show you like how the leaves change our basic from the accessibility features a zey fund for the system system for into changes How this changes, that's all. Hey, one more thing. I forgot. He just said There's two aspect feel, um our past. Really? That's better. Okay. Lets send this class to self citing DVT. Here you go. All right. So what's happened in that? Uh, let's go ahead and, uh, do the usual stuff. So I'm gonna copy of the code court from previous tutorial. It's just the same. They accept tissue lights on. We're gonna talk about these two lines in a bit. Um and, uh, we need extension part All right. Away. So, um, the way we actually tell our, um, our table you are to do to order a test itself, or are the justice hike basically, by setting our table beauty estimated Wilhite property. And this is the same value that we actually had given for the cell, if you remember right here. So saying valley. And then we say how the rou height should be your ideal view. Automatic. Now, in this, nobody said it's automatically going, Teoh. Increase on decrease the value off the height of the row, depending upon the settings. And you're going to see that now, for this case, I'm gonna copy another bit of good. Basically a sale. Um, so this is just a regular you idea will be cell again. Ourself citing ourselves being named and got three properties here just like how the old interested in everything. So that's buying these And make sure that, uh, everything is connected properly. So do is stay. So fighting fell and there's a limit to you at a test that Titley with that title I stopped like so and, uh, as connect our they will you as well? I think so. Okay. So, uh, so this is this is about it, Lister, let's run and see how are tell you. It's looking, and we're gonna test properties. Couple of fund. Okay, um, you forget to define the cell. It's a good editor because this actually helps us a debug and see what's going on. I don't have used I didn't find it, Which is why it crashed. Said it. And we don, have you got and is against the cells are actually automatically reciting according to its content. But, uh, here's how, uh, this becomes more useful. So I'm gonna go to settings in General Sensibility and set the large fund, and we are going to increase that do maximum and gonna rerun project. And the difference you're gonna see is the two of you is gonna automatically it just its height as you can see it has actually increased font. And none of the tape. None of the none of the content is actually overlapping to each other. And this has been, um, this self sizing takeover you actually are cells become super useful. All right, so this is it for this video, and I hope you guys enjoy it. Thats video. In the next video, we're gonna be looking at a static table view on and be talking more about static terribly , and how it can be used in in ways, different situations. Um, thanks again for watching you guys in next video. 12. Static TableView for Settings or Form layout: Hello and welcome back. Hope you guys are doing great today. We are going to be looking at static to abuse and the way static daily views are used Are basically you gonna find, ah, lot off settings or details page basically including static table views there. Just full for situation where you know, how many roads are you gonna have? And it can support various different kind off. I mean, all kind of control basically in place, and you can directly show them. And it has a scalable scrawl of you support our American because it's it's a table. So for this to drill today, how we are going to be creating a table with, however, even listing all off our fruits and vegetables and basically gonna be creating a stick static table to show that the details off that food. Okay, so let's get started and create three boat. Call it static. Have you copy the name? And I want to create a file static. That's a view controller. I think so. Okay, so let's just ah, designer control our basic give a little bit more. Uh, can I m back this into navigation controller and our medication control it's going to be you Show your point. Yeah, This is going to be static Table. You Hey, we need a U I t mobile. It's strike that here. I think so. And right bird, I felt we just to use so regular sub table felt I didn't fire at cell. Okay, Now let's use this table of you control over that we have seen all along. So let's try this one. And if you notice it's elect its prototype. So basically what desperate I sell means is what you're actually providing a template off how a cell it's gonna look like. But all all the other self are basically gonna take that prototype and fill in their families. Now there is another type that comes in a safe, you click on table view you're gonna find in the property window the content type. It's animal property and said excels. Now in case where your table views embedded into a few controller. If you select that, it's a compile signer because static cells are not supported for regular till they're only support it in table view controller that we have just dragged. So let's select Let's protest. Let's let static Celts. And as you can see, it has just changed, uh, it to be like, you know, three ourself. It's firstly, we're gonna do We gonna control drag from the street controller to controller. So our main list even tore to details controller. And, uh, now, how are we going to start creating some controls? So this created label, I think I find about that, um, eight points across middle has changed. Size making bold. Can't Let's make it blue color seven sale. We're gonna use a image of you, Dragon top that one. Nothing is center his center horizontally and vertically and then you can a five that 202 100 exit. All right. It looks like the two sides of the liver Mark. Okay, that looks better. Now a selects his property to affect film. In Last is the subtitle label, So label and pin it eight points across. Hi. Has make it your lines. Serving conferred multiple life there he and, uh, size is Okay, let's make sure it's a little bit darker. Great. How they so create a new control. And this time you're gonna inherit. It's inherited from you, Ivory Control. We're gonna inherit from you. I they will controller, and we're gonna call it details you control in detail. Still drawer. Okay, so, uh, the they will be controller comforted all these properties. So, uh, remember when in the last video we were dragging, dropping, like, you knows, assigning delegates and data types and other stuff. Well, if you use a table view controller and you have to any of those now reason, I tend to use you, have you controller and an embedded I have embedded table view because it gives you more flexibility to personally out. But if the only thing that you can have in your view, is that they review and you don't care about, like, you know, putting anything else, then you can very well used you ideal if you control that. All right, so let's first set our static debut. So this is going to be the same code that we have seen a lot along, uh, someone Type it for your quick. I be outlet. Speak our day. One of you you I table with you and then our data fruits and vegetables empty haIf pain in our You didn't know it going to say? I thought they were You don't telling it that got deal you dot dare sos itself that data fruits and veggies, Food items. All right. And then let's create extension for this class and do I table you delegate, you are able dancers, huh? Number of sections return data Don't count. You have How cover many sexual. You have number off rose in section return data section that would I don't start count and self for Rohit next path It's going to be fell table you dot de que So return to tell Unwrap sell out text label That text is equal to That's great food. Difficult to Dana and expat section in next bath dot bro and says food that tell that details that text that he got to food Subtitle and sell Don't you made you doctor is equal to dot Thanks. All right. And we need section name. So Heather, we gonna return Data section taught me. Okay, so now, in order to support our, um, detail you control or we're gonna have to pass some information like which food user have selected. So let's create a available in our details. Still you and what we want to do basically has and have the outlets. Not that we are image the I'd be outlet Week far Title text You I maple speak far. Subtitle Thanks. You are label like so no se basically you on a shoulder now are images are like in a very low resolution at this former. So let's update her model to include a new margin a full playing up in age. All right, se Oh, there is do you and as myself for me to go to full image and let's build because it's gonna tell us he's gonna tell us that we made if you need to make all the adjustments, So we're gonna say, Fix that. And we know this is the orange. So we're gonna just say new food we're creating with the orange have the default type. Okay, Lets fix all these. Thanks. Picks. Thanks. And we're gonna placeholder. Okay. All right. So this is apple happy. God. Blueberry. Thank you. Oranges Pete alone and strong. Hi. This to the same thing, Peter. That plant he's tomatoes que so it looks like being fixed that Okay, so, uh, go back to our details. Can you say you need to be. Don't Image is equal to food dot Full image title text. Our text critical to dot title subtitle. Thanks. Tuck. Text easy dot like So. Okay, now, how are we gonna supplies data? So, plus thing you can do since we have already remember the already created the Segway in name to send details, details, uh, we're gonna back here, and we're gonna use how one of the method that be abused before did select Romantic. Expect so this again, What it does is it, um, it actually, whichever the role user has selected, it's actually gonna thank you house. Uh, the honey, the opportunity to do something when when it is selected and what we're gonna do basically say, perform sacred in this case. So this is the identified that we just have just given to, uh, the segment right here. So details. Same Segway identifier that we can I get here. Center. It's going to be in Time data index path dot ro dot Food Items in index path that. Hi. This is gonna be row. This is gonna be section makes up, right? Well, nothing. Uh uh, We need to prepare. So basically, when we perform the Segway for using the code we need to prepare, like in order to set some of the things. So basically, because we're supplying this food, we don't actually set the food variable that we have to find here. And this is the operative the place where we get the opportunity to do it. So let's see how we can do it. If so, they say, if it's a way Segway, I think in type Segway identifier is equal to details on that we already having clipboard. If that is the case, then as a testy nation, the controller is equal to segway dot The destination has, um, and because we know like which which you control, the Segway is going to get a view. Actually, we can, uh, Ford's son wrap this one and saying detail you control it is the one. And this is where we can say you will receive that food. A sequel to center as food because we are setting their center here. I and we're missing appliances. That's why it's complaining and see right? Failed. All right. He didn't. Okay, cool. All right, so let's take let's set this as the starting point and take a look what we've got so far. And if you want any missed any step are, in fact they will be is gonna work. Well, we have definitely missed some things. We forgot to connect our till. So static Timpview terrorists and the table we have, uh okay, so we don't have that. So let us to this on a lot of details. Let's connect all the outlets. We definitely missed that step title. Yeah, that's one our So we can see our fruits and readies in a few. Select one, uh, says you can see we have our details. They'll be showing with the correct item that we have. Okay, So taste wraps up the video for static Timo views in the next video, we are going to be looking at search. How? Functionality. So basically, we're gonna add, um, so it's gonna be similar to this one, and we're gonna add a search bar at the top. Pains can actually type no name off a fruit or a vegetable, and it's gonna feel town the riddles. All right, so thanks again for watching can see you guys in next video. 13. TableView with Search Functionality: Hello. And welcome back on today. Uh, we are going to be talking about a ray last topic for this video, see? And, uh, its, uh it's ah, all the quite interesting one. So they're going to be creating a table view with a first functionality. So let's get started. Hollis. Name our group search table view and list. Copy that, um, and create our storyboard. The same name has the last. Hey, you. I view controller. Right? So But this one, we are going to be taking a very simple table view, no affections involved. And we can be placing a search around it. And as either types on the search box, How are we gonna filter the results and show them? Okay, so I've already attract au I gave you a controller and let's wrap this in. Hey, navigation controller. Let's make sure that the navigation controller has and you she'll have a beautiful view controller. Cancel us. Let's give it a title search table view and, uh, you I table you are table. Here you go. Make sure full screen. All right, now, before praise before we place our prototype self. How do you do pay to get in a start for search bar, and I'm gonna police it right on the top. I am the addict e. It actually is part off. They will view. So what happens is if you drag it unless they if it ends up somewhere like this and it's not going to be a part of two of you and it's not gonna show up. So I wanna make sure before you create a pro dental, you actually drag it. Eso the search becomes part of the review. And it actually because the header off the team of you all right now we can actually, uh, type sell and take the prototype self and put it in. It's just a simple prototype self, the one that we've been using quite a lot. And, uh, so that's that's about it will stand up. It's going to back, um, in the you control work and do think putting up and let's create and I be Outlet week bar came over You. You why they believe excel And let's create a data and this is gonna be just a It's an array of food. Basically, all right has make sure that they will use delegate is affect itself. And data source is set to self as though. And now we're gonna say for item in person. Ready? Start Who names gonna penned that sequence, huh? Have you got got food items? Like? So? All right, So if you're unclear about any of these watch of the earlier videos, I think it's ah, basic. They will view that we created will be with section 11 for that right here. Do you think they will be story? What? And, uh, we have you find more explanation there. Um, let's create an extension. First. You off you and this is gonna be you. I table view in you. I love you, Deli. I think so. And, uh, we are going to require two methods number off roll infection. So we're gonna return data dot com and sell for row at the next path. You can say let's sell is equal to table view. Got dick. You so and say sell dot text labelled up. Text is equal to data next path dot ro dot title sell dot detail. Thanks. Eight equal to data index path dot Rope. Start stepped out and sell that image. You don't image is equal to data index staff that rope dot You mean like so? And we're going to return to sell unwrapped. All right, so that's about it for the table. You. So let's make sure everything is working. Before we do that, we need to sign 30. They will view. And you just our plate to the tail of you that make it main storyboard for launch and, uh, take a look. But I got so far right, So it's wanting. All right, Cool. So, as you can see, we have a uh um you have a table U s terrible story. Okay. And if you could call service retyped anything here, I can click on such. You can see nothing happens. So we wanna build that puts Alby. So let's do that Teoh product for the for the search to work there. Two things that we're gonna need. First thing is, we are going to need a Babel How we're gonna store our data, um, filter data. So let's call it food is all that's gonna be filtered data. It's totally up type and area food. And initially we gonna say filter data. Um, did they equal to data, All right. And it's self returning from data. We're gonna return from felt or data. That way, we can actually modify the voter data and get the get the service reserves. Okay, so let's to Okay, let's to another expression here. Um, extension 30 day, will you? You? I search bar telling it. All right. And, uh, you need an outlet here at I b out it. Okay. Sexually complain something. So the meat comment without I'd be out Beak bar. Sort of far you. I search bar. So in time, do you know anything that you wanna do? You wanna sign ourselves? Has Davis SOS Highs delegate or such? Okay, that's uncommon. This and, uh, we are, by the way, the uncommon shortcut is command slash. Um, so you select and come and slash to comment and command slash to income. It just boggles the method that you believe it's text dead change, Okay. And what we need to do first, we need to make sure, um, that we have something in the search box. So search next that if empty, if it's not empty than continue otherwise, filter data is equal to data and a table view top reload in the time from here. Okay, But if search box has something, then filtered data is equal to data that filter. Okay. And this takes, uh, this is a clue there. Detergents gives us a food, and we need to return something. So you're gonna return Food tart title that contains. So if the title contains something that is already typed in the search text, then we're gonna return true, which is going to create a new away off in third item. So only those items included that are are matching or that that contains the text that we have type. And let's not forgetting to reload the tell you. All right, so let's connector search bar to the outlet. And, uh, I found it. Our table view is here, and we can type apple on, As you can see, Apricot in Taif. AIG Another one. I'll say it's probably us match. So it's doing search aren't. So this wraps up. That's really serious. This was the last video for the studio story. Hope you guys enjoy the, uh, the videos and learn something new. Please leave some reviews, and if you have any questions, please post them and I'll try to respond. Teoh those as soon as I can. Thanks again for watching and, uh, until next Video series. Goodbye. 14. Advanced TableView: multiple swipe buttons: Hello, everyone. Welcome back. And, uh, today we are going to be looking at on this. Ah, new hub way off, showing context, many or action buttons for the table view. So what we're gonna be doing today, basically, we are going to be adding swipe right and swipe left, and you're gonna be providing thes action buttons so you can use them to provide, like, more, um, more functionality or form or actions basically to your to your team of you. All right, So this is what we're gonna be building today, So let's get started. First thing I'm gonna do is I'm going to create a new group, and I'm gonna call this action, but Okay, Well, okay. And, uh, had in you scoring Bork, and this is gonna be called actions table if you okay. And let's create a controller as well. So, coco, test class on this is going to be you. I You controller. You call this actions table, you controller. Okay. All right. So let's had a you controller, and first thing we're gonna do go to Predator. Many auction and embedded in navigation controller. All right. And, um, going to give it a title and the title is going to be actions they were. Yeah, and that's trying 80. Move you out. That's constrained. This too. Cover that full screen. Try a settle out. Let's give it a custom height off 100. Select the cell type to be up. Subtitle I didn't fire as sale and personal things. We can leave it People selection from Justin. Okay, I must have done that. Let's go to the controller and, uh, the anti wall these he and going to create a public so I'd be a public we coir table. You do. I able you unwrapped and then data this again Could be a food type. And you're here. Beaded load I would not do is we're gonna hit rate over fruits and veggies on our food items and appended to date ourself as before. Item in props and reading. Start food items, and, uh, data got upend. Um, 10 self. I can't talk food items. Okay, then you're gonna have table view that delegate is equal yourself and tell you don't take the source. It she called herself just to make this class conformed to Thies To date assholes interrogates This creates an extension so extension actually stable few. You, I say, Will you dedicate? And you are a table, you data source. Okay, now number off Rose infection going to return this as data don't count and sell for a low at index, Pat is going to be so table you got Dick, you musical So that indifferent and the identifier is so that we have to find, um, in the storyboard, sell that text level. That text is equal to take up text past doctor rule Don't title. Okay, so that's optimizes a little bit. You gonna take and create a variable called Flicked Foot and, uh, I can't say fruit. That title that tail's so celled art teacher stare text leveled off. Text is equal to fruits, fruit, not some title and sell, doc image you got. Image is equal to data, not data proofs, fruit, that image. Thanks. And we're going to return the fell untracked housing. So once we have done that, let's run our app and check it up. So first thing we're gonna do is mainly interface. You're gonna change this to pictures to his trolling for and this one. Oh, full run it. They forgot to add the outlier. So, this ad, let's give it a class. So actions jail if you in the hell is this one? Cool. And, uh, this is to find a cell call on it. Okay, Um, I figured since tension, because there's no designated entry point and you know that they're basically just to fix select the navigation controller and said it has is in the show a few controller that's rebuild and run. Cool. So you can see you don't have any kind of gesture right now and you're seeing all the fruits. So basically, uh, less trust, Um, make our health Olympic bigger. So they're gonna see table you talk right is equal to 100. Just so it next unlearned. Big reason we're making them being is because we're going to show not only text, but they're on. We're also gonna show icons for these context menus. Okay, that that looks good. So let's add our two new functions. So, basically, for when it's cold leading swipe actions and expats So leading fight actions configuration for rule and in next bath and ah, reason, it is leading because the second method is trailing swipe actions and business leading trailing, not front and back. Um, it's because of some of the language is you go right to left. Are you read? It's rough reading Left, right, You read right to left. So all the context and are all the orientation like, you know, basically the way you work changes are so you're you are changes with that and iPhone are likely, or IOS are likely conforms to work. Which is why leading the definition off leading changes for right left language to be on, um, this side. So, um and right now, for our English language, it's ah, Leading is here, and trading is here. Now if, like, you know, you have Hebrew or any other language that reads right to left in those cases you're gonna have leading on this side and trading on this side, I hope, uh, it is clear. So let's move forward, and it's create her to actions. So you say Let archive action. And if you like contextual, contextual action and we can choose style so you can say style dot normal. And, uh, this is title is going to be okay and, uh, gonna provide he completion handler with this and uh, sit there, get the opportunity to act upon basically like, you know, when a user has selected that. So for now, we just kind of left. So you're gonna say, Ah, user selected our clients, Let's create another one. So they're gonna say, Say affection And this was going to be Do I contextual actions and style again is going to be Doc Normal. A normal title is going to be say, you and, uh, for the completion here again, going to say Frank hands on me copyists. It's a selective state of it. Now, once we have these two created, what we do is we are going to say, Let could be so you can create a conflict optic anything you I swipe actions configuration , and we're gonna define We're going to give a passenger re off configurations that gonna basically collide. So, uh, actually archive action so and direction and the order off these matters because the way actually thes appear, you're gonna see the archive, and the positioning off them actually effects the, uh, positioning effects the way it's lead shown. So let's run it second, show you the archive is going to, uh, be added first in the list. So as you can see, our kind was added first and save was added after that. And, uh, if he noticed, we have same colors. So we're gonna, uh we don't have any background color defined, So you're gonna come back to that in a minute. Let's define her, um, are left complication or are training configuration of though. So for this one, we're gonna have created to, um, actions that create a in for action. Then you I contextual action, and the style is going to be normal, and the string is going to be and full and completion. It's going to be action with you, like so And print you are gonna print is a selective. Okay, let's create another one, Uh, delete action. And you say you like context, collection and duck destructive. So this time we're choosing style destructive, because delete is something that we show in radical and especially in built. So if we choose destructive style, just like in your alert, um, it actually has its own styling. So you can say you've selected elite this planet Hope, uh, we're gonna create. We can fix up and bake you. I swipe actions, consecration actions and remember the order. So Duncan leak and then in full, so the lead is going to be at it first. But it's going to be towards the eso first item that you enter. It is a pendant towards the edge. And then it sort of like, you know, adds the next time. So unity, I was gonna look waas you run it and, uh, take a look. So, as you can see, delete is right off the edge, and in this case, archive is right up the edge. Okay, Now, if you notice if I I took it a little bit further and, um, it actually selected that user selected archive. That's the feature. What happens? Basically, in case of delete found, Apple has for some reason, they have decided to design where if you swipe from leading direction, Leslie only fills up the half off the screen. But if you do it from the right inside, it actually does full, I guess because elite has been around for a while, and they have just added these other properties. So for that reason, But if you notice, um, it is to say it actually works And if you choose kinfolk, it works it up. Cool. So let's fix this. Ah, swipe to anything. Because that's the liberty. Um, So what we can do and you can sink and faith dot Perform first action. Pitiful sight visible to false. I'm gonna copy that. And what if the hunt this fall and limit command are is the shortcut for running? And, uh, if you notice I'm trying to pull this and, uh, it's not doing that default behavior, which is good, because what we want Cool. That's less add colors too deep. So you don't do anything I say archive action dot background color is equal to, and I'm gonna use color literal. So just type color literal. And you see this Nice option money. And you can choose to say this color and, uh, save action back on is equal to color. Neutral again. Hand choose by color. Uh, blue color. So this shoes Yeah, shade of blue act. Let's run it and see if that is working, and then we're gonna add it to others. Okay, cool. So that looks get. Um, Now, let's, uh, add the's to our info action. Dark taipan color is equal to color. Literal. Um, can I keep this one green color? So that's like my share of grain and delete, but Bill is action. Ah, you can change and give it a color. I won't actually select something a little bit a lot like red. So our Limbert a different shade off like orangish kind of Fred. OK, list from that. And, um, check out. Okay, so that looks good. And these looks good. Better far Christmassy color. That was going on a year, but Okay, cool. That works for me. Okay? Now, what else can we do? So we can also provide some images. So what I'm gonna do is, uh I am going to, um, get some images, and I'm gonna put it in the assets and you'll actually find in the final project. Don't. You may. Just let me put one for all right. And put one for do eat so and saying cool Now we didn't do is, um we are going to assign these images into these buttons. And that's the reason why we actually increase the size off the height. Because so we can see the button on and the the images property for some reason, If you have, like, the role small, um, it sometimes doesn't show the image or like in a good, exquisite little bit. So that's why I have actually made it Lipitor. But you can check out different image sizes and see if that works for you. Um, so are correction in same action that you made a sequel to safe. All right, can let's give images to our info action. That image is equal to info and, uh, elite action, Doc. Image is equal to delete. All right. And listen on this, all right? And take out we have here is is with a nice table. Cool. So this is it. This is how you can actually expand your context? Many and had more options to your context. Many. So, uh, I hope you guys enjoyed this video and, uh, stay tuned for more radios. And thanks again for watching 15. Advanced TableView: Expand Collapse functionality: Yes. I hope you're doing great. He and welcome back. And today how we are going to be looking at this. Ah, new functionality in the daily lives. And this is expandable on collapsible Our table views. So in the steno we have, ah, two table two sections And at Nikki, click on Hide. Um, I can hide that whole section. And when I click on show, I can show only that section it like so and its functionalities Very easy to implement. So let's get this get started. All right, So I'm gonna create any group here gonna call this, uh, spanned Clean. We're going, Teoh, create me. Wow! In this by we are gonna create a storyboard. And, uh, you mean this expand story board and they call it class. So you live in controller and expandable. Expandable table, you controller. Okay, now let's remove all this on. This is the stuff. I'm here and we're going to He is gonna bust Dragon, drop a few controller and go to after embed in the ignition controller to wrap this inside in ambition Control. Right. We've been there. Mountain name this title this expand Favorable collapse Several people. Okay, and thin. You're gonna sign the you want to or because it's not so expandable controller like, so let's drive anything with you. Okay? And discuss Train it to full screen. So zero from all sides had poor constraints. Dragger table so and accurately reuse identified as cell like subtype type. Okay, now your turn for the uh huh. Put the spark back to been controller, and we are going to create e any up it unique are they leave you? I people now have been created data, and this is going to be foods in Reggie's type. How very which is empty initially. Imputed load. How are we gonna assign ourselves or then the gate and, uh, is those and we're also gonna say so. Don't Data is equal to send veggies dot to negligence, you know? Now, um, passing it on to do is, uh, you can hide, um, this the terror extra rules that always shows up. It's part of a table reporter. So they hide table view footer by saying they will you dot Able to interview is equal to empty live. You like them? Yeah. Now this first implement, these requirements are so let's expand exchange and extension Expandable. Do you feel you are table view? Delegate Your table, you dinosaurs and number off sections. I do. We gonna return. They got outcome. Okay, number off. Rose injection. Gonna saying, uh, basically return data section, start food items dot com No. And, uh, so for removal at an expat can say cell is in court. Temu being taught teach you de que self resent into fire as self. And, uh, I gotta say food, huh? Yeah. What? I don't. Well, Adam is equal to data index path dot section. So you get a position that food items and we need to get in expat dark for. So what happened for who died? Okay, Algo se sell dot A title or text labeled a text it equal to food item food item dot title. So that detail text Leland a text people to food item dot subtitle You sell that? You made bean image. If you go to food, item that image. Hey, there, don. This self. Okay, Now we also need, um the name off the section, sir. Table header. So it's title for header in section and then return data. Um, section dark Name like this one. Um, okay, but again, how we need to make your outlook is connected to the terrible and all right, so we have a change of start you So is going to dio Project Settings and Joel Tap It's electric spent Gualtiero expands to important our storyboard and run it again. All right, Once again, we I forgot basically to make this initial I better time to the charm. Cool. So we have two sections fruits and veggies cooked. So this ad, Theo, expand functionality expanded collapse was now functionality. So what will you do? Basically, first we gonna give are terrible our section height So height for header in section and because a return um 36 for this. Yeah. Ah, we turn, turn. All right, That's kid I'll be Are you can see, But are section high section header High pill increased Now let's give this Ah header a a new be so we can override the this matter you for header in section and you say, like label still gonna add in evil I accept you want people label doc text Now we have to use this hack basically showing the label or label is going to be right at the edge. And in order to make this appear like, in a little bit further, away from the edge can add or spaces and then in the state how data section got me. Okay. Can give label a text color takes color and, uh, cover natural white color, That's what want. And label that back on color. And it's going to be color literal are. And this time I'm gonna choose make some room here, and this time I'm gonna choose. I don't look. And, uh, pretty Yeah, maybe, Doctor. Now, how we gonna create a button? So but in physical to you, my button handing us a the type off the button is system. There's the button will begin and the functionality for collapse. So, yes, a basically, uh, button dot com color is equal to car patrol, and Selena sees this color or both. Okay, eso this low background color and, uh, that set title, um, color, um, is going to be color neutral white car, Not normal. Okay. And we also need button text. So for now, being an asset title Next do I, which is not gonna operate in the web But you will come back to that. And then we're gonna need but not had target, Basically, the function that's going to handle the tap. And, uh, let's create a function at opt. Say funk handle section couple from sender. Why? But, uh hi. Nothing is implemented there. So you can actually say telling me to south selected his hash selector. Um, handle how? Section total. And then evens are touch up inside. Yeah, So this is going to add 1000 to our button, and we cannot use buttoned up tight property on, and I'm gonna make it equal to section teacher. So basically, this is how we gonna know which sections button waas clicked. Now let's create a stack New and Vienna, um, basically stack you and we're gonna put these two controls inside to stack. You say you stopped you and arrange Stop. Use our enable comma button. Okay, stacking dot alignment is equal to dock fail, so it's gonna fill Langlands stack you dot Texas is equal to horizontal stack. You don't distribution is Dr Phil I like, and I'm gonna done the stack. Okay, so this way we have both of our views taking right amount of space, and we can actually add more controls as we lead into the stack. Me and they're evenly gonna distribute themselves within this sub you. So let's go ahead and run and see what you got so far. Okay, Cool. So you can see this awestruck mark so you can see it like this. Sort off. Very. But it will see tourists training. So this ad for space is at the end. I hope Apple comes back with a new weight, like, you know, just in these, But for now, you have to actually do this for, um I'll try to find any other alternative if I find I love think the video with that. But yeah, this is what we have. And, um, you can see it's, uh it's looking at cricket. We have a little bit of transparency coming on him, and he can see the fruits and hand the button was stolen, operated the moment. So, um, let's make that work. So what? What we want, basically, is, um, we want to, um, change her data source a pit and the way we're gonna change our dinner sorts is basically going to go to our troops in outcomes and Betty's class and gonna give it any property you say is expanded. Angina created as goalie in type and, uh, can say stop thought it's expanded is equal to truth, which means and test at the start, it's gonna be all expanded, like, fully basically open put under sections. And, uh, that is how about it Now, what's gonna happen? Basically, when we are in this section basically in the section better we have tapped down something we're going to check on the expand state. Okay, so in this function right here, we're gonna say, I think that fender Dr Egg. So I understand. Er, doc type visiting the button that has been clicked that day is you're gonna find the section number and is expanded, and I'm gonna say not data, um, sander dot tech that is expended. So basically were doubling that property. So whatever it is, you're gonna sign it opposite of that, then you can say table view that Oh, don't reload sections in the sections that we're gonna reload our center, that deg okay. And the animation is going to be automatic. All right, So when we are when we are actually showing this. Um, if we re running right now, all of this gonna do is basically toggle, thes, thes this property, but it's not gonna act upon it. So for that, what we need to do is number off sections Number of roads in section 31 actually update this part. And we're going to say if data section dot is expanded, so if it has expanded, then return the original count otherwise returned. Okay, this is a There are no roads to show if the expanding its false and, uh, that is going to the strike is going to make it look like it's collapsing is an expected. So let's click on that. And thats click on that David got. And as you can see, it's basically showing and hiding. Now, one thing that we need to do is, uh, this title I need to make this title as well. Like proper. So you say if data section section, um, stock is expanded, Okay, so then you can just for show hide. Otherwise, you can say show. Okay, Alice, when it one more time and speed in action. Okay, so oops. Shope and hide show hype. I think so All right, so, uh, so this is what it hope you guys enjoyed this'll It'll trick on. And this video, um and uh huh. Keep keep in sync and trying out these things. And I will be uploading some more. Some more videos. And until that time, thanks again for watching house, he goes extinct. 16. Advanced TableView: Refresh Control: Hello and welcome back. And today how we are going to be looking at this new ah technique with table views and we can be adding any fresh control. So you guys must have seen this, um, there if you tracked down on their views, you see a little animation going, and if you let it go in a few minutes, table updates itself with the new date. And this is ah, need technique. Basically, to show your users that there's new data available and they can actually just drank down and refresh debate with you wanted. Now, we're not example. We can keep adding these Teoh fruits back in the people. But in your case for in production environment, you can actually make the same thing. But new data that you might have gotten from the FBI or often service that you're using. Okay, so lets guests that it gets started in, huh? Build this. That's like shouting sound lyrically. And you group and I'm gonna call this group they will view with refresh. Okay. Okay. And what we need basically, is, uh, again, I'm gonna need in your file a story bore Strong board is going to be table you with fresh and a uh, could this class, um, table you brand with fresh, you see? Okay, Now, this, uh, drag out you controller and before I forget someone actually sign this class stable. You like this, um, less rapid inside a then mission controller and give it e. And I startled to show what, 20 minutes of people? Yeah, Fresh. All right, let's make this initially controller. Select, I think will be what's again, constrain it. Do floor scream How to sell. Subtitle You said in your cell Okay, I Let's go back. He started wanting this, so I am going to need hey, acting your clit. So had me up. Let we car people. Yeah, Why didn't you? And we're gonna need data. And despite to me, fruits and veggies, huh? Now, let's first build the basic thing we're and then we're gonna add refreshing tall. So? So that thing you got, delegate isn't stuff self doctor, will you? That s O says he felt itself so that data equal to troops and really start food items and reason. I actually do this this whole process over so I can make each with your independent and It doesn't matter which video you watch, how you're gonna get into an experience. So I hope you guys like that style is create an extension table view freshly seem and lighting overview. You like able do They're so And yes, a number of sections returns. They did not count. And there our rules in section return data fiction that food I don't start count sell for Boyton. Expat like cell. It's equal, Teoh. Thank you. And just to sell. So oh, let's create food item And this is going to be data index index path dot section dot full adults. Um, in expats dot rope. OK, so that's our food items. So they sell that text labeled our text look food items, that title. So that detail I won't hide in that. It's the pedal that he made beauty that is equal to him. I mean and returned this cell unwrapped. The last thing you need is a title far header in section and you say to return Data section Top name? Yeah, that's on it. Oh, um, make sure you're running the like one, So se do fresh stock storyboard. Yeah, on that Khost. Um So that air is because you need to sign this year. And the air ball was basically there is a mill that it encountered because we're we have created unwrapped outlet. I could not cast value two of you sell. Where is that? All right. Sticking out. What we have is a name of you fresh. That's training word. A different story. And this guy is connected to you and are this guy How? Yes, Singley. Oh, they move you refresh to have you with We're fresh. We see That's the problem. Okay. And, uh, you to make sure are Yeah, I felt that Stay with fresh and it's actually looking fine cope, So ah, for the professional, what we need to do is all the Davies come All things will use comes with is a refreshment role, that is No, there's just nothing there. So we need to do if we need to make it active. Now is we need to create in fresh control off herself so fresh You're fresh control and this is going to be you. I fresh control. Okay. And, uh, gonna initialize it here saying us here professional troll is equal to you. I Fresh control initialize it and then assert yourself. Starting with that refresh control is equal to refresh control. Okay, If I want it, as is right now, you're gonna see that we will get a can Imation a spinning animation and that how is your fresh? And this a fresh animation is never gonna go away. We have the handle events for lasted less at a target for the fresh control. So I'm gonna say fresh controlled on an tongue it and target itself. And let's create a function upsy function. Handle the fresh and, uh, begin to say here, hash selector, her and handle refresh for event type is value changed. Okay, now Oh, you do? Basically, in this in this handled in a fresh is, um we're gonna hide the fresh, basically end refreshing. And when I add you contact now, in order to mimic that we're making a service. I call and everything. I'm gonna create a two second of the way, so I'm gonna say, dispatch to you, but the doctor mean that they think after and we're gonna choose this deadline one and you're gonna say thought now plus dot Milly seconds and add two seconds. 2000 seconds, basically. And this is a block that month and under this block after two seconds would be onto his. You know, fresh control dot and refreshing must fall. And they say south our data, It says, you know, I got food items not offend a food. Yeah, I'm gonna actually I have a copy. This here. So the coffee at hope. Okay. And, uh, let's copy. I got se self dot data, you know dot Put it. I don't And and the hot let's add one more. So this ad elicit maybe peaches. Our strawberries is it was a different now they felt that data Here's to next stock food. I don't opened this. Yeah. Now let's hear from that. We are going to say so that they were looked at reload section. And since funeral trainings, serial sectioning, I say, you know, to the united section, which is a first section, and it could be okay. That's Robin it one more time. You take a look. All right? Yeah. OK, Whitman. And let's refresh read for two seconds and we have our new fruit showing up. Go. I cool. So this is the end off the studio and I hope you guys enjoyed this little trick with ease off refreshing your content with new content. Um, and I'll see you guys in the next video. Thanks again for watching. 17. Advanced TableView: Floating Button: Hello and welcome back. And today how we are going to be looking at this trick off. Then you are to show a floating button on the top off, do you? So if you know this, if I scroll up and down, um, the team only button this button actually stays there. It's like what we have you tube and compose icon for female lap and stuff like that s So this is what we are going to be building today. So let's get started. I'm gonna create a new cook. You're gonna call this his thinking better, People, do you think taking a table and let's copy this. And, uh uh, this could be a story part and create a covert Plus, do you see? Okay, Now let's move this on this recode. And now at a view controller and let's just be control inside. Irrigation controller, sticky button, table table, you and the same Really Is there going to be constrained? Full screen, you know, from all sites and had for constraints. And I have heard itself This is going to be off. So I didn't fire. Um, you control is going to be stinky. But to be Okay. All right. Give it show. Forget. Just make the change to stick with that material, all right? And so, like the type to be sometime. Okay, so now we're going to play. So we want to add a button. So this add a button and, uh, the way I want to enters, but is basically I won't add it right at the same level as there is seven. This added here. And if you notice is actually, it actually added it as a little stale. So someone that's gonna move it up, Okay. And, uh, this it just so button comes after the table, and this way weapon is going to show up a lot of time. And then, uh, we want to constrain this. But so the way How are we going to constrain this? But it is going to be, Yes, I like this. And take, say, little hat are going to be 50 50 cake, and it's going to be 10 points from left or trailing and 10 points from the but And those constraints? Hey, man, let's check out. So seems like Okay, One thing I don't understand. Why you sexually Sure. Together. So try to move it out. Can't see. Okay. Yeah. So that happens. Okay, this change of properties, because so gonna have for us, has it? It's just the trailing line trilling to save the area. So such safe can, Uh, okay, maybe I just making that. It's super weird. Okay, But since I care sexually taking negative values and negative from 10 complicity Yeah. Okay, so now I need to show him allergic. So the shot good for that is control command space. If he had that, you are going to see the window, Would you? Over. Plus, I got here. I see Right here. And this is news. Okay. Can make it to the good. Bigger size. Now, one thing that we wanna set is, um, said his background color. So that set the background color to be something like this that we saw a little bit transparent. And we can just transparency Well, it, like, more like 90%. Okay. No, you can make this button round, Justin storyboard. I mean, start gonna show up around strong board, but it will show up right here. See, if we can do is you can set user defined one time. It gives end these attributes Hung gets applying during the right time so you can say layer dark corner. Great. Yes. And it's a number type. And because our side is 50 you gonna give around radius size Estrin if I just have a back And it's a later taught max £2 to All right, So once we have the necklace, run it just to see what we have so far, we should show a sticky button right there, as you can see Come and go back to our T mobile and finished the year finished implementation. So it's gonna be a really simple one. So because it Ivy Applet week are table view Who I people for You clearly data okay. He had, um for item and fruits and veggies start food items. You're gonna take all items there even have been to do, um, data. So second proved guidance. You hear table you dot telling it is itself. They move. You don't Data source is equal to so. All right, let's clear the extension part to keep it until you see what table you delegate and your table. You Yes, I think what we need is two metres number off those section return data don't count. Sell for row. And today's pat A cell is equal to table view that take you three little sell, sell. And yes, a food I don't equal two data index past Don't cocoa. Okay, yes. Itself that text people that taste is equal. To who? Hiding that title himself out detail, Tex Text city called food item Don't. So, look, s l dot image viewed up image is equal to food and dot image and returned itself. So it's gonna be at i b outlet. That action. Okay, one more thing. We want to a self gonna connect our button to some sort of actions. If this is a profound performed some sort of, actually, you can say action Funk did tap on Ed button. And it's gonna be a sender, you white button. All right. And for now, we can just print message use That attempt on ad okay, has disconnect these actions. So, David, use connected to you and the tap on and put in the center is connected to Did you touch up inside off? What? Okay, let's run it. You check it out. Cool. So if you attack and see Adapt and you can scroll up and down and your partner sell better . Cool. So this this is it for this video. And I hope you guys enjoyed this. Um, help you guys. Yeah, liking these new tricks and, uh, using it for your naps. Please let me know if ever there any suggestions And, uh see you guys next video. Thank you. 18. Advanced TableView: Empty table message: Lohan. Look, Mac. And today how we are going to be looking at something, something new. And, uh, this one is to show empty messages basically on your table You when your data is loading. So we're gonna influence this example here. There's nothing in the table. Police fate and content appear. And wait a few seconds change Your table view is gonna get populated with the data. And the message goes, What? So this is, uh, you technique that we're gonna build today, So let's get started. I'm gonna create a new group. Cold it anti where they and to be head when you fell 24 in your flow core protest class. See table, you see? Okay. And let's create that cool. That's going to tell you that Cuban told her I have this Wii controller inside a Now he's controller. The title to this and tackle this come to be Yeah, empty table. You and make this hands hours starting the point and a sign. This guy class m t c. Okay. Fucking with them to is thing I look for you. Why people all right in the contract and drop you Are you gonna make it full screen. So covering the entire Yeah, like so And every gonna look for people gonna make it sit there. Um, it's going to be 10 points from each side. And, uh, it's gonna be, um, like, uh, not easy, husband one my excess, which is vertically. Okay, Now, this guy is also going to be center light, um, client CEO, and you're gonna say, Please wait. Content is being no date, no sighs a bit. Except so now you have this. Now, next thing we're gonna do is we're gonna try our table. New York. So it right here. But this team movie is not going to go inside. The view is going to go outside it. So table view, and then one of you is gonna come front off the view. Okay, Alice, like this to you and, uh, askew it full screen as well. Let's make sure the order your view goes behind that. They so it four the table. You okay? Now, we're gonna say you just sell. Gonna put the cell in there. You that any fire, the title And, uh, I guess, uh, set, um, gonna go in the back. Found on the beacon toner inside. Hi. And we mean access to a few ticks. We need access to our to our view, the main view and many Texas to our. So we're gonna create two outlets, so I be outlet week. You are no content for you. You live you and I've, er click require Sure. You You know why, people, You okay? And down here, you can say table. Do you got telling it physical to self table view that their sores in people to self table You talk, um, duck you And this is what we're gonna sign are no content. You too intensity will be dot footer table interview phrase equal to an empty you so we don't show anything there. All right, Now it's conformed to those sanctions. Those matters so empty. There you are. And yet hey. Hey. And, uh, gonna give it. Basically the data and data is going to be food. You're a Okay. Getting to know you gonna have a number of items. Rose. Interaction, return. Think return data out count. Okay. And, uh, so for you at the next batter is coming to be same thing. Let's sell or yeah, So there you go. to the table. But that dick you musical so? So that food item is equal to make some room here, you see data index path dark road dot Yeah, it about the roast duck takes tough texts. Easy for two. I'm not table, but detail text. You go to food, I'd dot table so dot image you got image is equal to not, And in return, this cell left. Okay, now, when we have that, we basically need a delay. So you do basically gonna delay? And this is where again you're gonna be making a service. I'd call and fetching some data, but in my case, or in this case, we are going to be using a delay load data with Do you play? Can you say que cut global? You mean define que os quote service to be this batch? Que os dot que os class dot Huh? And, um duck, you think after deadline is we don't know how less dark. Really. Seconds. Oh, five seconds. And gonna execute for item and fruits and veggies. Start full, Adams. Hey, it's done. The data dot happened contents off. No item. Dark food item, and then we're gonna dispatch main que Hey, think and say self table. Don't reload. Okay, now this connector outlets and give it a go. So are okay. Deal of you. Is this guy here? And no content you is to speak. Okay, if you would go. Uh All right. Um, so it was a Latin king created a bar. Also, we need to make sure that we have the correct starting point selected. Let's go. Basic content being loaded. And any seconds now you're gonna see off. I'm going to see it because we never call this method of se self that load. Like, let's call it again. Okay, Lets wait for five seconds and, uh, content beloved head. Boom. There you go. All right. So I hope you enjoyed on this video. And, uh, thanks again for watching, and I'll be coming up with new videos and you techniques with lead and keep updating the content. So stay tuned and, uh, thank you