SDLStartTime Class Reference

Section Contents

Overview

Describes the hour, minute and second values used to set the media clock.

@since SDL 1.0

-initWithTimeInterval:

Create a time struct with a time interval (time in seconds). Fractions of the second will be eliminated and rounded down.

Objective-C

- (nonnull instancetype)initWithTimeInterval:(NSTimeInterval)timeInterval;

Swift

init(timeInterval: TimeInterval)

Parameters

timeInterval

The time interval to transform into hours, minutes, seconds

Return Value

The object

-initWithHours:minutes:seconds:

Create a time struct with hours, minutes, and seconds

Objective-C

- (nonnull instancetype)initWithHours:(UInt8)hours
                              minutes:(UInt8)minutes
                              seconds:(UInt8)seconds;

Swift

init(hours: UInt8, minutes: UInt8, seconds: UInt8)

Parameters

hours

The number of hours

minutes

The number of minutes

seconds

The number of seconds

Return Value

The object

hours

The hour of the media clock

Some display types only support a max value of 19. If out of range, it will be rejected.

Required, Integer, 0 - 59

Objective-C

@property (nonatomic, strong) NSNumber<SDLInt> *_Nonnull hours;

Swift

var hours: NSNumber & SDLInt { get set }

minutes

The minute of the media clock

Required, Integer, 0 - 59

Objective-C

@property (nonatomic, strong) NSNumber<SDLInt> *_Nonnull minutes;

Swift

var minutes: NSNumber & SDLInt { get set }

seconds

The second of the media clock

Required, Integer, 0 - 59

Objective-C

@property (nonatomic, strong) NSNumber<SDLInt> *_Nonnull seconds;

Swift

var seconds: NSNumber & SDLInt { get set }