会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
开发工程师
博客园
首页
新随笔
联系
管理
订阅
上一页
1
2
3
4
下一页
2017年2月27日
iOS图片设置圆角
摘要: //图片压缩
阅读全文
posted @ 2017-02-27 09:33 福泽小院
阅读(169)
评论(0)
推荐(0)
2017年2月23日
iOS 时间戳转时间
摘要: 1 +(NSString*)getTimeFromTimeStamp:(NSString*)dateStamp 2 { 3 4 NSDate *confromTimesp = [NSDate dateWithTimeIntervalSince1970:dateStamp.floatValue]; 5 NSDateFormatter *formatter = [[NSD...
阅读全文
posted @ 2017-02-23 11:41 福泽小院
阅读(128)
评论(0)
推荐(0)
iOS 时间转时间戳
摘要: 1 +(NSString*)getTimeStamp:(NSDate*)dateNow 2 { 3 4 NSTimeInterval time = [dateNow timeIntervalSince1970]*1000;//NSTimeInterval本身是个秒级别的double类型数值,小数点后面即毫秒数,*1000.0f即可得到毫秒级别的时间差 5 long long d...
阅读全文
posted @ 2017-02-23 11:41 福泽小院
阅读(173)
评论(0)
推荐(0)
2017年2月22日
iOS loading等待图
摘要: 1 #import "HXCActivity.h" 2 #define Activity_WIDTH 40.f 3 #define Activity_HEIGHT 40.f 4 5 static UIWebView *_gifView; 6 static UIWindow *window; 7 static UIView *showview; 8 @interface HXCA...
阅读全文
posted @ 2017-02-22 13:51 福泽小院
阅读(1190)
评论(0)
推荐(0)
iOS简便写法
摘要: @是一种简便写法 1. 6不是一个对象,加个@6会转化成对象,等同于[NSNumber numberWithInt:5], 2.@[@"1",@"2",@"3"],代表数组 3.@{@"key":@"1"},代表字典 字典的另一种写法:(装逼的写法,post请求的时候来使用)
阅读全文
posted @ 2017-02-22 10:07 福泽小院
阅读(239)
评论(0)
推荐(0)
2017年2月21日
iOS判断UITableView的滑动方向
摘要: 1 -(void)scrollViewWillBeginDragging:(UIScrollView*)scrollView{ 2 lastContentOffset = scrollView.contentOffset.y; 3 } 4 -( void )scrollViewDidScroll:( UIScrollView *)scrollView { 5 ...
阅读全文
posted @ 2017-02-21 10:08 福泽小院
阅读(1794)
评论(0)
推荐(0)
iOS常用宏定义
摘要: #define RGBCOLOR(r,g,b) [UIColor colorWithRed:(r)/255.0 green:(g)/255.0 blue:(b)/255.0 alpha:1] #define RGBACOLOR(r,g,b,a) [UIColor colorWithRed:(r)/2
阅读全文
posted @ 2017-02-21 09:12 福泽小院
阅读(208)
评论(0)
推荐(0)
2017年2月20日
iOS sha1加密算法
摘要: 1 //sha1加密方式 2 +(NSString *)sha1:(NSString *)input 3 { 4 //const char *cstr = [input cStringUsingEncoding:NSUTF8StringEncoding]; 5 //NSData *data = [NSData dataWithBytes:cstr length:inpu...
阅读全文
posted @ 2017-02-20 09:08 福泽小院
阅读(327)
评论(0)
推荐(0)
iOS MD5加密算法
摘要: 1 //MD5加密 2 + (NSString *)md5HexDigest:(NSString*)password 3 { 4 const char *original_str = [password UTF8String]; 5 unsigned char result[CC_MD5_DIGEST_LENGTH]; 6 CC_MD5(original_str, ...
阅读全文
posted @ 2017-02-20 09:08 福泽小院
阅读(139)
评论(0)
推荐(0)
2017年2月17日
iOS 判断网络是否连接
摘要: 1 //判断网络是否连接 2 + (BOOL) connectedToNetwork 3 { 4 //创建零地址,0.0.0.0的地址表示查询本机的网络连接状态 5 struct sockaddr_in zeroAddress; //struct用来向方法中传递复杂的参数(把参数当作对象,这样便于扩展) 6 bzero(&zeroAddr...
阅读全文
posted @ 2017-02-17 09:29 福泽小院
阅读(617)
评论(0)
推荐(0)
上一页
1
2
3
4
下一页
公告