You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Feb 28, 2020. It is now read-only.
Hello, I am trying to migrate our project from version 5.2 to 6.0.1 and I am encountering some problems. Below is current code
import AlecrimCoreData
import CoreData
import CoreLocation
open class AbstractCoordinateCD: NSManagedObject {
@NSManaged open var latitude: CLLocationDegrees
@NSManaged open var longitude: CLLocationDegrees
}
// MARK: - AbstractCoordinateCD query attributes
extension AbstractCoordinateCD {
static let latitude = AlecrimCoreData.Attribute<CLLocationDegrees>("latitude")
static let longitude = AlecrimCoreData.Attribute<CLLocationDegrees>("longitude")
}
// MARK: - AttributeProtocol extensions
extension AlecrimCoreData.AttributeProtocol where Self.ValueType: AbstractCoordinateCD {
var latitude: AlecrimCoreData.Attribute<CLLocationDegrees> { return AlecrimCoreData.Attribute<CLLocationDegrees>("latitude", self) }
var longitude: AlecrimCoreData.Attribute<CLLocationDegrees> { return AlecrimCoreData.Attribute<CLLocationDegrees>("longitude", self) }
}
extension AlecrimCoreData.TableProtocol where Self.Element: AbstractCoordinateCD {
func create(_ coordinate: CLLocationCoordinate2D) -> Self.Element {
let retValue = create()
retValue.latitude = coordinate.latitude
retValue.longitude = coordinate.longitude
return retValue
}
}
extension AbstractCoordinateCD {
var coordinate: CLLocationCoordinate2D {
return CLLocationCoordinate2D(latitude: latitude, longitude: longitude)
}
}
In version 6.0.1 there is no AlecrimCoreData.Attribute, AlecrimCoreData.AttributeProtocol, AlecrimCoreData.TableProtocol ... maybe I am blind, but I don't find any alternatives in 6.0.1 version.
Can somebody help me please?
The text was updated successfully, but these errors were encountered:
As in README: "In version 6 the framework was rewritten from scratch. AlecrimCoreData now uses key paths and it does not rely on generated (or written) custom attributes anymore. Also the ACDGen utility is no more. If your code depends on this, please use the previous versions."
I would like to resume library support, but for professional and personal reasons, it's just not been possible. If anyone else can help with this issue (and others), it would be nice.
Thank you.
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Hello, I am trying to migrate our project from version 5.2 to 6.0.1 and I am encountering some problems. Below is current code
In version 6.0.1 there is no AlecrimCoreData.Attribute, AlecrimCoreData.AttributeProtocol, AlecrimCoreData.TableProtocol ... maybe I am blind, but I don't find any alternatives in 6.0.1 version.
Can somebody help me please?
The text was updated successfully, but these errors were encountered: