摘要: 1.将String转化为NSString再截取,代码如下: var s="1234567890"var ns1=(s as NSString).substringFromIndex(5)var ns2=(s as NSString).substringToIndex(4)var ns3=(s as ... 阅读全文
posted @ 2014-12-03 18:12 wuchunyang 阅读(755) 评论(0) 推荐(0) 编辑
摘要: 前几个步骤可参考这篇文章:http://www.cs.utexas.edu/~mitra/csSpring2011/cs327/cx_mac.html在进行到sudo python setup.py build 以及install的时候明明echo $ORACLE_HOME等这些环境变量都设置的,但... 阅读全文
posted @ 2014-12-02 16:28 wuchunyang 阅读(5022) 评论(1) 推荐(0) 编辑
摘要: AppDelegate: self.window = UIWindow(frame: UIScreen.mainScreen().bounds) self.window!.backgroundColor = UIColor.whiteColor() self... 阅读全文
posted @ 2014-11-19 14:18 wuchunyang 阅读(329) 评论(0) 推荐(0) 编辑
摘要: 代码如下import AVFoundationclass ViewController: UIViewController { var audioPlayer:AVAudioPlayer? override func viewDidLoad() { super.viewDi... 阅读全文
posted @ 2014-11-15 14:50 wuchunyang 阅读(404) 评论(0) 推荐(0) 编辑
摘要: button.layer.cornerRadius = 10 // 这个值根据你想要的效果可以更改button.clipsToBounds = true 阅读全文
posted @ 2014-11-15 14:48 wuchunyang 阅读(153) 评论(0) 推荐(0) 编辑