SFSDKResourceUtils Class Reference

Inherits from NSObject
Declared in SFSDKResourceUtils.h

Overview

Class that handles access to Mobile SDK’s main bundle.

+ mainSdkBundle

Mobile SDK’s main bundle.

+ (NSBundle *)mainSdkBundle

Return Value

Mobile SDK’s main bundle.

Declared In

SFSDKResourceUtils.h

+ localizedString:

Gets a localized string from the main Mobile SDK bundle.

+ (NSString *)localizedString:(NSString *)localizationKey

Parameters

localizationKey

Localization key used to look up the localized string.

Return Value

Localized string associated with the key.

Declared In

SFSDKResourceUtils.h

+ imageNamed:

Retrieves an image from the “Images” asset catalog of the Mobile SDK framework bundle.

+ (UIImage *)imageNamed:(NSString *)name

Parameters

name

Name of the image in the asset catalog.

Return Value

UIImage object containing the named image from the asset catalog.

Declared In

SFSDKResourceUtils.h

+ loadConfigFromFile:error:

Read a configuration resource file and parse its contents. The file must be in JSON format.

+ (nullable NSDictionary *)loadConfigFromFile:(NSString *)configFilePath error:(NSError **)error

Parameters

configFilePath

Path to the configuration resource file.

error

Input-output parameter that sets or returns any error that occurs during file reading.

Return Value

NSDictionary object built from the file’s contents.

Declared In

SFSDKResourceUtils.h