2010-10-22 64 views

回答

0

我找到了答案我的問題, 1. NSValue包含CGPoint值(CGPoint是C結構)首先我們必須做鑄造[NSValue valueWithCGPoint:anyCGPoint];現在我們可以將它保存到NSMutableArray中。 2.要將NSMutableArray保存到Coredata中,首先必須將其轉換爲NSSet。這將通過Coredata的一對多關係來完成。

+0

可以請提供關於您的「2」點的更多詳細信息。我也在尋找相同的方法。 – ajay 2012-04-03 03:46:03

+0

@ajay看看這些文章會很有用[link1](http://www.theappcodeblog.com/2011/09/29/iphone-app-development-tutorial-core-data-part-2-one -to-many-relationship /),[link2](http://stackoverflow.com/questions/5399195/where-can-i-find-a-good-example-of-a-core-data-to-many -關係) – theDebugger 2012-04-04 06:17:17