//
 /***************************************************************
 * Copyright © 2017 HERE Global B.V. All rights reserved. *
 **************************************************************/

#import "HereSDKDemandRideLocation+Dictionary.h"
#import "NSString+Utilities.h"
#import "NSDate+NSNumber.h"
#import "CLLocation+Dictionary.h"

@implementation HereSDKDemandRideLocation (Dictionary)

- (NSDictionary *)dictionary
{
    return @{
             @"vehicleLocation": (self.vehicleLocation) ? self.vehicleLocation.dictionary : [NSNull null],
             @"estimatedPickupTime": (self.estimatedPickupTime) ? self.estimatedPickupTime.hereSdk_toNumber : [NSNull null],
             @"estimatedDropOffTime": (self.estimatedDropoffTime) ? self.estimatedDropoffTime.hereSdk_toNumber : [NSNull null],
             @"lastUpdateTime": (self.lastUpdateTime) ? self.lastUpdateTime.hereSdk_toNumber : [NSNull null],
             @"rideId": [NSString hereSDK_utilities_emptyOrString:self.rideId],
             };
}

@end
