调用方法
[object method]; [object methodWithInput:input]; output = [object methodWithOutput]; output = [object methodWithInputAndOutput:input]; id myObject = [NSString string]; NSString* myString = [NSString string];
嵌套消息
function1 ( function2() ); [NSString stringWithFormat:[prefs format]];
多个输入參数的方法
-(BOOL)writeToFile:(NSString *)path atomically:(BOOL)useAuxiliaryFile; BOOL result = [myData writeToFile:@"/tmp/log.txt"atomically:NO];
原文:learn_objective_C part
1
原文:http://www.cnblogs.com/gcczhongduan/p/4822354.html