summaryrefslogtreecommitdiff
path: root/platform/darwin/src/NSDate+MGLAdditions.h
blob: 1da03fda62dbd07134ac54a088a5ec66129d7720 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#import <Foundation/Foundation.h>

#import "MGLFoundation.h"
#include <mbgl/util/chrono.hpp>

NS_ASSUME_NONNULL_BEGIN


/// Converts from a duration in seconds to a duration object usable in mbgl.
MGL_EXPORT
mbgl::Duration MGLDurationFromTimeInterval(NSTimeInterval duration);

/// Converts from an mbgl duration object to a duration in seconds.
MGL_EXPORT
NSTimeInterval MGLTimeIntervalFromDuration(mbgl::Duration duration);

NS_ASSUME_NONNULL_END