随笔分类 -  开源类

IOS开源类
摘要:一:AFNetworking的文件上传: 主要几个以下类似- (BOOL)appendPartWithFileURL:(NSURL *)fileURL name:(NSString *)name error:(NSError * __autoreleasing *)error;二:主要代码: //配置文件上传 //图片data 上传 //UIImage *upImage = [UIImage imageNamed:@"testImage.png"]; //NSData ... 阅读全文
posted @ 2013-12-25 22:02 cocoajin 阅读(7329) 评论(0) 推荐(0) 编辑
摘要:APP注册APNS流程http://mobiforge.com/design-development/programming-apple-push-notification-services服务器端口推送库php https://github.com/sebastianborggrewe/PHP-Apple-Push-Notification-Serverjava https://github.com/notnoop/java-apns 阅读全文
posted @ 2013-11-19 16:44 cocoajin 阅读(257) 评论(0) 推荐(0) 编辑
摘要:添加高德地图的一个错误has been modified since the precompiled header解决方案:xcode---product----clean 清理重新编译一下就可以了参考:http://stackoverflow.com/questions/14793329/fixing-file-project-pch-has-been-modified-since-the-precompiled-header-was-bui 阅读全文
posted @ 2013-11-12 16:05 cocoajin 阅读(195) 评论(0) 推荐(0) 编辑
摘要:一:所需类库 iOS-QR-Code-Encoder 官网主页:https://github.com/moqod/iOS-QR-Code-Encoder 导入:QuartzCore.framework二:使用流程导入libqrencode文件夹里的所有文件在使用的地方 导入#import "qrencode.h"添加如下生成代码://生成二维码:- (UIImage *)qrImageForString:(NSString *)string imageSize:(CGFloat)size { if (![string length]) { return nil; ... 阅读全文
posted @ 2013-11-11 15:50 cocoajin 阅读(2309) 评论(0) 推荐(0) 编辑
摘要:一:终端进入cd /usr/share/vim/二:sudo vim vimrc三:添加syntax enablesyntax on四:保存退出 阅读全文
posted @ 2013-08-27 12:04 cocoajin 阅读(410) 评论(0) 推荐(0) 编辑
摘要:一:使用 cocoaPod错误The platform of the target `Pods` (iOS 4.3) is not compatible with `AFNetworking (1.3.2)` which has a minimum requirement of OS X 10.7 - iOS 5.0.二:解决方案 打开项目中 Podfile 文件 修改其 iOS平台为对应平台 阅读全文
posted @ 2013-08-27 11:27 cocoajin 阅读(585) 评论(0) 推荐(0) 编辑
摘要:一、到http://regexkit.sourceforge.net/下载RegexKitLite类,添加到项目中;因为RegexKitLite使用ICU库,所以需要动态链接到/usr/lib/libicucore.dylib库当中去,否则你会得到13个错误。具体Dynamically linked to /usr/lib/libicucore.dylib方法如下1.进入菜单Project->Edit Project Settings2.在搜索框内输入linker搜索,找到”Other Linker Flags”选项。加入一个新的标签,名为-licucore。(这样可能更好:工程中添加l 阅读全文
posted @ 2013-08-17 13:36 cocoajin 阅读(408) 评论(0) 推荐(0) 编辑
摘要:PPRevealSideViewController 这是一个开源类;使用: 1:创建一个PPRevealSideViewController,UINavigationController对象; 2: 设置 self.window.rootViewController = slideViewController; 注:要先在-Prefix.pch 预编译文件里面 加上 #import "PPRevealSideViewController.h" 3: 在主页面导航上加一个 UIBarButtonItem 并设置回调方法 enterLeftNavication; 4: 在回调 阅读全文
posted @ 2013-05-17 21:56 cocoajin 阅读(603) 评论(0) 推荐(0) 编辑
摘要:#import <Foundation/Foundation.h> #import "JSONKit.h" int main (int argc, const char * argv[]) { NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init]; NSString *res = nil; /* * json格式编码 */ //字符串 NSString *str = @"this is a nsstring"; r... 阅读全文
posted @ 2013-05-16 21:49 cocoajin 阅读(229) 评论(0) 推荐(0) 编辑
摘要:1:JSON转XML---通常把JSON数据写到Plist文件即可;2:XML数据转JSON-- 使用开源类 XMLReader 先XML数据先转换为 NSDictionary 即可3: 开源类XMLReader 1 // 2 // XMLReader.h 3 // 4 // 5 /* 6 本类使用方法: 7 1:在使用的页面里面 导入本类 #import "XMLReader.h" 8 2: 调用XMLReader 的两个类方法 就可以了,就可以返回字典数据; 9 3:得到 NSDictionary数据,就是JSON 数据了;10 ... 阅读全文
posted @ 2013-05-16 20:19 cocoajin 阅读(683) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示