-
Notifications
You must be signed in to change notification settings - Fork 104
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #842 from smartdevicelink/develop
v5.1 Release
- Loading branch information
Showing
97 changed files
with
2,153 additions
and
366 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,4 @@ | ||
# github "Quick/Quick" ~> 1.1 | ||
github "Quick/Quick" ~> 1.2 | ||
github "Quick/Nimble" ~> 7.0 | ||
github "AliSoftware/OHHTTPStubs" ~> 6.1 | ||
github "erikdoe/ocmock" ~> 3.4 | ||
github "facebook/ios-snapshot-test-case" ~> 2.1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,7 +7,7 @@ s.homepage = "https://github.com/smartdevicelink/SmartDeviceLink-iOS" | |
s.license = { :type => "New BSD", :file => "LICENSE" } | ||
s.author = { "SmartDeviceLink Team" => "[email protected]" } | ||
s.platform = :ios, "8.0" | ||
s.dependency 'BiSON', '~> 1.0' | ||
s.dependency 'BiSON', '~> 1.1.1' | ||
s.source = { :git => "https://github.com/smartdevicelink/sdl_ios.git", :tag => s.version.to_s } | ||
s.requires_arc = true | ||
s.resource_bundles = { 'SmartDeviceLink' => ['SmartDeviceLink/Assets/**/*'] } | ||
|
@@ -38,6 +38,9 @@ ss.public_header_files = [ | |
'SmartDeviceLink/SDLArtwork.h', | ||
'SmartDeviceLink/SDLAudioPassThruCapabilities.h', | ||
'SmartDeviceLink/SDLAudioStreamingState.h', | ||
'SmartDeviceLink/SDLAudioStreamManager.h', | ||
'SmartDeviceLink/SDLAudioStreamManagerDelegate.h', | ||
'SmartDeviceLink/SDLStreamingAudioManagerType.h', | ||
'SmartDeviceLink/SDLAudioType.h', | ||
'SmartDeviceLink/SDLBeltStatus.h', | ||
'SmartDeviceLink/SDLBitsPerSample.h', | ||
|
@@ -48,6 +51,7 @@ ss.public_header_files = [ | |
'SmartDeviceLink/SDLButtonPress.h', | ||
'SmartDeviceLink/SDLButtonPressMode.h', | ||
'SmartDeviceLink/SDLCarModeStatus.h', | ||
'SmartDeviceLink/SDLCarWindowViewController.h', | ||
'SmartDeviceLink/SDLChangeRegistration.h', | ||
'SmartDeviceLink/SDLChangeRegistrationResponse.h', | ||
'SmartDeviceLink/SDLCharacterSet.h', | ||
|
@@ -156,11 +160,11 @@ ss.public_header_files = [ | |
'SmartDeviceLink/SDLManager.h', | ||
'SmartDeviceLink/SDLManagerDelegate.h', | ||
'SmartDeviceLink/SDLMediaClockFormat.h', | ||
'SmartDeviceLink/SDLModuleData.h', | ||
'SmartDeviceLink/SDLModuleType.h', | ||
'SmartDeviceLink/SDLMenuParams.h', | ||
'SmartDeviceLink/SDLMetadataTags.h', | ||
'SmartDeviceLink/SDLMetadataType.h', | ||
'SmartDeviceLink/SDLModuleData.h', | ||
'SmartDeviceLink/SDLModuleType.h', | ||
'SmartDeviceLink/SDLMyKey.h', | ||
'SmartDeviceLink/SDLNavigationCapability.h', | ||
'SmartDeviceLink/SDLNotificationConstants.h', | ||
|
@@ -212,23 +216,24 @@ ss.public_header_files = [ | |
'SmartDeviceLink/SDLProxyListener.h', | ||
'SmartDeviceLink/SDLPutFile.h', | ||
'SmartDeviceLink/SDLPutFileResponse.h', | ||
'SmartDeviceLink/SDLRadioBand.h', | ||
'SmartDeviceLink/SDLRadioControlCapabilities.h', | ||
'SmartDeviceLink/SDLRadioControlData.h', | ||
'SmartDeviceLink/SDLRadioState.h', | ||
'SmartDeviceLink/SDLReadDID.h', | ||
'SmartDeviceLink/SDLRectangle.h', | ||
'SmartDeviceLink/SDLReadDIDResponse.h', | ||
'SmartDeviceLink/SDLRectangle.h', | ||
'SmartDeviceLink/SDLRegisterAppInterface.h', | ||
'SmartDeviceLink/SDLRegisterAppInterfaceResponse.h', | ||
'SmartDeviceLink/SDLRemoteControlCapabilities.h', | ||
'SmartDeviceLink/SDLRequestType.h', | ||
'SmartDeviceLink/SDLResetGlobalProperties.h', | ||
'SmartDeviceLink/SDLResetGlobalPropertiesResponse.h', | ||
'SmartDeviceLink/SDLResult.h', | ||
'SmartDeviceLink/SDLRDSData.h', | ||
'SmartDeviceLink/SDLRPCMessage.h', | ||
'SmartDeviceLink/SDLRPCMessageType.h', | ||
'SmartDeviceLink/SDLRadioBand.h', | ||
'SmartDeviceLink/SDLRadioControlCapabilities.h', | ||
'SmartDeviceLink/SDLRadioControlData.h', | ||
'SmartDeviceLink/SDLRadioState.h', | ||
'SmartDeviceLink/SDLRDSData.h', | ||
'SmartDeviceLink/SDLRemoteControlCapabilities.h', | ||
'SmartDeviceLink/SDLRPCNotification.h', | ||
'SmartDeviceLink/SDLRPCNotificationNotification.h', | ||
'SmartDeviceLink/SDLRPCRequest.h', | ||
|
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,7 +7,7 @@ s.homepage = "https://github.com/smartdevicelink/SmartDeviceLink-iOS" | |
s.license = { :type => "New BSD", :file => "LICENSE" } | ||
s.author = { "SmartDeviceLink Team" => "[email protected]" } | ||
s.platform = :ios, "8.0" | ||
s.dependency 'BiSON', '~> 1.0' | ||
s.dependency 'BiSON', '~> 1.1.1' | ||
s.source = { :git => "https://github.com/smartdevicelink/sdl_ios.git", :tag => s.version.to_s } | ||
s.requires_arc = true | ||
s.resource_bundles = { 'SmartDeviceLink' => ['SmartDeviceLink/Assets/**/*'] } | ||
|
@@ -38,6 +38,9 @@ ss.public_header_files = [ | |
'SmartDeviceLink/SDLArtwork.h', | ||
'SmartDeviceLink/SDLAudioPassThruCapabilities.h', | ||
'SmartDeviceLink/SDLAudioStreamingState.h', | ||
'SmartDeviceLink/SDLAudioStreamManager.h', | ||
'SmartDeviceLink/SDLAudioStreamManagerDelegate.h', | ||
'SmartDeviceLink/SDLStreamingAudioManagerType.h', | ||
'SmartDeviceLink/SDLAudioType.h', | ||
'SmartDeviceLink/SDLBeltStatus.h', | ||
'SmartDeviceLink/SDLBitsPerSample.h', | ||
|
@@ -48,6 +51,7 @@ ss.public_header_files = [ | |
'SmartDeviceLink/SDLButtonPress.h', | ||
'SmartDeviceLink/SDLButtonPressMode.h', | ||
'SmartDeviceLink/SDLCarModeStatus.h', | ||
'SmartDeviceLink/SDLCarWindowViewController.h', | ||
'SmartDeviceLink/SDLChangeRegistration.h', | ||
'SmartDeviceLink/SDLChangeRegistrationResponse.h', | ||
'SmartDeviceLink/SDLCharacterSet.h', | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
// | ||
// SDLAudioFile.h | ||
// SmartDeviceLink-Example | ||
// | ||
// Created by Joel Fischer on 10/24/17. | ||
// Copyright © 2017 smartdevicelink. All rights reserved. | ||
// | ||
|
||
#import <SmartDeviceLink/SmartDeviceLink.h> | ||
|
||
NS_ASSUME_NONNULL_BEGIN | ||
|
||
@interface SDLAudioFile : NSObject | ||
|
||
@property (copy, nonatomic, readonly) NSURL *inputFileURL; | ||
|
||
@property (copy, nonatomic, readonly) NSURL *outputFileURL; | ||
|
||
/** | ||
In seconds. UINT32_MAX if unknown. | ||
*/ | ||
@property (assign, nonatomic) UInt32 estimatedDuration; | ||
|
||
@property (copy, nonatomic, readonly) NSData *data; | ||
|
||
@property (assign, nonatomic, readonly) unsigned long long fileSize; | ||
|
||
- (instancetype)initWithInputFileURL:(NSURL *)inputURL outputFileURL:(NSURL *)outputURL estimatedDuration:(UInt32)duration; | ||
|
||
@end | ||
|
||
NS_ASSUME_NONNULL_END |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
// | ||
// SDLAudioFile.m | ||
// SmartDeviceLink-Example | ||
// | ||
// Created by Joel Fischer on 10/24/17. | ||
// Copyright © 2017 smartdevicelink. All rights reserved. | ||
// | ||
|
||
#import "SDLAudioFile.h" | ||
|
||
NS_ASSUME_NONNULL_BEGIN | ||
|
||
@interface SDLAudioFile () | ||
|
||
@property (copy, nonatomic, readwrite) NSURL *inputFileURL; | ||
@property (copy, nonatomic, readwrite) NSURL *outputFileURL; | ||
@property (copy, nonatomic, readwrite) NSData *data; | ||
@property (copy, nonatomic, readwrite) NSString *name; | ||
|
||
@end | ||
|
||
@implementation SDLAudioFile | ||
|
||
- (instancetype)initWithInputFileURL:(NSURL *)inputURL outputFileURL:(NSURL *)outputURL estimatedDuration:(UInt32)duration { | ||
self = [super init]; | ||
if (!self) { return nil; } | ||
|
||
_inputFileURL = inputURL; | ||
_outputFileURL = outputURL; | ||
_estimatedDuration = duration; | ||
|
||
return self; | ||
} | ||
|
||
- (NSData *)data { | ||
if (_data.length == 0) { | ||
return [NSData dataWithContentsOfURL:_outputFileURL]; | ||
} | ||
|
||
return _data; | ||
} | ||
|
||
/** | ||
Gets the size of the data. The data may be stored on disk or it may already be in the application's memory. | ||
@return The size of the data. | ||
*/ | ||
- (unsigned long long)fileSize { | ||
if (_outputFileURL != nil) { | ||
// Data in file | ||
NSString *path = [_outputFileURL path]; | ||
return [[NSFileManager defaultManager] attributesOfItemAtPath:path error:nil].fileSize; | ||
} else if (_data) { | ||
// Data in memory | ||
return _data.length; | ||
} | ||
return 0; | ||
} | ||
|
||
@end | ||
|
||
NS_ASSUME_NONNULL_END |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
// | ||
// SDLBinaryAudioManager.h | ||
// SmartDeviceLink-Example | ||
// | ||
// Created by Joel Fischer on 10/24/17. | ||
// Copyright © 2017 smartdevicelink. All rights reserved. | ||
// | ||
|
||
#import <Foundation/Foundation.h> | ||
|
||
@class SDLAudioFile; | ||
@class SDLManager; | ||
@class SDLStreamingMediaLifecycleManager; | ||
@protocol SDLStreamingAudioManagerType; | ||
@protocol SDLAudioStreamManagerDelegate; | ||
|
||
NS_ASSUME_NONNULL_BEGIN | ||
|
||
extern NSString *const SDLErrorDomainAudioStreamManager; | ||
|
||
typedef NS_ENUM(NSInteger, SDLAudioStreamManagerError) { | ||
SDLAudioStreamManagerErrorNotConnected = -1, | ||
SDLAudioStreamManagerErrorNoQueuedAudio = -2 | ||
}; | ||
|
||
@interface SDLAudioStreamManager : NSObject | ||
|
||
@property (weak, nonatomic) id<SDLAudioStreamManagerDelegate> delegate; | ||
|
||
@property (assign, nonatomic, readonly, getter=isPlaying) BOOL playing; | ||
@property (copy, nonatomic, readonly) NSArray<SDLAudioFile *> *queue; | ||
|
||
- (instancetype)init NS_UNAVAILABLE; | ||
|
||
- (instancetype)initWithManager:(id<SDLStreamingAudioManagerType>)streamManager NS_DESIGNATED_INITIALIZER; | ||
|
||
/** | ||
Push a new file URL onto the queue after converting it into the correct PCM format for streaming binary data. Call `playNextWhenReady` to start playing the next completed pushed file. | ||
@note This happens on a serial background thread and will provide an error callback using the delegate if the conversion fails. | ||
@param fileURL File URL to convert | ||
*/ | ||
- (void)pushWithFileURL:(NSURL *)fileURL; | ||
|
||
/** | ||
Play the next item in the queue. If an item is currently playing, it will continue playing and this item will begin playing after it is completed. | ||
When complete, this will callback on the delegate. | ||
*/ | ||
- (void)playNextWhenReady; | ||
|
||
/** | ||
Stop playing the queue after the current item completes and clear the queue. If nothing is playing, the queue will be cleared. | ||
*/ | ||
- (void)stop; | ||
|
||
@end | ||
|
||
NS_ASSUME_NONNULL_END |
Oops, something went wrong.