mirror of
https://github.com/zhigang1992/RestKit.git
synced 2026-05-04 20:41:18 +08:00
Renamed Polymorphic mapping to dynamic mapping after consulting with the community. Dropped abstract superclass in favor of a RKObjectMappingDefinition protocol. Caught missing cases with dynamic object mapping + targetObject. Updated docs and method signatures to reflect the updates.
This commit is contained in:
@@ -10,6 +10,10 @@
|
||||
|
||||
@implementation RKObjectMappingProvider
|
||||
|
||||
+ (RKObjectMappingProvider*)mappingProvider {
|
||||
return [[self new] autorelease];
|
||||
}
|
||||
|
||||
- (id)init {
|
||||
if ((self = [super init])) {
|
||||
_objectMappings = [NSMutableArray new];
|
||||
@@ -30,7 +34,7 @@
|
||||
[_mappingsByKeyPath setValue:mapping forKey:keyPath];
|
||||
}
|
||||
|
||||
- (RKObjectAbstractMapping*)mappingForKeyPath:(NSString*)keyPath {
|
||||
- (id<RKObjectMappingDefinition>)mappingForKeyPath:(NSString*)keyPath {
|
||||
return [_mappingsByKeyPath objectForKey:keyPath];
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user