ManagedModels icon indicating copy to clipboard operation
ManagedModels copied to clipboard

A SwiftData like `@Model` infrastructure for CoreData.

Results 17 ManagedModels issues
Sort by recently updated
recently updated
newest added

This may have the necessary ingredients to implement this: https://fatbobman.com/en/posts/core-data-reform-achieving-elegant-concurrency-operations-like-swiftdata/

Hi @helje5 Thank you for quick solve previous issue I use [Tagged](https://github.com/pointfreeco/swift-tagged.git) Tagged structure also have Codable protocol realisation like RawValue type Example ``` struct AccessTokenTagged {} typealias AccessToken =...

bug
question

Looks like SwiftData flattens Codable structure into own table columns vs storing them as JSON. Presumably to be able to run queries against such. E.g. ```swift @Model class Person {...

Sharing a whole entity hasn't been the best idea. But pre-creating the metadata info slots should always be possible. Of course inverse relationships won't usually be set as that requires...

The Foundation `Predicate` is available in the open source Foundation. I think it requires iOS 17+ because it uses variadic generics. But that's not actually necessary for the SwiftData APIs...

enhancement

Some support for `NSOrderedSet` is prepared in the codebase, need to test this and check what actually works. A problem w/ `NSOrderedSet` is the lack of an associated type, i.e....

help wanted
question

SwiftData seems to have more options that it passes to the `ModelContainer`. No idea what CoreData supports here and how those things should be mapped. The related option types are...

enhancement
help wanted

Maybe that could be aliased to `@FetchRequest` and enhanced w/ `Predicate` support, if FR doesn't have that already?

enhancement
help wanted

The CoreData generator also generates such accessors for toMany properties: ```swift extension GroupOfItems { @objc(insertObject:inItemsAtIndex:) @NSManaged public func insertIntoItems(_ value: Item, at idx: Int) @objc(removeObjectFromItemsAtIndex:) @NSManaged public func removeFromItems(at idx:...

enhancement
help wanted

Most of the infrastructure is in place, the sole thing missing should be the extraction of the parameters from the model macro. E.g.: ```swift @Model(originalName: "OldName", versionHash: "2828287") class NewName:...

enhancement
help wanted