How to save NSMutableArray of NSValue in CoreData?
-
10-10-2019 - |
문제
I'm doing drawing app for ipad which need to save multiples of NSMutableArray of CGPoint (Converting into NSValue), suggest me for choosing coredata functions or any other approachs for saving more number of arrays
해결책
i found the answer for my question, 1. NSValue contain CGPoint values (CGPoint is C struct) for that first we have to do casting [NSValue valueWithCGPoint: anyCGPoint]; now we can save it into NSMutableArray. 2. To save a NSMutableArray into Coredata, first we have to convert it into NSSet. It will be done by one to many relationship in Coredata.
제휴하지 않습니다 StackOverflow