Media Authoring
with Java API

tv.amwa.maj.iface
Interface AAFFileDescriptor

All Superinterfaces:
EssenceDescriptor, InterchangeObject
All Known Subinterfaces:
AES3PCMDescriptor, AIFCDescriptor, CDCIDescriptor, DataEssenceDescriptor, DigitalImageDescriptor, HTMLDescriptor, MPEGVideoDescriptor, MultipleDescriptor, PCMDescriptor, RGBADescriptor, SoundDescriptor, TIFFDescriptor, WAVEDescriptor
All Known Implementing Classes:
AAFFileDescriptor, AES3PCMDescriptor, AIFCDescriptor, CDCIDescriptor, DataEssenceDescriptor, DigitalImageDescriptor, HTMLDescriptor, MPEGVideoDescriptor, MultipleDescriptor, PCMDescriptor, RGBADescriptor, SoundDescriptor, TIFFDescriptor, WAVEDescriptor

public interface AAFFileDescriptor
extends EssenceDescriptor

Specifies a file descriptor that describes an essence source that is directly manipulated by an AAF application.

A source mob that contains a file descriptor is also known as an MXF file package or a file source mob.

Author:
Richard Cartwright
See Also:
EssenceDescriptor, SourceMob.getEssenceDescriptor()

Method Summary
 CodecDefinition getCodecDefinition()
          Returns the codec of the described file, which identifies the mechanism used to compress and uncompress samples of essence or used to convert samples of essence from one format to another.
 ContainerDefinition getContainerFormat()
          Returns the file format of the described file, which identifies the container mechanism used to store the essence.
 long getLength()
          Returns the length of the essence in sample units (not edit units).
 int getLinkedSlotID()
          Returns the linked slot id of this file descriptor, which specifies which mob slot of the associated source mob this descriptor describes when the source mob is described by a multiple descriptor.
 Rational getSampleRate()
          Returns the sample rate of the essence.
 void setCodecDefinition(CodecDefinition codecDef)
          Set the codec of the described file, which identifies the mechanism used to compress and uncompress samples of essence or used to convert samples of essence from one format to another.
 void setContainerFormat(ContainerDefinition format)
          Specifies the file format of the described file, which identifies the container mechanism used to store the essence.
 void setLength(long length)
          Sets the length of the essence in sample units (not edit units).
 void setLinkedSlotID(Integer linkedSlotId)
          Set the linked slot id of this file descriptor, which specifies which mob slot of the associated source mob this descriptor describes when the source mob is described by a multiple descriptor.
 void setSampleRate(Rational rate)
          Sets sample rate of the essence.
 
Methods inherited from interface tv.amwa.maj.iface.EssenceDescriptor
appendLocator, appendSubDescriptor, countLocators, countSubDescriptors, getLocatorAt, getLocators, getSubDescriptorAt, getSubDescriptors, insertLocatorAt, insertSubDescriptorAt, prependLocator, prependSubDescriptor, removeLocatorAt, removeSubDescriptorAt
 
Methods inherited from interface tv.amwa.maj.iface.InterchangeObject
countProperties, createOptionalPropertyValue, disableGenerationTracking, enableGenerationTracking, getDefinition, getGeneration, getGenerationAUID, getProperties, getPropertyValue, isGenerationTracked, isPropertyPresent, omitOpionalProperty, setPropertyValue
 

Method Detail

setLength

void setLength(@LengthType
               long length)
               throws BadPropertyException,
                      BadLengthException

Sets the length of the essence in sample units (not edit units).

Parameters:
length - Length of the essence in samples.
Throws:
BadPropertyException - The length property is not present as this file descriptor describes static essence.
BadLengthException - The length of the described material is negative.

getLength

@LengthType
long getLength()
               throws BadPropertyException

Returns the length of the essence in sample units (not edit units).

Returns:
Length of essence in samples.
Throws:
BadPropertyException - The length property is not present as this file descriptor describes static essence.

setCodecDefinition

void setCodecDefinition(CodecDefinition codecDef)

Set the codec of the described file, which identifies the mechanism used to compress and uncompress samples of essence or used to convert samples of essence from one format to another.

Parameters:
codecDef - Codec that was used for the file.
Throws:
NullPointerException - The given codec is null.
See Also:
CodecDefinition.forName(String), CodecConstant

getCodecDefinition

CodecDefinition getCodecDefinition()
                                   throws PropertyNotPresentException

Returns the codec of the described file, which identifies the mechanism used to compress and uncompress samples of essence or used to convert samples of essence from one format to another.

Returns:
Codec used to make the file.
Throws:
PropertyNotPresentException - The optional codec definition property is not present for this file descriptor.

setSampleRate

void setSampleRate(Rational rate)
                   throws NullPointerException,
                          BadPropertyException

Sets sample rate of the essence.

Parameters:
rate - Sample rate of the essence.
Throws:
NullPointerException - The given sample rate is null.
BadPropertyException - The sample rate property is not present as this file descriptor describes static essence.

getSampleRate

Rational getSampleRate()
                       throws BadPropertyException

Returns the sample rate of the essence.

Returns:
Sample rate of the essence.
Throws:
BadPropertyException - The sample rate property is not present as this file descriptor describes static essence.

setContainerFormat

void setContainerFormat(ContainerDefinition format)

Specifies the file format of the described file, which identifies the container mechanism used to store the essence.

The container format is defined as an optional property but version 1.1 of the AAF object specification requires it to be specified for each file. The property can be omitted by setting its value to null for compatibility with older versions of the specification.

Parameters:
format - File format to set for this file descriptor.
See Also:
ContainerDefinition.forName(String), ContainerConstant

getContainerFormat

ContainerDefinition getContainerFormat()
                                       throws PropertyNotPresentException

Returns the file format of the described file, which identifies the container mechanism used to store the essence.

The container format is defined as an optional property but version 1.1 of the AAF object specification requires it to be specified for each file. However, file descriptors created with tools supporting earlier versions of the AAF specification may omit the property, in which case a PropertyNotPresentException is thrown.

Returns:
File format of the described file.
Throws:
PropertyNotPresentException - The (rarely) optional container format property is not present in this file descriptor.

setLinkedSlotID

void setLinkedSlotID(@SlotID
                     Integer linkedSlotId)
                     throws IllegalArgumentException

Set the linked slot id of this file descriptor, which specifies which mob slot of the associated source mob this descriptor describes when the source mob is described by a multiple descriptor. In this case, this file descriptor is one of the collection of file descriptors that are part of a multiple descriptor, as returned by MultipleDescriptor.getFileDescriptors(). If this file descriptor is not part of a multiple descriptor collection, set this optional property to null to omit it.

Parameters:
linkedSlotId - Linked slot id of this file descriptor.
Throws:
IllegalArgumentException - The linked slot id is negative.

getLinkedSlotID

@SlotID
int getLinkedSlotID()
                    throws PropertyNotPresentException

Returns the linked slot id of this file descriptor, which specifies which mob slot of the associated source mob this descriptor describes when the source mob is described by a multiple descriptor. This is an optional property.

Returns:
Linked slot id of this file descriptor.
Throws:
PropertyNotPresentException - The optional linked slot id property is not present in this file descriptor.

Media Authoring
with Java API

(c) 2007-2008 Richard Cartwright, all rights reserved. Subject to the terms of the AAF SDK Public Source License.