Inherits from NSObject
Declared in Bit6Utils.h

Overview

Bit6 utility class.

Class Methods

audioDurationForFileAtPath:

Convenient method to retrieve the duration of an audio file.

+ (double)audioDurationForFileAtPath:(nonnull NSString *)filePath

Parameters

filePath

path to the audio file.

Return Value

duration in seconds of the audio file.

Declared In

Bit6Utils.h

clockFormatForSeconds:

Convenient method to convert seconds into a clock format NSString. For example 75s will be converted to 01:15

+ (nullable NSString *)clockFormatForSeconds:(double)seconds

Parameters

seconds

number of seconds to convert

Return Value

seconds in a clock format. Returns nil if the isnan(seconds).

Declared In

Bit6Utils.h

imageWithColor:

Convenient method to return an UIImage of a single color.

+ (nonnull UIImage *)imageWithColor:(nonnull UIColor *)color

Parameters

color

color to fill the UIImage with.

Return Value

UIImage of a single color.

Declared In

Bit6Utils.h

requestAccessToCameraWithSuccessBlock:failedBlock:

Request access to the Camera. On iOS7 and earlier it always succeeds.

+ (void)requestAccessToCameraWithSuccessBlock:(nullable void ( ^ ) ( ))successBlock failedBlock:(nullable void ( ^ ) ( ))failedBlock

Parameters

successBlock

block to be called if camera access has been granted

failedBlock

block to be called if camera access is not granted

Declared In

Bit6Utils.h

requestAccessToMicrophoneWithSuccessBlock:failedBlock:

Request access to the Microphone. On iOS6 it always succeeds.

+ (void)requestAccessToMicrophoneWithSuccessBlock:(nullable void ( ^ ) ( ))successBlock failedBlock:(nullable void ( ^ ) ( ))failedBlock

Parameters

successBlock

block to be called if microphone access has been granted

failedBlock

block to be called if microphone access is not granted

Declared In

Bit6Utils.h