RSDFetchableImageThemeElementObject
public struct RSDFetchableImageThemeElementObject : RSDFetchableImageThemeElement, RSDDecodableBundleInfo, Codable
RSDFetchableImageThemeElementObject is a Codable concrete implementation of RSDFetchableImageThemeElement.
-
The name of the image.
Declaration
Swift
public let imageName: String -
The bundle identifier for the image resource bundle.
Declaration
Swift
public let bundleIdentifier: String? -
The preferred placement of the image. Default placement is
iconBeforeif undefined.Declaration
Swift
public let placementType: RSDImagePlacementType? -
The image size. If undefined then default sizing will be used.
Declaration
Swift
public var size: CGSize? -
The unique identifier for the image
Declaration
Swift
public var identifier: String -
Default initializer.
Declaration
Swift
public init(imageName: String, bundleIdentifier: String? = nil, placementType: RSDImagePlacementType? = nil, size: CGSize? = nil)Parameters
imageNameThe name of the image.
bundleIdentifierThe bundle identifier for the image resource bundle. Default =
nil.placementTypeThe preferred placement of the image. Default =
nil.sizeThe image size. Default =
nil. -
A method for fetching the image.
Declaration
Swift
public func fetchImage(for size: CGSize, callback: @escaping ((UIImage?) -> Void))Parameters
sizeThe size of the image to return.
callbackThe callback with the image, run on the main thread.
View on GitHub
RSDFetchableImageThemeElementObject Structure Reference