Instance Method インスタンスメソッド

snapshot(contentType:)

Create a snapshot of the current state of the document, which will be used for serialization while self becomes editable by the user.

Declaration 宣言

func snapshot(contentType: UTType) throws -> Self.Snapshot

Parameters パラメータ

contentType

The content type being written, for which the snapshot should be created.

Discussion 議論

When saving a ReferenceFileDocument, edits to the document are blocked until snapshot with a copy of any mutable references can be created. Once the snapshot is created, the document becomes editable in parallel to the snapshot being serialized using write(snapshot:to:contentType:).

See Also 参照

Getting a Snapshot