@interface ViewController (){ Shape *_shape;}@end@implementation ViewController- (void)loadView{ //设置画板 self.view=[[SimpleDrawBoard alloc]ini...
分类:
其他好文 时间:
2014-09-04 22:13:40
阅读次数:
245
1.密码判断
至少包含数字、字母(区分大小写)、符号中的2种
NSString *regex = @"^(?![A-Z]+$)(?![a-z]+$)(?!\\d+$)(?![\\W_]+$)\\S+$";
NSPredicate *predicate = [NSPredicate predicateWithFormat:@"self matches %@",re...
分类:
其他好文 时间:
2014-09-04 19:05:50
阅读次数:
210
不多解释,预防普通锁不正规的获取与释放#!/usr/bin/env python# -*- coding: utf-8 -*-import threadingimport timeclass MyThread(threading.Thread): def run(self): g...
分类:
编程语言 时间:
2014-09-04 19:00:19
阅读次数:
201
- (void)loadData { NSMutableArray *array = [NSMutableArray arrayWithCapacity:10]; if ([self.title isEqualToString:@"名字"]) { self.nameStr = inputT...
分类:
移动开发 时间:
2014-09-04 16:34:39
阅读次数:
179
如有错漏请不吝拍砖指正,转载请注明出处,很感谢 桌面便签软件是android上经常使用软件的一种,比方比較早的Sticky Note,就曾很流行,Sticky Note的介绍能够參见 http://www.tompda.com/c/article/11778/而实际上使用android平台对widg...
分类:
移动开发 时间:
2014-09-04 16:33:59
阅读次数:
345
抄自http://beyondvincent.com/blog/2014/03/17/five-tips-for-using-self-signed-ssl-certificates-with-ios/ios7以后,inhouse安装需要ssl了,一般用商用的,不想用商用的,就自己弄一个,通过ope...
分类:
移动开发 时间:
2014-09-04 14:40:09
阅读次数:
232
摘要:最近的手机市场很是让人亢奋,前段时间的小米4,近两天的魅族MX4,大肆宣传、热度持续的苹果iPhone6,还有昨晚的刚发布的三星 Galaxy Note 4和搭载曲面屏幕的 Galaxy Note Edge ,都在抢劫你的钱包。在昨晚的发布会上除了这两款新手机,三星还同时发布了同样有嘘头的智能手表 Gear S 和智能眼镜 Gear VR。
昨晚,三星在柏林、纽约和北京同时召开...
分类:
其他好文 时间:
2014-09-04 13:28:09
阅读次数:
246
首先重写UITableViewCell的初始化方法:- (id)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
if (...
分类:
移动开发 时间:
2014-09-04 09:46:27
阅读次数:
195
Given an array of integers, every element appearsthreetimes except for one. Find that single one.Note:Your algorithm should have a linear runtime comp...
分类:
其他好文 时间:
2014-09-03 21:03:57
阅读次数:
201
OC的self相当于C++里面的this吧。一般都是隐形的,就是不写出来的。其实就是自己的意思,谁调用就说的是谁,那么super呢?就是父类,谁调用那么就是谁的父类。...
分类:
其他好文 时间:
2014-09-03 16:49:07
阅读次数:
211