         get: { $0.strength },
         set: { (inout medication: Medication, strength) in medication.strength = flush(strength, not(isEmpty)) }
     )
+
+    static let uuid = Lens(
+        get: { $0.uuid },
+        set: { (inout medication: Medication, uuid) in medication.uuid = uuid }
+    )
 }

    private var pictureData: NSData?
    private var schedules: [Schedule]
    private var strength: String?
    private var uuid: NSUUID

    init(doctorRecordID: ABRecordID? = nil, dosesLeft: Int? = nil, lastFilledDate: NSDate? = nil, name: String? = nil, note: String? = nil, pharmacyRecordID: ABRecordID? = nil, pictureData: NSData? = nil, schedules: [Schedule] = [], strength: String? = nil, uuid: NSUUID = NSUUID()) {
        self.doctorRecordID = doctorRecordID
        self.dosesLeft = dosesLeft
        self.lastFilledDate = lastFilledDate

        self.uuid = uuid
    }

    var hashValue: Int {
        if let uuid = uuid {
            return uuid.hash
        } else {
            return (name?.hash ?? 0) ^ (strength?.hash ?? 0)
        }
    }
}

func ==(lhs: Medication, rhs: Medication) -> Bool {
    switch (lhs.uuid, rhs.uuid) {
    case let (.Some(lhu), .Some(rhu)):
        return lhu == rhu
    default:
        return lhs.name == rhs.name && lhs.strength ==  rhs.strength
    }
}

struct MedicationLenses {
