Type Method creation Request For Asset(from:)
Creates a request for adding a new image asset to the Photos library.
iOS 8+ macOS 10.15+ Beta Mac Catalyst 13.0+ Beta tvOS 10+ Declaration iOS, tvOS class func creationRequestForAsset( from image: ) -> UIImage
Self macOS, Mac Catalyst class func creationRequestForAsset( from image: ) -> NSImage
Self Return Value
An asset creation request.
Call this method within a photo library change block to create a new asset. For details on change blocks, see
. PHPhoto Library
To reference the newly created asset later in the same change block or after the change block completes, use the
property to retrieve a placeholder object. placeholder For Created Asset
object does not contain all metadata associated with the image file it was originally loaded from (for example, Exif tags such as geographic location, camera model, and exposure parameters). To ensure such metadata is saved in the Photos library, instead use the UIImage method or the creation Request For Asset From Image(at File URL:) class. To copy metadata from one file to another, see PHAsset Creation Request Image I/O.
This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.
Learn more about using Apple's beta software