TNResourceMaster
public class TNResourceMaster : NSObject
Class to load resources from framework’s bundle
-
Returns a Dictionary or Array object initialized by reading the content of Plist file from resources with given name.
Declaration
Swift
public class func objectFromPlistWithName(_ name: String, inBundle bundle: Bundle) -> AnyObject?Parameters
nameThe name of the plist file.
inBundleBundle where plist is stored
Return Value
A Dictionary or Array object initialized by reading the content of file from resources or nil if the file could not be located..
-
Returns a data object initialized by reading the file from resources with given name and extension.
Declaration
Swift
public class func dataFromFileWithName(_ name: String, ofType type: String, inBundle bundle: Bundle) -> Data?Parameters
nameThe name of the resource file.
typeThe extension of file.
bundleBundle where file is stored.
Return Value
A data object initialized by reading the file from resources or nil if the file could not be located..
-
Returns a string object initialized by reading the content of file from resources with given name and extension.
Declaration
Swift
public class func stringFromFileWithName(_ name: String, ofType type: String, inBundle bundle: Bundle) -> String?Parameters
nameThe name of the resource file.
typeThe extension of file.
bundleBundle where file is stored.
Return Value
A strign object initialized by reading the content of file from resources or nil if the file could not be located..
TNResourceMaster Class Reference