등의 방법을 통과, 그래서 끝이 실행될 때 호출하는 방법을 알고있다. 가능한가? @Daniel 댓글에서 언급 한 바와 같이XCODE는 매개 변수
[self bringJSON:(NSString *)_passedValua:(NSObject *)anotherMethod];
등의 방법을 통과, 그래서 끝이 실행될 때 호출하는 방법을 알고있다. 가능한가? @Daniel 댓글에서 언급 한 바와 같이XCODE는 매개 변수
[self bringJSON:(NSString *)_passedValua:(NSObject *)anotherMethod];
당신은 그것에 대해 selector를 사용할 수 있습니다. 기본 구성표는 다음과 같습니다 :
// Method declaration - method accept selector as parameter
- (void) bringJSON:(NSString *)_passedValua toMethod:(SEL)anotherMethod];
// Method call - create selector from method name (mind the colon in selector - it is required if your method takes 1 parameter)
[self bringJSON:jsonString toMethod:@selector(methodName:)];
// Implementation
- (void) bringJSON:(NSString *)_passedValua toMethod:(SEL)anotherMethod]{
...
if ([target respondsToSelector:anotherMethod])
[target performSelector:anotherMethod withObject:_passedValua];
}
선택기를 사용해 보셨습니까? – Daniel
AFAIK 불가능합니다 – Lefteris