     }
     
     // MARK: - Helpers
-    func stringFromDate(date: NSDate) -> String {
-        return self.formatter.stringFromDate(date)
-    }
-    func dateFromString(date: String) -> NSDate? {
-        return self.formatter.dateFromString(date)!
+    func stringFromDate(_ date: Date) -> String {
+        return self.formatter.string(from: date as Date)
+    }
+    func dateFromString(_ date: String) -> Date? {
+        return self.formatter.date(from: date)! as Date?
     }
 }
 
 extension Dictionary {
-    mutating func update(other:Dictionary) {
+    mutating func update(_ other:Dictionary) {
         for (key,value) in other {
             self.updateValue(value, forKey:key)
         }
     }
 }
 
-public class OV9292API:NSObject {
-    
-    public static let baseURL = "http://api.9292.nl/0.1/"
-    
-    public class func journeysForTransportationTypes(transportationTypes:Array<TransportationType>, from:Station, to: Station, departure:NSDate)  -> Array<Journey> {
+open class OV9292API:NSObject {
+    
+    open static let baseURL = "http://api.9292.nl/0.1/"
+    
+    open class func journeysForTransportationTypes(_ transportationTypes:Array<TransportationType>, from:Station, to: Station, departure:Date)  -> Array<Journey> {
         
         let obj = OV9292API.getJourney(transportationTypes, from: from, to: to, departure: departure)
         

struct LudMessage {
    var text:String = ""
    var urlString:String = ""
    var url:NSURL? {
        get {
            if let url = NSURL(string: urlString) {
                return url
            }
            

    var coordinates:LatLong = LatLong()
}

open class Journey:NSObject {
    var ludMessages:Array<LudMessage> = []
    var departure:Date?
    var arrival:Date?
    var numberOfChanges:Int = 0
    var legs:Array<JourneyLeg> = []
    var fareInfo:FareInfo = FareInfo()
