mirror of
https://github.com/zhigang1992/RestKit.git
synced 2026-04-01 22:42:51 +08:00
* Removed RestKit from inheritance hierarchy * Mappings are implemented as concrete classes * Mapper is much more flexible & powerful * Much more robust error handling * Serialization is reimplemented as an object mapping operation * Added ability to serialize to JSON natively * Reworked Core Data integration * Simplified the codebase substantially
26 lines
668 B
Objective-C
26 lines
668 B
Objective-C
//
|
|
// RKObjectElementMapping.h
|
|
// RestKit
|
|
//
|
|
// Created by Blake Watters on 4/30/11.
|
|
// Copyright 2011 Two Toasters. All rights reserved.
|
|
//
|
|
|
|
#import <Foundation/Foundation.h>
|
|
|
|
// Defines the rules for mapping a particular element
|
|
@interface RKObjectAttributeMapping : NSObject {
|
|
NSString* _sourceKeyPath;
|
|
NSString* _destinationKeyPath;
|
|
}
|
|
|
|
@property (nonatomic, retain) NSString* sourceKeyPath;
|
|
@property (nonatomic, retain) NSString* destinationKeyPath;
|
|
|
|
/**
|
|
Defines a mapping from one keyPath to another within an object mapping
|
|
*/
|
|
+ (RKObjectAttributeMapping*)mappingFromKeyPath:(NSString*)sourceKeyPath toKeyPath:(NSString*)destinationKeyPath;
|
|
|
|
@end
|