summaryrefslogtreecommitdiff
path: root/SmartDeviceLink/SDLRPCResponse.m
diff options
context:
space:
mode:
Diffstat (limited to 'SmartDeviceLink/SDLRPCResponse.m')
-rw-r--r--SmartDeviceLink/SDLRPCResponse.m11
1 files changed, 7 insertions, 4 deletions
diff --git a/SmartDeviceLink/SDLRPCResponse.m b/SmartDeviceLink/SDLRPCResponse.m
index 6df0315d7..0bab8bdeb 100644
--- a/SmartDeviceLink/SDLRPCResponse.m
+++ b/SmartDeviceLink/SDLRPCResponse.m
@@ -37,7 +37,8 @@ NS_ASSUME_NONNULL_BEGIN
}
- (NSNumber<SDLInt> *)correlationID {
- return [function sdl_objectForName:SDLRPCParameterNameCorrelationId];
+ NSError *error;
+ return [function sdl_objectForName:SDLRPCParameterNameCorrelationId ofClass:NSNumber.class error:&error];
}
- (void)setCorrelationID:(NSNumber<SDLInt> *)corrID {
@@ -49,7 +50,8 @@ NS_ASSUME_NONNULL_BEGIN
}
- (NSNumber<SDLBool> *)success {
- return [parameters sdl_objectForName:SDLRPCParameterNameSuccess];
+ NSError *error;
+ return [parameters sdl_objectForName:SDLRPCParameterNameSuccess ofClass:NSNumber.class error:&error];
}
- (void)setResultCode:(SDLResult)resultCode {
@@ -57,7 +59,8 @@ NS_ASSUME_NONNULL_BEGIN
}
- (SDLResult)resultCode {
- return [parameters sdl_objectForName:SDLRPCParameterNameResultCode];
+ NSError *error;
+ return [parameters sdl_enumForName:SDLRPCParameterNameResultCode error:&error];
}
- (void)setInfo:(nullable NSString *)info {
@@ -65,7 +68,7 @@ NS_ASSUME_NONNULL_BEGIN
}
- (nullable NSString *)info {
- return [parameters sdl_objectForName:SDLRPCParameterNameInfo];
+ return [parameters sdl_objectForName:SDLRPCParameterNameInfo ofClass:NSString.class];
}
@end