removed unused initalizers in some core data classes
This commit is contained in:
parent
259f03a98b
commit
c30f59cf51
|
@ -21,20 +21,6 @@ public class Atom: NSManagedObject {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// create Atom
|
|
||||||
/// - parameters:
|
|
||||||
init(address: String, name: String, alias: String?, sensorSerialNumber: String?, webOOPEnabled: Bool, nsManagedObjectContext:NSManagedObjectContext) {
|
|
||||||
|
|
||||||
let entity = NSEntityDescription.entity(forEntityName: "Atom", in: nsManagedObjectContext)!
|
|
||||||
|
|
||||||
super.init(entity: entity, insertInto: nsManagedObjectContext)
|
|
||||||
|
|
||||||
blePeripheral = BLEPeripheral(address: address, name: name, alias: nil, bluetoothPeripheralType: .AtomType, nsManagedObjectContext: nsManagedObjectContext)
|
|
||||||
|
|
||||||
blePeripheral.webOOPEnabled = webOOPEnabled
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
private override init(entity: NSEntityDescription, insertInto context: NSManagedObjectContext?) {
|
private override init(entity: NSEntityDescription, insertInto context: NSManagedObjectContext?) {
|
||||||
super.init(entity: entity, insertInto: context)
|
super.init(entity: entity, insertInto: context)
|
||||||
}
|
}
|
||||||
|
|
|
@ -18,20 +18,6 @@ public class Blucon: NSManagedObject {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// create Blucon
|
|
||||||
/// - parameters:
|
|
||||||
init(address: String, name: String, alias: String?, sensorSerialNumber: String?, webOOPEnabled: Bool, nsManagedObjectContext:NSManagedObjectContext) {
|
|
||||||
|
|
||||||
let entity = NSEntityDescription.entity(forEntityName: "Blucon", in: nsManagedObjectContext)!
|
|
||||||
|
|
||||||
super.init(entity: entity, insertInto: nsManagedObjectContext)
|
|
||||||
|
|
||||||
blePeripheral = BLEPeripheral(address: address, name: name, alias: nil, bluetoothPeripheralType: .BluconType, nsManagedObjectContext: nsManagedObjectContext)
|
|
||||||
|
|
||||||
blePeripheral.webOOPEnabled = webOOPEnabled
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
private override init(entity: NSEntityDescription, insertInto context: NSManagedObjectContext?) {
|
private override init(entity: NSEntityDescription, insertInto context: NSManagedObjectContext?) {
|
||||||
super.init(entity: entity, insertInto: context)
|
super.init(entity: entity, insertInto: context)
|
||||||
}
|
}
|
||||||
|
|
|
@ -21,20 +21,6 @@ public class Bubble: NSManagedObject {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// create Bubble
|
|
||||||
/// - parameters:
|
|
||||||
init(address: String, name: String, alias: String?, sensorSerialNumber: String?, webOOPEnabled: Bool, nsManagedObjectContext:NSManagedObjectContext) {
|
|
||||||
|
|
||||||
let entity = NSEntityDescription.entity(forEntityName: "Bubble", in: nsManagedObjectContext)!
|
|
||||||
|
|
||||||
super.init(entity: entity, insertInto: nsManagedObjectContext)
|
|
||||||
|
|
||||||
blePeripheral = BLEPeripheral(address: address, name: name, alias: nil, bluetoothPeripheralType: .BubbleType, nsManagedObjectContext: nsManagedObjectContext)
|
|
||||||
|
|
||||||
blePeripheral.webOOPEnabled = webOOPEnabled
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
private override init(entity: NSEntityDescription, insertInto context: NSManagedObjectContext?) {
|
private override init(entity: NSEntityDescription, insertInto context: NSManagedObjectContext?) {
|
||||||
super.init(entity: entity, insertInto: context)
|
super.init(entity: entity, insertInto: context)
|
||||||
}
|
}
|
||||||
|
|
|
@ -18,20 +18,6 @@ public class Libre2: NSManagedObject {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// create Libre2
|
|
||||||
/// - parameters:
|
|
||||||
init(address: String, name: String, alias: String?, sensorSerialNumber: String?, webOOPEnabled: Bool, nsManagedObjectContext:NSManagedObjectContext) {
|
|
||||||
|
|
||||||
let entity = NSEntityDescription.entity(forEntityName: "Libre2", in: nsManagedObjectContext)!
|
|
||||||
|
|
||||||
super.init(entity: entity, insertInto: nsManagedObjectContext)
|
|
||||||
|
|
||||||
blePeripheral = BLEPeripheral(address: address, name: name, alias: nil, bluetoothPeripheralType: .Libre2Type, nsManagedObjectContext: nsManagedObjectContext)
|
|
||||||
|
|
||||||
blePeripheral.webOOPEnabled = webOOPEnabled
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
private override init(entity: NSEntityDescription, insertInto context: NSManagedObjectContext?) {
|
private override init(entity: NSEntityDescription, insertInto context: NSManagedObjectContext?) {
|
||||||
super.init(entity: entity, insertInto: context)
|
super.init(entity: entity, insertInto: context)
|
||||||
}
|
}
|
||||||
|
|
|
@ -21,20 +21,6 @@ public class MiaoMiao: NSManagedObject {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// create MiaoMiao
|
|
||||||
/// - parameters:
|
|
||||||
init(address: String, name: String, alias: String?, sensorSerialNumber: String?, webOOPEnabled: Bool, nsManagedObjectContext:NSManagedObjectContext) {
|
|
||||||
|
|
||||||
let entity = NSEntityDescription.entity(forEntityName: "MiaoMiao", in: nsManagedObjectContext)!
|
|
||||||
|
|
||||||
super.init(entity: entity, insertInto: nsManagedObjectContext)
|
|
||||||
|
|
||||||
blePeripheral = BLEPeripheral(address: address, name: name, alias: nil, bluetoothPeripheralType: .MiaoMiaoType, nsManagedObjectContext: nsManagedObjectContext)
|
|
||||||
|
|
||||||
blePeripheral.webOOPEnabled = webOOPEnabled
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
private override init(entity: NSEntityDescription, insertInto context: NSManagedObjectContext?) {
|
private override init(entity: NSEntityDescription, insertInto context: NSManagedObjectContext?) {
|
||||||
super.init(entity: entity, insertInto: context)
|
super.init(entity: entity, insertInto: context)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue