Class

ALAssetRepresentation

An ALAssetRepresentation object encapsulates one of the representations of a given ALAsset object.

Overview

A given asset in the library may have more than one representation. For example, if a camera provides RAW and JPEG versions of an image, the resulting asset will have two representations—one for the RAW file and one for the JPEG file.

Symbols

Getting Image Representations

func cgImage(options: [AnyHashable : Any]! = [:])

Returns a full resolution CGImage of the representation.

func fullResolutionImage()

Returns a CGImage representation of the asset.

func fullScreenImage()

Returns a CGImage of the representation that is appropriate for displaying full screen.

Getting Image Attributes

func orientation()

Returns the representation’s orientation.

func scale()

Returns the representation’s scale.

func dimensions()

Returns the representation’s dimensions.

func filename()

Returns a string representing the filename of the representation on disk.

Getting Raw Data

func size()

Returns the size in bytes of the file for the representation.

Getting Metadata

func uti()

Returns the representation's UTI.

func metadata()

Returns a dictionary of dictionaries of metadata for the representation.

Getting an URL

func url()

Returns a persistent URL uniquely identifying the representation.

Relationships

Inherits From

Conforms To