IosWidgetFeedStorage

class IosWidgetFeedStorage : WidgetFeedStorage(source)

Generation folders inside the App Group container so the widget extension can read them.

Constructors

Link copied to clipboard
constructor(appGroup: String, directoryName: String)

<App Group container>/<directoryName>. Throws on first use when the App Group is not in the entitlements.

Functions

Link copied to clipboard
open override fun assetPath(generationDirectory: String, fileName: String): String?

Absolute path of assets/<fileName> inside generationDirectory, or null when unsafe or missing.

Link copied to clipboard
open override fun clear()

Removes every generation and the pointer.

Link copied to clipboard
open override fun readGenerationCandidates(): List<WidgetGeneration>
Link copied to clipboard
open override fun writeGeneration(generationId: String, feedBytes: ByteArray, assets: List<WidgetAsset>, keepPrevious: Int)

Writes a complete generation, promotes it atomically, updates the pointer, prunes to keepPrevious old ones.