Core Data Mac OS X 基于文档的应用程序中的 NSArrayController 类与实体模式

发布于 2024-09-19 19:07:03 字数 207 浏览 1 评论 0原文

任何人都可以解释 NSArrayContoller 模式(类/实体}之间的实践差异吗?

我只是在基于文档的 Core Data 桌面应用程序中面临一些调试问题(对我的所有控制器使用实体模式)。

我的数据库结构变得非常复杂,需要如此我花了很多时间来查找错误的绑定(输入错误的键路径等)。

如果我将所有控制器切换到类模式,这会对跟踪绑定错误产生任何影响吗?

Can anyone explain differences in practise between NSArrayContoller modes (Class / Entity}?

I am just facing some debugging issues in my document based Core Data desktop application (using Entity mode for all my controllers).

My database structure became quite complicated and it takes so much time to find wrong bindings (mistyped key-paths, etc..). I have also generated classes for each entity in my data model.

Would it make any difference in tracking binding mistakes if I switched all my controllers to the Class mode?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

梦行七里 2024-09-26 19:07:03

实体用于阵列包含 Core Data 托管对象的阵列控制器。

类适用于数组包含普通(非托管)对象的数组控制器。

因此,不,将保存托管对象的阵列控制器切换到非托管对象模式不会有帮助。

我的数据库结构变得非常复杂,需要花费很多时间才能找到错误的绑定(输入错误的键路径等......)。

您应该在调试器控制台中得到有关该问题的异常。

Entity is for array controllers whose arrays contain Core Data managed objects.

Class is for array controllers whose arrays contain plain (not managed) objects.

So, no, switching an array controller that holds managed objects over to the unmanaged-object mode will not help.

My database structure became quite complicated and it takes so much time to find wrong bindings (mistyped key-paths, etc..).

You should get an exception about that in the Debugger Console.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文