摘要:
ELYTAppDelegate.m#import "ELYTAppDelegate.h"@implementation ELYTAppDelegate@synthesize window = _window;- (void)dealloc{ [_window release]; [super dealloc];}- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions{ self.window = [[[UIWind 阅读全文
posted @ 2013-06-07 15:17
jason.android
阅读(156)
评论(0)
推荐(0)
摘要:
UserController.h#import @interface UserController : NSObject { int _id;}@property (nonatomic,assign) int _id;- (void) display;+ (id) defaultUserController:(int) _id;@endUserController.m#import "UserController.h"static UserController* singleInstance = nil;@implementation UserController@synt 阅读全文
posted @ 2013-06-07 14:52
jason.android
阅读(138)
评论(0)
推荐(0)
摘要:
main.m#import #import "Person.h"int main(int argc, const char * argv[]){ @autoreleasepool { //-----------第1种归档方式--------- //1.使用NSKeyedArchiver 归档对象到文件(对象序列化,持久化) NSArray* arrays = [[NSArray alloc]initWithObjects:@"111",@"222", nil]; NSStrin... 阅读全文
posted @ 2013-06-07 13:55
jason.android
阅读(113)
评论(0)
推荐(0)
摘要:
#import int main(int argc, const char * argv[]){ @autoreleasepool { NSMutableArray* arr1 = [[NSMutableArray alloc] initWithObjects:@"1",@"2",@"3",@"4",@"5", nil]; //使用retain得到对象所有权,arr1的引用计数加1后为2 NSMutableArray* arr2 = [arr1 retain]; NSLog(@"arr 阅读全文
posted @ 2013-06-07 11:59
jason.android
阅读(119)
评论(0)
推荐(0)

浙公网安备 33010602011771号