斯坦福大学公开课

来源:互联网 发布:php分前后端吗 编辑:程序博客网 时间:2024/04/27 14:09

回家在下,搜到了一个地址,貌似到ituns下载搜索也可以,这个是电驴的地址

http://www.ed2000.com/ShowFile.asp?FileID=270791


1. MVC and Introduction to Objective-C (September 27, 2011)
2. My First iOS App (September 29, 2011)
3. Objective-C (October 4, 2011)
4. Views (October 6, 2011)
5. Protocols and Gestures (October 11, 2011)
6. Multiple MVCs and Segues (October 13, 2011)
7. iPad Apps (October 18, 2011)
8. Controller Lifecycle & Image/Scroll/WebViews (October 20, 2011)
9. Table Views (October 25, 2011)
10. Blocks and Multithreading (October 27, 2011)
11. Core Location and MapKit (November 1, 2011)
12. Persistence (November 3, 2011)
13. Core Data (November 8, 2011)
14. Core Data Demo (November 10, 2011)
15. Modal View Controller/Test/Animation/Timer (November 15, 2011)
16. Action Sheets, Image Picker, Core Motion (November 17, 2011)
17. iCloud (November 29, 2011)
18. iCloud Demo (December 1, 2011)
19. Automated Testing (December 6, 2011)

看来这些是基本知识,必须掌握,后面的章节,我看书也可以的


想想现在看这个公开课视频,是不是可以都听懂了啊,打开链接一看,发现一共有10集,挺好的。

内容已经是ios5了,挺好的。

1.翻译还是一如既往的坑爹啊,

刚刚看完了第一集,这个白胡子对mvc的讲解还是比较深入的,我疑惑的是,我看中文呢,还是看英文。

看中文的话,能一下子理解,但是翻译坑爹啊

看英文的话,一下子理解不了啊,字也不是很清楚,算了,还是看英文吧。

内容大概就是分层啊,mvc啊,objc的基本简单语法之类的,俺都懂的。

http://v.163.com/movie/2011/11/U/O/M807AH0S5_M807F04UO.html

2.延迟实例化,不到最后一秒,不实例化。不在构造函数当中实例化,但是,

但是自动生成的事这样的,这里面没有初始化value啊

- (void)setValue: (id)newValue{    if (value != newValue)    {        [value release];        value = newValue;        [value retain];    }}
这是怎么回事啊?为什么不在里面加上

if(Value==nil) value=[[id alloc] init];

额,还是没搞透啊,没搞透,不过这种看着他一点点把代码写出来,进步应该很快的。

答案:是放在getter里面。

明天还要好好看看,真心觉得讲得不错,不光是在讲语法,还在讲编程思想,习惯之类的。

第二集视频观后感:

视频2,
问题1:布尔值的默认值,为什么会是0;
 BOOL test;
    NSLog(@"test:%i",test);


/Users/weichao/Developer/Stanford/Claculator/Claculator/ClaculatorViewController.m:44:22: Variable 'test' is uninitialized when used here


妈的,我怎么发现ios6里面的,页面布局,autolayout,也给变掉了,幸好我本来就不怎么会。


lazy instantiation:
wait until the last second to instantiate something that you need


very common in IOS,我竟然不知道,算了,这不是知道了嘛。
1.疑惑还是搞不清楚什么时候用strong,什么时候用weak
2.那个一下子就把两个方法加到头文件里面的那个工具,不大会用
3.lazy instantiation
4.getter里面默认生成的是什么样子的。
5.我平时都把m层的事情放到c层里面干了。

6.两个窗口很好用
7,拖拽可以少些很多代码,很方便


视屏3:
1.is for safety and sub-classability of our instance variables 
if we are going to allow someone to subclass it,
then if they are going to start muting with our instance variables
2.heap and  stack difference ,?

原创粉丝点击