New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Map properties to multiple JSON key paths #270
Conversation
- (NSDictionary *)JSONDictionary __attribute((deprecated("Replaced by -serializeToJSONDictionary:"))); | ||
- (NSDictionary *)JSONDictionary __attribute__((deprecated("Replaced by -serializeToJSONDictionary:"))); | ||
|
||
- (NSString *)JSONKeyPathForPropertyKey:(NSString *)key __attribute__((unavailable("Replaced by -JSONKeyPathsByPropertyKey"))); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@paulyoung This may be relevant to #264
// Returns a dictionary mapping property keys to JSON key paths (as strings) or | ||
// NSNull values. | ||
// Returns a dictionary mapping property keys to one or multiple JSON key paths | ||
// (as strings or arrays of strings). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since this is getting more complicated, can you document an example on this method?
Can you add a test for associating multiple JSON key paths with multiple components to one property, as well? |
Let me know what you think of this example |
// Any keys omitted will not participate in JSON serialization. | ||
// | ||
// Returns a dictionary mapping property keys to JSON key paths (as strings) or | ||
// NSNull values. | ||
// For example: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be titled "Examples" per TomDoc style.
🚈 |
🚄 |
🚋 |
Map properties to multiple JSON key paths
Fixes #263