NSCoder AV Foundation Additions Reference

Inherits from
Framework
/System/Library/Frameworks/AVFoundation.framework
Availability
Available in iOS 4.0 and later.
Companion guide
Declared in
AVTime.h

Overview

The AV Foundation framework adds methods to the NSCoder class to make it easier to create archives including Core Media time structures, and extract Core Media time structure from archives.

Tasks

Encoding Core Media Time Structures

Decoding Core Media Time Structures

Instance Methods

decodeCMTimeForKey:

Returns the CMTime structure associated with a given key.

- (CMTime)decodeCMTimeForKey:(NSString *)key
Parameters
key

The key for a CMTime structure encoded in the receiver.

Return Value

The CMTime structure associated with key in the archive.

Availability
  • Available in iOS 4.0 and later.
Declared In
AVTime.h

decodeCMTimeMappingForKey:

Returns the CMTimeMapping structure associated with a given key.

- (CMTimeMapping)decodeCMTimeMappingForKey:(NSString *)key
Parameters
key

The key for a CMTimeMapping structure encoded in the receiver.

Return Value

The CMTimeMapping structure associated with key in the archive.

Availability
  • Available in iOS 4.0 and later.
Declared In
AVTime.h

decodeCMTimeRangeForKey:

Returns the CMTimeRange structure associated with a given key.

- (CMTimeRange)decodeCMTimeRangeForKey:(NSString *)key
Parameters
key

The key for a CMTimeRange structure encoded in the receiver.

Return Value

The CMTimeRange structure associated with key in the archive.

Availability
  • Available in iOS 4.0 and later.
Declared In
AVTime.h

encodeCMTime:forKey:

Encodes a given CMTime structure and associates it with a specified key.

- (void)encodeCMTime:(CMTime)time forKey:(NSString *)key
Parameters
time

A CMTime structure.

key

The key with which to associate time in the archive.

Availability
  • Available in iOS 4.0 and later.
Declared In
AVTime.h

encodeCMTimeMapping:forKey:

Encodes a given CMTimeMapping structure and associates it with a specified key.

- (void)encodeCMTimeMapping:(CMTimeMapping)timeMapping forKey:(NSString *)key
Parameters
timeMapping

A CMTimeMapping structure.

key

The key with which to associate timeMapping in the archive.

Availability
  • Available in iOS 4.0 and later.
Declared In
AVTime.h

encodeCMTimeRange:forKey:

Encodes a given CMTimeRange structure and associates it with a specified key.

- (void)encodeCMTimeRange:(CMTimeRange)timeRange forKey:(NSString *)key
Parameters
timeRange

A CMTimeRange structure.

key

The key with which to associate timeRange in the archive.

Availability
  • Available in iOS 4.0 and later.
Declared In
AVTime.h