gpt4 book ai didi

ios - 核心数据提取属性 - 基础

转载 作者:行者123 更新时间:2023-12-01 22:41:11 27 4
gpt4 key购买 nike

使用 Core Data Fetched Properties,我如何执行这个简单的请求:

我希望获取的属性 ( myFetchProp ) 存储 StoreA ,它应该这样做:

[myFetchProp getMeRecordWithPredicate:@“X == 35” inEntity:@“entityH” fromStore:StoreB];

原谅我的错误语法,但我想我的观点很容易理解。

我在网上找不到任何简单明了的例子。我想应该不会那么难。

最佳答案

由于我刚刚阅读了 Marcus S. Zarra 的 Core Data: Data Storage and Management for iOS, OS X, and iCloud (第 2 版)(见 herehere )让我引用它的主题:

In practice, I have found fetched properties to be less useful and less flexible than either creating a stored fetch request or building the fetch request in code. Usually when a situation calls for a fetched property, it tends to be easier to subclass the entity in question, perform an NSFetchRequest in code, and return the results.



因此,获取的属性可能很简单的假设可能是错误的。

关于ios - 核心数据提取属性 - 基础,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/28894809/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com