自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(13)
  • 资源 (1)
  • 收藏
  • 关注

原创 [!] The dependency `AFNetworking (~> 3.1.0)` is not used in any concrete target. --------cocoapods引用

[!] The dependency AFNetworking (~> 3.1.0) is not used in any concrete target. ——–cocoapods引用第三方库失败 podFile 文件必须这样写 platform :ios, ‘7.0’ use_frameworks! target “pod1” do //pod1 项目名称 pod 'A

2016-06-27 19:55:27 251

原创 loaded the "XXXView" nib but the view outlet was not set 解决方案

loaded the “XXXView” nib but the view outlet was not set 解决方案 Files's Owner, 里面有个默认的IBOutlet变量view, 看一下后面有没有做关联,如果没有就拉到下面的View和视图做个关联

2016-06-27 19:54:33 668

原创 AccessibilityIdentifier

image 的 AccessibilityIdentifier 属性的使用accessibilityIdentifier属性相当于给image添加了一个标记.类似View的tag属性.

2016-06-27 19:52:52 433

原创 获取沙盒路径

NSArray *docPath = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES);NSLog(@"%@", [docPath firstObject]);NSArray *cache = NSSearchPathForDirectoriesInDomains(NSCachesDirec

2016-06-27 19:52:05 248

原创 MD5加密字符串,返回加密后的字符串

MD5加密字符串,返回加密后的字符串- (NSString *)getMd5WithString:(NSString *)string{ const char *cStr = [string UTF8String]; unsigned char digest[CC_MD5_DIGEST_LENGTH]; CC_MD5( cStr, (int)string.length, dig

2016-06-27 19:50:56 642

原创 用UIWebView来显示动态图片

用UIWebView来显示动态图片 //得到图片的路径NSString *path = [[NSBundle mainBundle]pathForResource:@"happy" ofType:@"gif"]; //将图片转为NSDataNSData *gifData = [NSData dataWithContentsOfFile:path]; //创建一个we

2016-06-27 19:48:59 315

原创 计算代码执行时间的方法

计算代码执行时间的方法方法一 NSDate *began = [NSDate date]; NSData *data = [NSData dataWithContentsOfURL:url]; NSDate *end = [NSDate date]; NSLog(@"%f",[end timeIntervalSinceDate:began]);方法二 CFTimeInterval began

2016-06-27 19:45:33 283

原创 计算Label的文本尺寸

计算Label的文本尺寸使用 NSString(NSStringDrawing) - (CGRect)boundingRectWithSize:(CGSize)size options:(NSStringDrawingOptions)options attributes:(NSDictionary *)attributes cont

2016-06-27 19:43:11 224

原创 NSDate使用

NSDate使用经常使用 NSDate *date = [NSDate date]; //获取当前时间(时区不是本地时区) - (id) initWithTimeInterval:(NSTimeInterval) secsToBeAdde sinceDate:(NSDate *) anotherDate; //相对于已知的某个时间点,增加一定秒数 - (id) initWithTimeInt

2016-06-27 19:39:41 197

原创 UICollectionView 视图滚动到指定位置的方法

UICollectionView 视图滚动到指定位置的方法 -(void)scrollToItemAtIndexPath:(NSIndexPath *)indexPath atScrollPosition:(UICollectionViewScrollPosition)scrollPosition animated:(BOOL)animated;

2016-06-27 19:37:34 9253

原创 加载JSON文件的方法

1.加载JSON文件 使用NSBundle加载json文件获取JSON文件的路径 根据路径生成NSData对象解析JOSN数据NSDictionary *dic = [NSJSONSerialization JSONObjectWithData:data options:NSJSONReadingAllowFragments error:nil];

2016-06-27 19:35:00 1093

原创 pch文件的设置

pch文件的设置 相对路径输入方法 $(SRCROOT)/项目名/文件名.pch 设置pch文件的路径

2016-06-27 19:28:14 274

原创 Object -c 单例模式

单例模式:(Singleton)类的对象只实例化一次,外界方便访问,提供共享数据,节约资源占用。要点:1.一个类只能实例化一次。2.必须自行实例化。3.必须向整个系统提供这个实例。使用方式举例://// main.m// 单例模式//// Created by lzq on 16/4/5.// Copyright © 201

2016-04-11 07:51:56 321

2万条中文近义词、同义词词库

2万条中文近义词、同义词词库,部分如下格式: {"name": "深远", "nearWords": ["深刻", "长久", "长远", "久远", "深入", "永远", "悠久", "远大", "深切"]}, {"name": "尺书", "nearWords": ["函件", "信件", "文书", "文牍", "尺牍", "信札", "书信"]}, {"name": "倡寮", "nearWords": ["妓院"]}, {"name": "混充", "nearWords": ["假冒", "冒充"]}, {"name": "遭到", "nearWords": ["受到"]} ```

2020-06-30

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除