This repository has been archived by the owner on Mar 24, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 85
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use PCKMethodRedirector in Foundation and UIKit
Projects reference Support project via User Search Paths then in Project Dependencies and Link Binary With Libraries. Since both FoundationCore and FoundationSpecHelper need SupportCore, FoundationSpecHelper now depends on FoundationCore which in turn depends on SupportCore. This is to get around a duplicate symbol error when creating and linking the static libraries.
- Loading branch information
Joe Masilotti
committed
Feb 25, 2015
1 parent
d309be2
commit 70dd18f
Showing
20 changed files
with
723 additions
and
348 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
...ocation/CoreLocation.xcodeproj/xcshareddata/xcschemes/CoreLocation-StaticLibSpec.xcscheme
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,14 @@ | ||
#import "NSObject+MethodDecoration.h" | ||
#import "NSObject+MethodRedirection.h" | ||
#import "PCKMethodRedirector.h" | ||
#import "objc/runtime.h" | ||
|
||
@implementation NSObject (MethodDecoration) | ||
|
||
+ (void)decorateMethod:(NSString *)methodName with:(NSString *)decoration { | ||
[self redirectSelector:NSSelectorFromString(methodName) | ||
to:NSSelectorFromString([NSString stringWithFormat:@"%@With%@", methodName, [decoration capitalizedString]]) | ||
andRenameItTo:NSSelectorFromString([NSString stringWithFormat:@"%@Without%@", methodName, [decoration capitalizedString]])]; | ||
[PCKMethodRedirector redirectSelector:NSSelectorFromString(methodName) | ||
forClass:self | ||
to:NSSelectorFromString([NSString stringWithFormat:@"%@With%@", methodName, [decoration capitalizedString]]) | ||
andRenameItTo:NSSelectorFromString([NSString stringWithFormat:@"%@Without%@", methodName, [decoration capitalizedString]])]; | ||
} | ||
|
||
@end |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.