应用CocoaPods管理iOS的依赖库关系
就像Java有Maven,nodejs有npm一样,ios也有自己的库依赖管理工具:CocoaPods。
Read on →就像Java有Maven,nodejs有npm一样,ios也有自己的库依赖管理工具:CocoaPods。
Read on →ios通过NSURLSession进行网络请求,参考另一篇博客ios进行网络请求。
在开发阶段,server端我们会用self-signed证书(省钱啊!)。正因为不是第三方机构认证的证书,所以客户端都会报警告。我们需要对此进行处理(参考NSURLSession in Apple Tech Note和How do I accept a self-signed SSL certificate using iOS 7’s NSURLSession and its family of delegate methods for development purposes?):
Read on →服务器端利用Nodejs创建https的Server,请参考Nodejs创建HTTPS服务器
Read on →摘录在此,备忘。
HTTPS其实是有两部分组成:HTTP + SSL / TLS,也就是在HTTP上又加了一层处理加密信息的模块。服务端和客户端的信息传输都会通过TLS进行加密,所以传输的数据都是加密后的数据。
具体的加密过程看下图:
Read on →参考:Is there any way to enforce typing on NSArray, NSMutableArray, etc.?
随着Xcode7的发布,苹果实现了collection类(NSArray,NSDictionary,NSSet)的generics功能。
Read on →这一段时间,在对自己不是很了解的代码进行重构,重新了解了一下Property、Instance Variable和@synthesize,总结一下。
首先需要明白一点:Property和@synthesize是让编译器帮助我们做一些规律性的工作。
如果没有Property,我们可以这样实现Instance Variable的accessor(getter和setter),示例代码如下:
Read on →参考:
摘要:
AutoSizing和AutoLayout都是用来自动确定试图大小和位置的方法,区别在于:
Package Control是Sublime中用于插件管理的工具。安装之后,其它插件基本上可以通过它进行管理:安装、删除、禁用等。
参考Node.js for Beginners. 去除以下代码:
1 2 3 |
|
为什么需要在命令行进行文件和文件夹的操作:
Read on →在iOS中有三类事件:
这里要讨论的是触控事件的机制。
iOS中主要有两种触控事件:
For basic configuration of octopress blog, go to official site for references.
After updating OS to EI Caption (10.11), there is some bugs when we run rake preview
. You need to update your ruby version, and reinstall dependencies of octopress.
Refer to Errno::ENOENT: No Such File or Directory - Jekyll ~ Octopress and El Capitan post for more details.
If you can still not update your ruby version using the way in the above post, try the following commands (Refer to Using Rbenv to Manage Multiple Versions of Ruby for more details.) before install new ruby version:
1 2 |
|
1
|
|
Go to here to choose the theme you like. Personally, I like the boldandblue theme. It is simple and elegant.
Read on →Use shortcut to improve productivity while using Chrome.
A full page is on Chrome helper:
I will list some common used ones here by myself.
Read on →Compiler Warnings for Objective-C Developers is a good post for describing warning messages for Objective-C in xcode. A Chinese version can be found 谈谈Objective-C的警告.
Some important things are marked here.
Two ways to modify complier’s warning setting: UI Method and Custom Compiler Flags Method.
Read on →