Type Method

load(named:in:)

Blocks your app while loading an entity from a file in a bundle.

Declaration

static func load(named name: String, in bundle: Bundle? = nil) throws -> Entity

Parameters

name

The base name of the file to load, omitting the file extension.

bundle

The bundle containing the file. Use nil to search the app’s main bundle.

Return Value

The root entity in the loaded file.

See Also

Loading an Entity Hierarchy

static func load(contentsOf: URL, withName: String?) -> Entity

Blocks your app while loading an entity from a file URL.

static func loadAsync(named: String, in: Bundle?) -> LoadRequest<Entity>

Loads an entity from a file in a bundle asynchronously.