Files
mowesta/ios-app/CDevice+CoreDataClass.swift
T
pobel 592fa34706
LocationBasedServices/mowesta/feature%2Fios%2Fmeasurements This commit looks good
adding features more requests for measurement
2020-02-03 11:12:37 +01:00

29 lines
736 B
Swift

//
// CDevice+CoreDataClass.swift
// app
//
// Created by Sebastian Pobel on 01.02.20.
// Copyright © 2020 Marcus Handte. All rights reserved.
//
//
import Foundation
import CoreData
import MowestaApi
@objc(CDevice)
public class CDevice: NSManagedObject {
convenience init(context: NSManagedObjectContext, device: Device) {
self.init(context: context)
self.id = device._id!
self.creationTime = device.creationTime ?? -1000
self.device = device.device
self.manufacturer = device.manufacturer
self.markedDeleted = device.deleted ?? false
self.model = device.model
self.modificationTime = device.modificationTime ?? -1000
self.os = device.os.name
}
}