diff options
193 files changed, 980 insertions, 997 deletions
diff --git a/SmartDeviceLink/NSMutableDictionary+Store.h b/SmartDeviceLink/NSMutableDictionary+Store.h index b43ce8e3c..0c20aa1c8 100644 --- a/SmartDeviceLink/NSMutableDictionary+Store.h +++ b/SmartDeviceLink/NSMutableDictionary+Store.h @@ -19,34 +19,22 @@ typedef NSString* SDLEnum SDL_SWIFT_ENUM; - (void)sdl_setObject:(NSObject *)object forName:(SDLRPCParameterName)name; -- (nullable SDLEnum)sdl_enumForName:(SDLRPCParameterName)name error:(NSError **)error; -- (nullable NSArray<SDLRPCParameterName> *)sdl_enumsForName:(SDLRPCParameterName)name error:(NSError **)error; - -/** - * @return object of classType or nil - */ -- (nullable id)sdl_objectForName:(SDLRPCParameterName)name ofClass:(Class)classType; - -/** - * @return array of classType objects or nil -*/ -- (nullable NSArray *)sdl_objectsForName:(SDLRPCParameterName)name ofClass:(Class)classType; +- (nullable SDLEnum)sdl_enumForName:(SDLRPCParameterName)name error:(NSError * _Nullable *)error; +- (nullable NSArray<SDLEnum> *)sdl_enumsForName:(SDLRPCParameterName)name error:(NSError * _Nullable *)error; /** * @param classType expected class of returned object * @param error if stored value isn't classType - * @warning returned object can be not of classType - * @return object of classType overwise error would be filled + * @return object of classType or nil */ -- (nullable id)sdl_objectForName:(SDLRPCParameterName)name ofClass:(Class)classType error:(NSError **)error; +- (nullable id)sdl_objectForName:(SDLRPCParameterName)name ofClass:(Class)classType error:(NSError * _Nullable *)error; /** * @param classType expected class of array objects * @param error if array objects value isn't classType or stored objects aren't array - * @warning returned object can be not array or stored objects aren't of classType - * @return try to return array of classType objects overwise error would be filled + * @return return array of classType or nil */ -- (nullable NSArray *)sdl_objectsForName:(SDLRPCParameterName)name ofClass:(Class)classType error:(NSError **)error; +- (nullable NSArray *)sdl_objectsForName:(SDLRPCParameterName)name ofClass:(Class)classType error:(NSError * _Nullable *)error; @end diff --git a/SmartDeviceLink/NSMutableDictionary+Store.m b/SmartDeviceLink/NSMutableDictionary+Store.m index 23b2cc790..5cebee7d3 100644 --- a/SmartDeviceLink/NSMutableDictionary+Store.m +++ b/SmartDeviceLink/NSMutableDictionary+Store.m @@ -40,12 +40,6 @@ NS_ASSUME_NONNULL_BEGIN #pragma mark - object -- (nullable id)sdl_objectForName:(SDLRPCParameterName)name ofClass:(Class)classType { - NSError *error; - id object = [self sdl_objectForName:name ofClass:classType error:&error]; - return error == nil ? object : nil; -} - - (nullable id)sdl_objectForName:(SDLRPCParameterName)name ofClass:(Class)classType error:(NSError * _Nullable __autoreleasing * _Nullable)error { id obj = [self sdl_objectForName:name]; @@ -59,9 +53,10 @@ NS_ASSUME_NONNULL_BEGIN [self sdl_setObject:obj forName:name]; return obj; } - NSError *wrongObjectError = [NSError sdl_store_wrongObject:obj expectedType:classType]; + // The object in the store is not correct, we'll assert in debug and return an error and nil + NSError *wrongObjectError = [NSError sdl_store_invalidObjectErrorWithObject:obj expectedType:classType]; - NSAssert(NO, [[wrongObjectError userInfo] objectForKey:NSLocalizedFailureReasonErrorKey]); + NSAssert(NO, wrongObjectError.localizedFailureReason); if (error) { *error = wrongObjectError; @@ -72,19 +67,13 @@ NS_ASSUME_NONNULL_BEGIN #pragma mark - objects -- (nullable NSArray *)sdl_objectsForName:(SDLRPCParameterName)name ofClass:(Class)classType { - NSError *error; - id objects = [self sdl_objectsForName:name ofClass:classType error:&error]; - return error == nil ? objects : nil; -} - - (nullable NSArray *)sdl_objectsForName:(SDLRPCParameterName)name ofClass:(Class)classType error:(NSError * _Nullable __autoreleasing * _Nullable)error { NSArray *array = [self sdl_objectForName:name ofClass:NSArray.class error:error]; - if (!array || array.count < 1 || [array.firstObject isKindOfClass:classType]) { + if (array == nil || array.count < 1 || [array.firstObject isKindOfClass:classType]) { // It's an array of the actual class type, just return return array; } - if ([classType instancesRespondToSelector:@selector(initWithDictionary:)]) { + else if ([classType instancesRespondToSelector:@selector(initWithDictionary:)]) { // It's an array of dictionaries, make them into their class type NSMutableArray *newList = [NSMutableArray arrayWithCapacity:array.count]; for (NSDictionary<NSString *, id> *dict in array) { @@ -92,21 +81,24 @@ NS_ASSUME_NONNULL_BEGIN [newList addObject:[[classType alloc] initWithDictionary:dict]]; } } + [self sdl_setObject:newList forName:name]; return [newList copy]; - } - NSError *wrongObjectError = nil; - - if ([array isKindOfClass:NSArray.class] && ![array.firstObject isKindOfClass:classType]) { - wrongObjectError = [NSError sdl_store_wrongObject:array.firstObject expectedType:classType]; } else { - wrongObjectError = [NSError sdl_store_wrongObject:array expectedType:NSArray.class]; - } + // The object in the store is not correct, we'll assert in debug and return an error and nil + NSError *wrongObjectError = nil; - NSAssert(NO, [wrongObjectError.userInfo objectForKey:NSLocalizedFailureReasonErrorKey]); - if (error) { - *error = wrongObjectError; + if ([array isKindOfClass:NSArray.class] && ![array.firstObject isKindOfClass:classType]) { + wrongObjectError = [NSError sdl_store_invalidObjectErrorWithObject:array.firstObject expectedType:classType]; + } else { + wrongObjectError = [NSError sdl_store_invalidObjectErrorWithObject:array expectedType:NSArray.class]; + } + + NSAssert(NO, wrongObjectError.localizedFailureReason); + if (error) { + *error = wrongObjectError; + } + return nil; } - return nil; } @end diff --git a/SmartDeviceLink/SDLAddCommand.m b/SmartDeviceLink/SDLAddCommand.m index 8da22b041..074db8846 100644 --- a/SmartDeviceLink/SDLAddCommand.m +++ b/SmartDeviceLink/SDLAddCommand.m @@ -107,7 +107,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)cmdID { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameCommandId ofClass:NSNumber.class error:&error]; } @@ -116,7 +116,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLMenuParams *)menuParams { - return [parameters sdl_objectForName:SDLRPCParameterNameMenuParams ofClass:SDLMenuParams.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameMenuParams ofClass:SDLMenuParams.class error:nil]; } - (void)setVrCommands:(nullable NSArray<NSString *> *)vrCommands { @@ -124,7 +124,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<NSString *> *)vrCommands { - return [parameters sdl_objectsForName:SDLRPCParameterNameVRCommands ofClass:NSString.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameVRCommands ofClass:NSString.class error:nil]; } - (void)setCmdIcon:(nullable SDLImage *)cmdIcon { @@ -132,7 +132,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLImage *)cmdIcon { - return [parameters sdl_objectForName:SDLRPCParameterNameCommandIcon ofClass:SDLImage.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameCommandIcon ofClass:SDLImage.class error:nil]; } -(id)copyWithZone:(nullable NSZone *)zone { diff --git a/SmartDeviceLink/SDLAddSubMenu.m b/SmartDeviceLink/SDLAddSubMenu.m index c57175ce7..3a79563a4 100644 --- a/SmartDeviceLink/SDLAddSubMenu.m +++ b/SmartDeviceLink/SDLAddSubMenu.m @@ -48,7 +48,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)menuID { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameMenuId ofClass:NSNumber.class error:&error]; } @@ -57,7 +57,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)position { - return [parameters sdl_objectForName:SDLRPCParameterNamePosition ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNamePosition ofClass:NSNumber.class error:nil]; } - (void)setMenuName:(NSString *)menuName { @@ -65,7 +65,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)menuName { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameMenuName ofClass:NSString.class error:&error]; } @@ -74,7 +74,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLImage *)menuIcon { - return [parameters sdl_objectForName:SDLRPCParameterNameMenuIcon ofClass:[SDLImage class]]; + return [parameters sdl_objectForName:SDLRPCParameterNameMenuIcon ofClass:[SDLImage class] error:nil]; } @end diff --git a/SmartDeviceLink/SDLAirbagStatus.m b/SmartDeviceLink/SDLAirbagStatus.m index 6ced889eb..a13f525f8 100644 --- a/SmartDeviceLink/SDLAirbagStatus.m +++ b/SmartDeviceLink/SDLAirbagStatus.m @@ -14,7 +14,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)driverAirbagDeployed { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameDriverAirbagDeployed error:&error]; } @@ -23,7 +23,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)driverSideAirbagDeployed { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameDriverSideAirbagDeployed error:&error]; } @@ -32,7 +32,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)driverCurtainAirbagDeployed { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameDriverCurtainAirbagDeployed error:&error]; } @@ -40,7 +40,7 @@ NS_ASSUME_NONNULL_BEGIN [store sdl_setObject:passengerAirbagDeployed forName:SDLRPCParameterNamePassengerAirbagDeployed];} - (SDLVehicleDataEventStatus)passengerAirbagDeployed { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNamePassengerAirbagDeployed error:&error]; } @@ -49,7 +49,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)passengerCurtainAirbagDeployed { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNamePassengerCurtainAirbagDeployed error:&error]; } @@ -58,7 +58,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)driverKneeAirbagDeployed { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameDriverKneeAirbagDeployed error:&error]; } @@ -67,7 +67,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)passengerSideAirbagDeployed { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNamePassengerSideAirbagDeployed error:&error]; } @@ -76,7 +76,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)passengerKneeAirbagDeployed { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNamePassengerKneeAirbagDeployed error:&error]; } diff --git a/SmartDeviceLink/SDLAlert.m b/SmartDeviceLink/SDLAlert.m index b5bff1378..7c9fa67f5 100644 --- a/SmartDeviceLink/SDLAlert.m +++ b/SmartDeviceLink/SDLAlert.m @@ -79,7 +79,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)alertText1 { - return [parameters sdl_objectForName:SDLRPCParameterNameAlertText1 ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAlertText1 ofClass:NSString.class error:nil]; } - (void)setAlertText2:(nullable NSString *)alertText2 { @@ -87,7 +87,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)alertText2 { - return [parameters sdl_objectForName:SDLRPCParameterNameAlertText2 ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAlertText2 ofClass:NSString.class error:nil]; } - (void)setAlertText3:(nullable NSString *)alertText3 { @@ -95,7 +95,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)alertText3 { - return [parameters sdl_objectForName:SDLRPCParameterNameAlertText3 ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAlertText3 ofClass:NSString.class error:nil]; } - (void)setTtsChunks:(nullable NSArray<SDLTTSChunk *> *)ttsChunks { @@ -103,7 +103,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLTTSChunk *> *)ttsChunks { - return [parameters sdl_objectsForName:SDLRPCParameterNameTTSChunks ofClass:SDLTTSChunk.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameTTSChunks ofClass:SDLTTSChunk.class error:nil]; } - (void)setDuration:(nullable NSNumber<SDLInt> *)duration { @@ -111,7 +111,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)duration { - return [parameters sdl_objectForName:SDLRPCParameterNameDuration ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameDuration ofClass:NSNumber.class error:nil]; } - (void)setPlayTone:(nullable NSNumber<SDLBool> *)playTone { @@ -119,7 +119,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)playTone { - return [parameters sdl_objectForName:SDLRPCParameterNamePlayTone ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNamePlayTone ofClass:NSNumber.class error:nil]; } - (void)setProgressIndicator:(nullable NSNumber<SDLBool> *)progressIndicator { @@ -127,7 +127,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)progressIndicator { - return [parameters sdl_objectForName:SDLRPCParameterNameProgressIndicator ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameProgressIndicator ofClass:NSNumber.class error:nil]; } - (void)setSoftButtons:(nullable NSArray<SDLSoftButton *> *)softButtons { @@ -135,7 +135,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLSoftButton *> *)softButtons { - return [parameters sdl_objectsForName:SDLRPCParameterNameSoftButtons ofClass:SDLSoftButton.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameSoftButtons ofClass:SDLSoftButton.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLAlertManeuver.m b/SmartDeviceLink/SDLAlertManeuver.m index 3d3ca63ff..7eb01682a 100644 --- a/SmartDeviceLink/SDLAlertManeuver.m +++ b/SmartDeviceLink/SDLAlertManeuver.m @@ -43,7 +43,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLTTSChunk *> *)ttsChunks { - return [parameters sdl_objectsForName:SDLRPCParameterNameTTSChunks ofClass:SDLTTSChunk.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameTTSChunks ofClass:SDLTTSChunk.class error:nil]; } - (void)setSoftButtons:(nullable NSArray<SDLSoftButton *> *)softButtons { @@ -51,7 +51,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLSoftButton *> *)softButtons { - return [parameters sdl_objectsForName:SDLRPCParameterNameSoftButtons ofClass:SDLSoftButton.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameSoftButtons ofClass:SDLSoftButton.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLAlertResponse.m b/SmartDeviceLink/SDLAlertResponse.m index dd77c2780..a35890723 100644 --- a/SmartDeviceLink/SDLAlertResponse.m +++ b/SmartDeviceLink/SDLAlertResponse.m @@ -21,7 +21,7 @@ NS_ASSUME_NONNULL_BEGIN [parameters sdl_setObject:tryAgainTime forName:SDLRPCParameterNameTryAgainTime];} - (nullable NSNumber<SDLInt> *)tryAgainTime { - return [parameters sdl_objectForName:SDLRPCParameterNameTryAgainTime ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameTryAgainTime ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLAppInfo.m b/SmartDeviceLink/SDLAppInfo.m index 73d622ff9..431382f91 100644 --- a/SmartDeviceLink/SDLAppInfo.m +++ b/SmartDeviceLink/SDLAppInfo.m @@ -31,7 +31,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)appDisplayName { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameAppDisplayName ofClass:NSString.class error:&error]; } @@ -40,7 +40,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)appBundleID { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameAppBundleId ofClass:NSString.class error:&error]; } @@ -49,7 +49,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)appVersion { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameAppVersion ofClass:NSString.class error:&error]; } diff --git a/SmartDeviceLink/SDLAppServiceCapability.m b/SmartDeviceLink/SDLAppServiceCapability.m index 94df91636..1dd6bb209 100644 --- a/SmartDeviceLink/SDLAppServiceCapability.m +++ b/SmartDeviceLink/SDLAppServiceCapability.m @@ -52,7 +52,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLAppServiceRecord *)updatedAppServiceRecord { - return [store sdl_objectForName:SDLRPCParameterNameUpdatedAppServiceRecord ofClass:SDLAppServiceRecord.class]; + return [store sdl_objectForName:SDLRPCParameterNameUpdatedAppServiceRecord ofClass:SDLAppServiceRecord.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLAppServiceData.m b/SmartDeviceLink/SDLAppServiceData.m index 9b19a3505..67c7a5a85 100644 --- a/SmartDeviceLink/SDLAppServiceData.m +++ b/SmartDeviceLink/SDLAppServiceData.m @@ -86,7 +86,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)serviceType { - return [store sdl_objectForName:SDLRPCParameterNameServiceType ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameServiceType ofClass:NSString.class error:nil]; } - (void)setServiceId:(NSString *)serviceId { @@ -94,7 +94,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)serviceId { - return [store sdl_objectForName:SDLRPCParameterNameServiceID ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameServiceID ofClass:NSString.class error:nil]; } - (void)setWeatherServiceData:(nullable SDLWeatherServiceData *)weatherServiceData { @@ -102,7 +102,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLWeatherServiceData *)weatherServiceData { - return [store sdl_objectForName:SDLRPCParameterNameWeatherServiceData ofClass:SDLWeatherServiceData.class]; + return [store sdl_objectForName:SDLRPCParameterNameWeatherServiceData ofClass:SDLWeatherServiceData.class error:nil]; } - (void)setMediaServiceData:(nullable SDLMediaServiceData *)mediaServiceData { @@ -110,7 +110,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLMediaServiceData *)mediaServiceData { - return [store sdl_objectForName:SDLRPCParameterNameMediaServiceData ofClass:SDLMediaServiceData.class]; + return [store sdl_objectForName:SDLRPCParameterNameMediaServiceData ofClass:SDLMediaServiceData.class error:nil]; } - (void)setNavigationServiceData:(nullable SDLNavigationServiceData *)navigationServiceData { @@ -118,7 +118,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLNavigationServiceData *)navigationServiceData { - return [store sdl_objectForName:SDLRPCParameterNameNavigationServiceData ofClass:SDLNavigationServiceData.class]; + return [store sdl_objectForName:SDLRPCParameterNameNavigationServiceData ofClass:SDLNavigationServiceData.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLAppServiceManifest.m b/SmartDeviceLink/SDLAppServiceManifest.m index b6ded0df2..0fe701225 100644 --- a/SmartDeviceLink/SDLAppServiceManifest.m +++ b/SmartDeviceLink/SDLAppServiceManifest.m @@ -71,7 +71,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)serviceName { - return [store sdl_objectForName:SDLRPCParameterNameServiceName ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameServiceName ofClass:NSString.class error:nil]; } - (void)setServiceType:(NSString *)serviceType { @@ -79,7 +79,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)serviceType { - return [store sdl_objectForName:SDLRPCParameterNameServiceType ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameServiceType ofClass:NSString.class error:nil]; } - (void)setServiceIcon:(nullable SDLImage *)serviceIcon { @@ -87,7 +87,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLImage *)serviceIcon { - return [store sdl_objectForName:SDLRPCParameterNameServiceIcon ofClass:SDLImage.class]; + return [store sdl_objectForName:SDLRPCParameterNameServiceIcon ofClass:SDLImage.class error:nil]; } - (void)setAllowAppConsumers:(nullable NSNumber<SDLBool> *)allowAppConsumers { @@ -95,7 +95,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)allowAppConsumers { - return [store sdl_objectForName:SDLRPCParameterNameAllowAppConsumers ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameAllowAppConsumers ofClass:NSNumber.class error:nil]; } - (void)setRpcSpecVersion:(nullable SDLSyncMsgVersion *)rpcSpecVersion { @@ -103,7 +103,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLSyncMsgVersion *)rpcSpecVersion { - return [store sdl_objectForName:SDLRPCParameterNameRPCSpecVersion ofClass:SDLSyncMsgVersion.class]; + return [store sdl_objectForName:SDLRPCParameterNameRPCSpecVersion ofClass:SDLSyncMsgVersion.class error:nil]; } - (void)setHandledRPCs:(nullable NSArray<NSNumber<SDLInt> *> *)handledRPCs { @@ -111,7 +111,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<NSNumber<SDLInt> *> *)handledRPCs { - return [store sdl_objectsForName:SDLRPCParameterNameHandledRPCs ofClass:NSNumber.class]; + return [store sdl_objectsForName:SDLRPCParameterNameHandledRPCs ofClass:NSNumber.class error:nil]; } - (void)setWeatherServiceManifest:(nullable SDLWeatherServiceManifest *)weatherServiceManifest { @@ -119,7 +119,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLWeatherServiceManifest *)weatherServiceManifest { - return [store sdl_objectForName:SDLRPCParameterNameWeatherServiceManifest ofClass:SDLWeatherServiceManifest.class]; + return [store sdl_objectForName:SDLRPCParameterNameWeatherServiceManifest ofClass:SDLWeatherServiceManifest.class error:nil]; } - (void)setMediaServiceManifest:(nullable SDLMediaServiceManifest *)mediaServiceManifest { @@ -127,7 +127,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLMediaServiceManifest *)mediaServiceManifest { - return [store sdl_objectForName:SDLRPCParameterNameMediaServiceManifest ofClass:SDLMediaServiceManifest.class]; + return [store sdl_objectForName:SDLRPCParameterNameMediaServiceManifest ofClass:SDLMediaServiceManifest.class error:nil]; } - (void)setNavigationServiceManifest:(nullable SDLNavigationServiceManifest *)navigationServiceManifest { @@ -135,7 +135,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLNavigationServiceManifest *)navigationServiceManifest { - return [store sdl_objectForName:SDLRPCParameterNameNavigationServiceManifest ofClass:SDLNavigationServiceManifest.class]; + return [store sdl_objectForName:SDLRPCParameterNameNavigationServiceManifest ofClass:SDLNavigationServiceManifest.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLAppServiceRecord.m b/SmartDeviceLink/SDLAppServiceRecord.m index 4ca0e3a2c..2ad7eb1d0 100644 --- a/SmartDeviceLink/SDLAppServiceRecord.m +++ b/SmartDeviceLink/SDLAppServiceRecord.m @@ -35,7 +35,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)serviceID { - return [store sdl_objectForName:SDLRPCParameterNameServiceID ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameServiceID ofClass:NSString.class error:nil]; } - (void)setServiceManifest:(SDLAppServiceManifest *)serviceManifest { @@ -43,7 +43,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLAppServiceManifest *)serviceManifest { - return [store sdl_objectForName:SDLRPCParameterNameServiceManifest ofClass:SDLAppServiceManifest.class]; + return [store sdl_objectForName:SDLRPCParameterNameServiceManifest ofClass:SDLAppServiceManifest.class error:nil]; } - (void)setServicePublished:(NSNumber<SDLBool> *)servicePublished { @@ -51,7 +51,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)servicePublished { - return [store sdl_objectForName:SDLRPCParameterNameServicePublished ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameServicePublished ofClass:NSNumber.class error:nil]; } - (void)setServiceActive:(NSNumber<SDLBool> *)serviceActive { @@ -59,7 +59,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)serviceActive { - return [store sdl_objectForName:SDLRPCParameterNameServiceActive ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameServiceActive ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLAppServicesCapabilities.m b/SmartDeviceLink/SDLAppServicesCapabilities.m index 8a747f208..f0d032c54 100644 --- a/SmartDeviceLink/SDLAppServicesCapabilities.m +++ b/SmartDeviceLink/SDLAppServicesCapabilities.m @@ -32,7 +32,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLAppServiceCapability *> *)appServices { - return [store sdl_objectsForName:SDLRPCParameterNameAppServices ofClass:SDLAppServiceCapability.class]; + return [store sdl_objectsForName:SDLRPCParameterNameAppServices ofClass:SDLAppServiceCapability.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLAudioControlCapabilities.m b/SmartDeviceLink/SDLAudioControlCapabilities.m index f1939ea69..9d22c4d94 100644 --- a/SmartDeviceLink/SDLAudioControlCapabilities.m +++ b/SmartDeviceLink/SDLAudioControlCapabilities.m @@ -39,7 +39,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)moduleName { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameModuleName ofClass:NSString.class error:&error]; } @@ -48,7 +48,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)sourceAvailable { - return [store sdl_objectForName:SDLRPCParameterNameSourceAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameSourceAvailable ofClass:NSNumber.class error:nil]; } - (void)setKeepContextAvailable:(nullable NSNumber<SDLBool> *)keepContextAvailable { @@ -56,7 +56,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)keepContextAvailable { - return [store sdl_objectForName:SDLRPCParameterNameKeepContextAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameKeepContextAvailable ofClass:NSNumber.class error:nil]; } - (void)setVolumeAvailable:(nullable NSNumber<SDLBool> *)volumeAvailable { @@ -64,7 +64,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)volumeAvailable { - return [store sdl_objectForName:SDLRPCParameterNameVolumeAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameVolumeAvailable ofClass:NSNumber.class error:nil]; } - (void)setEqualizerAvailable:(nullable NSNumber<SDLBool> *)equalizerAvailable { @@ -72,7 +72,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)equalizerAvailable { - return [store sdl_objectForName:SDLRPCParameterNameEqualizerAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameEqualizerAvailable ofClass:NSNumber.class error:nil]; } - (void)setEqualizerMaxChannelId:(nullable NSNumber<SDLInt> *)equalizerMaxChannelId { @@ -80,7 +80,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)equalizerMaxChannelId { - return [store sdl_objectForName:SDLRPCParameterNameEqualizerMaxChannelId ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameEqualizerMaxChannelId ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLAudioControlData.m b/SmartDeviceLink/SDLAudioControlData.m index f6e1841a9..b205aee71 100644 --- a/SmartDeviceLink/SDLAudioControlData.m +++ b/SmartDeviceLink/SDLAudioControlData.m @@ -38,7 +38,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)keepContext { - return [store sdl_objectForName:SDLRPCParameterNameKeepContext ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameKeepContext ofClass:NSNumber.class error:nil]; } - (void)setVolume:(nullable NSNumber<SDLInt> *)volume { @@ -46,7 +46,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)volume { - return [store sdl_objectForName:SDLRPCParameterNameVolume ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameVolume ofClass:NSNumber.class error:nil]; } - (void)setEqualizerSettings:(nullable NSArray<SDLEqualizerSettings *> *)equalizerSettings { @@ -54,7 +54,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLEqualizerSettings *> *)equalizerSettings { - return [store sdl_objectsForName:SDLRPCParameterNameEqualizerSettings ofClass:SDLEqualizerSettings.class]; + return [store sdl_objectsForName:SDLRPCParameterNameEqualizerSettings ofClass:SDLEqualizerSettings.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLAudioPassThruCapabilities.m b/SmartDeviceLink/SDLAudioPassThruCapabilities.m index 87c4e6473..51c1e64bb 100644 --- a/SmartDeviceLink/SDLAudioPassThruCapabilities.m +++ b/SmartDeviceLink/SDLAudioPassThruCapabilities.m @@ -16,7 +16,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLSamplingRate)samplingRate { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameSamplingRate error:&error]; } @@ -25,7 +25,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLBitsPerSample)bitsPerSample { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameBitsPerSample error:&error]; } @@ -34,7 +34,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLAudioType)audioType { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameAudioType error:&error]; } diff --git a/SmartDeviceLink/SDLBeltStatus.m b/SmartDeviceLink/SDLBeltStatus.m index eae7c8954..1432b9453 100644 --- a/SmartDeviceLink/SDLBeltStatus.m +++ b/SmartDeviceLink/SDLBeltStatus.m @@ -16,7 +16,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)driverBeltDeployed { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameDriverBeltDeployed error:&error]; } @@ -25,7 +25,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)passengerBeltDeployed { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNamePassengerBeltDeployed error:&error]; } @@ -34,7 +34,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)passengerBuckleBelted { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNamePassengerBuckleBelted error:&error]; } @@ -43,7 +43,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)driverBuckleBelted { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameDriverBuckleBelted error:&error]; } @@ -52,7 +52,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)leftRow2BuckleBelted { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameLeftRow2BuckleBelted error:&error]; } @@ -61,7 +61,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)passengerChildDetected { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNamePassengerChildDetected error:&error]; } @@ -70,7 +70,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)rightRow2BuckleBelted { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameRightRow2BuckleBelted error:&error]; } @@ -79,7 +79,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)middleRow2BuckleBelted { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameMiddleRow2BuckleBelted error:&error]; } @@ -88,7 +88,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)middleRow3BuckleBelted { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameMiddleRow3BuckleBelted error:&error]; } @@ -97,7 +97,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)leftRow3BuckleBelted { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameLeftRow3BuckleBelted error:&error]; } @@ -106,7 +106,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)rightRow3BuckleBelted { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameRightRow3BuckleBelted error:&error]; } @@ -115,7 +115,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)leftRearInflatableBelted { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameLeftRearInflatableBelted error:&error]; } @@ -124,7 +124,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)rightRearInflatableBelted { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameRightRearInflatableBelted error:&error]; } @@ -133,7 +133,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)middleRow1BeltDeployed { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameMiddleRow1BeltDeployed error:&error]; } @@ -142,7 +142,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)middleRow1BuckleBelted { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameMiddleRow1BuckleBelted error:&error]; } diff --git a/SmartDeviceLink/SDLBodyInformation.m b/SmartDeviceLink/SDLBodyInformation.m index e7360cb0b..5591998a3 100644 --- a/SmartDeviceLink/SDLBodyInformation.m +++ b/SmartDeviceLink/SDLBodyInformation.m @@ -18,7 +18,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)parkBrakeActive { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameParkBrakeActive ofClass:NSNumber.class error:&error]; } @@ -27,7 +27,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLIgnitionStableStatus)ignitionStableStatus { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameIgnitionStableStatus error:&error]; } @@ -36,7 +36,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLIgnitionStatus)ignitionStatus { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameIgnitionStatus error:&error]; } @@ -45,7 +45,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)driverDoorAjar { - return [store sdl_objectForName:SDLRPCParameterNameDriverDoorAjar ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameDriverDoorAjar ofClass:NSNumber.class error:nil]; } - (void)setPassengerDoorAjar:(nullable NSNumber<SDLBool> *)passengerDoorAjar { @@ -53,7 +53,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)passengerDoorAjar { - return [store sdl_objectForName:SDLRPCParameterNamePassengerDoorAjar ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNamePassengerDoorAjar ofClass:NSNumber.class error:nil]; } - (void)setRearLeftDoorAjar:(nullable NSNumber<SDLBool> *)rearLeftDoorAjar { @@ -61,7 +61,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)rearLeftDoorAjar { - return [store sdl_objectForName:SDLRPCParameterNameRearLeftDoorAjar ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameRearLeftDoorAjar ofClass:NSNumber.class error:nil]; } - (void)setRearRightDoorAjar:(nullable NSNumber<SDLBool> *)rearRightDoorAjar { @@ -69,7 +69,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)rearRightDoorAjar { - return [store sdl_objectForName:SDLRPCParameterNameRearRightDoorAjar ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameRearRightDoorAjar ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLButtonCapabilities.m b/SmartDeviceLink/SDLButtonCapabilities.m index 332bafc49..79fbc3fdf 100644 --- a/SmartDeviceLink/SDLButtonCapabilities.m +++ b/SmartDeviceLink/SDLButtonCapabilities.m @@ -15,7 +15,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLButtonName)name { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameName error:&error]; } @@ -24,7 +24,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)shortPressAvailable { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameShortPressAvailable ofClass:NSNumber.class error:&error]; } @@ -33,7 +33,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)longPressAvailable { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameLongPressAvailable ofClass:NSNumber.class error:&error]; } @@ -42,7 +42,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)upDownAvailable { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameUpDownAvailable ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLButtonPress.m b/SmartDeviceLink/SDLButtonPress.m index 0b3bbe78b..7823edbe2 100644 --- a/SmartDeviceLink/SDLButtonPress.m +++ b/SmartDeviceLink/SDLButtonPress.m @@ -34,7 +34,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLModuleType)moduleType { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameModuleType error:&error]; } @@ -43,7 +43,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLButtonName)buttonName { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameButtonName error:&error]; } @@ -52,7 +52,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLButtonPressMode)buttonPressMode { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameButtonPressMode error:&error]; } diff --git a/SmartDeviceLink/SDLChangeRegistration.m b/SmartDeviceLink/SDLChangeRegistration.m index bc975f6ee..828653a39 100644 --- a/SmartDeviceLink/SDLChangeRegistration.m +++ b/SmartDeviceLink/SDLChangeRegistration.m @@ -49,7 +49,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLLanguage)language { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameLanguage error:&error]; } @@ -58,7 +58,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLLanguage)hmiDisplayLanguage { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameHMIDisplayLanguage error:&error]; } @@ -67,7 +67,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)appName { - return [[parameters sdl_objectForName:SDLRPCParameterNameAppName ofClass:NSString.class] copy]; + return [[parameters sdl_objectForName:SDLRPCParameterNameAppName ofClass:NSString.class error:nil] copy]; } - (void)setTtsName:(nullable NSArray<SDLTTSChunk *> *)ttsName { @@ -75,7 +75,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLTTSChunk *> *)ttsName { - return [parameters sdl_objectsForName:SDLRPCParameterNameTTSName ofClass:SDLTTSChunk.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameTTSName ofClass:SDLTTSChunk.class error:nil]; } - (void)setNgnMediaScreenAppName:(nullable NSString *)ngnMediaScreenAppName { @@ -83,7 +83,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)ngnMediaScreenAppName { - return [parameters sdl_objectForName:SDLRPCParameterNameNGNMediaScreenAppName ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameNGNMediaScreenAppName ofClass:NSString.class error:nil]; } - (void)setVrSynonyms:(nullable NSArray<NSString *> *)vrSynonyms { @@ -91,7 +91,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<NSString *> *)vrSynonyms { - return [parameters sdl_objectsForName:SDLRPCParameterNameVRSynonyms ofClass:NSString.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameVRSynonyms ofClass:NSString.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLChoice.m b/SmartDeviceLink/SDLChoice.m index 4a398191b..0734c2a66 100644 --- a/SmartDeviceLink/SDLChoice.m +++ b/SmartDeviceLink/SDLChoice.m @@ -43,7 +43,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)choiceID { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameChoiceId ofClass:NSNumber.class error:&error]; } @@ -52,7 +52,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)menuName { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameMenuName ofClass:NSString.class error:&error]; } @@ -61,7 +61,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<NSString *> *)vrCommands { - return [store sdl_objectsForName:SDLRPCParameterNameVRCommands ofClass:NSString.class]; + return [store sdl_objectsForName:SDLRPCParameterNameVRCommands ofClass:NSString.class error:nil]; } - (void)setImage:(nullable SDLImage *)image { @@ -69,7 +69,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLImage *)image { - return [store sdl_objectForName:SDLRPCParameterNameImage ofClass:SDLImage.class]; + return [store sdl_objectForName:SDLRPCParameterNameImage ofClass:SDLImage.class error:nil]; } - (void)setSecondaryText:(nullable NSString *)secondaryText { @@ -77,7 +77,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)secondaryText { - return [store sdl_objectForName:SDLRPCParameterNameSecondaryText ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameSecondaryText ofClass:NSString.class error:nil]; } - (void)setTertiaryText:(nullable NSString *)tertiaryText { @@ -85,7 +85,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)tertiaryText { - return [store sdl_objectForName:SDLRPCParameterNameTertiaryText ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameTertiaryText ofClass:NSString.class error:nil]; } - (void)setSecondaryImage:(nullable SDLImage *)secondaryImage { @@ -93,7 +93,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLImage *)secondaryImage { - return [store sdl_objectForName:SDLRPCParameterNameSecondaryImage ofClass:SDLImage.class]; + return [store sdl_objectForName:SDLRPCParameterNameSecondaryImage ofClass:SDLImage.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLClimateControlCapabilities.m b/SmartDeviceLink/SDLClimateControlCapabilities.m index d36b1a88d..e34c8405f 100644 --- a/SmartDeviceLink/SDLClimateControlCapabilities.m +++ b/SmartDeviceLink/SDLClimateControlCapabilities.m @@ -43,7 +43,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)moduleName { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameModuleName ofClass:NSString.class error:&error]; } @@ -52,7 +52,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)fanSpeedAvailable { - return [store sdl_objectForName:SDLRPCParameterNameFanSpeedAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameFanSpeedAvailable ofClass:NSNumber.class error:nil]; } - (void)setDesiredTemperatureAvailable:(nullable NSNumber<SDLBool> *)desiredTemperatureAvailable { @@ -60,7 +60,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)desiredTemperatureAvailable { - return [store sdl_objectForName:SDLRPCParameterNameDesiredTemperatureAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameDesiredTemperatureAvailable ofClass:NSNumber.class error:nil]; } - (void)setAcEnableAvailable:(nullable NSNumber<SDLBool> *)acEnableAvailable { @@ -68,7 +68,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)acEnableAvailable { - return [store sdl_objectForName:SDLRPCParameterNameACEnableAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameACEnableAvailable ofClass:NSNumber.class error:nil]; } - (void)setAcMaxEnableAvailable:(nullable NSNumber<SDLBool> *)acMaxEnableAvailable { @@ -76,7 +76,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)acMaxEnableAvailable { - return [store sdl_objectForName:SDLRPCParameterNameACMaxEnableAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameACMaxEnableAvailable ofClass:NSNumber.class error:nil]; } - (void)setCirculateAirEnableAvailable:(nullable NSNumber<SDLBool> *)circulateAirEnableAvailable { @@ -84,7 +84,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)circulateAirEnableAvailable { - return [store sdl_objectForName:SDLRPCParameterNameCirculateAirEnableAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameCirculateAirEnableAvailable ofClass:NSNumber.class error:nil]; } - (void)setAutoModeEnableAvailable:(nullable NSNumber<SDLBool> *)autoModeEnableAvailable { @@ -92,7 +92,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)autoModeEnableAvailable { - return [store sdl_objectForName:SDLRPCParameterNameAutoModeEnableAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameAutoModeEnableAvailable ofClass:NSNumber.class error:nil]; } - (void)setDualModeEnableAvailable:(nullable NSNumber<SDLBool> *)dualModeEnableAvailable { @@ -100,7 +100,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)dualModeEnableAvailable { - return [store sdl_objectForName:SDLRPCParameterNameDualModeEnableAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameDualModeEnableAvailable ofClass:NSNumber.class error:nil]; } - (void)setDefrostZoneAvailable:(nullable NSNumber<SDLBool> *)defrostZoneAvailable { @@ -108,7 +108,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)defrostZoneAvailable { - return [store sdl_objectForName:SDLRPCParameterNameDefrostZoneAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameDefrostZoneAvailable ofClass:NSNumber.class error:nil]; } - (void)setDefrostZone:(nullable NSArray <SDLDefrostZone>*)defrostZone { @@ -124,7 +124,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)ventilationModeAvailable { - return [store sdl_objectForName:SDLRPCParameterNameVentilationModeAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameVentilationModeAvailable ofClass:NSNumber.class error:nil]; } - (void)setVentilationMode:(nullable NSArray<SDLVentilationMode> *)ventilationMode { @@ -140,7 +140,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)heatedSteeringWheelAvailable { - return [store sdl_objectForName:SDLRPCParameterNameHeatedSteeringWheelAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHeatedSteeringWheelAvailable ofClass:NSNumber.class error:nil]; } - (void)setHeatedWindshieldAvailable:(nullable NSNumber<SDLBool> *)heatedWindshieldAvailable { @@ -148,7 +148,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)heatedWindshieldAvailable { - return [store sdl_objectForName:SDLRPCParameterNameHeatedWindshieldAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHeatedWindshieldAvailable ofClass:NSNumber.class error:nil]; } - (void)setHeatedRearWindowAvailable:(nullable NSNumber<SDLBool> *)heatedRearWindowAvailable { @@ -156,7 +156,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)heatedRearWindowAvailable { - return [store sdl_objectForName:SDLRPCParameterNameHeatedRearWindowAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHeatedRearWindowAvailable ofClass:NSNumber.class error:nil]; } - (void)setHeatedMirrorsAvailable:(nullable NSNumber<SDLBool> *)heatedMirrorsAvailable { @@ -164,7 +164,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)heatedMirrorsAvailable { - return [store sdl_objectForName:SDLRPCParameterNameHeatedMirrorsAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHeatedMirrorsAvailable ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLClimateControlData.m b/SmartDeviceLink/SDLClimateControlData.m index bf5151759..f5e312e58 100644 --- a/SmartDeviceLink/SDLClimateControlData.m +++ b/SmartDeviceLink/SDLClimateControlData.m @@ -43,7 +43,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)fanSpeed { - return [store sdl_objectForName:SDLRPCParameterNameFanSpeed ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameFanSpeed ofClass:NSNumber.class error:nil]; } - (void)setCurrentTemperature:(nullable SDLTemperature *)currentTemperature { @@ -51,7 +51,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLTemperature *)currentTemperature { - return [store sdl_objectForName:SDLRPCParameterNameCurrentTemperature ofClass:SDLTemperature.class]; + return [store sdl_objectForName:SDLRPCParameterNameCurrentTemperature ofClass:SDLTemperature.class error:nil]; } - (void)setDesiredTemperature:(nullable SDLTemperature *)desiredTemperature { @@ -59,7 +59,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLTemperature *)desiredTemperature { - return [store sdl_objectForName:SDLRPCParameterNameDesiredTemperature ofClass:SDLTemperature.class]; + return [store sdl_objectForName:SDLRPCParameterNameDesiredTemperature ofClass:SDLTemperature.class error:nil]; } - (void)setAcEnable:(nullable NSNumber<SDLBool> *)acEnable { @@ -67,7 +67,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)acEnable { - return [store sdl_objectForName:SDLRPCParameterNameACEnable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameACEnable ofClass:NSNumber.class error:nil]; } - (void)setCirculateAirEnable:(nullable NSNumber<SDLBool> *)circulateAirEnable { @@ -75,7 +75,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)circulateAirEnable { - return [store sdl_objectForName:SDLRPCParameterNameCirculateAirEnable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameCirculateAirEnable ofClass:NSNumber.class error:nil]; } - (void)setAutoModeEnable:(nullable NSNumber<SDLBool> *)autoModeEnable { @@ -83,7 +83,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)autoModeEnable { - return [store sdl_objectForName:SDLRPCParameterNameAutoModeEnable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameAutoModeEnable ofClass:NSNumber.class error:nil]; } - (void)setDefrostZone:(nullable SDLDefrostZone)defrostZone { @@ -99,7 +99,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)dualModeEnable { - return [store sdl_objectForName:SDLRPCParameterNameDualModeEnable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameDualModeEnable ofClass:NSNumber.class error:nil]; } - (void)setAcMaxEnable:(nullable NSNumber<SDLBool> *)acMaxEnable { @@ -107,7 +107,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)acMaxEnable { - return [store sdl_objectForName:SDLRPCParameterNameACMaxEnable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameACMaxEnable ofClass:NSNumber.class error:nil]; } - (void)setVentilationMode:(nullable SDLVentilationMode)ventilationMode { @@ -123,7 +123,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)heatedSteeringWheelEnable { - return [store sdl_objectForName:SDLRPCParameterNameHeatedSteeringWheelEnable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHeatedSteeringWheelEnable ofClass:NSNumber.class error:nil]; } - (void)setHeatedWindshieldEnable:(nullable NSNumber<SDLBool> *)heatedWindshieldEnable { @@ -131,7 +131,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)heatedWindshieldEnable { - return [store sdl_objectForName:SDLRPCParameterNameHeatedWindshieldEnable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHeatedWindshieldEnable ofClass:NSNumber.class error:nil]; } - (void)setHeatedRearWindowEnable:(nullable NSNumber<SDLBool> *)heatedRearWindowEnable { @@ -139,7 +139,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)heatedRearWindowEnable { - return [store sdl_objectForName:SDLRPCParameterNameHeatedRearWindowEnable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHeatedRearWindowEnable ofClass:NSNumber.class error:nil]; } - (void)setHeatedMirrorsEnable:(nullable NSNumber<SDLBool> *)heatedMirrorsEnable { @@ -147,7 +147,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)heatedMirrorsEnable { - return [store sdl_objectForName:SDLRPCParameterNameHeatedMirrorsEnable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHeatedMirrorsEnable ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLClusterModeStatus.m b/SmartDeviceLink/SDLClusterModeStatus.m index 4d37978e4..05b635357 100644 --- a/SmartDeviceLink/SDLClusterModeStatus.m +++ b/SmartDeviceLink/SDLClusterModeStatus.m @@ -15,7 +15,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)powerModeActive { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNamePowerModeActive ofClass:NSNumber.class error:&error]; } @@ -24,7 +24,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLPowerModeQualificationStatus)powerModeQualificationStatus { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNamePowerModeQualificationStatus error:&error]; } @@ -33,7 +33,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLCarModeStatus)carModeStatus { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameCarModeStatus error:&error]; } @@ -42,7 +42,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLPowerModeStatus)powerModeStatus { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNamePowerModeStatus error:&error]; } diff --git a/SmartDeviceLink/SDLCreateInteractionChoiceSet.m b/SmartDeviceLink/SDLCreateInteractionChoiceSet.m index 06154fd9f..d35a0470b 100644 --- a/SmartDeviceLink/SDLCreateInteractionChoiceSet.m +++ b/SmartDeviceLink/SDLCreateInteractionChoiceSet.m @@ -35,7 +35,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)interactionChoiceSetID { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameInteractionChoiceSetId ofClass:NSNumber.class error:&error]; } @@ -44,7 +44,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<SDLChoice *> *)choiceSet { - NSError *error; + NSError *error = nil; return [parameters sdl_objectsForName:SDLRPCParameterNameChoiceSet ofClass:SDLChoice.class error:&error]; } diff --git a/SmartDeviceLink/SDLDIDResult.m b/SmartDeviceLink/SDLDIDResult.m index 14d7fc73d..885a64839 100644 --- a/SmartDeviceLink/SDLDIDResult.m +++ b/SmartDeviceLink/SDLDIDResult.m @@ -15,7 +15,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataResultCode)resultCode { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameResultCode error:&error]; } @@ -24,7 +24,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)didLocation { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameDIDLocation ofClass:NSNumber.class error:&error]; } @@ -33,7 +33,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)data { - return [store sdl_objectForName:SDLRPCParameterNameData ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameData ofClass:NSString.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLDateTime.m b/SmartDeviceLink/SDLDateTime.m index cfd0bc223..bb496cd9c 100644 --- a/SmartDeviceLink/SDLDateTime.m +++ b/SmartDeviceLink/SDLDateTime.m @@ -63,7 +63,7 @@ } - (NSNumber<SDLInt> *)millisecond { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameMillisecond ofClass:NSNumber.class error:&error]; } @@ -72,7 +72,7 @@ } - (NSNumber<SDLInt> *)second { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameSecond ofClass:NSNumber.class error:&error]; } @@ -81,7 +81,7 @@ } - (NSNumber<SDLInt> *)minute { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameMinute ofClass:NSNumber.class error:&error]; } @@ -90,7 +90,7 @@ } - (NSNumber<SDLInt> *)hour { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameHour ofClass:NSNumber.class error:&error]; } @@ -99,7 +99,7 @@ } - (NSNumber<SDLInt> *)day { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameDay ofClass:NSNumber.class error:&error]; } @@ -108,7 +108,7 @@ } - (NSNumber<SDLInt> *)month { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameMonth ofClass:NSNumber.class error:&error]; } @@ -117,7 +117,7 @@ } - (NSNumber<SDLInt> *)year { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameYear ofClass:NSNumber.class error:&error]; } @@ -126,7 +126,7 @@ } - (NSNumber<SDLInt> *)timezoneMinuteOffset { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameTimezoneMinuteOffset ofClass:NSNumber.class error:&error]; } @@ -135,7 +135,7 @@ } - (NSNumber<SDLInt> *)timezoneHourOffset { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameTimezoneHourOffset ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLDeleteCommand.m b/SmartDeviceLink/SDLDeleteCommand.m index dec3dd105..cc8b80feb 100644 --- a/SmartDeviceLink/SDLDeleteCommand.m +++ b/SmartDeviceLink/SDLDeleteCommand.m @@ -34,7 +34,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)cmdID { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameCommandId ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLDeleteFile.m b/SmartDeviceLink/SDLDeleteFile.m index bcd50bbd3..007959f47 100644 --- a/SmartDeviceLink/SDLDeleteFile.m +++ b/SmartDeviceLink/SDLDeleteFile.m @@ -34,7 +34,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)syncFileName { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameSyncFileName ofClass:NSString.class error:&error]; } diff --git a/SmartDeviceLink/SDLDeleteFileResponse.m b/SmartDeviceLink/SDLDeleteFileResponse.m index 78edc6293..cddc4f1a2 100644 --- a/SmartDeviceLink/SDLDeleteFileResponse.m +++ b/SmartDeviceLink/SDLDeleteFileResponse.m @@ -23,7 +23,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)spaceAvailable { - return [parameters sdl_objectForName:SDLRPCParameterNameSpaceAvailable ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSpaceAvailable ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLDeleteInteractionChoiceSet.m b/SmartDeviceLink/SDLDeleteInteractionChoiceSet.m index 3c1f66bf6..8c749aaea 100644 --- a/SmartDeviceLink/SDLDeleteInteractionChoiceSet.m +++ b/SmartDeviceLink/SDLDeleteInteractionChoiceSet.m @@ -34,7 +34,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)interactionChoiceSetID { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameInteractionChoiceSetId ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLDeleteSubMenu.m b/SmartDeviceLink/SDLDeleteSubMenu.m index 44b1f181f..6e260712e 100644 --- a/SmartDeviceLink/SDLDeleteSubMenu.m +++ b/SmartDeviceLink/SDLDeleteSubMenu.m @@ -34,7 +34,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)menuID { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameMenuId ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLDeviceInfo.m b/SmartDeviceLink/SDLDeviceInfo.m index 6afabdcfd..cd4474166 100644 --- a/SmartDeviceLink/SDLDeviceInfo.m +++ b/SmartDeviceLink/SDLDeviceInfo.m @@ -34,7 +34,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)hardware { - return [store sdl_objectForName:SDLRPCParameterNameHardware ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameHardware ofClass:NSString.class error:nil]; } - (void)setFirmwareRev:(nullable NSString *)firmwareRev { @@ -42,7 +42,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)firmwareRev { - return [store sdl_objectForName:SDLRPCParameterNameFirmwareRevision ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameFirmwareRevision ofClass:NSString.class error:nil]; } - (void)setOs:(nullable NSString *)os { @@ -50,7 +50,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)os { - return [store sdl_objectForName:SDLRPCParameterNameOS ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameOS ofClass:NSString.class error:nil]; } - (void)setOsVersion:(nullable NSString *)osVersion { @@ -58,7 +58,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)osVersion { - return [store sdl_objectForName:SDLRPCParameterNameOSVersion ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameOSVersion ofClass:NSString.class error:nil]; } - (void)setCarrier:(nullable NSString *)carrier { @@ -66,7 +66,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)carrier { - return [store sdl_objectForName:SDLRPCParameterNameCarrier ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameCarrier ofClass:NSString.class error:nil]; } - (void)setMaxNumberRFCOMMPorts:(nullable NSNumber<SDLInt> *)maxNumberRFCOMMPorts { @@ -74,7 +74,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)maxNumberRFCOMMPorts { - return [store sdl_objectForName:SDLRPCParameterNameMaxNumberRFCOMMPorts ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameMaxNumberRFCOMMPorts ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLDeviceStatus.m b/SmartDeviceLink/SDLDeviceStatus.m index bab61c0f2..048e4f8c4 100644 --- a/SmartDeviceLink/SDLDeviceStatus.m +++ b/SmartDeviceLink/SDLDeviceStatus.m @@ -17,7 +17,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)voiceRecOn { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameVoiceRecognitionOn ofClass:NSNumber.class error:&error]; } @@ -26,7 +26,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)btIconOn { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameBluetoothIconOn ofClass:NSNumber.class error:&error]; } @@ -35,7 +35,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)callActive { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameCallActive ofClass:NSNumber.class error:&error]; } @@ -44,7 +44,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)phoneRoaming { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNamePhoneRoaming ofClass:NSNumber.class error:&error]; } @@ -53,7 +53,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)textMsgAvailable { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameTextMessageAvailable ofClass:NSNumber.class error:&error]; } @@ -62,7 +62,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLDeviceLevelStatus)battLevelStatus { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameBatteryLevelStatus error:&error]; } @@ -71,7 +71,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)stereoAudioOutputMuted { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameStereoAudioOutputMuted ofClass:NSNumber.class error:&error]; } @@ -80,7 +80,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)monoAudioOutputMuted { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameMonoAudioOutputMuted ofClass:NSNumber.class error:&error]; } @@ -89,7 +89,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLDeviceLevelStatus)signalLevelStatus { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameSignalLevelStatus error:&error]; } @@ -98,7 +98,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLPrimaryAudioSource)primaryAudioSource { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNamePrimaryAudioSource error:&error]; } @@ -107,7 +107,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)eCallEventActive { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameECallEventActive ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLDiagnosticMessage.m b/SmartDeviceLink/SDLDiagnosticMessage.m index 95eae8a18..89f636c26 100644 --- a/SmartDeviceLink/SDLDiagnosticMessage.m +++ b/SmartDeviceLink/SDLDiagnosticMessage.m @@ -36,7 +36,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)targetID { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameTargetId ofClass:NSNumber.class error:&error]; } @@ -45,7 +45,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)messageLength { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameMessageLength ofClass:NSNumber.class error:&error]; } @@ -54,7 +54,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<NSNumber<SDLInt> *> *)messageData { - NSError *error; + NSError *error = nil; return [parameters sdl_objectsForName:SDLRPCParameterNameMessageData ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLDiagnosticMessageResponse.m b/SmartDeviceLink/SDLDiagnosticMessageResponse.m index ad48d199c..6b275135a 100644 --- a/SmartDeviceLink/SDLDiagnosticMessageResponse.m +++ b/SmartDeviceLink/SDLDiagnosticMessageResponse.m @@ -22,7 +22,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<NSNumber<SDLInt> *> *)messageDataResult { - NSError *error; + NSError *error = nil; return [parameters sdl_objectsForName:SDLRPCParameterNameMessageDataResult ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLDialNumber.m b/SmartDeviceLink/SDLDialNumber.m index ae82fac75..47c312416 100644 --- a/SmartDeviceLink/SDLDialNumber.m +++ b/SmartDeviceLink/SDLDialNumber.m @@ -32,7 +32,7 @@ } - (NSString *)number { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameNumber ofClass:NSString.class error:&error]; } diff --git a/SmartDeviceLink/SDLDisplayCapabilities.m b/SmartDeviceLink/SDLDisplayCapabilities.m index 015af1159..8667eafa8 100644 --- a/SmartDeviceLink/SDLDisplayCapabilities.m +++ b/SmartDeviceLink/SDLDisplayCapabilities.m @@ -18,7 +18,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLDisplayType)displayType { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameDisplayType error:&error]; } @@ -27,7 +27,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)displayName { - return [store sdl_objectForName:SDLRPCParameterNameDisplayName ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameDisplayName ofClass:NSString.class error:nil]; } - (void)setTextFields:(NSArray<SDLTextField *> *)textFields { @@ -35,7 +35,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<SDLTextField *> *)textFields { - NSError *error; + NSError *error = nil; return [store sdl_objectsForName:SDLRPCParameterNameTextFields ofClass:SDLTextField.class error:&error]; } @@ -44,7 +44,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLImageField *> *)imageFields { - return [store sdl_objectsForName:SDLRPCParameterNameImageFields ofClass:SDLImageField.class]; + return [store sdl_objectsForName:SDLRPCParameterNameImageFields ofClass:SDLImageField.class error:nil]; } - (void)setMediaClockFormats:(NSArray<SDLMediaClockFormat> *)mediaClockFormats { @@ -52,7 +52,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<SDLMediaClockFormat> *)mediaClockFormats { - NSError *error; + NSError *error = nil; return [store sdl_enumsForName:SDLRPCParameterNameMediaClockFormats error:&error]; } @@ -61,7 +61,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)graphicSupported { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameGraphicSupported ofClass:NSNumber.class error:&error]; } @@ -70,7 +70,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<NSString *> *)templatesAvailable { - return [store sdl_objectsForName:SDLRPCParameterNameTemplatesAvailable ofClass:NSString.class]; + return [store sdl_objectsForName:SDLRPCParameterNameTemplatesAvailable ofClass:NSString.class error:nil]; } - (void)setScreenParams:(nullable SDLScreenParams *)screenParams { @@ -78,7 +78,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLScreenParams *)screenParams { - return [store sdl_objectForName:SDLRPCParameterNameScreenParams ofClass:SDLScreenParams.class]; + return [store sdl_objectForName:SDLRPCParameterNameScreenParams ofClass:SDLScreenParams.class error:nil]; } - (void)setNumCustomPresetsAvailable:(nullable NSNumber<SDLInt> *)numCustomPresetsAvailable { @@ -86,7 +86,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)numCustomPresetsAvailable { - return [store sdl_objectForName:SDLRPCParameterNameNumberCustomPresetsAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameNumberCustomPresetsAvailable ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLECallInfo.m b/SmartDeviceLink/SDLECallInfo.m index 55175b12e..4b77e3e3d 100644 --- a/SmartDeviceLink/SDLECallInfo.m +++ b/SmartDeviceLink/SDLECallInfo.m @@ -15,7 +15,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataNotificationStatus)eCallNotificationStatus { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameECallNotificationStatus error:&error]; } @@ -24,7 +24,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataNotificationStatus)auxECallNotificationStatus { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameAuxECallNotificationStatus error:&error]; } @@ -33,7 +33,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLECallConfirmationStatus)eCallConfirmationStatus { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameECallConfirmationStatus error:&error]; } diff --git a/SmartDeviceLink/SDLEmergencyEvent.m b/SmartDeviceLink/SDLEmergencyEvent.m index e071d04c2..e2869823c 100644 --- a/SmartDeviceLink/SDLEmergencyEvent.m +++ b/SmartDeviceLink/SDLEmergencyEvent.m @@ -15,7 +15,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLEmergencyEventType)emergencyEventType { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameEmergencyEventType error:&error]; } @@ -24,7 +24,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLFuelCutoffStatus)fuelCutoffStatus { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameFuelCutoffStatus error:&error]; } @@ -33,7 +33,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)rolloverEvent { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameRolloverEvent error:&error]; } @@ -42,7 +42,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)maximumChangeVelocity { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameMaximumChangeVelocity ofClass:NSNumber.class error:&error]; } @@ -51,7 +51,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataEventStatus)multipleEvents { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameMultipleEvents error:&error]; } diff --git a/SmartDeviceLink/SDLEncodedSyncPData.m b/SmartDeviceLink/SDLEncodedSyncPData.m index 0067b5491..913e2f53a 100644 --- a/SmartDeviceLink/SDLEncodedSyncPData.m +++ b/SmartDeviceLink/SDLEncodedSyncPData.m @@ -23,7 +23,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<NSString *> *)data { - NSError *error; + NSError *error = nil; return [parameters sdl_objectsForName:SDLRPCParameterNameData ofClass:NSString.class error:&error]; } diff --git a/SmartDeviceLink/SDLEqualizerSettings.m b/SmartDeviceLink/SDLEqualizerSettings.m index 191f5ac78..988177006 100644 --- a/SmartDeviceLink/SDLEqualizerSettings.m +++ b/SmartDeviceLink/SDLEqualizerSettings.m @@ -26,7 +26,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)channelId { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameChannelId ofClass:NSNumber.class error:&error]; } @@ -35,7 +35,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)channelName { - return [store sdl_objectForName:SDLRPCParameterNameChannelName ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameChannelName ofClass:NSString.class error:nil]; } - (void)setChannelSetting:(NSNumber<SDLInt> *)channelSetting { @@ -43,7 +43,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)channelSetting { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameChannelSetting ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLError.h b/SmartDeviceLink/SDLError.h index e13f24182..8b018fda0 100644 --- a/SmartDeviceLink/SDLError.h +++ b/SmartDeviceLink/SDLError.h @@ -77,7 +77,7 @@ extern SDLErrorDomain *const SDLErrorDomainStore; #pragma mark Store -+ (NSError *)sdl_store_wrongObject:(id)wrongObject expectedType:(Class)type; ++ (NSError *)sdl_store_invalidObjectErrorWithObject:(id)wrongObject expectedType:(Class)type; @end diff --git a/SmartDeviceLink/SDLError.m b/SmartDeviceLink/SDLError.m index a788764ba..025ff9068 100644 --- a/SmartDeviceLink/SDLError.m +++ b/SmartDeviceLink/SDLError.m @@ -19,7 +19,7 @@ SDLErrorDomain *const SDLErrorDomainSoftButtonManager = @"com.sdl.softbuttonmana SDLErrorDomain *const SDLErrorDomainMenuManager = @"com.sdl.menumanager.error"; SDLErrorDomain *const SDLErrorDomainChoiceSetManager = @"com.sdl.choicesetmanager.error"; SDLErrorDomain *const SDLErrorDomainTransport = @"com.sdl.transport.error"; -SDLErrorDomain *const SDLErrorDomainStore = @"com.sdl.dictionary.store"; +SDLErrorDomain *const SDLErrorDomainStore = @"com.sdl.rpcStore.error"; @implementation NSError (SDLErrors) @@ -268,13 +268,13 @@ SDLErrorDomain *const SDLErrorDomainStore = @"com.sdl.dictionary.store"; #pragma mark Store -+ (NSError *)sdl_store_wrongObject:(id)wrongObject expectedType:(Class)type { ++ (NSError *)sdl_store_invalidObjectErrorWithObject:(id)wrongObject expectedType:(Class)type { NSDictionary<NSString *, NSString *> *userInfo = @{ NSLocalizedDescriptionKey: NSLocalizedString(@"Type of stored value doesn't match with requested", nil), NSLocalizedFailureReasonErrorKey: [NSString stringWithFormat:@"Requested %@ but returned %@", NSStringFromClass(type), NSStringFromClass([wrongObject class])], - NSLocalizedRecoverySuggestionErrorKey: NSLocalizedString(@"Check the expected object type", nil) + NSLocalizedRecoverySuggestionErrorKey: NSLocalizedString(@"Check the object type returned from the head unit system", nil) }; - return [NSError errorWithDomain:SDLErrorDomainStore code:SDLStoreErrorWrongObject userInfo:userInfo]; + return [NSError errorWithDomain:SDLErrorDomainStore code:SDLRPCStoreErrorGetInvalidObject userInfo:userInfo]; } @end diff --git a/SmartDeviceLink/SDLErrorConstants.h b/SmartDeviceLink/SDLErrorConstants.h index 0041b88be..c86ee2946 100644 --- a/SmartDeviceLink/SDLErrorConstants.h +++ b/SmartDeviceLink/SDLErrorConstants.h @@ -153,9 +153,9 @@ typedef NS_ENUM(NSInteger, SDLTransportError) { /** * Errors associated with store. */ -typedef NS_ENUM(NSInteger, SDLStoreError) { +typedef NS_ENUM(NSInteger, SDLRPCStoreError) { /** * In dictionary stored value with unexpected type */ - SDLStoreErrorWrongObject = -1, + SDLRPCStoreErrorGetInvalidObject = -1, }; diff --git a/SmartDeviceLink/SDLFuelRange.m b/SmartDeviceLink/SDLFuelRange.m index 2e63141c3..01d704484 100644 --- a/SmartDeviceLink/SDLFuelRange.m +++ b/SmartDeviceLink/SDLFuelRange.m @@ -28,7 +28,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)range { - return [store sdl_objectForName:SDLRPCParameterNameRange ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameRange ofClass:NSNumber.class error:nil]; } diff --git a/SmartDeviceLink/SDLGPSData.m b/SmartDeviceLink/SDLGPSData.m index aaf616e52..11caf5f5c 100644 --- a/SmartDeviceLink/SDLGPSData.m +++ b/SmartDeviceLink/SDLGPSData.m @@ -15,7 +15,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLFloat> *)longitudeDegrees { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameLongitudeDegrees ofClass:NSNumber.class error:&error]; } @@ -24,7 +24,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLFloat> *)latitudeDegrees { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameLatitudeDegrees ofClass:NSNumber.class error:&error]; } @@ -33,7 +33,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)utcYear { - return [store sdl_objectForName:SDLRPCParameterNameUTCYear ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameUTCYear ofClass:NSNumber.class error:nil]; } - (void)setUtcMonth:(nullable NSNumber<SDLInt> *)utcMonth { @@ -41,7 +41,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)utcMonth { - return [store sdl_objectForName:SDLRPCParameterNameUTCMonth ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameUTCMonth ofClass:NSNumber.class error:nil]; } - (void)setUtcDay:(nullable NSNumber<SDLInt> *)utcDay { @@ -49,7 +49,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)utcDay { - return [store sdl_objectForName:SDLRPCParameterNameUTCDay ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameUTCDay ofClass:NSNumber.class error:nil]; } - (void)setUtcHours:(nullable NSNumber<SDLInt> *)utcHours { @@ -57,7 +57,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)utcHours { - return [store sdl_objectForName:SDLRPCParameterNameUTCHours ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameUTCHours ofClass:NSNumber.class error:nil]; } - (void)setUtcMinutes:(nullable NSNumber<SDLInt> *)utcMinutes { @@ -65,7 +65,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)utcMinutes { - return [store sdl_objectForName:SDLRPCParameterNameUTCMinutes ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameUTCMinutes ofClass:NSNumber.class error:nil]; } - (void)setUtcSeconds:(nullable NSNumber<SDLInt> *)utcSeconds { @@ -73,7 +73,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)utcSeconds { - return [store sdl_objectForName:SDLRPCParameterNameUTCSeconds ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameUTCSeconds ofClass:NSNumber.class error:nil]; } - (void)setCompassDirection:(nullable SDLCompassDirection)compassDirection { @@ -89,7 +89,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)pdop { - return [store sdl_objectForName:SDLRPCParameterNamePDOP ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNamePDOP ofClass:NSNumber.class error:nil]; } - (void)setHdop:(nullable NSNumber<SDLFloat> *)hdop { @@ -97,7 +97,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)hdop { - return [store sdl_objectForName:SDLRPCParameterNameHDOP ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHDOP ofClass:NSNumber.class error:nil]; } - (void)setVdop:(nullable NSNumber<SDLFloat> *)vdop { @@ -105,7 +105,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)vdop { - return [store sdl_objectForName:SDLRPCParameterNameVDOP ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameVDOP ofClass:NSNumber.class error:nil]; } - (void)setActual:(nullable NSNumber<SDLBool> *)actual { @@ -113,7 +113,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)actual { - return [store sdl_objectForName:SDLRPCParameterNameActual ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameActual ofClass:NSNumber.class error:nil]; } - (void)setSatellites:(nullable NSNumber<SDLInt> *)satellites { @@ -121,7 +121,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)satellites { - return [store sdl_objectForName:SDLRPCParameterNameSatellites ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameSatellites ofClass:NSNumber.class error:nil]; } - (void)setDimension:(nullable SDLDimension)dimension { @@ -137,7 +137,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)altitude { - return [store sdl_objectForName:SDLRPCParameterNameAltitude ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameAltitude ofClass:NSNumber.class error:nil]; } - (void)setHeading:(nullable NSNumber<SDLFloat> *)heading { @@ -145,7 +145,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)heading { - return [store sdl_objectForName:SDLRPCParameterNameHeading ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHeading ofClass:NSNumber.class error:nil]; } - (void)setSpeed:(nullable NSNumber<SDLFloat> *)speed { @@ -153,7 +153,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)speed { - return [store sdl_objectForName:SDLRPCParameterNameSpeed ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameSpeed ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLGetAppServiceData.m b/SmartDeviceLink/SDLGetAppServiceData.m index 2a0948834..0baec947e 100644 --- a/SmartDeviceLink/SDLGetAppServiceData.m +++ b/SmartDeviceLink/SDLGetAppServiceData.m @@ -57,7 +57,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)serviceType { - return [parameters sdl_objectForName:SDLRPCParameterNameServiceType ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameServiceType ofClass:NSString.class error:nil]; } - (void)setSubscribe:(nullable NSNumber<SDLBool> *)subscribe { @@ -65,7 +65,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)subscribe { - return [parameters sdl_objectForName:SDLRPCParameterNameSubscribe ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSubscribe ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLGetAppServiceDataResponse.m b/SmartDeviceLink/SDLGetAppServiceDataResponse.m index c1302aaf9..de67e4cc8 100644 --- a/SmartDeviceLink/SDLGetAppServiceDataResponse.m +++ b/SmartDeviceLink/SDLGetAppServiceDataResponse.m @@ -39,7 +39,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLAppServiceData *)serviceData { - return [parameters sdl_objectForName:SDLRPCParameterNameServiceData ofClass:SDLAppServiceData.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameServiceData ofClass:SDLAppServiceData.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLGetDTCs.m b/SmartDeviceLink/SDLGetDTCs.m index a6bde3cb5..61b7e0b74 100644 --- a/SmartDeviceLink/SDLGetDTCs.m +++ b/SmartDeviceLink/SDLGetDTCs.m @@ -45,7 +45,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)ecuName { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameECUName ofClass:NSNumber.class error:&error]; } @@ -54,7 +54,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)dtcMask { - return [parameters sdl_objectForName:SDLRPCParameterNameDTCMask ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameDTCMask ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLGetDTCsResponse.m b/SmartDeviceLink/SDLGetDTCsResponse.m index af115982b..ce31face1 100644 --- a/SmartDeviceLink/SDLGetDTCsResponse.m +++ b/SmartDeviceLink/SDLGetDTCsResponse.m @@ -23,7 +23,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)ecuHeader { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameECUHeader ofClass:NSNumber.class error:&error]; } @@ -32,7 +32,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<NSString *> *)dtc { - NSError *error; + NSError *error = nil; return [parameters sdl_objectsForName:SDLRPCParameterNameDTC ofClass:NSString.class error:&error]; } diff --git a/SmartDeviceLink/SDLGetFile.m b/SmartDeviceLink/SDLGetFile.m index f7d2bed11..d581a369c 100644 --- a/SmartDeviceLink/SDLGetFile.m +++ b/SmartDeviceLink/SDLGetFile.m @@ -63,7 +63,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)fileName { - return [parameters sdl_objectForName:SDLRPCParameterNameFilename ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameFilename ofClass:NSString.class error:nil]; } - (void)setAppServiceId:(nullable NSString *)appServiceId { @@ -71,7 +71,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)appServiceId { - return [parameters sdl_objectForName:SDLRPCParameterNameAppServiceId ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAppServiceId ofClass:NSString.class error:nil]; } - (void)setFileType:(nullable SDLFileType)fileType { @@ -87,7 +87,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLUInt> *)offset { - return [parameters sdl_objectForName:SDLRPCParameterNameOffset ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameOffset ofClass:NSNumber.class error:nil]; } - (void)setLength:(nullable NSNumber<SDLUInt> *)length { @@ -95,7 +95,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLUInt> *)length { - return [parameters sdl_objectForName:SDLRPCParameterNameLength ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameLength ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLGetFileResponse.m b/SmartDeviceLink/SDLGetFileResponse.m index 2f19d5bb5..14e86e8ce 100644 --- a/SmartDeviceLink/SDLGetFileResponse.m +++ b/SmartDeviceLink/SDLGetFileResponse.m @@ -41,7 +41,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLUInt> *)offset { - return [parameters sdl_objectForName:SDLRPCParameterNameOffset ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameOffset ofClass:NSNumber.class error:nil]; } - (void)setLength:(nullable NSNumber<SDLUInt> *)length { @@ -49,7 +49,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLUInt> *)length { - return [parameters sdl_objectForName:SDLRPCParameterNameLength ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameLength ofClass:NSNumber.class error:nil]; } - (void)setFileType:(nullable SDLFileType)fileType { @@ -65,7 +65,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLUInt> *)crc { - return [parameters sdl_objectForName:SDLRPCParameterNameCRC ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameCRC ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLGetInteriorVehicleData.m b/SmartDeviceLink/SDLGetInteriorVehicleData.m index f29c48820..f91938fa3 100755 --- a/SmartDeviceLink/SDLGetInteriorVehicleData.m +++ b/SmartDeviceLink/SDLGetInteriorVehicleData.m @@ -57,7 +57,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLModuleType)moduleType { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameModuleType error:&error]; } @@ -66,7 +66,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)subscribe { - return [parameters sdl_objectForName:SDLRPCParameterNameSubscribe ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSubscribe ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLGetInteriorVehicleDataResponse.m b/SmartDeviceLink/SDLGetInteriorVehicleDataResponse.m index 65c4c9854..3a7096cb3 100644 --- a/SmartDeviceLink/SDLGetInteriorVehicleDataResponse.m +++ b/SmartDeviceLink/SDLGetInteriorVehicleDataResponse.m @@ -24,7 +24,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLModuleData *)moduleData { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameModuleData ofClass:SDLModuleData.class error:&error]; } @@ -33,7 +33,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)isSubscribed { - return [parameters sdl_objectForName:SDLRPCParameterNameIsSubscribed ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameIsSubscribed ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLGetSystemCapability.m b/SmartDeviceLink/SDLGetSystemCapability.m index 74d4df538..df14d5212 100644 --- a/SmartDeviceLink/SDLGetSystemCapability.m +++ b/SmartDeviceLink/SDLGetSystemCapability.m @@ -50,7 +50,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLSystemCapabilityType)systemCapabilityType { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameSystemCapabilityType error:&error]; } @@ -59,7 +59,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)subscribe { - return [parameters sdl_objectForName:SDLRPCParameterNameSubscribe ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSubscribe ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLGetSystemCapabilityResponse.m b/SmartDeviceLink/SDLGetSystemCapabilityResponse.m index 126a87147..e1cd63f90 100644 --- a/SmartDeviceLink/SDLGetSystemCapabilityResponse.m +++ b/SmartDeviceLink/SDLGetSystemCapabilityResponse.m @@ -32,7 +32,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLSystemCapability *)systemCapability { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameSystemCapability ofClass:SDLSystemCapability.class error:&error]; } diff --git a/SmartDeviceLink/SDLGetVehicleData.m b/SmartDeviceLink/SDLGetVehicleData.m index 66f7adfe1..ab6ff5d0c 100644 --- a/SmartDeviceLink/SDLGetVehicleData.m +++ b/SmartDeviceLink/SDLGetVehicleData.m @@ -66,7 +66,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)gps { - return [parameters sdl_objectForName:SDLRPCParameterNameGPS ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameGPS ofClass:NSNumber.class error:nil]; } - (void)setSpeed:(nullable NSNumber<SDLBool> *)speed { @@ -74,7 +74,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)speed { - return [parameters sdl_objectForName:SDLRPCParameterNameSpeed ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSpeed ofClass:NSNumber.class error:nil]; } - (void)setRpm:(nullable NSNumber<SDLBool> *)rpm { @@ -82,7 +82,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)rpm { - return [parameters sdl_objectForName:SDLRPCParameterNameRPM ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameRPM ofClass:NSNumber.class error:nil]; } - (void)setFuelLevel:(nullable NSNumber<SDLBool> *)fuelLevel { @@ -90,7 +90,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)fuelLevel { - return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevel ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevel ofClass:NSNumber.class error:nil]; } - (void)setFuelLevel_State:(nullable NSNumber<SDLBool> *)fuelLevel_State { @@ -98,7 +98,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)fuelLevel_State { - return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevelState ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevelState ofClass:NSNumber.class error:nil]; } - (void)setFuelRange:(nullable NSNumber<SDLBool> *)fuelRange { @@ -106,7 +106,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)fuelRange { - return [parameters sdl_objectForName:SDLRPCParameterNameFuelRange ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameFuelRange ofClass:NSNumber.class error:nil]; } - (void)setInstantFuelConsumption:(nullable NSNumber<SDLBool> *)instantFuelConsumption { @@ -114,7 +114,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)instantFuelConsumption { - return [parameters sdl_objectForName:SDLRPCParameterNameInstantFuelConsumption ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameInstantFuelConsumption ofClass:NSNumber.class error:nil]; } - (void)setExternalTemperature:(nullable NSNumber<SDLBool> *)externalTemperature { @@ -122,7 +122,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)externalTemperature { - return [parameters sdl_objectForName:SDLRPCParameterNameExternalTemperature ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameExternalTemperature ofClass:NSNumber.class error:nil]; } - (void)setVin:(nullable NSNumber<SDLBool> *)vin { @@ -130,7 +130,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)vin { - return [parameters sdl_objectForName:SDLRPCParameterNameVIN ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameVIN ofClass:NSNumber.class error:nil]; } - (void)setPrndl:(nullable NSNumber<SDLBool> *)prndl { @@ -138,7 +138,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)prndl { - return [parameters sdl_objectForName:SDLRPCParameterNamePRNDL ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNamePRNDL ofClass:NSNumber.class error:nil]; } - (void)setTirePressure:(nullable NSNumber<SDLBool> *)tirePressure { @@ -146,7 +146,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)tirePressure { - return [parameters sdl_objectForName:SDLRPCParameterNameTirePressure ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameTirePressure ofClass:NSNumber.class error:nil]; } - (void)setOdometer:(nullable NSNumber<SDLBool> *)odometer { @@ -154,7 +154,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)odometer { - return [parameters sdl_objectForName:SDLRPCParameterNameOdometer ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameOdometer ofClass:NSNumber.class error:nil]; } - (void)setBeltStatus:(nullable NSNumber<SDLBool> *)beltStatus { @@ -162,7 +162,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)beltStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameBeltStatus ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameBeltStatus ofClass:NSNumber.class error:nil]; } - (void)setBodyInformation:(nullable NSNumber<SDLBool> *)bodyInformation { @@ -170,7 +170,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)bodyInformation { - return [parameters sdl_objectForName:SDLRPCParameterNameBodyInformation ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameBodyInformation ofClass:NSNumber.class error:nil]; } - (void)setDeviceStatus:(nullable NSNumber<SDLBool> *)deviceStatus { @@ -178,7 +178,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)deviceStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameDeviceStatus ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameDeviceStatus ofClass:NSNumber.class error:nil]; } - (void)setDriverBraking:(nullable NSNumber<SDLBool> *)driverBraking { @@ -186,7 +186,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)driverBraking { - return [parameters sdl_objectForName:SDLRPCParameterNameDriverBraking ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameDriverBraking ofClass:NSNumber.class error:nil]; } - (void)setWiperStatus:(nullable NSNumber<SDLBool> *)wiperStatus { @@ -194,7 +194,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)wiperStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameWiperStatus ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameWiperStatus ofClass:NSNumber.class error:nil]; } - (void)setHeadLampStatus:(nullable NSNumber<SDLBool> *)headLampStatus { @@ -202,7 +202,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)headLampStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameHeadLampStatus ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameHeadLampStatus ofClass:NSNumber.class error:nil]; } - (void)setEngineOilLife:(nullable NSNumber<SDLBool> *)engineOilLife { @@ -210,7 +210,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)engineOilLife { - return [parameters sdl_objectForName:SDLRPCParameterNameEngineOilLife ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameEngineOilLife ofClass:NSNumber.class error:nil]; } - (void)setEngineTorque:(nullable NSNumber<SDLBool> *)engineTorque { @@ -218,7 +218,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)engineTorque { - return [parameters sdl_objectForName:SDLRPCParameterNameEngineTorque ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameEngineTorque ofClass:NSNumber.class error:nil]; } - (void)setAccPedalPosition:(nullable NSNumber<SDLBool> *)accPedalPosition { @@ -226,7 +226,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)accPedalPosition { - return [parameters sdl_objectForName:SDLRPCParameterNameAccelerationPedalPosition ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAccelerationPedalPosition ofClass:NSNumber.class error:nil]; } - (void)setSteeringWheelAngle:(nullable NSNumber<SDLBool> *)steeringWheelAngle { @@ -234,7 +234,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)steeringWheelAngle { - return [parameters sdl_objectForName:SDLRPCParameterNameSteeringWheelAngle ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSteeringWheelAngle ofClass:NSNumber.class error:nil]; } - (void)setECallInfo:(nullable NSNumber<SDLBool> *)eCallInfo { @@ -242,7 +242,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)eCallInfo { - return [parameters sdl_objectForName:SDLRPCParameterNameECallInfo ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameECallInfo ofClass:NSNumber.class error:nil]; } - (void)setAirbagStatus:(nullable NSNumber<SDLBool> *)airbagStatus { @@ -250,7 +250,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)airbagStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameAirbagStatus ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAirbagStatus ofClass:NSNumber.class error:nil]; } - (void)setEmergencyEvent:(nullable NSNumber<SDLBool> *)emergencyEvent { @@ -258,7 +258,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)emergencyEvent { - return [parameters sdl_objectForName:SDLRPCParameterNameEmergencyEvent ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameEmergencyEvent ofClass:NSNumber.class error:nil]; } - (void)setClusterModeStatus:(nullable NSNumber<SDLBool> *)clusterModeStatus { @@ -266,7 +266,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)clusterModeStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameClusterModeStatus ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameClusterModeStatus ofClass:NSNumber.class error:nil]; } - (void)setMyKey:(nullable NSNumber<SDLBool> *)myKey { @@ -274,7 +274,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)myKey { - return [parameters sdl_objectForName:SDLRPCParameterNameMyKey ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameMyKey ofClass:NSNumber.class error:nil]; } - (void)setElectronicParkBrakeStatus:(nullable NSNumber<SDLBool> *)electronicParkBrakeStatus { @@ -282,7 +282,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)electronicParkBrakeStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameElectronicParkBrakeStatus ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameElectronicParkBrakeStatus ofClass:NSNumber.class error:nil]; } - (void)setTurnSignal:(nullable NSNumber<SDLBool> *)turnSignal { @@ -290,7 +290,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)turnSignal { - return [parameters sdl_objectForName:SDLRPCParameterNameTurnSignal ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameTurnSignal ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLGetVehicleDataResponse.m b/SmartDeviceLink/SDLGetVehicleDataResponse.m index 8a8975591..2cb20ee25 100644 --- a/SmartDeviceLink/SDLGetVehicleDataResponse.m +++ b/SmartDeviceLink/SDLGetVehicleDataResponse.m @@ -35,7 +35,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLGPSData *)gps { - return [parameters sdl_objectForName:SDLRPCParameterNameGPS ofClass:SDLGPSData.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameGPS ofClass:SDLGPSData.class error:nil]; } - (void)setSpeed:(nullable NSNumber<SDLFloat> *)speed { @@ -43,7 +43,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)speed { - return [parameters sdl_objectForName:SDLRPCParameterNameSpeed ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSpeed ofClass:NSNumber.class error:nil]; } - (void)setRpm:(nullable NSNumber<SDLInt> *)rpm { @@ -51,7 +51,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)rpm { - return [parameters sdl_objectForName:SDLRPCParameterNameRPM ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameRPM ofClass:NSNumber.class error:nil]; } - (void)setFuelLevel:(nullable NSNumber<SDLFloat> *)fuelLevel { @@ -59,7 +59,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)fuelLevel { - return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevel ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevel ofClass:NSNumber.class error:nil]; } - (void)setFuelLevel_State:(nullable SDLComponentVolumeStatus)fuelLevel_State { @@ -79,11 +79,11 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLFuelRange *> *)fuelRange { - return [parameters sdl_objectsForName:SDLRPCParameterNameFuelRange ofClass:SDLFuelRange.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameFuelRange ofClass:SDLFuelRange.class error:nil]; } - (nullable NSNumber<SDLFloat> *)instantFuelConsumption { - return [parameters sdl_objectForName:SDLRPCParameterNameInstantFuelConsumption ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameInstantFuelConsumption ofClass:NSNumber.class error:nil]; } - (void)setExternalTemperature:(nullable NSNumber<SDLFloat> *)externalTemperature { @@ -91,7 +91,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)externalTemperature { - return [parameters sdl_objectForName:SDLRPCParameterNameExternalTemperature ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameExternalTemperature ofClass:NSNumber.class error:nil]; } - (void)setVin:(nullable NSString *)vin { @@ -99,7 +99,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)vin { - return [parameters sdl_objectForName:SDLRPCParameterNameVIN ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameVIN ofClass:NSString.class error:nil]; } - (void)setPrndl:(nullable SDLPRNDL)prndl { @@ -115,7 +115,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLTireStatus *)tirePressure { - return [parameters sdl_objectForName:SDLRPCParameterNameTirePressure ofClass:SDLTireStatus.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameTirePressure ofClass:SDLTireStatus.class error:nil]; } - (void)setOdometer:(nullable NSNumber<SDLInt> *)odometer { @@ -123,7 +123,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)odometer { - return [parameters sdl_objectForName:SDLRPCParameterNameOdometer ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameOdometer ofClass:NSNumber.class error:nil]; } - (void)setBeltStatus:(nullable SDLBeltStatus *)beltStatus { @@ -131,7 +131,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLBeltStatus *)beltStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameBeltStatus ofClass:SDLBeltStatus.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameBeltStatus ofClass:SDLBeltStatus.class error:nil]; } - (void)setBodyInformation:(nullable SDLBodyInformation *)bodyInformation { @@ -139,7 +139,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLBodyInformation *)bodyInformation { - return [parameters sdl_objectForName:SDLRPCParameterNameBodyInformation ofClass:SDLBodyInformation.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameBodyInformation ofClass:SDLBodyInformation.class error:nil]; } - (void)setDeviceStatus:(nullable SDLDeviceStatus *)deviceStatus { @@ -147,7 +147,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLDeviceStatus *)deviceStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameDeviceStatus ofClass:SDLDeviceStatus.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameDeviceStatus ofClass:SDLDeviceStatus.class error:nil]; } - (void)setDriverBraking:(nullable SDLVehicleDataEventStatus)driverBraking { @@ -171,7 +171,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLHeadLampStatus *)headLampStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameHeadLampStatus ofClass:SDLHeadLampStatus.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameHeadLampStatus ofClass:SDLHeadLampStatus.class error:nil]; } - (void)setEngineOilLife:(nullable NSNumber<SDLFloat> *)engineOilLife { @@ -179,7 +179,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)engineOilLife { - return [parameters sdl_objectForName:SDLRPCParameterNameEngineOilLife ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameEngineOilLife ofClass:NSNumber.class error:nil]; } - (void)setEngineTorque:(nullable NSNumber<SDLFloat> *)engineTorque { @@ -187,7 +187,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)engineTorque { - return [parameters sdl_objectForName:SDLRPCParameterNameEngineTorque ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameEngineTorque ofClass:NSNumber.class error:nil]; } - (void)setAccPedalPosition:(nullable NSNumber<SDLFloat> *)accPedalPosition { @@ -195,7 +195,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)accPedalPosition { - return [parameters sdl_objectForName:SDLRPCParameterNameAccelerationPedalPosition ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAccelerationPedalPosition ofClass:NSNumber.class error:nil]; } - (void)setSteeringWheelAngle:(nullable NSNumber<SDLFloat> *)steeringWheelAngle { @@ -203,7 +203,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)steeringWheelAngle { - return [parameters sdl_objectForName:SDLRPCParameterNameSteeringWheelAngle ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSteeringWheelAngle ofClass:NSNumber.class error:nil]; } - (void)setECallInfo:(nullable SDLECallInfo *)eCallInfo { @@ -211,7 +211,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLECallInfo *)eCallInfo { - return [parameters sdl_objectForName:SDLRPCParameterNameECallInfo ofClass:SDLECallInfo.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameECallInfo ofClass:SDLECallInfo.class error:nil]; } - (void)setAirbagStatus:(nullable SDLAirbagStatus *)airbagStatus { @@ -219,7 +219,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLAirbagStatus *)airbagStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameAirbagStatus ofClass:SDLAirbagStatus.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAirbagStatus ofClass:SDLAirbagStatus.class error:nil]; } - (void)setEmergencyEvent:(nullable SDLEmergencyEvent *)emergencyEvent { @@ -227,7 +227,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLEmergencyEvent *)emergencyEvent { - return [parameters sdl_objectForName:SDLRPCParameterNameEmergencyEvent ofClass:SDLEmergencyEvent.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameEmergencyEvent ofClass:SDLEmergencyEvent.class error:nil]; } - (void)setClusterModeStatus:(nullable SDLClusterModeStatus *)clusterModeStatus { @@ -235,7 +235,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLClusterModeStatus *)clusterModeStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameClusterModeStatus ofClass:SDLClusterModeStatus.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameClusterModeStatus ofClass:SDLClusterModeStatus.class error:nil]; } - (void)setMyKey:(nullable SDLMyKey *)myKey { @@ -243,7 +243,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLMyKey *)myKey { - return [parameters sdl_objectForName:SDLRPCParameterNameMyKey ofClass:SDLMyKey.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameMyKey ofClass:SDLMyKey.class error:nil]; } - (void)setElectronicParkBrakeStatus:(nullable SDLElectronicParkBrakeStatus)electronicParkBrakeStatus { diff --git a/SmartDeviceLink/SDLGetWayPointsResponse.m b/SmartDeviceLink/SDLGetWayPointsResponse.m index 36fd70dc5..19e5ca6cb 100644 --- a/SmartDeviceLink/SDLGetWayPointsResponse.m +++ b/SmartDeviceLink/SDLGetWayPointsResponse.m @@ -23,7 +23,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLLocationDetails *> *)waypoints { - return [parameters sdl_objectsForName:SDLRPCParameterNameWayPoints ofClass:SDLLocationDetails.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameWayPoints ofClass:SDLLocationDetails.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLHMICapabilities.m b/SmartDeviceLink/SDLHMICapabilities.m index 87d57ddab..11fa60306 100644 --- a/SmartDeviceLink/SDLHMICapabilities.m +++ b/SmartDeviceLink/SDLHMICapabilities.m @@ -16,7 +16,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)navigation { - return [store sdl_objectForName:SDLRPCParameterNameNavigation ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameNavigation ofClass:NSNumber.class error:nil]; } - (void)setPhoneCall:(nullable NSNumber<SDLBool> *)phoneCall { @@ -24,7 +24,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)phoneCall { - return [store sdl_objectForName:SDLRPCParameterNamePhoneCall ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNamePhoneCall ofClass:NSNumber.class error:nil]; } - (void)setVideoStreaming:(nullable NSNumber<SDLBool> *)videoStreaming { @@ -32,7 +32,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)videoStreaming { - return [store sdl_objectForName:SDLRPCParameterNameVideoStreaming ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameVideoStreaming ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLHMIPermissions.m b/SmartDeviceLink/SDLHMIPermissions.m index dec88e5dd..b48ca2be4 100644 --- a/SmartDeviceLink/SDLHMIPermissions.m +++ b/SmartDeviceLink/SDLHMIPermissions.m @@ -16,7 +16,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<SDLHMILevel> *)allowed { - NSError *error; + NSError *error = nil; return [store sdl_enumsForName:SDLRPCParameterNameAllowed error:&error]; } @@ -25,7 +25,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<SDLHMILevel> *)userDisallowed { - NSError *error; + NSError *error = nil; return [store sdl_enumsForName:SDLRPCParameterNameUserDisallowed error:&error]; } diff --git a/SmartDeviceLink/SDLHMISettingsControlCapabilities.m b/SmartDeviceLink/SDLHMISettingsControlCapabilities.m index 295e5b99a..fc93c8005 100644 --- a/SmartDeviceLink/SDLHMISettingsControlCapabilities.m +++ b/SmartDeviceLink/SDLHMISettingsControlCapabilities.m @@ -37,7 +37,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)moduleName { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameModuleName ofClass:NSString.class error:&error]; } @@ -47,7 +47,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)distanceUnitAvailable { - return [store sdl_objectForName:SDLRPCParameterNameDistanceUnitAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameDistanceUnitAvailable ofClass:NSNumber.class error:nil]; } - (void)setTemperatureUnitAvailable:(nullable NSNumber<SDLBool> *)temperatureUnitAvailable { @@ -55,7 +55,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)temperatureUnitAvailable { - return [store sdl_objectForName:SDLRPCParameterNameTemperatureUnitAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameTemperatureUnitAvailable ofClass:NSNumber.class error:nil]; } - (void)setDisplayModeUnitAvailable:(nullable NSNumber<SDLBool> *)displayModeUnitAvailable { @@ -63,7 +63,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)displayModeUnitAvailable { - return [store sdl_objectForName:SDLRPCParameterNameDisplayModeUnitAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameDisplayModeUnitAvailable ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLHapticRect.m b/SmartDeviceLink/SDLHapticRect.m index b64959ce3..b7d74c3a3 100644 --- a/SmartDeviceLink/SDLHapticRect.m +++ b/SmartDeviceLink/SDLHapticRect.m @@ -32,7 +32,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)id { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameId ofClass:NSNumber.class error:&error]; } @@ -41,7 +41,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLRectangle *)rect { - return [store sdl_objectForName:SDLRPCParameterNameRect ofClass:SDLRectangle.class]; + return [store sdl_objectForName:SDLRPCParameterNameRect ofClass:SDLRectangle.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLHeadLampStatus.m b/SmartDeviceLink/SDLHeadLampStatus.m index 54bb94262..89bad48ee 100644 --- a/SmartDeviceLink/SDLHeadLampStatus.m +++ b/SmartDeviceLink/SDLHeadLampStatus.m @@ -16,7 +16,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)lowBeamsOn { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameLowBeamsOn ofClass:NSNumber.class error:&error]; } @@ -25,7 +25,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)highBeamsOn { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameHighBeamsOn ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLImage.m b/SmartDeviceLink/SDLImage.m index 9e3c7c439..7a2dd72cd 100644 --- a/SmartDeviceLink/SDLImage.m +++ b/SmartDeviceLink/SDLImage.m @@ -61,7 +61,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)value { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameValue ofClass:NSString.class error:&error]; } @@ -78,7 +78,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)isTemplate { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameImageTemplate ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLImageField.m b/SmartDeviceLink/SDLImageField.m index 0bef1383a..94a6ccedc 100644 --- a/SmartDeviceLink/SDLImageField.m +++ b/SmartDeviceLink/SDLImageField.m @@ -17,7 +17,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLImageFieldName)name { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameName error:&error]; } @@ -26,7 +26,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<SDLFileType> *)imageTypeSupported { - NSError *error; + NSError *error = nil; return [store sdl_enumsForName:SDLRPCParameterNameImageTypeSupported error:&error]; } @@ -35,7 +35,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLImageResolution *)imageResolution { - return [store sdl_objectForName:SDLRPCParameterNameImageResolution ofClass:SDLImageResolution.class]; + return [store sdl_objectForName:SDLRPCParameterNameImageResolution ofClass:SDLImageResolution.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLImageResolution.m b/SmartDeviceLink/SDLImageResolution.m index d766ab86f..b85bf8e9b 100644 --- a/SmartDeviceLink/SDLImageResolution.m +++ b/SmartDeviceLink/SDLImageResolution.m @@ -26,7 +26,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)resolutionWidth { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameResolutionWidth ofClass:NSNumber.class error:&error]; } @@ -35,7 +35,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)resolutionHeight { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameResolutionHeight ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLKeyboardProperties.m b/SmartDeviceLink/SDLKeyboardProperties.m index 027229a6a..1e6376f24 100644 --- a/SmartDeviceLink/SDLKeyboardProperties.m +++ b/SmartDeviceLink/SDLKeyboardProperties.m @@ -54,7 +54,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<NSString *> *)limitedCharacterList { - return [store sdl_objectsForName:SDLRPCParameterNameLimitedCharacterList ofClass:NSString.class]; + return [store sdl_objectsForName:SDLRPCParameterNameLimitedCharacterList ofClass:NSString.class error:nil]; } - (void)setAutoCompleteText:(nullable NSString *)autoCompleteText { @@ -62,7 +62,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)autoCompleteText { - return [store sdl_objectForName:SDLRPCParameterNameAutoCompleteText ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameAutoCompleteText ofClass:NSString.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLLightCapabilities.m b/SmartDeviceLink/SDLLightCapabilities.m index 1338cc7c1..cd24fe9a2 100644 --- a/SmartDeviceLink/SDLLightCapabilities.m +++ b/SmartDeviceLink/SDLLightCapabilities.m @@ -37,7 +37,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLLightName)name { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameName error:&error]; } @@ -46,7 +46,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)densityAvailable { - return [store sdl_objectForName:SDLRPCParameterNameDensityAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameDensityAvailable ofClass:NSNumber.class error:nil]; } - (void)setColorAvailable:(nullable NSNumber<SDLBool> *)colorAvailable { @@ -54,7 +54,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)colorAvailable { - return [store sdl_objectForName:SDLRPCParameterNameRGBColorSpaceAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameRGBColorSpaceAvailable ofClass:NSNumber.class error:nil]; } - (void)setStatusAvailable:(nullable NSNumber<SDLBool> *)statusAvailable { @@ -62,7 +62,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)statusAvailable { - return [store sdl_objectForName:SDLRPCParameterNameStatusAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameStatusAvailable ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLLightControlCapabilities.m b/SmartDeviceLink/SDLLightControlCapabilities.m index 3b8fa0328..478e60f29 100644 --- a/SmartDeviceLink/SDLLightControlCapabilities.m +++ b/SmartDeviceLink/SDLLightControlCapabilities.m @@ -27,7 +27,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)moduleName { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameModuleName ofClass:NSString.class error:&error]; } @@ -37,7 +37,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<SDLLightCapabilities *> *)supportedLights { - NSError *error; + NSError *error = nil; return [store sdl_objectsForName:SDLRPCParameterNameSupportedLights ofClass:SDLLightCapabilities.class error:&error]; } diff --git a/SmartDeviceLink/SDLLightControlData.m b/SmartDeviceLink/SDLLightControlData.m index 80624221d..586fe9a2d 100644 --- a/SmartDeviceLink/SDLLightControlData.m +++ b/SmartDeviceLink/SDLLightControlData.m @@ -25,7 +25,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<SDLLightState *> *)lightState { - NSError *error; + NSError *error = nil; return [store sdl_objectsForName:SDLRPCParameterNameLightState ofClass:SDLLightState.class error:&error]; } diff --git a/SmartDeviceLink/SDLLightState.m b/SmartDeviceLink/SDLLightState.m index f33080b7e..28357d3ef 100644 --- a/SmartDeviceLink/SDLLightState.m +++ b/SmartDeviceLink/SDLLightState.m @@ -52,7 +52,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLLightName)id { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameId error:&error]; } @@ -61,7 +61,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLLightStatus)status { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameStatus error:&error]; } @@ -70,7 +70,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)density { - return [store sdl_objectForName:SDLRPCParameterNameDensity ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameDensity ofClass:NSNumber.class error:nil]; } - (void)setColor:(nullable SDLRGBColor *)color { @@ -78,7 +78,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLRGBColor *)color { - return [store sdl_objectForName:SDLRPCParameterNameColor ofClass:[SDLRGBColor class]]; + return [store sdl_objectForName:SDLRPCParameterNameColor ofClass:SDLRGBColor.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLListFilesResponse.m b/SmartDeviceLink/SDLListFilesResponse.m index 5a0059351..e3ef9e8b0 100644 --- a/SmartDeviceLink/SDLListFilesResponse.m +++ b/SmartDeviceLink/SDLListFilesResponse.m @@ -23,7 +23,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<NSString *> *)filenames { - return [parameters sdl_objectsForName:SDLRPCParameterNameFilenames ofClass:NSString.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameFilenames ofClass:NSString.class error:nil]; } - (void)setSpaceAvailable:(nullable NSNumber<SDLInt> *)spaceAvailable { @@ -31,7 +31,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)spaceAvailable { - return [parameters sdl_objectForName:SDLRPCParameterNameSpaceAvailable ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSpaceAvailable ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLLocationCoordinate.m b/SmartDeviceLink/SDLLocationCoordinate.m index 00d1d3ae4..79bd42028 100644 --- a/SmartDeviceLink/SDLLocationCoordinate.m +++ b/SmartDeviceLink/SDLLocationCoordinate.m @@ -27,7 +27,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLFloat> *)longitudeDegrees { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameLongitudeDegrees ofClass:NSNumber.class error:&error]; } @@ -36,7 +36,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLFloat> *)latitudeDegrees { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameLatitudeDegrees ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLLocationDetails.m b/SmartDeviceLink/SDLLocationDetails.m index 983aff11c..8de7aa7ea 100644 --- a/SmartDeviceLink/SDLLocationDetails.m +++ b/SmartDeviceLink/SDLLocationDetails.m @@ -45,7 +45,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLLocationCoordinate *)coordinate { - return [store sdl_objectForName:SDLRPCParameterNameLocationCoordinate ofClass:SDLLocationCoordinate.class]; + return [store sdl_objectForName:SDLRPCParameterNameLocationCoordinate ofClass:SDLLocationCoordinate.class error:nil]; } - (void)setLocationName:(nullable NSString *)locationName { @@ -53,7 +53,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)locationName { - return [store sdl_objectForName:SDLRPCParameterNameLocationName ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameLocationName ofClass:NSString.class error:nil]; } - (void)setAddressLines:(nullable NSArray<NSString *> *)addressLines { @@ -61,7 +61,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<NSString *> *)addressLines { - return [store sdl_objectsForName:SDLRPCParameterNameAddressLines ofClass:NSString.class]; + return [store sdl_objectsForName:SDLRPCParameterNameAddressLines ofClass:NSString.class error:nil]; } - (void)setLocationDescription:(nullable NSString *)locationDescription { @@ -69,7 +69,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)locationDescription { - return [store sdl_objectForName:SDLRPCParameterNameLocationDescription ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameLocationDescription ofClass:NSString.class error:nil]; } - (void)setPhoneNumber:(nullable NSString *)phoneNumber { @@ -77,7 +77,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)phoneNumber { - return [store sdl_objectForName:SDLRPCParameterNamePhoneNumber ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNamePhoneNumber ofClass:NSString.class error:nil]; } - (void)setLocationImage:(nullable SDLImage *)locationImage { @@ -85,7 +85,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLImage *)locationImage { - return [store sdl_objectForName:SDLRPCParameterNameLocationImage ofClass:SDLImage.class]; + return [store sdl_objectForName:SDLRPCParameterNameLocationImage ofClass:SDLImage.class error:nil]; } - (void)setSearchAddress:(nullable SDLOasisAddress *)searchAddress { @@ -93,7 +93,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLOasisAddress *)searchAddress { - return [store sdl_objectForName:SDLRPCParameterNameSearchAddress ofClass:SDLOasisAddress.class]; + return [store sdl_objectForName:SDLRPCParameterNameSearchAddress ofClass:SDLOasisAddress.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLMassageCushionFirmness.m b/SmartDeviceLink/SDLMassageCushionFirmness.m index a61efdcbe..fe3bc6335 100644 --- a/SmartDeviceLink/SDLMassageCushionFirmness.m +++ b/SmartDeviceLink/SDLMassageCushionFirmness.m @@ -26,7 +26,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLMassageCushion)cushion { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameCushion error:&error]; } @@ -35,7 +35,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)firmness { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameFirmness ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLMassageModeData.m b/SmartDeviceLink/SDLMassageModeData.m index bd24ba906..35fa3a8b3 100644 --- a/SmartDeviceLink/SDLMassageModeData.m +++ b/SmartDeviceLink/SDLMassageModeData.m @@ -26,7 +26,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLMassageMode)massageMode { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameMassageMode error:&error]; } @@ -35,7 +35,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLMassageZone)massageZone { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameMassageZone error:&error]; } diff --git a/SmartDeviceLink/SDLMediaServiceData.m b/SmartDeviceLink/SDLMediaServiceData.m index ffdc4b919..4abb6c5d2 100644 --- a/SmartDeviceLink/SDLMediaServiceData.m +++ b/SmartDeviceLink/SDLMediaServiceData.m @@ -50,7 +50,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)mediaTitle { - return [store sdl_objectForName:SDLRPCParameterNameMediaTitle ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameMediaTitle ofClass:NSString.class error:nil]; } - (void)setMediaArtist:(nullable NSString *)mediaArtist { @@ -58,7 +58,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)mediaArtist { - return [store sdl_objectForName:SDLRPCParameterNameMediaArtist ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameMediaArtist ofClass:NSString.class error:nil]; } - (void)setMediaAlbum:(nullable NSString *)mediaAlbum { @@ -66,7 +66,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)mediaAlbum { - return [store sdl_objectForName:SDLRPCParameterNameMediaAlbum ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameMediaAlbum ofClass:NSString.class error:nil]; } - (void)setPlaylistName:(nullable NSString *)playlistName { @@ -74,7 +74,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)playlistName { - return [store sdl_objectForName:SDLRPCParameterNamePlaylistName ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNamePlaylistName ofClass:NSString.class error:nil]; } - (void)setIsExplicit:(nullable NSNumber<SDLBool> *)isExplicit { @@ -82,7 +82,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)isExplicit { - return [store sdl_objectForName:SDLRPCParameterNameIsExplicit ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameIsExplicit ofClass:NSNumber.class error:nil]; } - (void)setTrackPlaybackProgress:(nullable NSNumber<SDLInt> *)trackPlaybackProgress { @@ -90,7 +90,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)trackPlaybackProgress { - return [store sdl_objectForName:SDLRPCParameterNameTrackPlaybackProgress ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameTrackPlaybackProgress ofClass:NSNumber.class error:nil]; } - (void)setTrackPlaybackDuration:(nullable NSNumber<SDLInt> *)trackPlaybackDuration { @@ -98,7 +98,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)trackPlaybackDuration { - return [store sdl_objectForName:SDLRPCParameterNameTrackPlaybackDuration ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameTrackPlaybackDuration ofClass:NSNumber.class error:nil]; } - (void)setQueuePlaybackProgress:(nullable NSNumber<SDLInt> *)queuePlaybackProgress { @@ -106,7 +106,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)queuePlaybackProgress { - return [store sdl_objectForName:SDLRPCParameterNameQueuePlaybackProgress ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameQueuePlaybackProgress ofClass:NSNumber.class error:nil]; } - (void)setQueuePlaybackDuration:(nullable NSNumber<SDLInt> *)queuePlaybackDuration { @@ -114,7 +114,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)queuePlaybackDuration { - return [store sdl_objectForName:SDLRPCParameterNameQueuePlaybackDuration ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameQueuePlaybackDuration ofClass:NSNumber.class error:nil]; } - (void)setQueueCurrentTrackNumber:(nullable NSNumber<SDLInt> *)queueCurrentTrackNumber { @@ -122,7 +122,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)queueCurrentTrackNumber { - return [store sdl_objectForName:SDLRPCParameterNameQueueCurrentTrackNumber ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameQueueCurrentTrackNumber ofClass:NSNumber.class error:nil]; } - (void)setQueueTotalTrackCount:(nullable NSNumber<SDLInt> *)queueTotalTrackCount { @@ -130,7 +130,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)queueTotalTrackCount { - return [store sdl_objectForName:SDLRPCParameterNameQueueTotalTrackCount ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameQueueTotalTrackCount ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLMenuParams.m b/SmartDeviceLink/SDLMenuParams.m index 873004150..89242ffdb 100644 --- a/SmartDeviceLink/SDLMenuParams.m +++ b/SmartDeviceLink/SDLMenuParams.m @@ -39,7 +39,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)parentID { - return [store sdl_objectForName:SDLRPCParameterNameParentId ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameParentId ofClass:NSNumber.class error:nil]; } - (void)setPosition:(nullable NSNumber<SDLInt> *)position { @@ -47,7 +47,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)position { - return [store sdl_objectForName:SDLRPCParameterNamePosition ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNamePosition ofClass:NSNumber.class error:nil]; } - (void)setMenuName:(NSString *)menuName { @@ -55,7 +55,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)menuName { - return [store sdl_objectForName:SDLRPCParameterNameMenuName ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameMenuName ofClass:NSString.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLModuleData.m b/SmartDeviceLink/SDLModuleData.m index 22a87682d..64d2a5bf0 100644 --- a/SmartDeviceLink/SDLModuleData.m +++ b/SmartDeviceLink/SDLModuleData.m @@ -93,7 +93,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLModuleType)moduleType { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameModuleType error:&error]; } @@ -102,7 +102,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLRadioControlData *)radioControlData { - return [store sdl_objectForName:SDLRPCParameterNameRadioControlData ofClass:SDLRadioControlData.class]; + return [store sdl_objectForName:SDLRPCParameterNameRadioControlData ofClass:SDLRadioControlData.class error:nil]; } - (void)setClimateControlData:(nullable SDLClimateControlData *)climateControlData { @@ -110,7 +110,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLClimateControlData *)climateControlData { - return [store sdl_objectForName:SDLRPCParameterNameClimateControlData ofClass:SDLClimateControlData.class]; + return [store sdl_objectForName:SDLRPCParameterNameClimateControlData ofClass:SDLClimateControlData.class error:nil]; } - (void)setSeatControlData:(nullable SDLSeatControlData *)seatControlData { @@ -118,7 +118,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLSeatControlData *)seatControlData { - return [store sdl_objectForName:SDLRPCParameterNameSeatControlData ofClass:SDLSeatControlData.class]; + return [store sdl_objectForName:SDLRPCParameterNameSeatControlData ofClass:SDLSeatControlData.class error:nil]; } - (void)setAudioControlData:(nullable SDLAudioControlData *)audioControlData { @@ -126,7 +126,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLAudioControlData *)audioControlData { - return [store sdl_objectForName:SDLRPCParameterNameAudioControlData ofClass:SDLAudioControlData.class]; + return [store sdl_objectForName:SDLRPCParameterNameAudioControlData ofClass:SDLAudioControlData.class error:nil]; } - (void)setLightControlData:(nullable SDLLightControlData *)lightControlData { @@ -134,7 +134,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLLightControlData *)lightControlData { - return [store sdl_objectForName:SDLRPCParameterNameLightControlData ofClass:SDLLightControlData.class]; + return [store sdl_objectForName:SDLRPCParameterNameLightControlData ofClass:SDLLightControlData.class error:nil]; } - (void)setHmiSettingsControlData:(nullable SDLHMISettingsControlData *)hmiSettingsControlData { @@ -142,7 +142,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLHMISettingsControlData *)hmiSettingsControlData { - return [store sdl_objectForName:SDLRPCParameterNameHmiSettingsControlData ofClass:SDLHMISettingsControlData.class]; + return [store sdl_objectForName:SDLRPCParameterNameHmiSettingsControlData ofClass:SDLHMISettingsControlData.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLMyKey.m b/SmartDeviceLink/SDLMyKey.m index 751e23556..0d79bc07a 100644 --- a/SmartDeviceLink/SDLMyKey.m +++ b/SmartDeviceLink/SDLMyKey.m @@ -16,7 +16,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataStatus)e911Override { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameE911Override error:&error]; } diff --git a/SmartDeviceLink/SDLNavigationCapability.m b/SmartDeviceLink/SDLNavigationCapability.m index 61181dc51..60c2034d4 100644 --- a/SmartDeviceLink/SDLNavigationCapability.m +++ b/SmartDeviceLink/SDLNavigationCapability.m @@ -32,7 +32,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber *)sendLocationEnabled { - return [store sdl_objectForName:SDLRPCParameterNameSendLocationEnabled ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameSendLocationEnabled ofClass:NSNumber.class error:nil]; } - (void)setGetWayPointsEnabled:(nullable NSNumber *)getWayPointsEnabled { @@ -40,7 +40,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber *)getWayPointsEnabled { - return [store sdl_objectForName:SDLRPCParameterNameGetWayPointsEnabled ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameGetWayPointsEnabled ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLNavigationInstruction.m b/SmartDeviceLink/SDLNavigationInstruction.m index 396d76425..701ed2453 100644 --- a/SmartDeviceLink/SDLNavigationInstruction.m +++ b/SmartDeviceLink/SDLNavigationInstruction.m @@ -52,7 +52,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLLocationDetails *)locationDetails { - return [store sdl_objectForName:SDLRPCParameterNameLocationDetails ofClass:SDLLocationDetails.class]; + return [store sdl_objectForName:SDLRPCParameterNameLocationDetails ofClass:SDLLocationDetails.class error:nil]; } - (void)setAction:(SDLNavigationAction)action { @@ -68,7 +68,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLDateTime *)eta { - return [store sdl_objectForName:SDLRPCParameterNameETA ofClass:SDLDateTime.class]; + return [store sdl_objectForName:SDLRPCParameterNameETA ofClass:SDLDateTime.class error:nil]; } - (void)setBearing:(nullable NSNumber<SDLInt> *)bearing { @@ -76,7 +76,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)bearing { - return [store sdl_objectForName:SDLRPCParameterNameBearing ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameBearing ofClass:NSNumber.class error:nil]; } - (void)setJunctionType:(nullable SDLNavigationJunction)junctionType { @@ -100,7 +100,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)details { - return [store sdl_objectForName:SDLRPCParameterNameDetails ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameDetails ofClass:NSString.class error:nil]; } - (void)setImage:(nullable SDLImage *)image { @@ -108,7 +108,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLImage *)image { - return [store sdl_objectForName:SDLRPCParameterNameImage ofClass:SDLImage.class]; + return [store sdl_objectForName:SDLRPCParameterNameImage ofClass:SDLImage.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLNavigationServiceData.m b/SmartDeviceLink/SDLNavigationServiceData.m index 2f74bd2ca..e1ef35a9a 100644 --- a/SmartDeviceLink/SDLNavigationServiceData.m +++ b/SmartDeviceLink/SDLNavigationServiceData.m @@ -52,7 +52,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLDateTime *)timestamp { - return [store sdl_objectForName:SDLRPCParameterNameTimeStamp ofClass:SDLDateTime.class]; + return [store sdl_objectForName:SDLRPCParameterNameTimeStamp ofClass:SDLDateTime.class error:nil]; } - (void)setOrigin:(nullable SDLLocationDetails *)origin { @@ -60,7 +60,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLLocationDetails *)origin { - return [store sdl_objectForName:SDLRPCParameterNameOrigin ofClass:SDLLocationDetails.class]; + return [store sdl_objectForName:SDLRPCParameterNameOrigin ofClass:SDLLocationDetails.class error:nil]; } - (void)setDestination:(nullable SDLLocationDetails *)destination { @@ -68,7 +68,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLLocationDetails *)destination { - return [store sdl_objectForName:SDLRPCParameterNameDestination ofClass:SDLLocationDetails.class]; + return [store sdl_objectForName:SDLRPCParameterNameDestination ofClass:SDLLocationDetails.class error:nil]; } - (void)setDestinationETA:(nullable SDLDateTime *)destinationETA { @@ -76,7 +76,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLDateTime *)destinationETA { - return [store sdl_objectForName:SDLRPCParameterNameDestinationETA ofClass:SDLDateTime.class]; + return [store sdl_objectForName:SDLRPCParameterNameDestinationETA ofClass:SDLDateTime.class error:nil]; } - (void)setInstructions:(nullable NSArray<SDLNavigationInstruction *> *)instructions { @@ -84,7 +84,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLNavigationInstruction *> *)instructions { - return [store sdl_objectsForName:SDLRPCParameterNameInstructions ofClass:SDLNavigationInstruction.class]; + return [store sdl_objectsForName:SDLRPCParameterNameInstructions ofClass:SDLNavigationInstruction.class error:nil]; } - (void)setNextInstructionETA:(nullable SDLDateTime *)nextInstructionETA { @@ -92,7 +92,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLDateTime *)nextInstructionETA { - return [store sdl_objectForName:SDLRPCParameterNameNextInstructionETA ofClass:SDLDateTime.class]; + return [store sdl_objectForName:SDLRPCParameterNameNextInstructionETA ofClass:SDLDateTime.class error:nil]; } - (void)setNextInstructionDistance:(nullable NSNumber<SDLFloat> *)nextInstructionDistance { @@ -100,7 +100,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)nextInstructionDistance { - return [store sdl_objectForName:SDLRPCParameterNameNextInstructionDistance ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameNextInstructionDistance ofClass:NSNumber.class error:nil]; } - (void)setNextInstructionDistanceScale:(nullable NSNumber<SDLFloat> *)nextInstructionDistanceScale { @@ -108,7 +108,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)nextInstructionDistanceScale { - return [store sdl_objectForName:SDLRPCParameterNameNextInstructionDistanceScale ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameNextInstructionDistanceScale ofClass:NSNumber.class error:nil]; } - (void)setPrompt:(nullable NSString *)prompt { @@ -116,7 +116,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)prompt { - return [store sdl_objectForName:SDLRPCParameterNamePrompt ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNamePrompt ofClass:NSString.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLNavigationServiceManifest.m b/SmartDeviceLink/SDLNavigationServiceManifest.m index 17183cbd6..4211227f0 100644 --- a/SmartDeviceLink/SDLNavigationServiceManifest.m +++ b/SmartDeviceLink/SDLNavigationServiceManifest.m @@ -31,7 +31,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)acceptsWayPoints { - return [store sdl_objectForName:SDLRPCParameterNameAcceptsWayPoints ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameAcceptsWayPoints ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLOasisAddress.m b/SmartDeviceLink/SDLOasisAddress.m index bcb4438e9..634695db9 100644 --- a/SmartDeviceLink/SDLOasisAddress.m +++ b/SmartDeviceLink/SDLOasisAddress.m @@ -38,7 +38,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)countryName { - return [store sdl_objectForName:SDLRPCParameterNameCountryName ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameCountryName ofClass:NSString.class error:nil]; } - (void)setCountryCode:(nullable NSString *)countryCode { @@ -46,7 +46,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)countryCode { - return [store sdl_objectForName:SDLRPCParameterNameCountryCode ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameCountryCode ofClass:NSString.class error:nil]; } - (void)setPostalCode:(nullable NSString *)postalCode { @@ -54,7 +54,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)postalCode { - return [store sdl_objectForName:SDLRPCParameterNamePostalCode ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNamePostalCode ofClass:NSString.class error:nil]; } - (void)setAdministrativeArea:(nullable NSString *)administrativeArea { @@ -62,7 +62,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)administrativeArea { - return [store sdl_objectForName:SDLRPCParameterNameAdministrativeArea ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameAdministrativeArea ofClass:NSString.class error:nil]; } - (void)setSubAdministrativeArea:(nullable NSString *)subAdministrativeArea { @@ -70,7 +70,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)subAdministrativeArea { - return [store sdl_objectForName:SDLRPCParameterNameSubAdministrativeArea ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameSubAdministrativeArea ofClass:NSString.class error:nil]; } - (void)setLocality:(nullable NSString *)locality { @@ -78,7 +78,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)locality { - return [store sdl_objectForName:SDLRPCParameterNameLocality ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameLocality ofClass:NSString.class error:nil]; } - (void)setSubLocality:(nullable NSString *)subLocality { @@ -86,7 +86,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)subLocality { - return [store sdl_objectForName:SDLRPCParameterNameSubLocality ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameSubLocality ofClass:NSString.class error:nil]; } - (void)setThoroughfare:(nullable NSString *)thoroughfare { @@ -94,7 +94,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)thoroughfare { - return [store sdl_objectForName:SDLRPCParameterNameThoroughfare ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameThoroughfare ofClass:NSString.class error:nil]; } - (void)setSubThoroughfare:(nullable NSString *)subThoroughfare { @@ -102,7 +102,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)subThoroughfare { - return [store sdl_objectForName:SDLRPCParameterNameSubThoroughfare ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameSubThoroughfare ofClass:NSString.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLOnAppInterfaceUnregistered.m b/SmartDeviceLink/SDLOnAppInterfaceUnregistered.m index b0109c2a2..39cd7acb1 100644 --- a/SmartDeviceLink/SDLOnAppInterfaceUnregistered.m +++ b/SmartDeviceLink/SDLOnAppInterfaceUnregistered.m @@ -22,7 +22,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLAppInterfaceUnregisteredReason)reason { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameReason error:&error]; } diff --git a/SmartDeviceLink/SDLOnAppServiceData.m b/SmartDeviceLink/SDLOnAppServiceData.m index bd427d20b..e185710c4 100644 --- a/SmartDeviceLink/SDLOnAppServiceData.m +++ b/SmartDeviceLink/SDLOnAppServiceData.m @@ -39,7 +39,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLAppServiceData *)serviceData { - return [parameters sdl_objectForName:SDLRPCParameterNameServiceData ofClass:SDLAppServiceData.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameServiceData ofClass:SDLAppServiceData.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLOnButtonEvent.m b/SmartDeviceLink/SDLOnButtonEvent.m index 1f78c9593..61a033e8a 100644 --- a/SmartDeviceLink/SDLOnButtonEvent.m +++ b/SmartDeviceLink/SDLOnButtonEvent.m @@ -22,7 +22,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLButtonName)buttonName { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameButtonName error:&error]; } @@ -31,7 +31,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLButtonEventMode)buttonEventMode { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameButtonEventMode error:&error]; } @@ -40,7 +40,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)customButtonID { - return [parameters sdl_objectForName:SDLRPCParameterNameCustomButtonId ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameCustomButtonId ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLOnButtonPress.m b/SmartDeviceLink/SDLOnButtonPress.m index ce519be20..90dc42e4b 100644 --- a/SmartDeviceLink/SDLOnButtonPress.m +++ b/SmartDeviceLink/SDLOnButtonPress.m @@ -22,7 +22,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLButtonName)buttonName { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameButtonName error:&error]; } @@ -31,7 +31,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLButtonPressMode)buttonPressMode { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameButtonPressMode error:&error]; } @@ -40,7 +40,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)customButtonID { - return [parameters sdl_objectForName:SDLRPCParameterNameCustomButtonId ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameCustomButtonId ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLOnCommand.m b/SmartDeviceLink/SDLOnCommand.m index 19b41c25d..b6048249e 100644 --- a/SmartDeviceLink/SDLOnCommand.m +++ b/SmartDeviceLink/SDLOnCommand.m @@ -22,7 +22,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)cmdID { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameCommandId ofClass:NSNumber.class error:&error]; } @@ -31,7 +31,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLTriggerSource)triggerSource { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameTriggerSource error:&error]; } diff --git a/SmartDeviceLink/SDLOnDriverDistraction.m b/SmartDeviceLink/SDLOnDriverDistraction.m index 502e0b57d..147964af8 100644 --- a/SmartDeviceLink/SDLOnDriverDistraction.m +++ b/SmartDeviceLink/SDLOnDriverDistraction.m @@ -23,7 +23,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLDriverDistractionState)state { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameState error:&error]; } diff --git a/SmartDeviceLink/SDLOnEncodedSyncPData.m b/SmartDeviceLink/SDLOnEncodedSyncPData.m index c5b8c349b..873411c80 100644 --- a/SmartDeviceLink/SDLOnEncodedSyncPData.m +++ b/SmartDeviceLink/SDLOnEncodedSyncPData.m @@ -22,7 +22,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<NSString *> *)data { - NSError *error; + NSError *error = nil; return [parameters sdl_objectsForName:SDLRPCParameterNameData ofClass:NSString.class error:&error]; } @@ -31,7 +31,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)URL { - return [parameters sdl_objectForName:SDLRPCParameterNameURLUppercase ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameURLUppercase ofClass:NSString.class error:nil]; } - (void)setTimeout:(nullable NSNumber<SDLInt> *)Timeout { @@ -39,7 +39,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)Timeout { - return [parameters sdl_objectForName:SDLRPCParameterNameTimeoutCapitalized ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameTimeoutCapitalized ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLOnHMIStatus.m b/SmartDeviceLink/SDLOnHMIStatus.m index 128be1c8e..8ab94e60f 100644 --- a/SmartDeviceLink/SDLOnHMIStatus.m +++ b/SmartDeviceLink/SDLOnHMIStatus.m @@ -25,7 +25,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLHMILevel)hmiLevel { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameHMILevel error:&error]; } @@ -34,7 +34,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLAudioStreamingState)audioStreamingState { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameAudioStreamingState error:&error]; } @@ -51,7 +51,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLSystemContext)systemContext { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameSystemContext error:&error]; } diff --git a/SmartDeviceLink/SDLOnHashChange.m b/SmartDeviceLink/SDLOnHashChange.m index bd00ada7e..7f0f6e9b4 100644 --- a/SmartDeviceLink/SDLOnHashChange.m +++ b/SmartDeviceLink/SDLOnHashChange.m @@ -23,7 +23,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)hashID { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameHashId ofClass:NSString.class error:&error]; } diff --git a/SmartDeviceLink/SDLOnInteriorVehicleData.m b/SmartDeviceLink/SDLOnInteriorVehicleData.m index e675ebb2e..f052ceaae 100644 --- a/SmartDeviceLink/SDLOnInteriorVehicleData.m +++ b/SmartDeviceLink/SDLOnInteriorVehicleData.m @@ -23,7 +23,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLModuleData *)moduleData { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameModuleData ofClass:SDLModuleData.class error:&error]; } diff --git a/SmartDeviceLink/SDLOnKeyboardInput.m b/SmartDeviceLink/SDLOnKeyboardInput.m index e49c5977e..6f781c377 100644 --- a/SmartDeviceLink/SDLOnKeyboardInput.m +++ b/SmartDeviceLink/SDLOnKeyboardInput.m @@ -22,7 +22,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLKeyboardEvent)event { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameEvent error:&error]; } @@ -31,7 +31,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)data { - return [parameters sdl_objectForName:SDLRPCParameterNameData ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameData ofClass:NSString.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLOnLanguageChange.m b/SmartDeviceLink/SDLOnLanguageChange.m index cccfbb55f..922b86eec 100644 --- a/SmartDeviceLink/SDLOnLanguageChange.m +++ b/SmartDeviceLink/SDLOnLanguageChange.m @@ -23,7 +23,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLLanguage)language { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameLanguage error:&error]; } @@ -32,7 +32,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLLanguage)hmiDisplayLanguage { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameHMIDisplayLanguage error:&error]; } diff --git a/SmartDeviceLink/SDLOnLockScreenStatus.m b/SmartDeviceLink/SDLOnLockScreenStatus.m index b29cc07db..7c24099e4 100644 --- a/SmartDeviceLink/SDLOnLockScreenStatus.m +++ b/SmartDeviceLink/SDLOnLockScreenStatus.m @@ -26,7 +26,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLLockScreenStatus)lockScreenStatus { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameOnLockScreenStatus error:&error]; } @@ -35,7 +35,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLHMILevel)hmiLevel { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameHMILevel error:&error]; } @@ -44,7 +44,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)userSelected { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameUserSelected ofClass:NSNumber.class error:&error]; } @@ -53,7 +53,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)driverDistractionStatus { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameDriverDistractionStatus ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLOnPermissionsChange.m b/SmartDeviceLink/SDLOnPermissionsChange.m index dae1ffddb..f517a197d 100644 --- a/SmartDeviceLink/SDLOnPermissionsChange.m +++ b/SmartDeviceLink/SDLOnPermissionsChange.m @@ -23,7 +23,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<SDLPermissionItem *> *)permissionItem { - NSError *error; + NSError *error = nil; return [parameters sdl_objectsForName:SDLRPCParameterNamePermissionItem ofClass:SDLPermissionItem.class error:&error]; } diff --git a/SmartDeviceLink/SDLOnRCStatus.m b/SmartDeviceLink/SDLOnRCStatus.m index 1dc620d16..551131661 100644 --- a/SmartDeviceLink/SDLOnRCStatus.m +++ b/SmartDeviceLink/SDLOnRCStatus.m @@ -19,7 +19,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)allowed { - return [parameters sdl_objectForName:SDLRPCParameterNameAllowed ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAllowed ofClass:NSNumber.class error:nil]; } - (void)setAllowed:(nullable NSNumber<SDLBool> *)allowed { @@ -32,7 +32,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<SDLModuleData *> *)allocatedModules { - NSError *error; + NSError *error = nil; return [parameters sdl_objectsForName:SDLRPCParameterNameAllocatedModules ofClass:SDLModuleData.class error:&error]; } @@ -41,7 +41,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<SDLModuleData *> *)freeModules { - NSError *error; + NSError *error = nil; return [parameters sdl_objectsForName:SDLRPCParameterNameFreeModules ofClass:SDLModuleData.class error:&error]; } diff --git a/SmartDeviceLink/SDLOnSyncPData.m b/SmartDeviceLink/SDLOnSyncPData.m index 4c6504a7c..d470b80c2 100644 --- a/SmartDeviceLink/SDLOnSyncPData.m +++ b/SmartDeviceLink/SDLOnSyncPData.m @@ -24,7 +24,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)URL { - return [parameters sdl_objectForName:SDLRPCParameterNameURLUppercase ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameURLUppercase ofClass:NSString.class error:nil]; } - (void)setTimeout:(nullable NSNumber<SDLInt> *)Timeout { @@ -32,7 +32,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)Timeout { - return [parameters sdl_objectForName:SDLRPCParameterNameTimeoutCapitalized ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameTimeoutCapitalized ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLOnSystemCapabilityUpdated.m b/SmartDeviceLink/SDLOnSystemCapabilityUpdated.m index 05167d62e..7bab5992c 100644 --- a/SmartDeviceLink/SDLOnSystemCapabilityUpdated.m +++ b/SmartDeviceLink/SDLOnSystemCapabilityUpdated.m @@ -39,7 +39,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLSystemCapability *)systemCapability { - return [parameters sdl_objectForName:SDLRPCParameterNameSystemCapability ofClass:SDLSystemCapability.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSystemCapability ofClass:SDLSystemCapability.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLOnSystemRequest.m b/SmartDeviceLink/SDLOnSystemRequest.m index 56862f367..211d68528 100644 --- a/SmartDeviceLink/SDLOnSystemRequest.m +++ b/SmartDeviceLink/SDLOnSystemRequest.m @@ -22,7 +22,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLRequestType)requestType { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameRequestType error:&error]; } @@ -31,7 +31,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)requestSubType { - return [parameters sdl_objectForName:SDLRPCParameterNameRequestSubType ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameRequestSubType ofClass:NSString.class error:nil]; } - (void)setUrl:(nullable NSString *)url { @@ -39,7 +39,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)url { - return [parameters sdl_objectForName:SDLRPCParameterNameURL ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameURL ofClass:NSString.class error:nil]; } - (void)setTimeout:(nullable NSNumber<SDLInt> *)timeout { @@ -47,7 +47,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)timeout { - return [parameters sdl_objectForName:SDLRPCParameterNameTimeout ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameTimeout ofClass:NSNumber.class error:nil]; } - (void)setFileType:(nullable SDLFileType)fileType { @@ -63,7 +63,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)offset { - return [parameters sdl_objectForName:SDLRPCParameterNameOffset ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameOffset ofClass:NSNumber.class error:nil]; } - (void)setLength:(nullable NSNumber<SDLInt> *)length { @@ -71,7 +71,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)length { - return [parameters sdl_objectForName:SDLRPCParameterNameLength ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameLength ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLOnTBTClientState.m b/SmartDeviceLink/SDLOnTBTClientState.m index a6392c472..de8017174 100644 --- a/SmartDeviceLink/SDLOnTBTClientState.m +++ b/SmartDeviceLink/SDLOnTBTClientState.m @@ -22,7 +22,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLTBTState)state { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameState error:&error]; } diff --git a/SmartDeviceLink/SDLOnTouchEvent.m b/SmartDeviceLink/SDLOnTouchEvent.m index 0eb4bc09d..0d8eea442 100644 --- a/SmartDeviceLink/SDLOnTouchEvent.m +++ b/SmartDeviceLink/SDLOnTouchEvent.m @@ -23,7 +23,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLTouchType)type { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameType error:&error]; } @@ -32,7 +32,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<SDLTouchEvent *> *)event { - NSError *error; + NSError *error = nil; return [parameters sdl_objectsForName:SDLRPCParameterNameEvent ofClass:SDLTouchEvent.class error:&error]; } diff --git a/SmartDeviceLink/SDLOnVehicleData.m b/SmartDeviceLink/SDLOnVehicleData.m index 44d553f8d..57caac065 100644 --- a/SmartDeviceLink/SDLOnVehicleData.m +++ b/SmartDeviceLink/SDLOnVehicleData.m @@ -34,7 +34,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLGPSData *)gps { - return [parameters sdl_objectForName:SDLRPCParameterNameGPS ofClass:SDLGPSData.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameGPS ofClass:SDLGPSData.class error:nil]; } - (void)setSpeed:(nullable NSNumber<SDLFloat> *)speed { @@ -42,7 +42,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)speed { - return [parameters sdl_objectForName:SDLRPCParameterNameSpeed ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSpeed ofClass:NSNumber.class error:nil]; } - (void)setRpm:(nullable NSNumber<SDLInt> *)rpm { @@ -50,7 +50,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)rpm { - return [parameters sdl_objectForName:SDLRPCParameterNameRPM ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameRPM ofClass:NSNumber.class error:nil]; } - (void)setFuelLevel:(nullable NSNumber<SDLFloat> *)fuelLevel { @@ -58,7 +58,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)fuelLevel { - return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevel ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevel ofClass:NSNumber.class error:nil]; } - (void)setFuelLevel_State:(nullable SDLComponentVolumeStatus)fuelLevel_State { @@ -74,7 +74,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLFuelRange *> *)fuelRange { - return [parameters sdl_objectsForName:SDLRPCParameterNameFuelRange ofClass:SDLFuelRange.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameFuelRange ofClass:SDLFuelRange.class error:nil]; } - (void)setInstantFuelConsumption:(nullable NSNumber<SDLFloat> *)instantFuelConsumption { @@ -82,7 +82,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)instantFuelConsumption { - return [parameters sdl_objectForName:SDLRPCParameterNameInstantFuelConsumption ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameInstantFuelConsumption ofClass:NSNumber.class error:nil]; } - (void)setExternalTemperature:(nullable NSNumber<SDLFloat> *)externalTemperature { @@ -90,7 +90,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)externalTemperature { - return [parameters sdl_objectForName:SDLRPCParameterNameExternalTemperature ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameExternalTemperature ofClass:NSNumber.class error:nil]; } - (void)setVin:(nullable NSString *)vin { @@ -98,7 +98,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)vin { - return [parameters sdl_objectForName:SDLRPCParameterNameVIN ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameVIN ofClass:NSString.class error:nil]; } - (void)setPrndl:(nullable SDLPRNDL)prndl { @@ -114,7 +114,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLTireStatus *)tirePressure { - return [parameters sdl_objectForName:SDLRPCParameterNameTirePressure ofClass:SDLTireStatus.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameTirePressure ofClass:SDLTireStatus.class error:nil]; } - (void)setOdometer:(nullable NSNumber<SDLInt> *)odometer { @@ -122,7 +122,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)odometer { - return [parameters sdl_objectForName:SDLRPCParameterNameOdometer ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameOdometer ofClass:NSNumber.class error:nil]; } - (void)setBeltStatus:(nullable SDLBeltStatus *)beltStatus { @@ -130,7 +130,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLBeltStatus *)beltStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameBeltStatus ofClass:SDLBeltStatus.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameBeltStatus ofClass:SDLBeltStatus.class error:nil]; } - (void)setBodyInformation:(nullable SDLBodyInformation *)bodyInformation { @@ -138,7 +138,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLBodyInformation *)bodyInformation { - return [parameters sdl_objectForName:SDLRPCParameterNameBodyInformation ofClass:SDLBodyInformation.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameBodyInformation ofClass:SDLBodyInformation.class error:nil]; } - (void)setDeviceStatus:(nullable SDLDeviceStatus *)deviceStatus { @@ -146,7 +146,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLDeviceStatus *)deviceStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameDeviceStatus ofClass:SDLDeviceStatus.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameDeviceStatus ofClass:SDLDeviceStatus.class error:nil]; } - (void)setDriverBraking:(nullable SDLVehicleDataEventStatus)driverBraking { @@ -170,7 +170,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLHeadLampStatus *)headLampStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameHeadLampStatus ofClass:SDLHeadLampStatus.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameHeadLampStatus ofClass:SDLHeadLampStatus.class error:nil]; } - (void)setEngineOilLife:(nullable NSNumber<SDLFloat> *)engineOilLife { @@ -178,7 +178,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)engineOilLife { - return [parameters sdl_objectForName:SDLRPCParameterNameEngineOilLife ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameEngineOilLife ofClass:NSNumber.class error:nil]; } - (void)setEngineTorque:(nullable NSNumber<SDLFloat> *)engineTorque { @@ -186,7 +186,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)engineTorque { - return [parameters sdl_objectForName:SDLRPCParameterNameEngineTorque ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameEngineTorque ofClass:NSNumber.class error:nil]; } - (void)setAccPedalPosition:(nullable NSNumber<SDLFloat> *)accPedalPosition { @@ -194,7 +194,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)accPedalPosition { - return [parameters sdl_objectForName:SDLRPCParameterNameAccelerationPedalPosition ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAccelerationPedalPosition ofClass:NSNumber.class error:nil]; } - (void)setSteeringWheelAngle:(nullable NSNumber<SDLFloat> *)steeringWheelAngle { @@ -202,7 +202,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)steeringWheelAngle { - return [parameters sdl_objectForName:SDLRPCParameterNameSteeringWheelAngle ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSteeringWheelAngle ofClass:NSNumber.class error:nil]; } - (void)setECallInfo:(nullable SDLECallInfo *)eCallInfo { @@ -210,7 +210,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLECallInfo *)eCallInfo { - return [parameters sdl_objectForName:SDLRPCParameterNameECallInfo ofClass:SDLECallInfo.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameECallInfo ofClass:SDLECallInfo.class error:nil]; } - (void)setAirbagStatus:(nullable SDLAirbagStatus *)airbagStatus { @@ -218,7 +218,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLAirbagStatus *)airbagStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameAirbagStatus ofClass:SDLAirbagStatus.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAirbagStatus ofClass:SDLAirbagStatus.class error:nil]; } - (void)setEmergencyEvent:(nullable SDLEmergencyEvent *)emergencyEvent { @@ -226,7 +226,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLEmergencyEvent *)emergencyEvent { - return [parameters sdl_objectForName:SDLRPCParameterNameEmergencyEvent ofClass:SDLEmergencyEvent.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameEmergencyEvent ofClass:SDLEmergencyEvent.class error:nil]; } - (void)setClusterModeStatus:(nullable SDLClusterModeStatus *)clusterModeStatus { @@ -234,7 +234,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLClusterModeStatus *)clusterModeStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameClusterModeStatus ofClass:SDLClusterModeStatus.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameClusterModeStatus ofClass:SDLClusterModeStatus.class error:nil]; } - (void)setMyKey:(nullable SDLMyKey *)myKey { @@ -242,7 +242,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLMyKey *)myKey { - return [parameters sdl_objectForName:SDLRPCParameterNameMyKey ofClass:SDLMyKey.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameMyKey ofClass:SDLMyKey.class error:nil]; } - (void)setElectronicParkBrakeStatus:(nullable SDLElectronicParkBrakeStatus)electronicParkBrakeStatus { diff --git a/SmartDeviceLink/SDLOnWayPointChange.m b/SmartDeviceLink/SDLOnWayPointChange.m index a2df4addb..bc7b5a492 100644 --- a/SmartDeviceLink/SDLOnWayPointChange.m +++ b/SmartDeviceLink/SDLOnWayPointChange.m @@ -23,7 +23,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<SDLLocationDetails *> *)waypoints { - NSError *error; + NSError *error = nil; return [parameters sdl_objectsForName:SDLRPCParameterNameWayPoints ofClass:SDLLocationDetails.class error:&error]; } diff --git a/SmartDeviceLink/SDLParameterPermissions.m b/SmartDeviceLink/SDLParameterPermissions.m index ecbcc7a5d..005955a50 100644 --- a/SmartDeviceLink/SDLParameterPermissions.m +++ b/SmartDeviceLink/SDLParameterPermissions.m @@ -16,7 +16,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<NSString *> *)allowed { - NSError *error; + NSError *error = nil; return [store sdl_objectsForName:SDLRPCParameterNameAllowed ofClass:NSString.class error:&error]; } @@ -25,7 +25,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<NSString *> *)userDisallowed { - NSError *error; + NSError *error = nil; return [store sdl_objectsForName:SDLRPCParameterNameUserDisallowed ofClass:NSString.class error:&error]; } diff --git a/SmartDeviceLink/SDLPerformAppServiceInteraction.m b/SmartDeviceLink/SDLPerformAppServiceInteraction.m index 58a568d54..5dc136c85 100644 --- a/SmartDeviceLink/SDLPerformAppServiceInteraction.m +++ b/SmartDeviceLink/SDLPerformAppServiceInteraction.m @@ -52,7 +52,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)serviceUri { - return [parameters sdl_objectForName:SDLRPCParameterNameServiceUri ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameServiceUri ofClass:NSString.class error:nil]; } - (void)setServiceID:(NSString *)serviceID { @@ -60,7 +60,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)serviceID { - return [parameters sdl_objectForName:SDLRPCParameterNameServiceID ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameServiceID ofClass:NSString.class error:nil]; } - (void)setOriginApp:(NSString *)originApp { @@ -68,7 +68,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)originApp { - return [parameters sdl_objectForName:SDLRPCParameterNameOriginApp ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameOriginApp ofClass:NSString.class error:nil]; } - (void)setRequestServiceActive:(nullable NSNumber<SDLBool> *)requestServiceActive { @@ -76,7 +76,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)requestServiceActive { - return [parameters sdl_objectForName:SDLRPCParameterNameRequestServiceActive ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameRequestServiceActive ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLPerformAppServiceInteractionResponse.m b/SmartDeviceLink/SDLPerformAppServiceInteractionResponse.m index 3b4ff5e07..112d7c209 100644 --- a/SmartDeviceLink/SDLPerformAppServiceInteractionResponse.m +++ b/SmartDeviceLink/SDLPerformAppServiceInteractionResponse.m @@ -38,7 +38,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)serviceSpecificResult { - return [parameters sdl_objectForName:SDLRPCParameterNameServiceSpecificResult ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameServiceSpecificResult ofClass:NSString.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLPerformAudioPassThru.m b/SmartDeviceLink/SDLPerformAudioPassThru.m index 6b300905e..85917babe 100644 --- a/SmartDeviceLink/SDLPerformAudioPassThru.m +++ b/SmartDeviceLink/SDLPerformAudioPassThru.m @@ -62,7 +62,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLTTSChunk *> *)initialPrompt { - return [parameters sdl_objectsForName:SDLRPCParameterNameInitialPrompt ofClass:SDLTTSChunk.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameInitialPrompt ofClass:SDLTTSChunk.class error:nil]; } - (void)setAudioPassThruDisplayText1:(nullable NSString *)audioPassThruDisplayText1 { @@ -70,7 +70,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)audioPassThruDisplayText1 { - return [parameters sdl_objectForName:SDLRPCParameterNameAudioPassThruDisplayText1 ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAudioPassThruDisplayText1 ofClass:NSString.class error:nil]; } - (void)setAudioPassThruDisplayText2:(nullable NSString *)audioPassThruDisplayText2 { @@ -78,7 +78,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)audioPassThruDisplayText2 { - return [parameters sdl_objectForName:SDLRPCParameterNameAudioPassThruDisplayText2 ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAudioPassThruDisplayText2 ofClass:NSString.class error:nil]; } - (void)setSamplingRate:(SDLSamplingRate)samplingRate { @@ -86,7 +86,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLSamplingRate)samplingRate { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameSamplingRate error:&error]; } @@ -95,7 +95,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)maxDuration { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameMaxDuration ofClass:NSNumber.class error:&error]; } @@ -104,7 +104,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLBitsPerSample)bitsPerSample { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameBitsPerSample error:&error]; } @@ -113,7 +113,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLAudioType)audioType { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameAudioType error:&error]; } @@ -122,7 +122,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)muteAudio { - return [parameters sdl_objectForName:SDLRPCParameterNameMuteAudio ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameMuteAudio ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLPerformInteraction.m b/SmartDeviceLink/SDLPerformInteraction.m index 581694608..b80e1bed6 100644 --- a/SmartDeviceLink/SDLPerformInteraction.m +++ b/SmartDeviceLink/SDLPerformInteraction.m @@ -96,7 +96,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)initialText { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameInitialText ofClass:NSString.class error:&error]; } @@ -105,7 +105,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLTTSChunk *> *)initialPrompt { - return [parameters sdl_objectsForName:SDLRPCParameterNameInitialPrompt ofClass:SDLTTSChunk.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameInitialPrompt ofClass:SDLTTSChunk.class error:nil]; } - (void)setInteractionMode:(SDLInteractionMode)interactionMode { @@ -113,7 +113,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLInteractionMode)interactionMode { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameInteractionMode error:&error]; } @@ -122,7 +122,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<NSNumber<SDLInt> *> *)interactionChoiceSetIDList { - NSError *error; + NSError *error = nil; return [parameters sdl_objectsForName:SDLRPCParameterNameInteractionChoiceSetIdList ofClass:NSNumber.class error:&error]; } @@ -131,7 +131,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLTTSChunk *> *)helpPrompt { - return [parameters sdl_objectsForName:SDLRPCParameterNameHelpPrompt ofClass:SDLTTSChunk.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameHelpPrompt ofClass:SDLTTSChunk.class error:nil]; } - (void)setTimeoutPrompt:(nullable NSArray<SDLTTSChunk *> *)timeoutPrompt { @@ -139,7 +139,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLTTSChunk *> *)timeoutPrompt { - return [parameters sdl_objectsForName:SDLRPCParameterNameTimeoutPrompt ofClass:SDLTTSChunk.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameTimeoutPrompt ofClass:SDLTTSChunk.class error:nil]; } - (void)setTimeout:(nullable NSNumber<SDLInt> *)timeout { @@ -147,7 +147,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)timeout { - return [parameters sdl_objectForName:SDLRPCParameterNameTimeout ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameTimeout ofClass:NSNumber.class error:nil]; } - (void)setVrHelp:(nullable NSArray<SDLVRHelpItem *> *)vrHelp { @@ -155,7 +155,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLVRHelpItem *> *)vrHelp { - return [parameters sdl_objectsForName:SDLRPCParameterNameVRHelp ofClass:SDLVRHelpItem.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameVRHelp ofClass:SDLVRHelpItem.class error:nil]; } - (void)setInteractionLayout:(nullable SDLLayoutMode)interactionLayout { diff --git a/SmartDeviceLink/SDLPerformInteractionResponse.m b/SmartDeviceLink/SDLPerformInteractionResponse.m index 78c7c1a6a..8da3c6bfe 100644 --- a/SmartDeviceLink/SDLPerformInteractionResponse.m +++ b/SmartDeviceLink/SDLPerformInteractionResponse.m @@ -23,7 +23,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)choiceID { - return [parameters sdl_objectForName:SDLRPCParameterNameChoiceId ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameChoiceId ofClass:NSNumber.class error:nil]; } - (void)setManualTextEntry:(nullable NSString *)manualTextEntry { @@ -31,7 +31,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)manualTextEntry { - return [parameters sdl_objectForName:SDLRPCParameterNameManualTextEntry ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameManualTextEntry ofClass:NSString.class error:nil]; } - (void)setTriggerSource:(nullable SDLTriggerSource)triggerSource { diff --git a/SmartDeviceLink/SDLPermissionItem.m b/SmartDeviceLink/SDLPermissionItem.m index 687e43a8b..462f7aaf3 100644 --- a/SmartDeviceLink/SDLPermissionItem.m +++ b/SmartDeviceLink/SDLPermissionItem.m @@ -17,7 +17,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)rpcName { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameRPCName ofClass:NSString.class error:&error]; } @@ -26,7 +26,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLHMIPermissions *)hmiPermissions { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameHMIPermissions ofClass:SDLHMIPermissions.class error:&error]; } @@ -35,7 +35,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLParameterPermissions *)parameterPermissions { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameParameterPermissions ofClass:SDLParameterPermissions.class error:&error]; } diff --git a/SmartDeviceLink/SDLPhoneCapability.m b/SmartDeviceLink/SDLPhoneCapability.m index 8547af230..0d19a7957 100644 --- a/SmartDeviceLink/SDLPhoneCapability.m +++ b/SmartDeviceLink/SDLPhoneCapability.m @@ -31,7 +31,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber *)dialNumberEnabled { - return [store sdl_objectForName:SDLRPCParameterNameDialNumberEnabled ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameDialNumberEnabled ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLPresetBankCapabilities.m b/SmartDeviceLink/SDLPresetBankCapabilities.m index d3c3c184a..ac11666ed 100644 --- a/SmartDeviceLink/SDLPresetBankCapabilities.m +++ b/SmartDeviceLink/SDLPresetBankCapabilities.m @@ -16,7 +16,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)onScreenPresetsAvailable { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameOnScreenPresetsAvailable ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLPublishAppService.m b/SmartDeviceLink/SDLPublishAppService.m index da660e2fa..aaf10799f 100644 --- a/SmartDeviceLink/SDLPublishAppService.m +++ b/SmartDeviceLink/SDLPublishAppService.m @@ -40,7 +40,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLAppServiceManifest *)appServiceManifest { - return [parameters sdl_objectForName:SDLRPCParameterNameAppServiceManifest ofClass:SDLAppServiceManifest.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAppServiceManifest ofClass:SDLAppServiceManifest.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLPublishAppServiceResponse.m b/SmartDeviceLink/SDLPublishAppServiceResponse.m index 59ae3a143..094a044ef 100644 --- a/SmartDeviceLink/SDLPublishAppServiceResponse.m +++ b/SmartDeviceLink/SDLPublishAppServiceResponse.m @@ -39,7 +39,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLAppServiceRecord *)appServiceRecord { - return [parameters sdl_objectForName:SDLRPCParameterNameAppServiceRecord ofClass:SDLAppServiceRecord.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAppServiceRecord ofClass:SDLAppServiceRecord.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLPutFile.m b/SmartDeviceLink/SDLPutFile.m index 29627ec93..5c54a712f 100644 --- a/SmartDeviceLink/SDLPutFile.m +++ b/SmartDeviceLink/SDLPutFile.m @@ -88,7 +88,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)syncFileName { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameSyncFileName ofClass:NSString.class error:&error]; } @@ -97,7 +97,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLFileType)fileType { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameFileType error:&error]; } @@ -106,7 +106,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)persistentFile { - return [parameters sdl_objectForName:SDLRPCParameterNamePersistentFile ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNamePersistentFile ofClass:NSNumber.class error:nil]; } - (void)setSystemFile:(nullable NSNumber<SDLBool> *)systemFile { @@ -114,7 +114,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)systemFile { - return [parameters sdl_objectForName:SDLRPCParameterNameSystemFile ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSystemFile ofClass:NSNumber.class error:nil]; } - (void)setOffset:(nullable NSNumber<SDLUInt> *)offset { @@ -122,7 +122,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLUInt> *)offset { - return [parameters sdl_objectForName:SDLRPCParameterNameOffset ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameOffset ofClass:NSNumber.class error:nil]; } - (void)setLength:(nullable NSNumber<SDLUInt> *)length { @@ -130,7 +130,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLUInt> *)length { - return [parameters sdl_objectForName:SDLRPCParameterNameLength ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameLength ofClass:NSNumber.class error:nil]; } - (void)setCrc:(nullable NSNumber<SDLUInt> *)crc { @@ -138,7 +138,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLUInt> *)crc { - return [parameters sdl_objectForName:SDLRPCParameterNameCRC ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameCRC ofClass:NSNumber.class error:nil]; } #pragma mark - Helpers diff --git a/SmartDeviceLink/SDLPutFileResponse.m b/SmartDeviceLink/SDLPutFileResponse.m index 735cce6c7..906f9a5bb 100644 --- a/SmartDeviceLink/SDLPutFileResponse.m +++ b/SmartDeviceLink/SDLPutFileResponse.m @@ -23,7 +23,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)spaceAvailable { - return [parameters sdl_objectForName:SDLRPCParameterNameSpaceAvailable ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSpaceAvailable ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLRDSData.m b/SmartDeviceLink/SDLRDSData.m index 4a5664daa..14219ba34 100755 --- a/SmartDeviceLink/SDLRDSData.m +++ b/SmartDeviceLink/SDLRDSData.m @@ -31,7 +31,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)programService { - return [store sdl_objectForName:SDLRPCParameterNameProgramService ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameProgramService ofClass:NSString.class error:nil]; } - (void)setRadioText:(nullable NSString *)radioText { @@ -39,7 +39,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)radioText { - return [store sdl_objectForName:SDLRPCParameterNameRadioText ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameRadioText ofClass:NSString.class error:nil]; } - (void)setClockText:(nullable NSString *)clockText { @@ -47,7 +47,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)clockText { - return [store sdl_objectForName:SDLRPCParameterNameClockText ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameClockText ofClass:NSString.class error:nil]; } - (void)setProgramIdentification:(nullable NSString *)programIdentification { @@ -55,7 +55,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)programIdentification { - return [store sdl_objectForName:SDLRPCParameterNameProgramIdentification ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameProgramIdentification ofClass:NSString.class error:nil]; } - (void)setProgramType:(nullable NSNumber<SDLInt> *)programType { @@ -63,7 +63,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)programType { - return [store sdl_objectForName:SDLRPCParameterNameProgramType ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameProgramType ofClass:NSNumber.class error:nil]; } - (void)setTrafficProgramIdentification:(nullable NSNumber<SDLBool> *)trafficProgramIdentification { @@ -71,7 +71,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)trafficProgramIdentification { - return [store sdl_objectForName:SDLRPCParameterNameTrafficProgramIdentification ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameTrafficProgramIdentification ofClass:NSNumber.class error:nil]; } - (void)setTrafficAnnouncementIdentification:(nullable NSNumber<SDLBool> *)trafficAnnouncementIdentification { @@ -79,7 +79,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)trafficAnnouncementIdentification { - return [store sdl_objectForName:SDLRPCParameterNameTrafficAnnouncementIdentification ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameTrafficAnnouncementIdentification ofClass:NSNumber.class error:nil]; } - (void)setRegion:(nullable NSString *)region { @@ -87,7 +87,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)region { - return [store sdl_objectForName:SDLRPCParameterNameRegion ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameRegion ofClass:NSString.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLRGBColor.m b/SmartDeviceLink/SDLRGBColor.m index 977675e32..ff2d4296e 100644 --- a/SmartDeviceLink/SDLRGBColor.m +++ b/SmartDeviceLink/SDLRGBColor.m @@ -45,7 +45,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)red { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameRed ofClass:NSNumber.class error:&error]; } @@ -54,7 +54,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)green { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameGreen ofClass:NSNumber.class error:&error]; } @@ -63,7 +63,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)blue { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameBlue ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLRPCMessage.m b/SmartDeviceLink/SDLRPCMessage.m index f8dfc3b9e..1d55d5f61 100644 --- a/SmartDeviceLink/SDLRPCMessage.m +++ b/SmartDeviceLink/SDLRPCMessage.m @@ -47,7 +47,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)getFunctionName { - return [function sdl_objectForName:SDLRPCParameterNameOperationName ofClass:NSString.class]; + return [function sdl_objectForName:SDLRPCParameterNameOperationName ofClass:NSString.class error:nil]; } - (void)setFunctionName:(nullable NSString *)functionName { @@ -55,7 +55,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSObject *)getParameters:(NSString *)functionName { - return [parameters sdl_objectForName:functionName ofClass:NSObject.class]; + return [parameters sdl_objectForName:functionName ofClass:NSObject.class error:nil]; } - (void)setParameters:(NSString *)functionName value:(nullable NSObject *)value { diff --git a/SmartDeviceLink/SDLRPCRequest.m b/SmartDeviceLink/SDLRPCRequest.m index 4e4916680..7c3a7c618 100644 --- a/SmartDeviceLink/SDLRPCRequest.m +++ b/SmartDeviceLink/SDLRPCRequest.m @@ -12,7 +12,7 @@ NS_ASSUME_NONNULL_BEGIN @implementation SDLRPCRequest - (NSNumber<SDLInt> *)correlationID { - NSError *error; + NSError *error = nil; return [function sdl_objectForName:SDLRPCParameterNameCorrelationId ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLRPCResponse.m b/SmartDeviceLink/SDLRPCResponse.m index 0bab8bdeb..d288da5c7 100644 --- a/SmartDeviceLink/SDLRPCResponse.m +++ b/SmartDeviceLink/SDLRPCResponse.m @@ -37,7 +37,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)correlationID { - NSError *error; + NSError *error = nil; return [function sdl_objectForName:SDLRPCParameterNameCorrelationId ofClass:NSNumber.class error:&error]; } @@ -50,7 +50,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)success { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameSuccess ofClass:NSNumber.class error:&error]; } @@ -59,7 +59,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLResult)resultCode { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameResultCode error:&error]; } @@ -68,7 +68,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)info { - return [parameters sdl_objectForName:SDLRPCParameterNameInfo ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameInfo ofClass:NSString.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLRadioControlCapabilities.m b/SmartDeviceLink/SDLRadioControlCapabilities.m index 93a842abc..58b9b7e79 100644 --- a/SmartDeviceLink/SDLRadioControlCapabilities.m +++ b/SmartDeviceLink/SDLRadioControlCapabilities.m @@ -42,7 +42,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)moduleName { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameModuleName ofClass:NSString.class error:&error]; } @@ -51,7 +51,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)radioEnableAvailable { - return [store sdl_objectForName:SDLRPCParameterNameRadioEnableAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameRadioEnableAvailable ofClass:NSNumber.class error:nil]; } - (void)setRadioBandAvailable:(nullable NSNumber<SDLBool> *)radioBandAvailable { @@ -59,7 +59,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)radioBandAvailable { - return [store sdl_objectForName:SDLRPCParameterNameRadioBandAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameRadioBandAvailable ofClass:NSNumber.class error:nil]; } - (void)setRadioFrequencyAvailable:(nullable NSNumber<SDLBool> *)radioFrequencyAvailable { @@ -67,7 +67,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)radioFrequencyAvailable { - return [store sdl_objectForName:SDLRPCParameterNameRadioFrequencyAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameRadioFrequencyAvailable ofClass:NSNumber.class error:nil]; } - (void)setHdChannelAvailable:(nullable NSNumber<SDLBool> *)hdChannelAvailable { @@ -75,7 +75,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)hdChannelAvailable { - return [store sdl_objectForName:SDLRPCParameterNameHDChannelAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHDChannelAvailable ofClass:NSNumber.class error:nil]; } - (void)setRdsDataAvailable:(nullable NSNumber<SDLBool> *)rdsDataAvailable { @@ -83,7 +83,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)rdsDataAvailable { - return [store sdl_objectForName:SDLRPCParameterNameRDSDataAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameRDSDataAvailable ofClass:NSNumber.class error:nil]; } - (void)setAvailableHDsAvailable:(nullable NSNumber<SDLBool> *)availableHDsAvailable { @@ -91,7 +91,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)availableHDsAvailable { - return [store sdl_objectForName:SDLRPCParameterNameAvailableHDsAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameAvailableHDsAvailable ofClass:NSNumber.class error:nil]; } - (void)setStateAvailable:(nullable NSNumber<SDLBool> *)stateAvailable { @@ -99,7 +99,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)stateAvailable { - return [store sdl_objectForName:SDLRPCParameterNameStateAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameStateAvailable ofClass:NSNumber.class error:nil]; } - (void)setSignalStrengthAvailable:(nullable NSNumber<SDLBool> *)signalStrengthAvailable { @@ -107,7 +107,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)signalStrengthAvailable { - return [store sdl_objectForName:SDLRPCParameterNameSignalStrengthAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameSignalStrengthAvailable ofClass:NSNumber.class error:nil]; } - (void)setSignalChangeThresholdAvailable:(nullable NSNumber<SDLBool> *)signalChangeThresholdAvailable { @@ -115,7 +115,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)signalChangeThresholdAvailable { - return [store sdl_objectForName:SDLRPCParameterNameSignalChangeThresholdAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameSignalChangeThresholdAvailable ofClass:NSNumber.class error:nil]; } - (void)setHdRadioEnableAvailable:(nullable NSNumber<SDLBool> *)hdRadioEnableAvailable { @@ -123,7 +123,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)hdRadioEnableAvailable { - return [store sdl_objectForName:SDLRPCParameterNameHDRadioEnableAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHDRadioEnableAvailable ofClass:NSNumber.class error:nil]; } - (void)setSiriusXMRadioAvailable:(nullable NSNumber<SDLBool> *)siriusXMRadioAvailable { @@ -131,7 +131,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)siriusXMRadioAvailable { - return [store sdl_objectForName:SDLRPCParameterNameSiriusXMRadioAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameSiriusXMRadioAvailable ofClass:NSNumber.class error:nil]; } - (void)setSisDataAvailable:(nullable NSNumber<SDLBool> *)sisDataAvailable { @@ -139,7 +139,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)sisDataAvailable { - return [store sdl_objectForName:SDLRPCParameterNameSISDataAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameSISDataAvailable ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLRadioControlData.m b/SmartDeviceLink/SDLRadioControlData.m index 0ff04872f..a87bd3367 100644 --- a/SmartDeviceLink/SDLRadioControlData.m +++ b/SmartDeviceLink/SDLRadioControlData.m @@ -48,7 +48,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)frequencyInteger { - return [store sdl_objectForName:SDLRPCParameterNameFrequencyInteger ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameFrequencyInteger ofClass:NSNumber.class error:nil]; } - (void)setFrequencyFraction:(nullable NSNumber<SDLInt> *)frequencyFraction { @@ -56,7 +56,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)frequencyFraction { - return [store sdl_objectForName:SDLRPCParameterNameFrequencyFraction ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameFrequencyFraction ofClass:NSNumber.class error:nil]; } - (void)setBand:(nullable SDLRadioBand)band { @@ -72,7 +72,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLRDSData *)rdsData { - return [store sdl_objectForName:SDLRPCParameterNameRDSData ofClass:SDLRDSData.class]; + return [store sdl_objectForName:SDLRPCParameterNameRDSData ofClass:SDLRDSData.class error:nil]; } - (void)setAvailableHDs:(nullable NSNumber<SDLInt> *)availableHDs { @@ -80,7 +80,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)availableHDs { - return [store sdl_objectForName:SDLRPCParameterNameAvailableHDs ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameAvailableHDs ofClass:NSNumber.class error:nil]; } - (void)setHdChannel:(nullable NSNumber<SDLInt> *)hdChannel { @@ -88,7 +88,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)hdChannel { - return [store sdl_objectForName:SDLRPCParameterNameHDChannel ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHDChannel ofClass:NSNumber.class error:nil]; } - (void)setSignalStrength:(nullable NSNumber<SDLInt> *)signalStrength { @@ -96,7 +96,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)signalStrength { - return [store sdl_objectForName:SDLRPCParameterNameSignalStrength ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameSignalStrength ofClass:NSNumber.class error:nil]; } - (void)setSignalChangeThreshold:(nullable NSNumber<SDLInt> *)signalChangeThreshold { @@ -104,7 +104,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)signalChangeThreshold { - return [store sdl_objectForName:SDLRPCParameterNameSignalChangeThreshold ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameSignalChangeThreshold ofClass:NSNumber.class error:nil]; } - (void)setRadioEnable:(nullable NSNumber<SDLBool> *)radioEnable { @@ -112,7 +112,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)radioEnable { - return [store sdl_objectForName:SDLRPCParameterNameRadioEnable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameRadioEnable ofClass:NSNumber.class error:nil]; } - (void)setState:(nullable SDLRadioState)state { @@ -128,7 +128,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)hdRadioEnable { - return [store sdl_objectForName:SDLRPCParameterNameHDRadioEnable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHDRadioEnable ofClass:NSNumber.class error:nil]; } - (void)setSisData:(nullable SDLSISData *)sisData { @@ -136,7 +136,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLSISData *)sisData { - return [store sdl_objectForName:SDLRPCParameterNameSISData ofClass:SDLSISData.class]; + return [store sdl_objectForName:SDLRPCParameterNameSISData ofClass:SDLSISData.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLReadDID.m b/SmartDeviceLink/SDLReadDID.m index 900ef7510..01996893a 100644 --- a/SmartDeviceLink/SDLReadDID.m +++ b/SmartDeviceLink/SDLReadDID.m @@ -35,7 +35,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)ecuName { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameECUName ofClass:NSNumber.class error:&error]; } @@ -44,7 +44,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<NSNumber<SDLInt> *> *)didLocation { - NSError *error; + NSError *error = nil; return [parameters sdl_objectsForName:SDLRPCParameterNameDIDLocation ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLReadDIDResponse.m b/SmartDeviceLink/SDLReadDIDResponse.m index fc6fb60d2..8bf510370 100644 --- a/SmartDeviceLink/SDLReadDIDResponse.m +++ b/SmartDeviceLink/SDLReadDIDResponse.m @@ -24,7 +24,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLDIDResult *> *)didResult { - return [parameters sdl_objectsForName:SDLRPCParameterNameDIDResult ofClass:SDLDIDResult.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameDIDResult ofClass:SDLDIDResult.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLRectangle.m b/SmartDeviceLink/SDLRectangle.m index a05033b08..64a368e13 100644 --- a/SmartDeviceLink/SDLRectangle.m +++ b/SmartDeviceLink/SDLRectangle.m @@ -33,7 +33,7 @@ } - (NSNumber<SDLFloat> *)x { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameX ofClass:NSNumber.class error:&error]; } @@ -42,7 +42,7 @@ } - (NSNumber<SDLFloat> *)y { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameY ofClass:NSNumber.class error:&error]; } @@ -51,7 +51,7 @@ } - (NSNumber<SDLFloat> *)width { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameWidth ofClass:NSNumber.class error:&error]; } @@ -60,7 +60,7 @@ } - (NSNumber<SDLFloat> *)height { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameHeight ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLRegisterAppInterface.m b/SmartDeviceLink/SDLRegisterAppInterface.m index 9299e44c4..963522619 100644 --- a/SmartDeviceLink/SDLRegisterAppInterface.m +++ b/SmartDeviceLink/SDLRegisterAppInterface.m @@ -121,7 +121,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLSyncMsgVersion *)syncMsgVersion { - return [parameters sdl_objectForName:SDLRPCParameterNameSyncMessageVersion ofClass:SDLSyncMsgVersion.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSyncMessageVersion ofClass:SDLSyncMsgVersion.class error:nil]; } - (void)setAppName:(NSString *)appName { @@ -129,7 +129,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)appName { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameAppName ofClass:NSString.class error:&error]; } @@ -138,7 +138,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLTTSChunk *> *)ttsName { - return [parameters sdl_objectsForName:SDLRPCParameterNameTTSName ofClass:SDLTTSChunk.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameTTSName ofClass:SDLTTSChunk.class error:nil]; } - (void)setNgnMediaScreenAppName:(nullable NSString *)ngnMediaScreenAppName { @@ -146,7 +146,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)ngnMediaScreenAppName { - return [parameters sdl_objectForName:SDLRPCParameterNameNGNMediaScreenAppName ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameNGNMediaScreenAppName ofClass:NSString.class error:nil]; } - (void)setVrSynonyms:(nullable NSArray<NSString *> *)vrSynonyms { @@ -154,7 +154,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<NSString *> *)vrSynonyms { - return [parameters sdl_objectsForName:SDLRPCParameterNameVRSynonyms ofClass:NSString.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameVRSynonyms ofClass:NSString.class error:nil]; } - (void)setIsMediaApplication:(NSNumber<SDLBool> *)isMediaApplication { @@ -162,7 +162,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)isMediaApplication { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameIsMediaApplication ofClass:NSNumber.class error:&error]; } @@ -171,7 +171,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLLanguage)languageDesired { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameLanguageDesired error:&error]; } @@ -180,7 +180,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLLanguage)hmiDisplayLanguageDesired { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameHMIDisplayLanguageDesired error:&error]; } @@ -197,7 +197,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)hashID { - return [parameters sdl_objectForName:SDLRPCParameterNameHashId ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameHashId ofClass:NSString.class error:nil]; } - (void)setDeviceInfo:(nullable SDLDeviceInfo *)deviceInfo { @@ -205,7 +205,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLDeviceInfo *)deviceInfo { - return [parameters sdl_objectForName:SDLRPCParameterNameDeviceInfo ofClass:SDLDeviceInfo.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameDeviceInfo ofClass:SDLDeviceInfo.class error:nil]; } - (void)setAppID:(NSString *)appID { @@ -213,7 +213,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)appID { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameAppId ofClass:NSString.class error:&error]; } @@ -222,7 +222,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)fullAppID { - return [parameters sdl_objectForName:SDLRPCParameterNameFullAppID ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameFullAppID ofClass:NSString.class error:nil]; } - (void)setAppInfo:(nullable SDLAppInfo *)appInfo { @@ -230,7 +230,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLAppInfo *)appInfo { - return [parameters sdl_objectForName:SDLRPCParameterNameAppInfo ofClass:SDLAppInfo.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAppInfo ofClass:SDLAppInfo.class error:nil]; } - (void)setDayColorScheme:(nullable SDLTemplateColorScheme *)dayColorScheme { @@ -238,7 +238,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLTemplateColorScheme *)dayColorScheme { - return [parameters sdl_objectForName:SDLRPCParameterNameDayColorScheme ofClass:[SDLTemplateColorScheme class]]; + return [parameters sdl_objectForName:SDLRPCParameterNameDayColorScheme ofClass:SDLTemplateColorScheme.class error:nil]; } - (void)setNightColorScheme:(nullable SDLTemplateColorScheme *)nightColorScheme { @@ -246,7 +246,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLTemplateColorScheme *)nightColorScheme { - return [parameters sdl_objectForName:SDLRPCParameterNameNightColorScheme ofClass:[SDLTemplateColorScheme class]]; + return [parameters sdl_objectForName:SDLRPCParameterNameNightColorScheme ofClass:SDLTemplateColorScheme.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLRegisterAppInterfaceResponse.m b/SmartDeviceLink/SDLRegisterAppInterfaceResponse.m index 56adb870b..d91d0dfb0 100644 --- a/SmartDeviceLink/SDLRegisterAppInterfaceResponse.m +++ b/SmartDeviceLink/SDLRegisterAppInterfaceResponse.m @@ -32,7 +32,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLSyncMsgVersion *)syncMsgVersion { - return [parameters sdl_objectForName:SDLRPCParameterNameSyncMessageVersion ofClass:SDLSyncMsgVersion.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSyncMessageVersion ofClass:SDLSyncMsgVersion.class error:nil]; } - (void)setLanguage:(nullable SDLLanguage)language { @@ -56,7 +56,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLDisplayCapabilities *)displayCapabilities { - return [parameters sdl_objectForName:SDLRPCParameterNameDisplayCapabilities ofClass:SDLDisplayCapabilities.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameDisplayCapabilities ofClass:SDLDisplayCapabilities.class error:nil]; } - (void)setButtonCapabilities:(nullable NSArray<SDLButtonCapabilities *> *)buttonCapabilities { @@ -64,7 +64,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLButtonCapabilities *> *)buttonCapabilities { - return [parameters sdl_objectsForName:SDLRPCParameterNameButtonCapabilities ofClass:SDLButtonCapabilities.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameButtonCapabilities ofClass:SDLButtonCapabilities.class error:nil]; } - (void)setSoftButtonCapabilities:(nullable NSArray<SDLSoftButtonCapabilities *> *)softButtonCapabilities { @@ -72,7 +72,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLSoftButtonCapabilities *> *)softButtonCapabilities { - return [parameters sdl_objectsForName:SDLRPCParameterNameSoftButtonCapabilities ofClass:SDLSoftButtonCapabilities.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameSoftButtonCapabilities ofClass:SDLSoftButtonCapabilities.class error:nil]; } - (void)setPresetBankCapabilities:(nullable SDLPresetBankCapabilities *)presetBankCapabilities { @@ -80,7 +80,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLPresetBankCapabilities *)presetBankCapabilities { - return [parameters sdl_objectForName:SDLRPCParameterNamePresetBankCapabilities ofClass:SDLPresetBankCapabilities.class]; + return [parameters sdl_objectForName:SDLRPCParameterNamePresetBankCapabilities ofClass:SDLPresetBankCapabilities.class error:nil]; } - (void)setHmiZoneCapabilities:(nullable NSArray<SDLHMIZoneCapabilities> *)hmiZoneCapabilities { @@ -120,7 +120,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLAudioPassThruCapabilities *> *)audioPassThruCapabilities { - return [parameters sdl_objectsForName:SDLRPCParameterNameAudioPassThruCapabilities ofClass:SDLAudioPassThruCapabilities.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameAudioPassThruCapabilities ofClass:SDLAudioPassThruCapabilities.class error:nil]; } - (void)setPcmStreamCapabilities:(nullable SDLAudioPassThruCapabilities *)pcmStreamCapabilities { @@ -128,7 +128,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLAudioPassThruCapabilities *)pcmStreamCapabilities { - return [parameters sdl_objectForName:SDLRPCParameterNamePCMStreamCapabilities ofClass:SDLAudioPassThruCapabilities.class]; + return [parameters sdl_objectForName:SDLRPCParameterNamePCMStreamCapabilities ofClass:SDLAudioPassThruCapabilities.class error:nil]; } - (void)setVehicleType:(nullable SDLVehicleType *)vehicleType { @@ -136,7 +136,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleType *)vehicleType { - return [parameters sdl_objectForName:SDLRPCParameterNameVehicleType ofClass:[SDLVehicleType class]]; + return [parameters sdl_objectForName:SDLRPCParameterNameVehicleType ofClass:SDLVehicleType.class error:nil]; } - (void)setSupportedDiagModes:(nullable NSArray<NSNumber<SDLInt> *> *)supportedDiagModes { @@ -144,7 +144,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<NSNumber<SDLInt> *> *)supportedDiagModes { - return [parameters sdl_objectsForName:SDLRPCParameterNameSupportedDiagnosticModes ofClass:NSNumber.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameSupportedDiagnosticModes ofClass:NSNumber.class error:nil]; } - (void)setHmiCapabilities:(nullable SDLHMICapabilities *)hmiCapabilities { @@ -152,7 +152,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLHMICapabilities *)hmiCapabilities { - return [parameters sdl_objectForName:SDLRPCParameterNameHMICapabilities ofClass:SDLHMICapabilities.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameHMICapabilities ofClass:SDLHMICapabilities.class error:nil]; } - (void)setSdlVersion:(nullable NSString *)sdlVersion { @@ -160,7 +160,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)sdlVersion { - return [parameters sdl_objectForName:SDLRPCParameterNameSDLVersion ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSDLVersion ofClass:NSString.class error:nil]; } - (void)setSystemSoftwareVersion:(nullable NSString *)systemSoftwareVersion { @@ -168,7 +168,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)systemSoftwareVersion { - return [parameters sdl_objectForName:SDLRPCParameterNameSystemSoftwareVersion ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSystemSoftwareVersion ofClass:NSString.class error:nil]; } - (void)setIconResumed:(nullable NSNumber<SDLBool> *)iconResumed { @@ -176,7 +176,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)iconResumed { - return [parameters sdl_objectForName:SDLRPCParameterNameIconResumed ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameIconResumed ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLRemoteControlCapabilities.m b/SmartDeviceLink/SDLRemoteControlCapabilities.m index af54458bd..f1620af10 100644 --- a/SmartDeviceLink/SDLRemoteControlCapabilities.m +++ b/SmartDeviceLink/SDLRemoteControlCapabilities.m @@ -44,7 +44,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLClimateControlCapabilities *> *)climateControlCapabilities { - return [store sdl_objectsForName:SDLRPCParameterNameClimateControlCapabilities ofClass:SDLClimateControlCapabilities.class]; + return [store sdl_objectsForName:SDLRPCParameterNameClimateControlCapabilities ofClass:SDLClimateControlCapabilities.class error:nil]; } -(void)setRadioControlCapabilities:(nullable NSArray<SDLRadioControlCapabilities *> *)radioControlCapabilities { @@ -52,14 +52,14 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLRadioControlCapabilities *> *)radioControlCapabilities { - return [store sdl_objectsForName:SDLRPCParameterNameRadioControlCapabilities ofClass:SDLRadioControlCapabilities.class]; + return [store sdl_objectsForName:SDLRPCParameterNameRadioControlCapabilities ofClass:SDLRadioControlCapabilities.class error:nil]; } - (void)setButtonCapabilities:(nullable NSArray<SDLButtonCapabilities *> *)buttonCapabilities { [store sdl_setObject:buttonCapabilities forName:SDLRPCParameterNameButtonCapabilities];} - (nullable NSArray<SDLButtonCapabilities *> *)buttonCapabilities { - return [store sdl_objectsForName:SDLRPCParameterNameButtonCapabilities ofClass:SDLButtonCapabilities.class]; + return [store sdl_objectsForName:SDLRPCParameterNameButtonCapabilities ofClass:SDLButtonCapabilities.class error:nil]; } - (void)setSeatControlCapabilities:(nullable NSArray<SDLSeatControlCapabilities *> *)seatControlCapabilities { @@ -67,7 +67,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLSeatControlCapabilities *> *)seatControlCapabilities { - return [store sdl_objectsForName:SDLRPCParameterNameSeatControlCapabilities ofClass:SDLSeatControlCapabilities.class]; + return [store sdl_objectsForName:SDLRPCParameterNameSeatControlCapabilities ofClass:SDLSeatControlCapabilities.class error:nil]; } - (void)setAudioControlCapabilities:(nullable NSArray<SDLAudioControlCapabilities *> *)audioControlCapabilities { @@ -75,7 +75,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLAudioControlCapabilities *> *)audioControlCapabilities { - return [store sdl_objectsForName:SDLRPCParameterNameAudioControlCapabilities ofClass:SDLAudioControlCapabilities.class]; + return [store sdl_objectsForName:SDLRPCParameterNameAudioControlCapabilities ofClass:SDLAudioControlCapabilities.class error:nil]; } @@ -84,7 +84,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLHMISettingsControlCapabilities *> *)hmiSettingsControlCapabilities { - return [store sdl_objectsForName:SDLRPCParameterNameHmiSettingsControlCapabilities ofClass:SDLHMISettingsControlCapabilities.class]; + return [store sdl_objectsForName:SDLRPCParameterNameHmiSettingsControlCapabilities ofClass:SDLHMISettingsControlCapabilities.class error:nil]; } - (void)setLightControlCapabilities:(nullable NSArray<SDLLightControlCapabilities *> *)lightControlCapabilities { @@ -92,7 +92,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLLightControlCapabilities *> *)lightControlCapabilities { - return [store sdl_objectsForName:SDLRPCParameterNameLightControlCapabilities ofClass:SDLLightControlCapabilities.class]; + return [store sdl_objectsForName:SDLRPCParameterNameLightControlCapabilities ofClass:SDLLightControlCapabilities.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLResetGlobalProperties.m b/SmartDeviceLink/SDLResetGlobalProperties.m index cdc258432..331f560bd 100644 --- a/SmartDeviceLink/SDLResetGlobalProperties.m +++ b/SmartDeviceLink/SDLResetGlobalProperties.m @@ -35,7 +35,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<SDLGlobalProperty> *)properties { - NSError *error; + NSError *error = nil; return [parameters sdl_enumsForName:SDLRPCParameterNameProperties error:&error]; } diff --git a/SmartDeviceLink/SDLSISData.m b/SmartDeviceLink/SDLSISData.m index b2f40425b..f7589afd9 100644 --- a/SmartDeviceLink/SDLSISData.m +++ b/SmartDeviceLink/SDLSISData.m @@ -32,7 +32,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)stationShortName { - return [store sdl_objectForName:SDLRPCParameterNameStationShortName ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameStationShortName ofClass:NSString.class error:nil]; } - (void)setStationIDNumber:(nullable SDLStationIDNumber *)stationIDNumber { @@ -40,7 +40,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLStationIDNumber *)stationIDNumber { - return [store sdl_objectForName:SDLRPCParameterNameStationIDNumber ofClass:SDLStationIDNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameStationIDNumber ofClass:SDLStationIDNumber.class error:nil]; } - (void)setStationLongName:(nullable NSString *)stationLongName { @@ -48,7 +48,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)stationLongName { - return [store sdl_objectForName:SDLRPCParameterNameStationLongName ofClass:NSString.class];; + return [store sdl_objectForName:SDLRPCParameterNameStationLongName ofClass:NSString.class error:nil];; } - (void)setStationLocation:(nullable SDLGPSData *)stationLocation { @@ -56,7 +56,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLGPSData *)stationLocation { - return [store sdl_objectForName:SDLRPCParameterNameStationLocation ofClass:SDLGPSData.class]; + return [store sdl_objectForName:SDLRPCParameterNameStationLocation ofClass:SDLGPSData.class error:nil]; } - (void)setStationMessage:(nullable NSString *)stationMessage { @@ -64,7 +64,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)stationMessage { - return [store sdl_objectForName:SDLRPCParameterNameStationMessage ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameStationMessage ofClass:NSString.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLScreenParams.m b/SmartDeviceLink/SDLScreenParams.m index 95d255f81..039f054e8 100644 --- a/SmartDeviceLink/SDLScreenParams.m +++ b/SmartDeviceLink/SDLScreenParams.m @@ -17,7 +17,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLImageResolution *)resolution { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameResolution ofClass:SDLImageResolution.class error:&error]; } @@ -26,7 +26,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLTouchEventCapabilities *)touchEventAvailable { - return [store sdl_objectForName:SDLRPCParameterNameTouchEventAvailable ofClass:SDLTouchEventCapabilities.class]; + return [store sdl_objectForName:SDLRPCParameterNameTouchEventAvailable ofClass:SDLTouchEventCapabilities.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLScrollableMessage.m b/SmartDeviceLink/SDLScrollableMessage.m index 92f1e68ea..034190e34 100644 --- a/SmartDeviceLink/SDLScrollableMessage.m +++ b/SmartDeviceLink/SDLScrollableMessage.m @@ -47,7 +47,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)scrollableMessageBody { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameScrollableMessageBody ofClass:NSString.class error:&error]; } @@ -56,7 +56,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)timeout { - return [parameters sdl_objectForName:SDLRPCParameterNameTimeout ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameTimeout ofClass:NSNumber.class error:nil]; } - (void)setSoftButtons:(nullable NSArray<SDLSoftButton *> *)softButtons { @@ -64,7 +64,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLSoftButton *> *)softButtons { - return [parameters sdl_objectsForName:SDLRPCParameterNameSoftButtons ofClass:SDLSoftButton.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameSoftButtons ofClass:SDLSoftButton.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLSeatControlCapabilities.m b/SmartDeviceLink/SDLSeatControlCapabilities.m index b9955b03c..0c5a95c58 100644 --- a/SmartDeviceLink/SDLSeatControlCapabilities.m +++ b/SmartDeviceLink/SDLSeatControlCapabilities.m @@ -48,7 +48,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)moduleName { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameModuleName ofClass:NSString.class error:&error]; } @@ -57,7 +57,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)heatingEnabledAvailable { - return [store sdl_objectForName:SDLRPCParameterNameHeatingEnabledAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHeatingEnabledAvailable ofClass:NSNumber.class error:nil]; } - (void)setCoolingEnabledAvailable:(nullable NSNumber<SDLBool> *)coolingEnabledAvailable { @@ -66,7 +66,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)coolingEnabledAvailable { - return [store sdl_objectForName:SDLRPCParameterNameCoolingEnabledAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameCoolingEnabledAvailable ofClass:NSNumber.class error:nil]; } @@ -76,7 +76,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)heatingLevelAvailable { - return [store sdl_objectForName:SDLRPCParameterNameHeatingLevelAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHeatingLevelAvailable ofClass:NSNumber.class error:nil]; } @@ -86,7 +86,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)coolingLevelAvailable { - return [store sdl_objectForName:SDLRPCParameterNameCoolingLevelAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameCoolingLevelAvailable ofClass:NSNumber.class error:nil]; } @@ -96,7 +96,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)horizontalPositionAvailable { - return [store sdl_objectForName:SDLRPCParameterNameHorizontalPositionAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHorizontalPositionAvailable ofClass:NSNumber.class error:nil]; } @@ -106,7 +106,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)verticalPositionAvailable { - return [store sdl_objectForName:SDLRPCParameterNameVerticalPositionAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameVerticalPositionAvailable ofClass:NSNumber.class error:nil]; } @@ -116,7 +116,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)frontVerticalPositionAvailable { - return [store sdl_objectForName:SDLRPCParameterNameFrontVerticalPositionAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameFrontVerticalPositionAvailable ofClass:NSNumber.class error:nil]; } @@ -126,7 +126,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)backVerticalPositionAvailable { - return [store sdl_objectForName:SDLRPCParameterNameBackVerticalPositionAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameBackVerticalPositionAvailable ofClass:NSNumber.class error:nil]; } @@ -136,7 +136,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)backTiltAngleAvailable { - return [store sdl_objectForName:SDLRPCParameterNameBackTiltAngleAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameBackTiltAngleAvailable ofClass:NSNumber.class error:nil]; } @@ -146,7 +146,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)headSupportHorizontalPositionAvailable { - return [store sdl_objectForName:SDLRPCParameterNameHeadSupportHorizontalPositionAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHeadSupportHorizontalPositionAvailable ofClass:NSNumber.class error:nil]; } @@ -156,7 +156,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)headSupportVerticalPositionAvailable { - return [store sdl_objectForName:SDLRPCParameterNameHeadSupportVerticalPositionAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHeadSupportVerticalPositionAvailable ofClass:NSNumber.class error:nil]; } @@ -166,7 +166,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)massageEnabledAvailable { - return [store sdl_objectForName:SDLRPCParameterNameMassageEnabledAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameMassageEnabledAvailable ofClass:NSNumber.class error:nil]; } @@ -176,7 +176,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)massageModeAvailable { - return [store sdl_objectForName:SDLRPCParameterNameMassageModeAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameMassageModeAvailable ofClass:NSNumber.class error:nil]; } @@ -186,7 +186,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)massageCushionFirmnessAvailable { - return [store sdl_objectForName:SDLRPCParameterNameMassageCushionFirmnessAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameMassageCushionFirmnessAvailable ofClass:NSNumber.class error:nil]; } @@ -196,7 +196,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)memoryAvailable { - return [store sdl_objectForName:SDLRPCParameterNameMemoryAvailable ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameMemoryAvailable ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLSeatControlData.m b/SmartDeviceLink/SDLSeatControlData.m index d9c47a0e6..734c412a7 100644 --- a/SmartDeviceLink/SDLSeatControlData.m +++ b/SmartDeviceLink/SDLSeatControlData.m @@ -58,7 +58,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLSupportedSeat)id { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameId error:&error]; } @@ -67,7 +67,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)heatingEnabled { - return [store sdl_objectForName:SDLRPCParameterNameHeatingEnabled ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHeatingEnabled ofClass:NSNumber.class error:nil]; } - (void)setCoolingEnabled:(nullable NSNumber<SDLBool> *)coolingEnabled { @@ -75,7 +75,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)coolingEnabled { - return [store sdl_objectForName:SDLRPCParameterNameCoolingEnabled ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameCoolingEnabled ofClass:NSNumber.class error:nil]; } - (void)setHeatingLevel:(nullable NSNumber<SDLInt> *)heatingLevel { @@ -83,7 +83,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)heatingLevel { - return [store sdl_objectForName:SDLRPCParameterNameHeatingLevel ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHeatingLevel ofClass:NSNumber.class error:nil]; } - (void)setCoolingLevel:(nullable NSNumber<SDLInt> *)coolingLevel { @@ -91,7 +91,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)coolingLevel { - return [store sdl_objectForName:SDLRPCParameterNameCoolingLevel ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameCoolingLevel ofClass:NSNumber.class error:nil]; } - (void)setHorizontalPosition:(nullable NSNumber<SDLInt> *)horizontalPosition { @@ -99,7 +99,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)horizontalPosition { - return [store sdl_objectForName:SDLRPCParameterNameHorizontalPosition ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHorizontalPosition ofClass:NSNumber.class error:nil]; } - (void)setVerticalPosition:(nullable NSNumber<SDLInt> *)verticalPosition { @@ -107,7 +107,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)verticalPosition { - return [store sdl_objectForName:SDLRPCParameterNameVerticalPosition ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameVerticalPosition ofClass:NSNumber.class error:nil]; } - (void)setFrontVerticalPosition:(nullable NSNumber<SDLInt> *)frontVerticalPosition { @@ -115,7 +115,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)frontVerticalPosition { - return [store sdl_objectForName:SDLRPCParameterNameFrontVerticalPosition ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameFrontVerticalPosition ofClass:NSNumber.class error:nil]; } - (void)setBackVerticalPosition:(nullable NSNumber<SDLInt> *)backVerticalPosition { @@ -123,7 +123,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)backVerticalPosition { - return [store sdl_objectForName:SDLRPCParameterNameBackVerticalPosition ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameBackVerticalPosition ofClass:NSNumber.class error:nil]; } - (void)setBackTiltAngle:(nullable NSNumber<SDLInt> *)backTiltAngle { @@ -131,7 +131,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)backTiltAngle { - return [store sdl_objectForName:SDLRPCParameterNameBackTiltAngle ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameBackTiltAngle ofClass:NSNumber.class error:nil]; } - (void)setHeadSupportHorizontalPosition:(nullable NSNumber<SDLInt> *)headSupportHorizontalPosition { @@ -139,7 +139,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)headSupportHorizontalPosition { - return [store sdl_objectForName:SDLRPCParameterNameHeadSupportHorizontalPosition ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHeadSupportHorizontalPosition ofClass:NSNumber.class error:nil]; } -(void)setHeadSupportVerticalPosition:(nullable NSNumber<SDLInt> *)headSupportVerticalPosition { @@ -147,7 +147,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)headSupportVerticalPosition { - return [store sdl_objectForName:SDLRPCParameterNameHeadSupportVerticalPosition ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHeadSupportVerticalPosition ofClass:NSNumber.class error:nil]; } - (void)setMassageEnabled:(nullable NSNumber<SDLBool> *)massageEnabled { @@ -155,7 +155,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)massageEnabled { - return [store sdl_objectForName:SDLRPCParameterNameMassageEnabled ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameMassageEnabled ofClass:NSNumber.class error:nil]; } @@ -164,7 +164,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLMassageModeData *> *)massageMode { - return [store sdl_objectsForName:SDLRPCParameterNameMassageMode ofClass:SDLMassageModeData.class]; + return [store sdl_objectsForName:SDLRPCParameterNameMassageMode ofClass:SDLMassageModeData.class error:nil]; } - (void)setMassageCushionFirmness:(nullable NSArray<SDLMassageCushionFirmness *> *)massageCushionFirmness { @@ -172,7 +172,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLMassageCushionFirmness *> *)massageCushionFirmness { - return [store sdl_objectsForName:SDLRPCParameterNameMassageCushionFirmness ofClass:SDLMassageCushionFirmness.class]; + return [store sdl_objectsForName:SDLRPCParameterNameMassageCushionFirmness ofClass:SDLMassageCushionFirmness.class error:nil]; } - (void)setMemory:(nullable SDLSeatMemoryAction *)memory { @@ -180,7 +180,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLSeatMemoryAction *)memory { - return [store sdl_objectForName:SDLRPCParameterNameMemory ofClass:SDLSeatMemoryAction.class]; + return [store sdl_objectForName:SDLRPCParameterNameMemory ofClass:SDLSeatMemoryAction.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLSeatMemoryAction.m b/SmartDeviceLink/SDLSeatMemoryAction.m index 5e69f94dc..a4144901a 100644 --- a/SmartDeviceLink/SDLSeatMemoryAction.m +++ b/SmartDeviceLink/SDLSeatMemoryAction.m @@ -36,7 +36,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)id { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameId ofClass:NSNumber.class error:&error]; } @@ -45,7 +45,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)label { - return [store sdl_objectForName:SDLRPCParameterNameLabel ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameLabel ofClass:NSString.class error:nil]; } - (void)setAction:(SDLSeatMemoryActionType)action { @@ -53,7 +53,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLSeatMemoryActionType)action { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameAction error:&error]; } @end diff --git a/SmartDeviceLink/SDLSendHapticData.m b/SmartDeviceLink/SDLSendHapticData.m index fc2af7a90..3302fbe49 100644 --- a/SmartDeviceLink/SDLSendHapticData.m +++ b/SmartDeviceLink/SDLSendHapticData.m @@ -38,7 +38,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLHapticRect *> *)hapticRectData { - return [parameters sdl_objectsForName:SDLRPCParameterNameHapticRectData ofClass:SDLHapticRect.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameHapticRectData ofClass:SDLHapticRect.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLSendLocation.m b/SmartDeviceLink/SDLSendLocation.m index 2460c632a..5874a86f3 100644 --- a/SmartDeviceLink/SDLSendLocation.m +++ b/SmartDeviceLink/SDLSendLocation.m @@ -66,7 +66,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)longitudeDegrees { - return [parameters sdl_objectForName:SDLRPCParameterNameLongitudeDegrees ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameLongitudeDegrees ofClass:NSNumber.class error:nil]; } - (void)setLatitudeDegrees:(nullable NSNumber<SDLFloat> *)latitudeDegrees { @@ -74,7 +74,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)latitudeDegrees { - return [parameters sdl_objectForName:SDLRPCParameterNameLatitudeDegrees ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameLatitudeDegrees ofClass:NSNumber.class error:nil]; } - (void)setLocationName:(nullable NSString *)locationName { @@ -82,7 +82,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)locationName { - return [parameters sdl_objectForName:SDLRPCParameterNameLocationName ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameLocationName ofClass:NSString.class error:nil]; } - (void)setAddressLines:(nullable NSArray<NSString *> *)addressLines { @@ -90,7 +90,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)locationDescription { - return [parameters sdl_objectForName:SDLRPCParameterNameLocationDescription ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameLocationDescription ofClass:NSString.class error:nil]; } - (void)setLocationDescription:(nullable NSString *)locationDescription { @@ -98,7 +98,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<NSString *> *)addressLines { - return [parameters sdl_objectsForName:SDLRPCParameterNameAddressLines ofClass:NSString.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameAddressLines ofClass:NSString.class error:nil]; } - (void)setPhoneNumber:(nullable NSString *)phoneNumber { @@ -106,7 +106,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)phoneNumber { - return [parameters sdl_objectForName:SDLRPCParameterNamePhoneNumber ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNamePhoneNumber ofClass:NSString.class error:nil]; } - (void)setLocationImage:(nullable SDLImage *)locationImage { @@ -114,7 +114,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLImage *)locationImage { - return [parameters sdl_objectForName:SDLRPCParameterNameLocationImage ofClass:SDLImage.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameLocationImage ofClass:SDLImage.class error:nil]; } - (void)setDeliveryMode:(nullable SDLDeliveryMode)deliveryMode { @@ -130,7 +130,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLDateTime *)timeStamp { - return [parameters sdl_objectForName:SDLRPCParameterNameTimeStamp ofClass:SDLDateTime.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameTimeStamp ofClass:SDLDateTime.class error:nil]; } - (void)setAddress:(nullable SDLOasisAddress *)address { @@ -138,7 +138,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLOasisAddress *)address { - return [parameters sdl_objectForName:SDLRPCParameterNameAddress ofClass:SDLOasisAddress.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAddress ofClass:SDLOasisAddress.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLSetAppIcon.m b/SmartDeviceLink/SDLSetAppIcon.m index e3a5d9756..a76abaa58 100644 --- a/SmartDeviceLink/SDLSetAppIcon.m +++ b/SmartDeviceLink/SDLSetAppIcon.m @@ -32,7 +32,7 @@ } - (NSString *)syncFileName { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameSyncFileName ofClass:NSString.class error:&error]; } diff --git a/SmartDeviceLink/SDLSetDisplayLayout.m b/SmartDeviceLink/SDLSetDisplayLayout.m index b99994681..90c253717 100644 --- a/SmartDeviceLink/SDLSetDisplayLayout.m +++ b/SmartDeviceLink/SDLSetDisplayLayout.m @@ -49,7 +49,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)displayLayout { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameDisplayLayout ofClass:NSString.class error:&error]; } @@ -58,7 +58,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLTemplateColorScheme *)dayColorScheme { - return [parameters sdl_objectForName:SDLRPCParameterNameDayColorScheme ofClass:[SDLTemplateColorScheme class]]; + return [parameters sdl_objectForName:SDLRPCParameterNameDayColorScheme ofClass:SDLTemplateColorScheme.class error:nil]; } - (void)setNightColorScheme:(nullable SDLTemplateColorScheme *)nightColorScheme { @@ -66,7 +66,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLTemplateColorScheme *)nightColorScheme { - return [parameters sdl_objectForName:SDLRPCParameterNameNightColorScheme ofClass:[SDLTemplateColorScheme class]]; + return [parameters sdl_objectForName:SDLRPCParameterNameNightColorScheme ofClass:SDLTemplateColorScheme.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLSetDisplayLayoutResponse.m b/SmartDeviceLink/SDLSetDisplayLayoutResponse.m index 6fe5946de..21d25661e 100644 --- a/SmartDeviceLink/SDLSetDisplayLayoutResponse.m +++ b/SmartDeviceLink/SDLSetDisplayLayoutResponse.m @@ -27,7 +27,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLDisplayCapabilities *)displayCapabilities { - return [parameters sdl_objectForName:SDLRPCParameterNameDisplayCapabilities ofClass:SDLDisplayCapabilities.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameDisplayCapabilities ofClass:SDLDisplayCapabilities.class error:nil]; } - (void)setButtonCapabilities:(nullable NSArray<SDLButtonCapabilities *> *)buttonCapabilities { @@ -35,7 +35,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLButtonCapabilities *> *)buttonCapabilities { - return [parameters sdl_objectsForName:SDLRPCParameterNameButtonCapabilities ofClass:SDLButtonCapabilities.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameButtonCapabilities ofClass:SDLButtonCapabilities.class error:nil]; } - (void)setSoftButtonCapabilities:(nullable NSArray<SDLSoftButtonCapabilities *> *)softButtonCapabilities { @@ -43,7 +43,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLSoftButtonCapabilities *> *)softButtonCapabilities { - return [parameters sdl_objectsForName:SDLRPCParameterNameSoftButtonCapabilities ofClass:SDLSoftButtonCapabilities.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameSoftButtonCapabilities ofClass:SDLSoftButtonCapabilities.class error:nil]; } - (void)setPresetBankCapabilities:(nullable SDLPresetBankCapabilities *)presetBankCapabilities { @@ -51,7 +51,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLPresetBankCapabilities *)presetBankCapabilities { - return [parameters sdl_objectForName:SDLRPCParameterNamePresetBankCapabilities ofClass:SDLPresetBankCapabilities.class]; + return [parameters sdl_objectForName:SDLRPCParameterNamePresetBankCapabilities ofClass:SDLPresetBankCapabilities.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLSetGlobalProperties.m b/SmartDeviceLink/SDLSetGlobalProperties.m index b5c279a3d..970c21e5a 100644 --- a/SmartDeviceLink/SDLSetGlobalProperties.m +++ b/SmartDeviceLink/SDLSetGlobalProperties.m @@ -52,7 +52,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLTTSChunk *> *)helpPrompt { - return [parameters sdl_objectsForName:SDLRPCParameterNameHelpPrompt ofClass:SDLTTSChunk.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameHelpPrompt ofClass:SDLTTSChunk.class error:nil]; } - (void)setTimeoutPrompt:(nullable NSArray<SDLTTSChunk *> *)timeoutPrompt { @@ -60,7 +60,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLTTSChunk *> *)timeoutPrompt { - return [parameters sdl_objectsForName:SDLRPCParameterNameTimeoutPrompt ofClass:SDLTTSChunk.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameTimeoutPrompt ofClass:SDLTTSChunk.class error:nil]; } - (void)setVrHelpTitle:(nullable NSString *)vrHelpTitle { @@ -68,7 +68,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)vrHelpTitle { - return [parameters sdl_objectForName:SDLRPCParameterNameVRHelpTitle ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameVRHelpTitle ofClass:NSString.class error:nil]; } - (void)setVrHelp:(nullable NSArray<SDLVRHelpItem *> *)vrHelp { @@ -76,7 +76,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLVRHelpItem *> *)vrHelp { - return [parameters sdl_objectsForName:SDLRPCParameterNameVRHelp ofClass:SDLVRHelpItem.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameVRHelp ofClass:SDLVRHelpItem.class error:nil]; } - (void)setMenuTitle:(nullable NSString *)menuTitle { @@ -84,7 +84,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)menuTitle { - return [parameters sdl_objectForName:SDLRPCParameterNameMenuTitle ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameMenuTitle ofClass:NSString.class error:nil]; } - (void)setMenuIcon:(nullable SDLImage *)menuIcon { @@ -92,7 +92,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLImage *)menuIcon { - return [parameters sdl_objectForName:SDLRPCParameterNameMenuIcon ofClass:SDLImage.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameMenuIcon ofClass:SDLImage.class error:nil]; } - (void)setKeyboardProperties:(nullable SDLKeyboardProperties *)keyboardProperties { @@ -100,7 +100,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLKeyboardProperties *)keyboardProperties { - return [parameters sdl_objectForName:SDLRPCParameterNameKeyboardProperties ofClass:SDLKeyboardProperties.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameKeyboardProperties ofClass:SDLKeyboardProperties.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLSetInteriorVehicleData.m b/SmartDeviceLink/SDLSetInteriorVehicleData.m index 7f99cc534..f49091768 100644 --- a/SmartDeviceLink/SDLSetInteriorVehicleData.m +++ b/SmartDeviceLink/SDLSetInteriorVehicleData.m @@ -34,7 +34,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLModuleData *)moduleData { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameModuleData ofClass:SDLModuleData.class error:&error]; } diff --git a/SmartDeviceLink/SDLSetInteriorVehicleDataResponse.m b/SmartDeviceLink/SDLSetInteriorVehicleDataResponse.m index 4aeb90eda..93a628366 100644 --- a/SmartDeviceLink/SDLSetInteriorVehicleDataResponse.m +++ b/SmartDeviceLink/SDLSetInteriorVehicleDataResponse.m @@ -23,7 +23,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLModuleData *)moduleData { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameModuleData ofClass:SDLModuleData.class error:&error]; } diff --git a/SmartDeviceLink/SDLSetMediaClockTimer.m b/SmartDeviceLink/SDLSetMediaClockTimer.m index d86a163b7..5b1dbfaed 100644 --- a/SmartDeviceLink/SDLSetMediaClockTimer.m +++ b/SmartDeviceLink/SDLSetMediaClockTimer.m @@ -114,7 +114,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLStartTime *)startTime { - return [parameters sdl_objectForName:SDLRPCParameterNameStartTime ofClass:SDLStartTime.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameStartTime ofClass:SDLStartTime.class error:nil]; } - (void)setEndTime:(nullable SDLStartTime *)endTime { @@ -122,7 +122,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLStartTime *)endTime { - return [parameters sdl_objectForName:SDLRPCParameterNameEndTime ofClass:SDLStartTime.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameEndTime ofClass:SDLStartTime.class error:nil]; } - (void)setUpdateMode:(SDLUpdateMode)updateMode { @@ -130,7 +130,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLUpdateMode)updateMode { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameUpdateMode error:&error]; } diff --git a/SmartDeviceLink/SDLShow.m b/SmartDeviceLink/SDLShow.m index efeba27a0..b4e0b0abd 100644 --- a/SmartDeviceLink/SDLShow.m +++ b/SmartDeviceLink/SDLShow.m @@ -102,7 +102,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)mainField1 { - return [parameters sdl_objectForName:SDLRPCParameterNameMainField1 ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameMainField1 ofClass:NSString.class error:nil]; } - (void)setMainField2:(nullable NSString *)mainField2 { @@ -110,7 +110,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)mainField2 { - return [parameters sdl_objectForName:SDLRPCParameterNameMainField2 ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameMainField2 ofClass:NSString.class error:nil]; } - (void)setMainField3:(nullable NSString *)mainField3 { @@ -118,7 +118,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)mainField3 { - return [parameters sdl_objectForName:SDLRPCParameterNameMainField3 ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameMainField3 ofClass:NSString.class error:nil]; } - (void)setMainField4:(nullable NSString *)mainField4 { @@ -126,7 +126,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)mainField4 { - return [parameters sdl_objectForName:SDLRPCParameterNameMainField4 ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameMainField4 ofClass:NSString.class error:nil]; } - (void)setAlignment:(nullable SDLTextAlignment)alignment { @@ -142,7 +142,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)statusBar { - return [parameters sdl_objectForName:SDLRPCParameterNameStatusBar ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameStatusBar ofClass:NSString.class error:nil]; } - (void)setMediaClock:(nullable NSString *)mediaClock { @@ -150,7 +150,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)mediaClock { - return [parameters sdl_objectForName:SDLRPCParameterNameMediaClock ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameMediaClock ofClass:NSString.class error:nil]; } - (void)setMediaTrack:(nullable NSString *)mediaTrack { @@ -158,7 +158,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)mediaTrack { - return [parameters sdl_objectForName:SDLRPCParameterNameMediaTrack ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameMediaTrack ofClass:NSString.class error:nil]; } - (void)setGraphic:(nullable SDLImage *)graphic { @@ -166,7 +166,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLImage *)graphic { - return [parameters sdl_objectForName:SDLRPCParameterNameGraphic ofClass:SDLImage.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameGraphic ofClass:SDLImage.class error:nil]; } - (void)setSecondaryGraphic:(nullable SDLImage *)secondaryGraphic { @@ -174,7 +174,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLImage *)secondaryGraphic { - return [parameters sdl_objectForName:SDLRPCParameterNameSecondaryGraphic ofClass:SDLImage.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSecondaryGraphic ofClass:SDLImage.class error:nil]; } - (void)setSoftButtons:(nullable NSArray<SDLSoftButton *> *)softButtons { @@ -182,7 +182,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLSoftButton *> *)softButtons { - return [parameters sdl_objectsForName:SDLRPCParameterNameSoftButtons ofClass:SDLSoftButton.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameSoftButtons ofClass:SDLSoftButton.class error:nil]; } - (void)setCustomPresets:(nullable NSArray<NSString *> *)customPresets { @@ -190,7 +190,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<NSString *> *)customPresets { - return [parameters sdl_objectsForName:SDLRPCParameterNameCustomPresets ofClass:NSString.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameCustomPresets ofClass:NSString.class error:nil]; } - (void)setMetadataTags:(nullable SDLMetadataTags *)metadataTags { @@ -198,7 +198,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLMetadataTags *)metadataTags { - return [parameters sdl_objectForName:SDLRPCParameterNameMetadataTags ofClass:SDLMetadataTags.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameMetadataTags ofClass:SDLMetadataTags.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLShowConstantTBT.m b/SmartDeviceLink/SDLShowConstantTBT.m index ceb2b37c2..d1068d963 100644 --- a/SmartDeviceLink/SDLShowConstantTBT.m +++ b/SmartDeviceLink/SDLShowConstantTBT.m @@ -46,7 +46,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)navigationText1 { - return [parameters sdl_objectForName:SDLRPCParameterNameNavigationText1 ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameNavigationText1 ofClass:NSString.class error:nil]; } - (void)setNavigationText2:(nullable NSString *)navigationText2 { @@ -54,7 +54,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)navigationText2 { - return [parameters sdl_objectForName:SDLRPCParameterNameNavigationText2 ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameNavigationText2 ofClass:NSString.class error:nil]; } - (void)setEta:(nullable NSString *)eta { @@ -62,7 +62,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)eta { - return [parameters sdl_objectForName:SDLRPCParameterNameETA ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameETA ofClass:NSString.class error:nil]; } - (void)setTimeToDestination:(nullable NSString *)timeToDestination { @@ -70,7 +70,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)timeToDestination { - return [parameters sdl_objectForName:SDLRPCParameterNameTimeToDestination ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameTimeToDestination ofClass:NSString.class error:nil]; } - (void)setTotalDistance:(nullable NSString *)totalDistance { @@ -78,7 +78,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)totalDistance { - return [parameters sdl_objectForName:SDLRPCParameterNameTotalDistance ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameTotalDistance ofClass:NSString.class error:nil]; } - (void)setTurnIcon:(nullable SDLImage *)turnIcon { @@ -86,7 +86,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLImage *)turnIcon { - return [parameters sdl_objectForName:SDLRPCParameterNameTurnIcon ofClass:SDLImage.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameTurnIcon ofClass:SDLImage.class error:nil]; } - (void)setNextTurnIcon:(nullable SDLImage *)nextTurnIcon { @@ -94,7 +94,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLImage *)nextTurnIcon { - return [parameters sdl_objectForName:SDLRPCParameterNameNextTurnIcon ofClass:SDLImage.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameNextTurnIcon ofClass:SDLImage.class error:nil]; } - (void)setDistanceToManeuver:(nullable NSNumber<SDLFloat> *)distanceToManeuver { @@ -102,7 +102,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)distanceToManeuver { - return [parameters sdl_objectForName:SDLRPCParameterNameDistanceToManeuver ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameDistanceToManeuver ofClass:NSNumber.class error:nil]; } - (void)setDistanceToManeuverScale:(nullable NSNumber<SDLFloat> *)distanceToManeuverScale { @@ -110,7 +110,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)distanceToManeuverScale { - return [parameters sdl_objectForName:SDLRPCParameterNameDistanceToManeuverScale ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameDistanceToManeuverScale ofClass:NSNumber.class error:nil]; } - (void)setManeuverComplete:(nullable NSNumber<SDLBool> *)maneuverComplete { @@ -118,7 +118,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)maneuverComplete { - return [parameters sdl_objectForName:SDLRPCParameterNameManeuverComplete ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameManeuverComplete ofClass:NSNumber.class error:nil]; } - (void)setSoftButtons:(nullable NSArray<SDLSoftButton *> *)softButtons { @@ -126,7 +126,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLSoftButton *> *)softButtons { - return [parameters sdl_objectsForName:SDLRPCParameterNameSoftButtons ofClass:SDLSoftButton.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameSoftButtons ofClass:SDLSoftButton.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLSingleTireStatus.m b/SmartDeviceLink/SDLSingleTireStatus.m index 45df91fc5..283e32f51 100644 --- a/SmartDeviceLink/SDLSingleTireStatus.m +++ b/SmartDeviceLink/SDLSingleTireStatus.m @@ -16,7 +16,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLComponentVolumeStatus)status { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameStatus error:&error]; } @@ -33,7 +33,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)pressure { - return [store sdl_objectForName:SDLRPCParameterNamePressure ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNamePressure ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLSlider.m b/SmartDeviceLink/SDLSlider.m index 68a320ada..25f83ce89 100644 --- a/SmartDeviceLink/SDLSlider.m +++ b/SmartDeviceLink/SDLSlider.m @@ -57,7 +57,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)numTicks { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameNumberTicks ofClass:NSNumber.class error:&error]; } @@ -66,7 +66,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)position { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNamePosition ofClass:NSNumber.class error:&error]; } @@ -75,7 +75,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)sliderHeader { - NSError *error; + NSError *error = nil; return [parameters sdl_objectForName:SDLRPCParameterNameSliderHeader ofClass:NSString.class error:&error]; } @@ -84,7 +84,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<NSString *> *)sliderFooter { - return [parameters sdl_objectsForName:SDLRPCParameterNameSliderFooter ofClass:NSString.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameSliderFooter ofClass:NSString.class error:nil]; } - (void)setTimeout:(nullable NSNumber<SDLInt> *)timeout { @@ -92,7 +92,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)timeout { - return [parameters sdl_objectForName:SDLRPCParameterNameTimeout ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameTimeout ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLSliderResponse.m b/SmartDeviceLink/SDLSliderResponse.m index 1f8c03c9f..fc8e1cbb6 100644 --- a/SmartDeviceLink/SDLSliderResponse.m +++ b/SmartDeviceLink/SDLSliderResponse.m @@ -23,7 +23,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)sliderPosition { - return [parameters sdl_objectForName:SDLRPCParameterNameSliderPosition ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSliderPosition ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLSoftButton.m b/SmartDeviceLink/SDLSoftButton.m index fc15a61d6..a2b526c23 100644 --- a/SmartDeviceLink/SDLSoftButton.m +++ b/SmartDeviceLink/SDLSoftButton.m @@ -44,7 +44,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLSoftButtonType)type { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameType error:&error]; } @@ -53,7 +53,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)text { - return [store sdl_objectForName:SDLRPCParameterNameText ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameText ofClass:NSString.class error:nil]; } - (void)setImage:(nullable SDLImage *)image { @@ -61,7 +61,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLImage *)image { - return [store sdl_objectForName:SDLRPCParameterNameImage ofClass:SDLImage.class]; + return [store sdl_objectForName:SDLRPCParameterNameImage ofClass:SDLImage.class error:nil]; } - (void)setIsHighlighted:(nullable NSNumber<SDLBool> *)isHighlighted { @@ -69,7 +69,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)isHighlighted { - return [store sdl_objectForName:SDLRPCParameterNameIsHighlighted ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameIsHighlighted ofClass:NSNumber.class error:nil]; } - (void)setSoftButtonID:(NSNumber<SDLInt> *)softButtonID { @@ -77,7 +77,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)softButtonID { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameSoftButtonId ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLSoftButtonCapabilities.m b/SmartDeviceLink/SDLSoftButtonCapabilities.m index a591f1dd0..d85c9bd69 100644 --- a/SmartDeviceLink/SDLSoftButtonCapabilities.m +++ b/SmartDeviceLink/SDLSoftButtonCapabilities.m @@ -16,7 +16,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)shortPressAvailable { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameShortPressAvailable ofClass:NSNumber.class error:&error]; } @@ -25,7 +25,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)longPressAvailable { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameLongPressAvailable ofClass:NSNumber.class error:&error]; } @@ -34,7 +34,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)upDownAvailable { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameUpDownAvailable ofClass:NSNumber.class error:&error]; } @@ -43,7 +43,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)imageSupported { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameImageSupported ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLSpeak.m b/SmartDeviceLink/SDLSpeak.m index bfd65f902..a0ce720e6 100644 --- a/SmartDeviceLink/SDLSpeak.m +++ b/SmartDeviceLink/SDLSpeak.m @@ -40,7 +40,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<SDLTTSChunk *> *)ttsChunks { - NSError *error; + NSError *error = nil; return [parameters sdl_objectsForName:SDLRPCParameterNameTTSChunks ofClass:SDLTTSChunk.class error:&error]; } diff --git a/SmartDeviceLink/SDLStartTime.m b/SmartDeviceLink/SDLStartTime.m index 1bd5dd82d..5420246ae 100644 --- a/SmartDeviceLink/SDLStartTime.m +++ b/SmartDeviceLink/SDLStartTime.m @@ -42,7 +42,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)hours { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameHours ofClass:NSNumber.class error:&error]; } @@ -51,7 +51,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)minutes { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameMinutes ofClass:NSNumber.class error:&error]; } @@ -60,7 +60,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)seconds { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameSeconds ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLStationIDNumber.m b/SmartDeviceLink/SDLStationIDNumber.m index 6c4922c74..623cb0b09 100644 --- a/SmartDeviceLink/SDLStationIDNumber.m +++ b/SmartDeviceLink/SDLStationIDNumber.m @@ -26,7 +26,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)countryCode { - return [store sdl_objectForName:SDLRPCParameterNameCountryCode ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameCountryCode ofClass:NSNumber.class error:nil]; } @@ -35,7 +35,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)fccFacilityId { - return [store sdl_objectForName:SDLRPCParameterNameFCCFacilityId ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameFCCFacilityId ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLSubscribeButton.m b/SmartDeviceLink/SDLSubscribeButton.m index dd314fa57..f3fc0a8ab 100644 --- a/SmartDeviceLink/SDLSubscribeButton.m +++ b/SmartDeviceLink/SDLSubscribeButton.m @@ -46,7 +46,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLButtonName)buttonName { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameButtonName error:&error]; } diff --git a/SmartDeviceLink/SDLSubscribeVehicleData.m b/SmartDeviceLink/SDLSubscribeVehicleData.m index 24b46577d..f33420cef 100644 --- a/SmartDeviceLink/SDLSubscribeVehicleData.m +++ b/SmartDeviceLink/SDLSubscribeVehicleData.m @@ -65,7 +65,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)gps { - return [parameters sdl_objectForName:SDLRPCParameterNameGPS ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameGPS ofClass:NSNumber.class error:nil]; } - (void)setSpeed:(nullable NSNumber<SDLBool> *)speed { @@ -73,7 +73,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)speed { - return [parameters sdl_objectForName:SDLRPCParameterNameSpeed ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSpeed ofClass:NSNumber.class error:nil]; } - (void)setRpm:(nullable NSNumber<SDLBool> *)rpm { @@ -81,7 +81,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)rpm { - return [parameters sdl_objectForName:SDLRPCParameterNameRPM ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameRPM ofClass:NSNumber.class error:nil]; } - (void)setFuelLevel:(nullable NSNumber<SDLBool> *)fuelLevel { @@ -89,7 +89,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)fuelLevel { - return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevel ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevel ofClass:NSNumber.class error:nil]; } - (void)setFuelLevel_State:(nullable NSNumber<SDLBool> *)fuelLevel_State { @@ -97,7 +97,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)fuelLevel_State { - return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevelState ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevelState ofClass:NSNumber.class error:nil]; } - (void)setFuelRange:(nullable NSNumber<SDLBool> *)fuelRange { @@ -105,7 +105,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)fuelRange { - return [parameters sdl_objectForName:SDLRPCParameterNameFuelRange ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameFuelRange ofClass:NSNumber.class error:nil]; } - (void)setInstantFuelConsumption:(nullable NSNumber<SDLBool> *)instantFuelConsumption { @@ -113,7 +113,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)instantFuelConsumption { - return [parameters sdl_objectForName:SDLRPCParameterNameInstantFuelConsumption ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameInstantFuelConsumption ofClass:NSNumber.class error:nil]; } - (void)setExternalTemperature:(nullable NSNumber<SDLBool> *)externalTemperature { @@ -121,7 +121,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)externalTemperature { - return [parameters sdl_objectForName:SDLRPCParameterNameExternalTemperature ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameExternalTemperature ofClass:NSNumber.class error:nil]; } - (void)setPrndl:(nullable NSNumber<SDLBool> *)prndl { @@ -129,7 +129,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)prndl { - return [parameters sdl_objectForName:SDLRPCParameterNamePRNDL ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNamePRNDL ofClass:NSNumber.class error:nil]; } - (void)setTirePressure:(nullable NSNumber<SDLBool> *)tirePressure { @@ -137,7 +137,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)tirePressure { - return [parameters sdl_objectForName:SDLRPCParameterNameTirePressure ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameTirePressure ofClass:NSNumber.class error:nil]; } - (void)setOdometer:(nullable NSNumber<SDLBool> *)odometer { @@ -145,7 +145,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)odometer { - return [parameters sdl_objectForName:SDLRPCParameterNameOdometer ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameOdometer ofClass:NSNumber.class error:nil]; } - (void)setBeltStatus:(nullable NSNumber<SDLBool> *)beltStatus { @@ -153,7 +153,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)beltStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameBeltStatus ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameBeltStatus ofClass:NSNumber.class error:nil]; } - (void)setBodyInformation:(nullable NSNumber<SDLBool> *)bodyInformation { @@ -161,7 +161,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)bodyInformation { - return [parameters sdl_objectForName:SDLRPCParameterNameBodyInformation ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameBodyInformation ofClass:NSNumber.class error:nil]; } - (void)setDeviceStatus:(nullable NSNumber<SDLBool> *)deviceStatus { @@ -169,7 +169,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)deviceStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameDeviceStatus ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameDeviceStatus ofClass:NSNumber.class error:nil]; } - (void)setDriverBraking:(nullable NSNumber<SDLBool> *)driverBraking { @@ -177,7 +177,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)driverBraking { - return [parameters sdl_objectForName:SDLRPCParameterNameDriverBraking ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameDriverBraking ofClass:NSNumber.class error:nil]; } - (void)setWiperStatus:(nullable NSNumber<SDLBool> *)wiperStatus { @@ -185,7 +185,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)wiperStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameWiperStatus ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameWiperStatus ofClass:NSNumber.class error:nil]; } - (void)setHeadLampStatus:(nullable NSNumber<SDLBool> *)headLampStatus { @@ -193,7 +193,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)headLampStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameHeadLampStatus ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameHeadLampStatus ofClass:NSNumber.class error:nil]; } - (void)setEngineOilLife:(nullable NSNumber<SDLBool> *)engineOilLife { @@ -201,7 +201,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)engineOilLife { - return [parameters sdl_objectForName:SDLRPCParameterNameEngineOilLife ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameEngineOilLife ofClass:NSNumber.class error:nil]; } - (void)setEngineTorque:(nullable NSNumber<SDLBool> *)engineTorque { @@ -209,7 +209,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)engineTorque { - return [parameters sdl_objectForName:SDLRPCParameterNameEngineTorque ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameEngineTorque ofClass:NSNumber.class error:nil]; } - (void)setAccPedalPosition:(nullable NSNumber<SDLBool> *)accPedalPosition { @@ -217,7 +217,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)accPedalPosition { - return [parameters sdl_objectForName:SDLRPCParameterNameAccelerationPedalPosition ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAccelerationPedalPosition ofClass:NSNumber.class error:nil]; } - (void)setSteeringWheelAngle:(nullable NSNumber<SDLBool> *)steeringWheelAngle { @@ -225,7 +225,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)steeringWheelAngle { - return [parameters sdl_objectForName:SDLRPCParameterNameSteeringWheelAngle ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSteeringWheelAngle ofClass:NSNumber.class error:nil]; } - (void)setECallInfo:(nullable NSNumber<SDLBool> *)eCallInfo { @@ -233,7 +233,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)eCallInfo { - return [parameters sdl_objectForName:SDLRPCParameterNameECallInfo ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameECallInfo ofClass:NSNumber.class error:nil]; } - (void)setAirbagStatus:(nullable NSNumber<SDLBool> *)airbagStatus { @@ -241,7 +241,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)airbagStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameAirbagStatus ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAirbagStatus ofClass:NSNumber.class error:nil]; } - (void)setEmergencyEvent:(nullable NSNumber<SDLBool> *)emergencyEvent { @@ -249,7 +249,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)emergencyEvent { - return [parameters sdl_objectForName:SDLRPCParameterNameEmergencyEvent ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameEmergencyEvent ofClass:NSNumber.class error:nil]; } - (void)setClusterModeStatus:(nullable NSNumber<SDLBool> *)clusterModeStatus { @@ -257,7 +257,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)clusterModeStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameClusterModeStatus ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameClusterModeStatus ofClass:NSNumber.class error:nil]; } - (void)setMyKey:(nullable NSNumber<SDLBool> *)myKey { @@ -265,7 +265,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)myKey { - return [parameters sdl_objectForName:SDLRPCParameterNameMyKey ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameMyKey ofClass:NSNumber.class error:nil]; } - (void)setElectronicParkBrakeStatus:(nullable NSNumber<SDLBool> *)electronicParkBrakeStatus { @@ -273,7 +273,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)electronicParkBrakeStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameElectronicParkBrakeStatus ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameElectronicParkBrakeStatus ofClass:NSNumber.class error:nil]; } - (void)setTurnSignal:(nullable NSNumber<SDLBool> *)turnSignal { @@ -281,7 +281,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)turnSignal { - return [parameters sdl_objectForName:SDLRPCParameterNameTurnSignal ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameTurnSignal ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLSubscribeVehicleDataResponse.m b/SmartDeviceLink/SDLSubscribeVehicleDataResponse.m index ab575d0c5..a91ed2d38 100644 --- a/SmartDeviceLink/SDLSubscribeVehicleDataResponse.m +++ b/SmartDeviceLink/SDLSubscribeVehicleDataResponse.m @@ -24,7 +24,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)gps { - return [parameters sdl_objectForName:SDLRPCParameterNameGPS ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameGPS ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setSpeed:(nullable SDLVehicleDataResult *)speed { @@ -32,7 +32,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)speed { - return [parameters sdl_objectForName:SDLRPCParameterNameSpeed ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSpeed ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setRpm:(nullable SDLVehicleDataResult *)rpm { @@ -40,7 +40,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)rpm { - return [parameters sdl_objectForName:SDLRPCParameterNameRPM ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameRPM ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setFuelLevel:(nullable SDLVehicleDataResult *)fuelLevel { @@ -48,7 +48,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)fuelLevel { - return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevel ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevel ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setFuelLevel_State:(nullable SDLVehicleDataResult *)fuelLevel_State { @@ -56,7 +56,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)fuelLevel_State { - return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevelState ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevelState ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setFuelRange:(nullable SDLVehicleDataResult *)fuelRange { @@ -64,7 +64,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)fuelRange { - return [parameters sdl_objectForName:SDLRPCParameterNameFuelRange ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameFuelRange ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setInstantFuelConsumption:(nullable SDLVehicleDataResult *)instantFuelConsumption { @@ -72,7 +72,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)instantFuelConsumption { - return [parameters sdl_objectForName:SDLRPCParameterNameInstantFuelConsumption ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameInstantFuelConsumption ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setExternalTemperature:(nullable SDLVehicleDataResult *)externalTemperature { @@ -80,7 +80,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)externalTemperature { - return [parameters sdl_objectForName:SDLRPCParameterNameExternalTemperature ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameExternalTemperature ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setPrndl:(nullable SDLVehicleDataResult *)prndl { @@ -88,7 +88,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)prndl { - return [parameters sdl_objectForName:SDLRPCParameterNamePRNDL ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNamePRNDL ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setTirePressure:(nullable SDLVehicleDataResult *)tirePressure { @@ -96,7 +96,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)tirePressure { - return [parameters sdl_objectForName:SDLRPCParameterNameTirePressure ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameTirePressure ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setOdometer:(nullable SDLVehicleDataResult *)odometer { @@ -104,7 +104,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)odometer { - return [parameters sdl_objectForName:SDLRPCParameterNameOdometer ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameOdometer ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setBeltStatus:(nullable SDLVehicleDataResult *)beltStatus { @@ -112,7 +112,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)beltStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameBeltStatus ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameBeltStatus ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setBodyInformation:(nullable SDLVehicleDataResult *)bodyInformation { @@ -120,7 +120,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)bodyInformation { - return [parameters sdl_objectForName:SDLRPCParameterNameBodyInformation ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameBodyInformation ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setDeviceStatus:(nullable SDLVehicleDataResult *)deviceStatus { @@ -128,7 +128,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)deviceStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameDeviceStatus ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameDeviceStatus ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setDriverBraking:(nullable SDLVehicleDataResult *)driverBraking { @@ -136,7 +136,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)driverBraking { - return [parameters sdl_objectForName:SDLRPCParameterNameDriverBraking ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameDriverBraking ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setWiperStatus:(nullable SDLVehicleDataResult *)wiperStatus { @@ -144,7 +144,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)wiperStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameWiperStatus ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameWiperStatus ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setHeadLampStatus:(nullable SDLVehicleDataResult *)headLampStatus { @@ -152,7 +152,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)headLampStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameHeadLampStatus ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameHeadLampStatus ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setEngineOilLife:(nullable SDLVehicleDataResult *)engineOilLife { @@ -160,7 +160,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)engineOilLife { - return [parameters sdl_objectForName:SDLRPCParameterNameEngineOilLife ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameEngineOilLife ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setEngineTorque:(nullable SDLVehicleDataResult *)engineTorque { @@ -168,7 +168,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)engineTorque { - return [parameters sdl_objectForName:SDLRPCParameterNameEngineTorque ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameEngineTorque ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setAccPedalPosition:(nullable SDLVehicleDataResult *)accPedalPosition { @@ -176,7 +176,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)accPedalPosition { - return [parameters sdl_objectForName:SDLRPCParameterNameAccelerationPedalPosition ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAccelerationPedalPosition ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setSteeringWheelAngle:(nullable SDLVehicleDataResult *)steeringWheelAngle { @@ -184,7 +184,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)steeringWheelAngle { - return [parameters sdl_objectForName:SDLRPCParameterNameSteeringWheelAngle ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSteeringWheelAngle ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setECallInfo:(nullable SDLVehicleDataResult *)eCallInfo { @@ -192,7 +192,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)eCallInfo { - return [parameters sdl_objectForName:SDLRPCParameterNameECallInfo ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameECallInfo ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setAirbagStatus:(nullable SDLVehicleDataResult *)airbagStatus { @@ -200,7 +200,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)airbagStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameAirbagStatus ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAirbagStatus ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setEmergencyEvent:(nullable SDLVehicleDataResult *)emergencyEvent { @@ -208,7 +208,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)emergencyEvent { - return [parameters sdl_objectForName:SDLRPCParameterNameEmergencyEvent ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameEmergencyEvent ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setClusterModes:(nullable SDLVehicleDataResult *)clusterModes { @@ -216,7 +216,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)clusterModes { - return [parameters sdl_objectForName:SDLRPCParameterNameClusterModes ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameClusterModes ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setMyKey:(nullable SDLVehicleDataResult *)myKey { @@ -224,7 +224,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)myKey { - return [parameters sdl_objectForName:SDLRPCParameterNameMyKey ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameMyKey ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setElectronicParkBrakeStatus:(nullable SDLVehicleDataResult *)electronicParkBrakeStatus { @@ -232,7 +232,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)electronicParkBrakeStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameElectronicParkBrakeStatus ofClass:[SDLVehicleDataResult class]]; + return [parameters sdl_objectForName:SDLRPCParameterNameElectronicParkBrakeStatus ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setTurnSignal:(nullable SDLVehicleDataResult *)turnSignal { @@ -240,7 +240,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)turnSignal { - return [parameters sdl_objectForName:SDLRPCParameterNameTurnSignal ofClass:[SDLVehicleDataResult class]]; + return [parameters sdl_objectForName:SDLRPCParameterNameTurnSignal ofClass:SDLVehicleDataResult.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLSyncMsgVersion.m b/SmartDeviceLink/SDLSyncMsgVersion.m index cc01938e1..82cfb6d4f 100644 --- a/SmartDeviceLink/SDLSyncMsgVersion.m +++ b/SmartDeviceLink/SDLSyncMsgVersion.m @@ -29,7 +29,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)majorVersion { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameMajorVersion ofClass:NSNumber.class error:&error]; } @@ -38,7 +38,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)minorVersion { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameMinorVersion ofClass:NSNumber.class error:&error]; } @@ -47,7 +47,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)patchVersion { - return [store sdl_objectForName:SDLRPCParameterNamePatchVersion ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNamePatchVersion ofClass:NSNumber.class error:nil]; } - (NSString *)description { diff --git a/SmartDeviceLink/SDLSystemCapability.m b/SmartDeviceLink/SDLSystemCapability.m index 23cc35c3d..23c826a34 100755 --- a/SmartDeviceLink/SDLSystemCapability.m +++ b/SmartDeviceLink/SDLSystemCapability.m @@ -86,7 +86,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLSystemCapabilityType)systemCapabilityType { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameSystemCapabilityType error:&error]; } @@ -95,7 +95,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLAppServicesCapabilities *)appServicesCapabilities { - return [store sdl_objectForName:SDLRPCParameterNameAppServicesCapabilities ofClass:SDLAppServicesCapabilities.class]; + return [store sdl_objectForName:SDLRPCParameterNameAppServicesCapabilities ofClass:SDLAppServicesCapabilities.class error:nil]; } - (void)setNavigationCapability:(nullable SDLNavigationCapability *)navigationCapability { @@ -103,7 +103,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLNavigationCapability *)navigationCapability { - return [store sdl_objectForName:SDLRPCParameterNameNavigationCapability ofClass:SDLNavigationCapability.class]; + return [store sdl_objectForName:SDLRPCParameterNameNavigationCapability ofClass:SDLNavigationCapability.class error:nil]; } - (void)setPhoneCapability:(nullable SDLPhoneCapability *)phoneCapability { @@ -111,7 +111,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLPhoneCapability *)phoneCapability { - return [store sdl_objectForName:SDLRPCParameterNamePhoneCapability ofClass:SDLPhoneCapability.class]; + return [store sdl_objectForName:SDLRPCParameterNamePhoneCapability ofClass:SDLPhoneCapability.class error:nil]; } - (void)setVideoStreamingCapability:(nullable SDLVideoStreamingCapability *)videoStreamingCapability { @@ -119,7 +119,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVideoStreamingCapability *)videoStreamingCapability { - return [store sdl_objectForName:SDLRPCParameterNameVideoStreamingCapability ofClass:SDLVideoStreamingCapability.class]; + return [store sdl_objectForName:SDLRPCParameterNameVideoStreamingCapability ofClass:SDLVideoStreamingCapability.class error:nil]; } - (void)setRemoteControlCapability:(nullable SDLRemoteControlCapabilities *)remoteControlCapability { @@ -127,7 +127,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLRemoteControlCapabilities *)remoteControlCapability { - return [store sdl_objectForName:SDLRPCParameterNameRemoteControlCapability ofClass:SDLRemoteControlCapabilities.class]; + return [store sdl_objectForName:SDLRPCParameterNameRemoteControlCapability ofClass:SDLRemoteControlCapabilities.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLSystemRequest.m b/SmartDeviceLink/SDLSystemRequest.m index 81cc6d9c5..db8eead44 100644 --- a/SmartDeviceLink/SDLSystemRequest.m +++ b/SmartDeviceLink/SDLSystemRequest.m @@ -46,7 +46,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLRequestType)requestType { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameRequestType error:&error]; } @@ -55,7 +55,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)requestSubType { - return [parameters sdl_objectForName:SDLRPCParameterNameRequestSubType ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameRequestSubType ofClass:NSString.class error:nil]; } - (void)setFileName:(nullable NSString *)fileName { @@ -63,7 +63,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)fileName { - return [parameters sdl_objectForName:SDLRPCParameterNameFilename ofClass:NSString.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameFilename ofClass:NSString.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLTTSChunk.m b/SmartDeviceLink/SDLTTSChunk.m index 76256582b..3d66387d0 100644 --- a/SmartDeviceLink/SDLTTSChunk.m +++ b/SmartDeviceLink/SDLTTSChunk.m @@ -59,7 +59,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)text { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameText ofClass:NSString.class error:&error]; } @@ -68,7 +68,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLSpeechCapabilities)type { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameType error:&error]; } diff --git a/SmartDeviceLink/SDLTemperature.m b/SmartDeviceLink/SDLTemperature.m index 27f54d363..66759f4fd 100644 --- a/SmartDeviceLink/SDLTemperature.m +++ b/SmartDeviceLink/SDLTemperature.m @@ -35,7 +35,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLTemperatureUnit)unit { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameUnit error:&error]; } @@ -44,7 +44,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLFloat> *)value { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameValue ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLTemplateColorScheme.m b/SmartDeviceLink/SDLTemplateColorScheme.m index 1172ea77f..da1e833e3 100644 --- a/SmartDeviceLink/SDLTemplateColorScheme.m +++ b/SmartDeviceLink/SDLTemplateColorScheme.m @@ -43,7 +43,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLRGBColor *)primaryColor { - return [store sdl_objectForName:SDLRPCParameterNamePrimaryColor ofClass:[SDLRGBColor class]]; + return [store sdl_objectForName:SDLRPCParameterNamePrimaryColor ofClass:SDLRGBColor.class error:nil]; } - (void)setSecondaryColor:(nullable SDLRGBColor *)secondaryColor { @@ -51,7 +51,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLRGBColor *)secondaryColor { - return [store sdl_objectForName:SDLRPCParameterNameSecondaryColor ofClass:[SDLRGBColor class]]; + return [store sdl_objectForName:SDLRPCParameterNameSecondaryColor ofClass:SDLRGBColor.class error:nil]; } - (void)setBackgroundColor:(nullable SDLRGBColor *)backgroundColor { @@ -59,7 +59,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLRGBColor *)backgroundColor { - return [store sdl_objectForName:SDLRPCParameterNameBackgroundColor ofClass:[SDLRGBColor class]]; + return [store sdl_objectForName:SDLRPCParameterNameBackgroundColor ofClass:SDLRGBColor.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLTextField.m b/SmartDeviceLink/SDLTextField.m index af2d04d24..6ac0fb052 100644 --- a/SmartDeviceLink/SDLTextField.m +++ b/SmartDeviceLink/SDLTextField.m @@ -17,7 +17,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLTextFieldName)name { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameName error:&error]; } @@ -26,7 +26,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLCharacterSet)characterSet { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameCharacterSet error:&error]; } @@ -35,7 +35,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)width { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameWidth ofClass:NSNumber.class error:&error]; } @@ -44,7 +44,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)rows { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameRows ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLTireStatus.m b/SmartDeviceLink/SDLTireStatus.m index 5ddabb0f2..9dd0a9036 100644 --- a/SmartDeviceLink/SDLTireStatus.m +++ b/SmartDeviceLink/SDLTireStatus.m @@ -16,7 +16,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLWarningLightStatus)pressureTelltale { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNamePressureTelltale error:&error]; } @@ -25,7 +25,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLSingleTireStatus *)leftFront { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameLeftFront ofClass:SDLSingleTireStatus.class error:&error]; } @@ -34,7 +34,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLSingleTireStatus *)rightFront { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameRightFront ofClass:SDLSingleTireStatus.class error:&error]; } @@ -43,7 +43,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLSingleTireStatus *)leftRear { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameLeftRear ofClass:SDLSingleTireStatus.class error:&error]; } @@ -52,7 +52,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLSingleTireStatus *)rightRear { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameRightRear ofClass:SDLSingleTireStatus.class error:&error]; } @@ -61,7 +61,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLSingleTireStatus *)innerLeftRear { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameInnerLeftRear ofClass:SDLSingleTireStatus.class error:&error]; } @@ -70,7 +70,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLSingleTireStatus *)innerRightRear { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameInnerRightRear ofClass:SDLSingleTireStatus.class error:&error]; } diff --git a/SmartDeviceLink/SDLTouchCoord.m b/SmartDeviceLink/SDLTouchCoord.m index 4e40d38b3..5c5500cdf 100644 --- a/SmartDeviceLink/SDLTouchCoord.m +++ b/SmartDeviceLink/SDLTouchCoord.m @@ -16,7 +16,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLFloat> *)x { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameX ofClass:NSNumber.class error:&error]; } @@ -25,7 +25,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLFloat> *)y { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameY ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLTouchEvent.m b/SmartDeviceLink/SDLTouchEvent.m index 92c2f3b98..89b2648ee 100644 --- a/SmartDeviceLink/SDLTouchEvent.m +++ b/SmartDeviceLink/SDLTouchEvent.m @@ -17,7 +17,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)touchEventId { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameId ofClass:NSNumber.class error:&error]; } @@ -26,7 +26,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<NSNumber<SDLInt> *> *)timeStamp { - NSError *error; + NSError *error = nil; return [store sdl_objectsForName:SDLRPCParameterNameTS ofClass:NSNumber.class error:&error]; } @@ -35,7 +35,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSArray<SDLTouchCoord *> *)coord { - NSError *error; + NSError *error = nil; return [store sdl_objectsForName:SDLRPCParameterNameCoordinate ofClass:SDLTouchCoord.class error:&error]; } diff --git a/SmartDeviceLink/SDLTouchEventCapabilities.m b/SmartDeviceLink/SDLTouchEventCapabilities.m index c3192e8a5..9ff250e27 100644 --- a/SmartDeviceLink/SDLTouchEventCapabilities.m +++ b/SmartDeviceLink/SDLTouchEventCapabilities.m @@ -16,7 +16,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)pressAvailable { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNamePressAvailable ofClass:NSNumber.class error:&error]; } @@ -25,7 +25,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)multiTouchAvailable { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameMultiTouchAvailable ofClass:NSNumber.class error:&error]; } @@ -34,7 +34,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLBool> *)doublePressAvailable { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameDoublePressAvailable ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLTurn.m b/SmartDeviceLink/SDLTurn.m index 925d2380e..c788c77c5 100644 --- a/SmartDeviceLink/SDLTurn.m +++ b/SmartDeviceLink/SDLTurn.m @@ -28,7 +28,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)navigationText { - return [store sdl_objectForName:SDLRPCParameterNameNavigationText ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameNavigationText ofClass:NSString.class error:nil]; } - (void)setTurnIcon:(nullable SDLImage *)turnIcon { @@ -36,7 +36,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLImage *)turnIcon { - return [store sdl_objectForName:SDLRPCParameterNameTurnIcon ofClass:SDLImage.class]; + return [store sdl_objectForName:SDLRPCParameterNameTurnIcon ofClass:SDLImage.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLUnsubscribeButton.m b/SmartDeviceLink/SDLUnsubscribeButton.m index af2738d1f..7d6d0157a 100644 --- a/SmartDeviceLink/SDLUnsubscribeButton.m +++ b/SmartDeviceLink/SDLUnsubscribeButton.m @@ -35,7 +35,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLButtonName)buttonName { - NSError *error; + NSError *error = nil; return [parameters sdl_enumForName:SDLRPCParameterNameButtonName error:&error]; } diff --git a/SmartDeviceLink/SDLUnsubscribeVehicleData.m b/SmartDeviceLink/SDLUnsubscribeVehicleData.m index 2e84228e9..05bcfd536 100644 --- a/SmartDeviceLink/SDLUnsubscribeVehicleData.m +++ b/SmartDeviceLink/SDLUnsubscribeVehicleData.m @@ -65,7 +65,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)gps { - return [parameters sdl_objectForName:SDLRPCParameterNameGPS ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameGPS ofClass:NSNumber.class error:nil]; } - (void)setSpeed:(nullable NSNumber<SDLBool> *)speed { @@ -73,7 +73,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)speed { - return [parameters sdl_objectForName:SDLRPCParameterNameSpeed ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSpeed ofClass:NSNumber.class error:nil]; } - (void)setRpm:(nullable NSNumber<SDLBool> *)rpm { @@ -81,7 +81,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)rpm { - return [parameters sdl_objectForName:SDLRPCParameterNameRPM ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameRPM ofClass:NSNumber.class error:nil]; } - (void)setFuelLevel:(nullable NSNumber<SDLBool> *)fuelLevel { @@ -89,7 +89,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)fuelLevel { - return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevel ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevel ofClass:NSNumber.class error:nil]; } - (void)setFuelLevel_State:(nullable NSNumber<SDLBool> *)fuelLevel_State { @@ -97,7 +97,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)fuelLevel_State { - return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevelState ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevelState ofClass:NSNumber.class error:nil]; } - (void)setFuelRange:(nullable NSNumber<SDLBool> *)fuelRange { @@ -105,7 +105,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)fuelRange { - return [parameters sdl_objectForName:SDLRPCParameterNameFuelRange ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameFuelRange ofClass:NSNumber.class error:nil]; } - (void)setInstantFuelConsumption:(nullable NSNumber<SDLBool> *)instantFuelConsumption { @@ -113,7 +113,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)instantFuelConsumption { - return [parameters sdl_objectForName:SDLRPCParameterNameInstantFuelConsumption ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameInstantFuelConsumption ofClass:NSNumber.class error:nil]; } - (void)setExternalTemperature:(nullable NSNumber<SDLBool> *)externalTemperature { @@ -121,7 +121,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)externalTemperature { - return [parameters sdl_objectForName:SDLRPCParameterNameExternalTemperature ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameExternalTemperature ofClass:NSNumber.class error:nil]; } - (void)setPrndl:(nullable NSNumber<SDLBool> *)prndl { @@ -129,7 +129,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)prndl { - return [parameters sdl_objectForName:SDLRPCParameterNamePRNDL ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNamePRNDL ofClass:NSNumber.class error:nil]; } - (void)setTirePressure:(nullable NSNumber<SDLBool> *)tirePressure { @@ -137,7 +137,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)tirePressure { - return [parameters sdl_objectForName:SDLRPCParameterNameTirePressure ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameTirePressure ofClass:NSNumber.class error:nil]; } - (void)setOdometer:(nullable NSNumber<SDLBool> *)odometer { @@ -145,7 +145,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)odometer { - return [parameters sdl_objectForName:SDLRPCParameterNameOdometer ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameOdometer ofClass:NSNumber.class error:nil]; } - (void)setBeltStatus:(nullable NSNumber<SDLBool> *)beltStatus { @@ -153,7 +153,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)beltStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameBeltStatus ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameBeltStatus ofClass:NSNumber.class error:nil]; } - (void)setBodyInformation:(nullable NSNumber<SDLBool> *)bodyInformation { @@ -161,7 +161,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)bodyInformation { - return [parameters sdl_objectForName:SDLRPCParameterNameBodyInformation ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameBodyInformation ofClass:NSNumber.class error:nil]; } - (void)setDeviceStatus:(nullable NSNumber<SDLBool> *)deviceStatus { @@ -169,7 +169,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)deviceStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameDeviceStatus ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameDeviceStatus ofClass:NSNumber.class error:nil]; } - (void)setDriverBraking:(nullable NSNumber<SDLBool> *)driverBraking { @@ -177,7 +177,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)driverBraking { - return [parameters sdl_objectForName:SDLRPCParameterNameDriverBraking ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameDriverBraking ofClass:NSNumber.class error:nil]; } - (void)setWiperStatus:(nullable NSNumber<SDLBool> *)wiperStatus { @@ -185,7 +185,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)wiperStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameWiperStatus ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameWiperStatus ofClass:NSNumber.class error:nil]; } - (void)setHeadLampStatus:(nullable NSNumber<SDLBool> *)headLampStatus { @@ -193,7 +193,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)headLampStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameHeadLampStatus ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameHeadLampStatus ofClass:NSNumber.class error:nil]; } - (void)setEngineOilLife:(nullable NSNumber<SDLBool> *)engineOilLife { @@ -201,7 +201,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)engineOilLife { - return [parameters sdl_objectForName:SDLRPCParameterNameEngineOilLife ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameEngineOilLife ofClass:NSNumber.class error:nil]; } - (void)setEngineTorque:(nullable NSNumber<SDLBool> *)engineTorque { @@ -209,7 +209,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)engineTorque { - return [parameters sdl_objectForName:SDLRPCParameterNameEngineTorque ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameEngineTorque ofClass:NSNumber.class error:nil]; } - (void)setAccPedalPosition:(nullable NSNumber<SDLBool> *)accPedalPosition { @@ -217,7 +217,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)accPedalPosition { - return [parameters sdl_objectForName:SDLRPCParameterNameAccelerationPedalPosition ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAccelerationPedalPosition ofClass:NSNumber.class error:nil]; } - (void)setSteeringWheelAngle:(nullable NSNumber<SDLBool> *)steeringWheelAngle { @@ -225,7 +225,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)steeringWheelAngle { - return [parameters sdl_objectForName:SDLRPCParameterNameSteeringWheelAngle ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSteeringWheelAngle ofClass:NSNumber.class error:nil]; } - (void)setECallInfo:(nullable NSNumber<SDLBool> *)eCallInfo { @@ -233,7 +233,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)eCallInfo { - return [parameters sdl_objectForName:SDLRPCParameterNameECallInfo ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameECallInfo ofClass:NSNumber.class error:nil]; } - (void)setAirbagStatus:(nullable NSNumber<SDLBool> *)airbagStatus { @@ -241,7 +241,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)airbagStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameAirbagStatus ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAirbagStatus ofClass:NSNumber.class error:nil]; } - (void)setEmergencyEvent:(nullable NSNumber<SDLBool> *)emergencyEvent { @@ -249,7 +249,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)emergencyEvent { - return [parameters sdl_objectForName:SDLRPCParameterNameEmergencyEvent ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameEmergencyEvent ofClass:NSNumber.class error:nil]; } - (void)setClusterModeStatus:(nullable NSNumber<SDLBool> *)clusterModeStatus { @@ -257,7 +257,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)clusterModeStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameClusterModeStatus ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameClusterModeStatus ofClass:NSNumber.class error:nil]; } - (void)setMyKey:(nullable NSNumber<SDLBool> *)myKey { @@ -265,7 +265,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)myKey { - return [parameters sdl_objectForName:SDLRPCParameterNameMyKey ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameMyKey ofClass:NSNumber.class error:nil]; } - (void)setElectronicParkBrakeStatus:(nullable NSNumber<SDLBool> *)electronicParkBrakeStatus { @@ -273,7 +273,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)electronicParkBrakeStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameElectronicParkBrakeStatus ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameElectronicParkBrakeStatus ofClass:NSNumber.class error:nil]; } - (void)setTurnSignal:(nullable NSNumber<SDLBool> *)turnSignal { @@ -281,7 +281,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)turnSignal { - return [parameters sdl_objectForName:SDLRPCParameterNameTurnSignal ofClass:NSNumber.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameTurnSignal ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLUnsubscribeVehicleDataResponse.m b/SmartDeviceLink/SDLUnsubscribeVehicleDataResponse.m index 2658fbb6f..ff289c1a1 100644 --- a/SmartDeviceLink/SDLUnsubscribeVehicleDataResponse.m +++ b/SmartDeviceLink/SDLUnsubscribeVehicleDataResponse.m @@ -24,7 +24,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)gps { - return [parameters sdl_objectForName:SDLRPCParameterNameGPS ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameGPS ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setSpeed:(nullable SDLVehicleDataResult *)speed { @@ -32,7 +32,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)speed { - return [parameters sdl_objectForName:SDLRPCParameterNameSpeed ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSpeed ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setRpm:(nullable SDLVehicleDataResult *)rpm { @@ -40,7 +40,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)rpm { - return [parameters sdl_objectForName:SDLRPCParameterNameRPM ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameRPM ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setFuelLevel:(nullable SDLVehicleDataResult *)fuelLevel { @@ -48,7 +48,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)fuelLevel { - return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevel ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevel ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setFuelLevel_State:(nullable SDLVehicleDataResult *)fuelLevel_State { @@ -56,7 +56,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)fuelLevel_State { - return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevelState ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameFuelLevelState ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setFuelRange:(nullable SDLVehicleDataResult *)fuelRange { @@ -64,7 +64,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)fuelRange { - return [parameters sdl_objectForName:SDLRPCParameterNameFuelRange ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameFuelRange ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setInstantFuelConsumption:(nullable SDLVehicleDataResult *)instantFuelConsumption { @@ -72,7 +72,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)instantFuelConsumption { - return [parameters sdl_objectForName:SDLRPCParameterNameInstantFuelConsumption ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameInstantFuelConsumption ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setExternalTemperature:(nullable SDLVehicleDataResult *)externalTemperature { @@ -80,7 +80,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)externalTemperature { - return [parameters sdl_objectForName:SDLRPCParameterNameExternalTemperature ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameExternalTemperature ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setPrndl:(nullable SDLVehicleDataResult *)prndl { @@ -88,7 +88,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)prndl { - return [parameters sdl_objectForName:SDLRPCParameterNamePRNDL ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNamePRNDL ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setTirePressure:(nullable SDLVehicleDataResult *)tirePressure { @@ -96,7 +96,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)tirePressure { - return [parameters sdl_objectForName:SDLRPCParameterNameTirePressure ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameTirePressure ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setOdometer:(nullable SDLVehicleDataResult *)odometer { @@ -104,7 +104,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)odometer { - return [parameters sdl_objectForName:SDLRPCParameterNameOdometer ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameOdometer ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setBeltStatus:(nullable SDLVehicleDataResult *)beltStatus { @@ -112,7 +112,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)beltStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameBeltStatus ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameBeltStatus ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setBodyInformation:(nullable SDLVehicleDataResult *)bodyInformation { @@ -120,7 +120,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)bodyInformation { - return [parameters sdl_objectForName:SDLRPCParameterNameBodyInformation ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameBodyInformation ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setDeviceStatus:(nullable SDLVehicleDataResult *)deviceStatus { @@ -128,7 +128,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)deviceStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameDeviceStatus ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameDeviceStatus ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setDriverBraking:(nullable SDLVehicleDataResult *)driverBraking { @@ -136,7 +136,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)driverBraking { - return [parameters sdl_objectForName:SDLRPCParameterNameDriverBraking ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameDriverBraking ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setWiperStatus:(nullable SDLVehicleDataResult *)wiperStatus { @@ -144,7 +144,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)wiperStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameWiperStatus ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameWiperStatus ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setHeadLampStatus:(nullable SDLVehicleDataResult *)headLampStatus { @@ -152,7 +152,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)headLampStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameHeadLampStatus ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameHeadLampStatus ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setEngineOilLife:(nullable SDLVehicleDataResult *)engineOilLife { @@ -160,7 +160,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)engineOilLife { - return [parameters sdl_objectForName:SDLRPCParameterNameEngineOilLife ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameEngineOilLife ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setEngineTorque:(nullable SDLVehicleDataResult *)engineTorque { @@ -168,7 +168,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)engineTorque { - return [parameters sdl_objectForName:SDLRPCParameterNameEngineTorque ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameEngineTorque ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setAccPedalPosition:(nullable SDLVehicleDataResult *)accPedalPosition { @@ -176,7 +176,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)accPedalPosition { - return [parameters sdl_objectForName:SDLRPCParameterNameAccelerationPedalPosition ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAccelerationPedalPosition ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setSteeringWheelAngle:(nullable SDLVehicleDataResult *)steeringWheelAngle { @@ -184,7 +184,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)steeringWheelAngle { - return [parameters sdl_objectForName:SDLRPCParameterNameSteeringWheelAngle ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameSteeringWheelAngle ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setECallInfo:(nullable SDLVehicleDataResult *)eCallInfo { @@ -192,7 +192,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)eCallInfo { - return [parameters sdl_objectForName:SDLRPCParameterNameECallInfo ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameECallInfo ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setAirbagStatus:(nullable SDLVehicleDataResult *)airbagStatus { @@ -200,7 +200,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)airbagStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameAirbagStatus ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameAirbagStatus ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setEmergencyEvent:(nullable SDLVehicleDataResult *)emergencyEvent { @@ -208,7 +208,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)emergencyEvent { - return [parameters sdl_objectForName:SDLRPCParameterNameEmergencyEvent ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameEmergencyEvent ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setClusterModes:(nullable SDLVehicleDataResult *)clusterModes { @@ -216,7 +216,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)clusterModes { - return [parameters sdl_objectForName:SDLRPCParameterNameClusterModes ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameClusterModes ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setMyKey:(nullable SDLVehicleDataResult *)myKey { @@ -224,7 +224,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)myKey { - return [parameters sdl_objectForName:SDLRPCParameterNameMyKey ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameMyKey ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setElectronicParkBrakeStatus:(nullable SDLVehicleDataResult *)electronicParkBrakeStatus { @@ -232,7 +232,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)electronicParkBrakeStatus { - return [parameters sdl_objectForName:SDLRPCParameterNameElectronicParkBrakeStatus ofClass:[SDLVehicleDataResult class]]; + return [parameters sdl_objectForName:SDLRPCParameterNameElectronicParkBrakeStatus ofClass:SDLVehicleDataResult.class error:nil]; } - (void)setTurnSignal:(nullable SDLVehicleDataResult *)turnSignal { @@ -240,7 +240,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLVehicleDataResult *)turnSignal { - return [parameters sdl_objectForName:SDLRPCParameterNameTurnSignal ofClass:SDLVehicleDataResult.class]; + return [parameters sdl_objectForName:SDLRPCParameterNameTurnSignal ofClass:SDLVehicleDataResult.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLUpdateTurnList.m b/SmartDeviceLink/SDLUpdateTurnList.m index c4cad5a40..3b6e77603 100644 --- a/SmartDeviceLink/SDLUpdateTurnList.m +++ b/SmartDeviceLink/SDLUpdateTurnList.m @@ -37,7 +37,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLTurn *> *)turnList { - return [parameters sdl_objectsForName:SDLRPCParameterNameTurnList ofClass:SDLTurn.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameTurnList ofClass:SDLTurn.class error:nil]; } - (void)setSoftButtons:(nullable NSArray<SDLSoftButton *> *)softButtons { @@ -45,7 +45,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLSoftButton *> *)softButtons { - return [parameters sdl_objectsForName:SDLRPCParameterNameSoftButtons ofClass:SDLSoftButton.class]; + return [parameters sdl_objectsForName:SDLRPCParameterNameSoftButtons ofClass:SDLSoftButton.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLVehicleDataResult.m b/SmartDeviceLink/SDLVehicleDataResult.m index 2414719cc..e4621a926 100644 --- a/SmartDeviceLink/SDLVehicleDataResult.m +++ b/SmartDeviceLink/SDLVehicleDataResult.m @@ -15,7 +15,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataType)dataType { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameDataType error:&error]; } @@ -24,7 +24,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVehicleDataResultCode)resultCode { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameResultCode error:&error]; } diff --git a/SmartDeviceLink/SDLVehicleType.m b/SmartDeviceLink/SDLVehicleType.m index e9ae41301..50d3023a5 100644 --- a/SmartDeviceLink/SDLVehicleType.m +++ b/SmartDeviceLink/SDLVehicleType.m @@ -16,7 +16,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)make { - return [store sdl_objectForName:SDLRPCParameterNameMake ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameMake ofClass:NSString.class error:nil]; } - (void)setModel:(nullable NSString *)model { @@ -24,7 +24,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)model { - return [store sdl_objectForName:SDLRPCParameterNameModel ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameModel ofClass:NSString.class error:nil]; } - (void)setModelYear:(nullable NSString *)modelYear { @@ -32,7 +32,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)modelYear { - return [store sdl_objectForName:SDLRPCParameterNameModelYear ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameModelYear ofClass:NSString.class error:nil]; } - (void)setTrim:(nullable NSString *)trim { @@ -40,7 +40,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)trim { - return [store sdl_objectForName:SDLRPCParameterNameTrim ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameTrim ofClass:NSString.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLVideoStreamingCapability.m b/SmartDeviceLink/SDLVideoStreamingCapability.m index b38ac9b25..f9cee09c5 100644 --- a/SmartDeviceLink/SDLVideoStreamingCapability.m +++ b/SmartDeviceLink/SDLVideoStreamingCapability.m @@ -36,7 +36,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLImageResolution *)preferredResolution { - return [store sdl_objectForName:SDLRPCParameterNamePreferredResolution ofClass:SDLImageResolution.class]; + return [store sdl_objectForName:SDLRPCParameterNamePreferredResolution ofClass:SDLImageResolution.class error:nil]; } - (void)setMaxBitrate:(nullable NSNumber<SDLInt> *)maxBitrate { @@ -44,7 +44,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)maxBitrate { - return [store sdl_objectForName:SDLRPCParameterNameMaxBitrate ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameMaxBitrate ofClass:NSNumber.class error:nil]; } - (void)setSupportedFormats:(nullable NSArray<SDLVideoStreamingFormat *> *)supportedFormats { @@ -52,7 +52,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLVideoStreamingFormat *> *)supportedFormats { - return [store sdl_objectsForName:SDLRPCParameterNameSupportedFormats ofClass:SDLVideoStreamingFormat.class]; + return [store sdl_objectsForName:SDLRPCParameterNameSupportedFormats ofClass:SDLVideoStreamingFormat.class error:nil]; } - (void)setHapticSpatialDataSupported:(nullable NSNumber<SDLBool> *)hapticSpatialDataSupported { @@ -60,7 +60,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)hapticSpatialDataSupported { - return [store sdl_objectForName:SDLRPCParameterNameHapticSpatialDataSupported ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHapticSpatialDataSupported ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLVideoStreamingFormat.m b/SmartDeviceLink/SDLVideoStreamingFormat.m index f4ee4613a..eb031a9c4 100644 --- a/SmartDeviceLink/SDLVideoStreamingFormat.m +++ b/SmartDeviceLink/SDLVideoStreamingFormat.m @@ -25,7 +25,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVideoStreamingProtocol)protocol { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameVideoProtocol error:&error]; } @@ -34,7 +34,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLVideoStreamingCodec)codec { - NSError *error; + NSError *error = nil; return [store sdl_enumForName:SDLRPCParameterNameVideoCodec error:&error]; } diff --git a/SmartDeviceLink/SDLVrHelpItem.m b/SmartDeviceLink/SDLVrHelpItem.m index fae9ea8fd..5584818d9 100644 --- a/SmartDeviceLink/SDLVrHelpItem.m +++ b/SmartDeviceLink/SDLVrHelpItem.m @@ -40,7 +40,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSString *)text { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNameText ofClass:NSString.class error:&error]; } @@ -49,7 +49,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLImage *)image { - return [store sdl_objectForName:SDLRPCParameterNameImage ofClass:SDLImage.class]; + return [store sdl_objectForName:SDLRPCParameterNameImage ofClass:SDLImage.class error:nil]; } - (void)setPosition:(NSNumber<SDLInt> *)position { @@ -57,7 +57,7 @@ NS_ASSUME_NONNULL_BEGIN } - (NSNumber<SDLInt> *)position { - NSError *error; + NSError *error = nil; return [store sdl_objectForName:SDLRPCParameterNamePosition ofClass:NSNumber.class error:&error]; } diff --git a/SmartDeviceLink/SDLWeatherAlert.m b/SmartDeviceLink/SDLWeatherAlert.m index 8d08284f8..d1dccaa53 100644 --- a/SmartDeviceLink/SDLWeatherAlert.m +++ b/SmartDeviceLink/SDLWeatherAlert.m @@ -36,7 +36,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)title { - return [store sdl_objectForName:SDLRPCParameterNameTitle ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameTitle ofClass:NSString.class error:nil]; } - (void)setSummary:(nullable NSString *)summary { @@ -44,7 +44,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)summary { - return [store sdl_objectForName:SDLRPCParameterNameSummary ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameSummary ofClass:NSString.class error:nil]; } - (void)setExpires:(nullable SDLDateTime *)expires { @@ -52,7 +52,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLDateTime *)expires { - return [store sdl_objectForName:SDLRPCParameterNameExpires ofClass:SDLDateTime.class]; + return [store sdl_objectForName:SDLRPCParameterNameExpires ofClass:SDLDateTime.class error:nil]; } - (void)setRegions:(nullable NSArray<NSString *> *)regions { @@ -60,7 +60,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<NSString *> *)regions { - return [store sdl_objectsForName:SDLRPCParameterNameRegions ofClass:NSString.class]; + return [store sdl_objectsForName:SDLRPCParameterNameRegions ofClass:NSString.class error:nil]; } - (void)setSeverity:(nullable NSString *)severity { @@ -68,7 +68,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)severity { - return [store sdl_objectForName:SDLRPCParameterNameSeverity ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameSeverity ofClass:NSString.class error:nil]; } - (void)setTimeIssued:(nullable SDLDateTime *)timeIssued { @@ -76,7 +76,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLDateTime *)timeIssued { - return [store sdl_objectForName:SDLRPCParameterNameTimeIssued ofClass:SDLDateTime.class]; + return [store sdl_objectForName:SDLRPCParameterNameTimeIssued ofClass:SDLDateTime.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLWeatherData.m b/SmartDeviceLink/SDLWeatherData.m index 19a51aa78..e10663fab 100644 --- a/SmartDeviceLink/SDLWeatherData.m +++ b/SmartDeviceLink/SDLWeatherData.m @@ -55,7 +55,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLTemperature *)currentTemperature { - return [store sdl_objectForName:SDLRPCParameterNameCurrentTemperature ofClass:SDLTemperature.class]; + return [store sdl_objectForName:SDLRPCParameterNameCurrentTemperature ofClass:SDLTemperature.class error:nil]; } - (void)setTemperatureHigh:(nullable SDLTemperature *)temperatureHigh { @@ -63,7 +63,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLTemperature *)temperatureHigh { - return [store sdl_objectForName:SDLRPCParameterNameTemperatureHigh ofClass:SDLTemperature.class]; + return [store sdl_objectForName:SDLRPCParameterNameTemperatureHigh ofClass:SDLTemperature.class error:nil]; } - (void)setTemperatureLow:(nullable SDLTemperature *)temperatureLow { @@ -71,7 +71,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLTemperature *)temperatureLow { - return [store sdl_objectForName:SDLRPCParameterNameTemperatureLow ofClass:SDLTemperature.class]; + return [store sdl_objectForName:SDLRPCParameterNameTemperatureLow ofClass:SDLTemperature.class error:nil]; } - (void)setApparentTemperature:(nullable SDLTemperature *)apparentTemperature { @@ -79,7 +79,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLTemperature *)apparentTemperature { - return [store sdl_objectForName:SDLRPCParameterNameApparentTemperature ofClass:SDLTemperature.class]; + return [store sdl_objectForName:SDLRPCParameterNameApparentTemperature ofClass:SDLTemperature.class error:nil]; } - (void)setApparentTemperatureHigh:(nullable SDLTemperature *)apparentTemperatureHigh { @@ -87,7 +87,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLTemperature *)apparentTemperatureHigh { - return [store sdl_objectForName:SDLRPCParameterNameApparentTemperatureHigh ofClass:SDLTemperature.class]; + return [store sdl_objectForName:SDLRPCParameterNameApparentTemperatureHigh ofClass:SDLTemperature.class error:nil]; } - (void)setApparentTemperatureLow:(nullable SDLTemperature *)apparentTemperatureLow { @@ -95,7 +95,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLTemperature *)apparentTemperatureLow { - return [store sdl_objectForName:SDLRPCParameterNameApparentTemperatureLow ofClass:SDLTemperature.class]; + return [store sdl_objectForName:SDLRPCParameterNameApparentTemperatureLow ofClass:SDLTemperature.class error:nil]; } - (void)setWeatherSummary:(nullable NSString *)weatherSummary { @@ -103,7 +103,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)weatherSummary { - return [store sdl_objectForName:SDLRPCParameterNameWeatherSummary ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNameWeatherSummary ofClass:NSString.class error:nil]; } - (void)setTime:(nullable SDLDateTime *)time { @@ -111,7 +111,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLDateTime *)time { - return [store sdl_objectForName:SDLRPCParameterNameTime ofClass:SDLDateTime.class]; + return [store sdl_objectForName:SDLRPCParameterNameTime ofClass:SDLDateTime.class error:nil]; } - (void)setHumidity:(nullable NSNumber<SDLFloat> *)humidity { @@ -119,7 +119,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)humidity { - return [store sdl_objectForName:SDLRPCParameterNameHumidity ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameHumidity ofClass:NSNumber.class error:nil]; } - (void)setCloudCover:(nullable NSNumber<SDLFloat> *)cloudCover { @@ -127,7 +127,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)cloudCover { - return [store sdl_objectForName:SDLRPCParameterNameCloudCover ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameCloudCover ofClass:NSNumber.class error:nil]; } - (void)setMoonPhase:(nullable NSNumber<SDLFloat> *)moonPhase { @@ -135,7 +135,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)moonPhase { - return [store sdl_objectForName:SDLRPCParameterNameMoonPhase ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameMoonPhase ofClass:NSNumber.class error:nil]; } - (void)setWindBearing:(nullable NSNumber<SDLInt> *)windBearing { @@ -143,7 +143,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)windBearing { - return [store sdl_objectForName:SDLRPCParameterNameWindBearing ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameWindBearing ofClass:NSNumber.class error:nil]; } - (void)setWindGust:(nullable NSNumber<SDLFloat> *)windGust { @@ -151,7 +151,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)windGust { - return [store sdl_objectForName:SDLRPCParameterNameWindGust ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameWindGust ofClass:NSNumber.class error:nil]; } - (void)setWindSpeed:(nullable NSNumber<SDLFloat> *)windSpeed { @@ -159,7 +159,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)windSpeed { - return [store sdl_objectForName:SDLRPCParameterNameWindSpeed ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameWindSpeed ofClass:NSNumber.class error:nil]; } - (void)setNearestStormBearing:(nullable NSNumber<SDLInt> *)nearestStormBearing { @@ -167,7 +167,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)nearestStormBearing { - return [store sdl_objectForName:SDLRPCParameterNameNearestStormBearing ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameNearestStormBearing ofClass:NSNumber.class error:nil]; } - (void)setNearestStormDistance:(nullable NSNumber<SDLInt> *)nearestStormDistance { @@ -175,7 +175,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)nearestStormDistance { - return [store sdl_objectForName:SDLRPCParameterNameNearestStormDistance ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameNearestStormDistance ofClass:NSNumber.class error:nil]; } - (void)setPrecipAccumulation:(nullable NSNumber<SDLFloat> *)precipAccumulation { @@ -183,7 +183,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)precipAccumulation { - return [store sdl_objectForName:SDLRPCParameterNamePrecipAccumulation ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNamePrecipAccumulation ofClass:NSNumber.class error:nil]; } - (void)setPrecipIntensity:(nullable NSNumber<SDLFloat> *)precipIntensity { @@ -191,7 +191,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)precipIntensity { - return [store sdl_objectForName:SDLRPCParameterNamePrecipIntensity ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNamePrecipIntensity ofClass:NSNumber.class error:nil]; } - (void)setPrecipProbability:(nullable NSNumber<SDLFloat> *)precipProbability { @@ -199,7 +199,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)precipProbability { - return [store sdl_objectForName:SDLRPCParameterNamePrecipProbability ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNamePrecipProbability ofClass:NSNumber.class error:nil]; } - (void)setPrecipType:(nullable NSString *)precipType { @@ -207,7 +207,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSString *)precipType { - return [store sdl_objectForName:SDLRPCParameterNamePrecipType ofClass:NSString.class]; + return [store sdl_objectForName:SDLRPCParameterNamePrecipType ofClass:NSString.class error:nil]; } - (void)setVisibility:(nullable NSNumber<SDLFloat> *)visibility { @@ -215,7 +215,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLFloat> *)visibility { - return [store sdl_objectForName:SDLRPCParameterNameVisibility ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameVisibility ofClass:NSNumber.class error:nil]; } - (void)setWeatherIcon:(nullable SDLImage *)weatherIcon { @@ -223,7 +223,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLImage *)weatherIcon { - return [store sdl_objectForName:SDLRPCParameterNameWeatherIcon ofClass:SDLImage.class]; + return [store sdl_objectForName:SDLRPCParameterNameWeatherIcon ofClass:SDLImage.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLWeatherServiceData.m b/SmartDeviceLink/SDLWeatherServiceData.m index 43091590f..5763221be 100644 --- a/SmartDeviceLink/SDLWeatherServiceData.m +++ b/SmartDeviceLink/SDLWeatherServiceData.m @@ -46,7 +46,7 @@ NS_ASSUME_NONNULL_BEGIN } - (SDLLocationDetails *)location { - return [store sdl_objectForName:SDLRPCParameterNameLocation ofClass:SDLLocationDetails.class]; + return [store sdl_objectForName:SDLRPCParameterNameLocation ofClass:SDLLocationDetails.class error:nil]; } - (void)setCurrentForecast:(nullable SDLWeatherData *)currentForecast { @@ -54,7 +54,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable SDLWeatherData *)currentForecast { - return [store sdl_objectForName:SDLRPCParameterNameCurrentForecast ofClass:SDLWeatherData.class]; + return [store sdl_objectForName:SDLRPCParameterNameCurrentForecast ofClass:SDLWeatherData.class error:nil]; } - (void)setMinuteForecast:(nullable NSArray<SDLWeatherData *> *)minuteForecast { @@ -62,7 +62,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLWeatherData *> *)minuteForecast { - return [store sdl_objectsForName:SDLRPCParameterNameMinuteForecast ofClass:SDLWeatherData.class]; + return [store sdl_objectsForName:SDLRPCParameterNameMinuteForecast ofClass:SDLWeatherData.class error:nil]; } - (void)setHourlyForecast:(nullable NSArray<SDLWeatherData *> *)hourlyForecast { @@ -70,7 +70,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLWeatherData *> *)hourlyForecast { - return [store sdl_objectsForName:SDLRPCParameterNameHourlyForecast ofClass:SDLWeatherData.class]; + return [store sdl_objectsForName:SDLRPCParameterNameHourlyForecast ofClass:SDLWeatherData.class error:nil]; } - (void)setMultidayForecast:(nullable NSArray<SDLWeatherData *> *)multidayForecast { @@ -78,7 +78,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLWeatherData *> *)multidayForecast { - return [store sdl_objectsForName:SDLRPCParameterNameMultidayForecast ofClass:SDLWeatherData.class]; + return [store sdl_objectsForName:SDLRPCParameterNameMultidayForecast ofClass:SDLWeatherData.class error:nil]; } - (void)setAlerts:(nullable NSArray<SDLWeatherAlert *> *)alerts { @@ -86,7 +86,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSArray<SDLWeatherAlert *> *)alerts { - return [store sdl_objectsForName:SDLRPCParameterNameAlerts ofClass:SDLWeatherAlert.class]; + return [store sdl_objectsForName:SDLRPCParameterNameAlerts ofClass:SDLWeatherAlert.class error:nil]; } @end diff --git a/SmartDeviceLink/SDLWeatherServiceManifest.m b/SmartDeviceLink/SDLWeatherServiceManifest.m index 86df7e43e..25da6461b 100644 --- a/SmartDeviceLink/SDLWeatherServiceManifest.m +++ b/SmartDeviceLink/SDLWeatherServiceManifest.m @@ -35,7 +35,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)currentForecastSupported { - return [store sdl_objectForName:SDLRPCParameterNameCurrentForecastSupported ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameCurrentForecastSupported ofClass:NSNumber.class error:nil]; } - (void)setMaxMultidayForecastAmount:(nullable NSNumber<SDLInt> *)maxMultidayForecastAmount { @@ -43,7 +43,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)maxMultidayForecastAmount { - return [store sdl_objectForName:SDLRPCParameterNameMaxMultidayForecastAmount ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameMaxMultidayForecastAmount ofClass:NSNumber.class error:nil]; } - (void)setMaxHourlyForecastAmount:(nullable NSNumber<SDLInt> *)maxHourlyForecastAmount { @@ -51,7 +51,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)maxHourlyForecastAmount { - return [store sdl_objectForName:SDLRPCParameterNameMaxHourlyForecastAmount ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameMaxHourlyForecastAmount ofClass:NSNumber.class error:nil]; } - (void)setMaxMinutelyForecastAmount:(nullable NSNumber<SDLInt> *)maxMinutelyForecastAmount { @@ -59,7 +59,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLInt> *)maxMinutelyForecastAmount { - return [store sdl_objectForName:SDLRPCParameterNameMaxMinutelyForecastAmount ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameMaxMinutelyForecastAmount ofClass:NSNumber.class error:nil]; } - (void)setWeatherForLocationSupported:(nullable NSNumber<SDLBool> *)weatherForLocationSupported { @@ -67,7 +67,7 @@ NS_ASSUME_NONNULL_BEGIN } - (nullable NSNumber<SDLBool> *)weatherForLocationSupported { - return [store sdl_objectForName:SDLRPCParameterNameWeatherForLocationSupported ofClass:NSNumber.class]; + return [store sdl_objectForName:SDLRPCParameterNameWeatherForLocationSupported ofClass:NSNumber.class error:nil]; } @end diff --git a/SmartDeviceLinkTests/DevAPISpecs/NSMutableDictionary+StoreSpec.m b/SmartDeviceLinkTests/DevAPISpecs/NSMutableDictionary+StoreSpec.m index 72ded2e98..459e14ac6 100644 --- a/SmartDeviceLinkTests/DevAPISpecs/NSMutableDictionary+StoreSpec.m +++ b/SmartDeviceLinkTests/DevAPISpecs/NSMutableDictionary+StoreSpec.m @@ -35,56 +35,56 @@ describe(@"A mutable dictionary with the storing category imported", ^{ testDictionary = [[NSMutableDictionary alloc] init]; }); - describe(@"adding a string", ^{ + describe(@"retrieving a string", ^{ __block NSString *testObject = @"Object"; beforeEach(^{ [testDictionary sdl_setObject:testObject forName:testKey]; }); - it(@"should return string", ^{ + it(@"should return string when called correctly", ^{ expect([testDictionary sdl_objectForName:testKey ofClass:[NSString class]]).to(equal(testObject)); }); - it(@"should raise exceprion", ^{ + it(@"should raise an exception when called with wrong class type", ^{ expectAction(^{ expect([testDictionary sdl_objectForName:testKey ofClass:[NSNumber class]]).to(beNil()); }).to(raiseException()); }); }); - describe(@"adding a single object", ^{ + describe(@"retrieving a single object", ^{ __block NSString *testObject = @"Object"; beforeEach(^{ [testDictionary sdl_setObject:testObject forName:testKey]; }); - it(@"should return nil", ^{ + it(@"should return nil and raise an exception when retrieved as an array", ^{ expectAction(^{ - expect([testDictionary sdl_objectsForName:testKey ofClass:[NSString class]]).to(beNil()); + expect([testDictionary sdl_objectsForName:testKey ofClass:[NSString class] error:nil]).to(beNil()); }).to(raiseException()); }); }); - describe(@"adding a custom object using JSON", ^{ - __block NSDictionary *testJson = @{}; - __block TestObject *testObject = [[TestObject alloc] initWithDictionary:testJson]; - + describe(@"Retrieving a custom JSON object", ^{ + __block TestObject *testObject = nil; beforeEach(^{ + NSDictionary *testJson = @{}; + testObject = [[TestObject alloc] initWithDictionary:testJson]; [testDictionary sdl_setObject:testJson forName:testKey]; }); - it(@"should return object", ^{ + it(@"should return the object correctly when retrieved correctly", ^{ expect([testDictionary sdl_objectForName:testKey ofClass:[TestObject class]]).to(equal(testObject)); }); - it(@"should raise exceprion", ^{ + it(@"should raise an exception when retrieved as an NSNumber", ^{ expectAction(^{ expect([testDictionary sdl_objectForName:testKey ofClass:[NSNumber class]]).to(beNil()); }).to(raiseException()); }); }); - describe(@"adding an array of strings", ^{ + describe(@"Retrieving an array of one string", ^{ __block NSString *testObject = @"Object"; __block NSArray<NSString *> *testObjectArray = @[testObject]; @@ -92,69 +92,74 @@ describe(@"A mutable dictionary with the storing category imported", ^{ [testDictionary sdl_setObject:testObjectArray forName:testKey]; }); - expectAction(^{ - expect([testDictionary sdl_objectForName:testKey ofClass:[NSString class]]).to(equal(testObject)); - }).to(raiseException()); - it(@"should return array", ^{ - expect([testDictionary sdl_objectsForName:testKey ofClass:[NSString class]]).to(equal(testObjectArray)); + it(@"should raise an exception when retrieved as an NSString", ^{ + expectAction(^{ + expect([testDictionary sdl_objectForName:testKey ofClass:[NSString class]]).to(equal(testObject)); + }).to(raiseException()); }); - it(@"should raise exceprion", ^{ + + it(@"should return correctly when retrieved correctly", ^{ + expect([testDictionary sdl_objectsForName:testKey ofClass:[NSString class] error:nil]).to(equal(testObjectArray)); + }); + it(@"should raise an exception when retrieved as an NSNumber", ^{ expectAction(^{ - expect([testDictionary sdl_objectForName:testKey ofClass:[NSNumber class]]).to(beNil()); - expect([testDictionary sdl_objectsForName:testKey ofClass:[NSNumber class]]).to(beNil()); + expect([testDictionary sdl_objectForName:testKey ofClass:[NSNumber class] error:nil]).to(beNil()); + expect([testDictionary sdl_objectsForName:testKey ofClass:[NSNumber class] error:nil]).to(beNil()); }).to(raiseException()); }); }); - describe(@"adding an array of custom objects", ^{ - __block NSDictionary *testJson = @{}; - __block TestObject *testObject = [[TestObject alloc] initWithDictionary:testJson]; - __block NSArray<NSDictionary *> *testJsonArray = @[testJson]; - __block NSArray<TestObject *> *testObjectArray = @[testObject]; + describe(@"retrieving an array of custom objects", ^{ + __block NSArray<TestObject *> *testObjectArray = nil; beforeEach(^{ + NSDictionary *testJson = @{}; + TestObject *testObject = [[TestObject alloc] initWithDictionary:testJson]; + NSArray<NSDictionary *> *testJsonArray = @[testJson]; + testObjectArray = @[testObject]; [testDictionary sdl_setObject:testJsonArray forName:testKey]; }); - it(@"should return array", ^{ - expect([testDictionary sdl_objectsForName:testKey ofClass:[TestObject class]]).to(equal(testObjectArray)); + it(@"should return correctly when retrieved correctly", ^{ + expect([testDictionary sdl_objectsForName:testKey ofClass:[TestObject class] error:nil]).to(equal(testObjectArray)); }); - it(@"should raise exceprion", ^{ + it(@"should raise an exception when retrieved as an NSNumber", ^{ expectAction(^{ - expect([testDictionary sdl_objectsForName:testKey ofClass:[NSNumber class]]).to(beNil()); + expect([testDictionary sdl_objectsForName:testKey ofClass:[NSNumber class] error:nil]).to(beNil()); }).to(raiseException()); }); }); - describe(@"adding a SDLEnum", ^{ + describe(@"Retrieving an SDLEnum", ^{ __block SDLEnum testObject = @"Object"; beforeEach(^{ [testDictionary sdl_setObject:testObject forName:testKey]; }); - it(@"should return SDLEnum", ^{ + it(@"should return correctly when retrieved correctly", ^{ expect([testDictionary sdl_enumForName:testKey error:nil]).to(equal(testObject)); }); - it(@"should raise exception", ^{ + it(@"should raise an exception when retrieved as an array", ^{ expectAction(^{ expect([testDictionary sdl_enumsForName:testKey error:nil]).to(beNil()); }).to(raiseException()); }); }); - describe(@"adding an array of SDLEnum", ^{ - __block SDLEnum testObject = @"Object"; - __block NSArray<SDLEnum> *testObjectArray = @[testObject]; + describe(@"retrieving an array of SDLEnums", ^{ + __block NSArray<SDLEnum> *testObjectArray = nil; beforeEach(^{ + __block SDLEnum testObject = @"Object"; + testObjectArray = @[testObject]; [testDictionary sdl_setObject:testObjectArray forName:testKey]; }); - it(@"should return array of SDLEnum", ^{ + it(@"should return an array of SDLEnum when retrieved correctly", ^{ expect([testDictionary sdl_enumsForName:testKey error:nil]).to(equal(testObjectArray)); }); - it(@"should raise exceprion", ^{ + it(@"should raise an exception when retrieved as an NSNumber", ^{ expectAction(^{ expect([testDictionary sdl_objectForName:testKey ofClass:[NSNumber class]]).to(beNil()); }).to(raiseException()); diff --git a/SmartDeviceLinkTests/RPCSpecs/ResponseSpecs/SDLGetVehicleDataResponseSpec.m b/SmartDeviceLinkTests/RPCSpecs/ResponseSpecs/SDLGetVehicleDataResponseSpec.m index 8884dee52..6eb1bbc3d 100644 --- a/SmartDeviceLinkTests/RPCSpecs/ResponseSpecs/SDLGetVehicleDataResponseSpec.m +++ b/SmartDeviceLinkTests/RPCSpecs/ResponseSpecs/SDLGetVehicleDataResponseSpec.m @@ -82,8 +82,6 @@ describe(@"Getter/Setter Tests", ^ { expect(testResponse.headLampStatus).to(equal(headLamp)); expect(testResponse.instantFuelConsumption).to(equal(@40.7)); expect(testResponse.myKey).to(equal(myKey)); - id odometer = testResponse.odometer; - expect(testResponse.odometer).to(equal(@70000)); expect(testResponse.prndl).to(equal(SDLPRNDLPark)); expect(testResponse.rpm).to(equal(@3)); |