SourceReferenceSegmentImpl (Media Authoring with Java API)
Date: 2016-02-05

tv.amwa.maj.model.impl

## Class SourceReferenceSegmentImpl

- java.lang.Object
- - tv.amwa.maj.model.impl.InterchangeObjectImpl
  - - tv.amwa.maj.model.impl.ComponentImpl
    - - tv.amwa.maj.model.impl.SegmentImpl
      - - tv.amwa.maj.model.impl.SourceReferenceSegmentImpl

- All Implemented Interfaces:
    Serializable, Cloneable, QComponent, QSegment, MediaEntity, MetadataObject, Component, InterchangeObject, Segment, SourceReferenceSegment
  Direct Known Subclasses:
    SourceClipImpl, TextClipImpl

      @MediaClass(uuid1=218169601,
                  uuid2=257,
                  uuid3=4096,
                  uuid4={6,14,43,52,2,6,1,1},
                  definedName="SourceReference",
                  description="The SourceReference class represents the essence or other data described by a Track in a Package.",
                  symbol="SourceReference",
                  isConcrete=false)
      public class SourceReferenceSegmentImpl
      extends SegmentImpl
      implements SourceReferenceSegment, Serializable, Cloneable

  Implements the representation of essence or other data described by a track in a package.

  See Also:
    `TypeDefinitions.SourceReferenceStrongReference`, `TypeDefinitions.SourceReferenceStrongReferenceVector`, Serialized Form

- - ### Field Summary

    - ### Fields inherited from class tv.amwa.maj.model.impl.InterchangeObjectImpl

      `ObjectClassPropertyID`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `SourceReferenceSegmentImpl()`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `clearChannelIDs()`
    `void` | `clearMonoSourceTrackIDs()`
    `SourceReferenceSegment` | `clone()` Create a cloned copy of this interchange object.
    `int[]` | `getChannelIDs()` For references to a multi-channel track, returns the channel ids property of this source reference, which specifies the channels within that tracks that are referenced.
    `int` | `getChannelIDsSize()` Returns the number of elements of the channel ids array of this source reference.
    `int[]` | `getMonoSourceTrackIDs()` For references from a multi-channel track to multiple mono tracks, returns the mono source track ids property of this source reference, which specifies multiple mono tracks that are referenced.
    `int` | `getMonoSourceTrackIDsSize()` Returns the size of the mono source track ids array.
    `PackageID` | `getSourcePackageID()` Returns the package id of the package that is the target of this reference.
    `String` | `getSourcePackageIDString()`
    `int` | `getSourceTrackID()` Returns the track id of this source reference.
    `static int` | `initializeSourceTrackID()`
    `void` | `setChannelIDs(int[] channelIDs)` For references to a multi-channel track, sets the channel ids property of this source reference, which specifies the channels within that tracks that are referenced.
    `void` | `setMonoSourceTrackIDs(int[] monoSourceTrackIDs)` For references from a multi-channel track to multiple mono tracks, sets the mono source track ids property of this source reference, which specifies multiple mono tracks that are referenced.
    `void` | `setSourcePackageID(PackageID sourcePackageID)` Set the source package id of this source reference, which identifies the package that is the target of this reference.
    `void` | `setSourcePackageIDString(String sourcePackageID)`
    `void` | `setSourceTrackID(int sourceTrackID)` Sets the track id of this source reference.

    - ### Methods inherited from class tv.amwa.maj.model.impl.SegmentImpl

      `generateSequence, getCutPoint, getKeyOffset, getPackLayerKeyIndicator, getSegmentBlob, getTrackBlob, getTrackKeyRenderSequence, getTrackName, getTrackRenderSequence, segmentOffsetToTC, segmentTCToOffset, setCutPoint, setKeyOffset, setPackLayerKeyIndicator, setSegmentBlob, setTrackBlob, setTrackKeyRenderSequence, setTrackName, setTrackRenderSequence`

    - ### Methods inherited from class tv.amwa.maj.model.impl.ComponentImpl

      `appendComponentAttribute, appendComponentAttribute, appendComponentKLVData, appendComponentUserComment, appendComponentUserComment, clearComponentAttributes, clearComponentKLVData, clearComponentUserComments, countComponentAttributes, countComponentKLVData, countComponentUserComments, getComment, getComponentAttributes, getComponentDataDefinition, getComponentKLVData, getComponentLength, getComponentUserComments, getEditName, getJupiterClipOffset, getJupiterID, getLengthPresent, initializeComponentDataDefinition, prependComponentAttribute, prependComponentKLVData, prependComponentUserComment, removeComponentAttribute, removeComponentKLVData, removeComponentUserComment, setComponentDataDefinition, setComponentLength, setComponentLengthFromStream, setEditName, setJupiterClipOffset, setJupiterID, setLengthPresent`

    - ### Methods inherited from class tv.amwa.maj.model.impl.InterchangeObjectImpl

      `addApplicationPlugin, appendXMLChildren, clearApplicationPlugins, containsApplicationPlugin, containsApplicationPlugin, countApplicationPlugins, deepEquals, disableGenerationTracking, enableGenerationTracking, equals, getApplicationPlugins, getGeneration, getLinkedGenerationID, getLinkedGenerationIDString, getObjectClass, getPersistentID, getPersistentIndex, hashCode, isGenerationTracked, removeApplicationPlugin, removeApplicationPlugin, setLinkedGenerationID, setLinkedGenerationIDString, setObjectClass, setPersistentID, setPersistentIndex, toString`

    - ### Methods inherited from class java.lang.Object

      `getClass, notify, notifyAll, wait, wait, wait`

    - ### Methods inherited from interface tv.amwa.maj.model.Segment

      `generateSequence, segmentOffsetToTC, segmentTCToOffset`

    - ### Methods inherited from interface tv.amwa.maj.model.Component

      `appendComponentAttribute, appendComponentAttribute, appendComponentKLVData, appendComponentUserComment, appendComponentUserComment, clearComponentAttributes, clearComponentKLVData, clearComponentUserComments, countComponentAttributes, countComponentKLVData, countComponentUserComments, getComponentAttributes, getComponentDataDefinition, getComponentKLVData, getComponentLength, getComponentUserComments, getLengthPresent, removeComponentAttribute, removeComponentKLVData, removeComponentUserComment, setComponentDataDefinition, setComponentLength, setLengthPresent`

    - ### Methods inherited from interface tv.amwa.maj.model.InterchangeObject

      `addApplicationPlugin, clearApplicationPlugins, containsApplicationPlugin, containsApplicationPlugin, countApplicationPlugins, deepEquals, disableGenerationTracking, enableGenerationTracking, equals, getApplicationPlugins, getGeneration, getLinkedGenerationID, getObjectClass, isGenerationTracked, removeApplicationPlugin, removeApplicationPlugin, setLinkedGenerationID, setObjectClass, toString`

    - ### Methods inherited from interface tv.amwa.maj.industry.MediaEntity

      `getPersistentID, setPersistentIndex`

- - ### Constructor Detail

    - #### SourceReferenceSegmentImpl

          public SourceReferenceSegmentImpl()

  - ### Method Detail

    - #### getChannelIDs

          @MediaProperty(uuid1=100729091,
                         uuid2=1792,
                         uuid3=0,
                         uuid4={6,14,43,52,1,1,1,7},
                         definedName="ChannelIDs",
                         typeName="UInt32Array",
                         optional=true,
                         uniqueIdentifier=false,
                         pid=4355,
                         symbol="ChannelIDs")
          public int[] getChannelIDs()
                                                                                                                                                                                                                                                                                                                                                                              throws PropertyNotPresentException

      Description copied from interface: `SourceReferenceSegment`

      For references to a multi-channel track, returns the channel ids property of this source reference, which specifies the channels within that tracks that are referenced. This optional property is omitted to indicate that all channels in the referenced track are referenced in the same order.

      The number of channel ids shall equal the number of channels being described the track containing the source reference, e.g. 1 element for a mono audio track, 6 elements for a 5.1 multi-channel audio track.

      Specified by:
        `getChannelIDs` in interface `SourceReferenceSegment`
      Returns:
        Array of channel ids for this source reference.
      Throws:
        `PropertyNotPresentException` - The optional channel ids property is not present in this source reference.

    - #### setChannelIDs

          @MediaPropertySetter(value="ChannelIDs")
          public void setChannelIDs(int[] channelIDs)
                                                                      throws IllegalArgumentException

      Description copied from interface: `SourceReferenceSegment`

      For references to a multi-channel track, sets the channel ids property of this source reference, which specifies the channels within that tracks that are referenced. Set this optional property to `null` to omit it and indicate that all channels in the referenced track are referenced in the same order.

      The number of channel ids shall equal the number of channels being described the `track` containing the source reference, e.g. 1 element for a mono audio track, 6 elements for a 5.1 multi-channel audio track.

      Specified by:
        `setChannelIDs` in interface `SourceReferenceSegment`
      Parameters:
        `channelIDs` - Array of channel IDs to set for the source reference.
      Throws:
        `IllegalArgumentException`

    - #### getChannelIDsSize

          public int getChannelIDsSize()
                                throws PropertyNotPresentException

      Description copied from interface: `SourceReferenceSegment`

      Returns the number of elements of the channel ids array of this source reference. For references to a multi-channel track, the channel ids property specifies the channels within the tracks that are referenced. This is an optional property.

      Specified by:
        `getChannelIDsSize` in interface `SourceReferenceSegment`
      Returns:
        Number of elements of the channel ids array of the source reference.
      Throws:
        `PropertyNotPresentException` - The optional channel ids property is not present in this source reference.

    - #### clearChannelIDs

          @MediaPropertyClear(value="ChannelIDs")
          public void clearChannelIDs()

    - #### getMonoSourceTrackIDs

          @MediaProperty(uuid1=100729091,
                         uuid2=2048,
                         uuid3=0,
                         uuid4={6,14,43,52,1,1,1,8},
                         definedName="MonoSourceTrackIDs",
                         aliases="MonoSourceSlotIDs",
                         typeName="UInt32Array",
                         optional=true,
                         uniqueIdentifier=false,
                         pid=4356,
                         symbol="MonoSourceTrackIDs")
          public int[] getMonoSourceTrackIDs()
                                                                                                                                                                                                                                                                                                                                                                                                                                                  throws PropertyNotPresentException

      Description copied from interface: `SourceReferenceSegment`

      For references from a multi-channel track to multiple mono tracks, returns the mono source track ids property of this source reference, which specifies multiple mono tracks that are referenced. This is an optional property that is omitted to specify that this is a single-channel reference.

      The number of elements in the mono source track ids array shall equal the number of channels being described by the track containing this source reference, e.g. 6 elements for a 5.1 multi-channel audio track.

      Specified by:
        `getMonoSourceTrackIDs` in interface `SourceReferenceSegment`
      Returns:
        Array of mono source track ids of this source reference.
      Throws:
        `PropertyNotPresentException` - This optional mono source track ids property is not present in this source reference.

    - #### setMonoSourceTrackIDs

          @MediaPropertySetter(value="MonoSourceTrackIDs")
          public void setMonoSourceTrackIDs(int[] monoSourceTrackIDs)
                                                                                      throws IllegalArgumentException

      Description copied from interface: `SourceReferenceSegment`

      For references from a multi-channel track to multiple mono tracks, sets the mono source track ids property of this source reference, which specifies multiple mono tracks that are referenced. Set this optional property to `null` to omit it and specify that this is a single-channel reference.

      The number of elements in the mono source track ids array shall equal the number of channels being described by the track containing this source reference, e.g. 6 elements for a 5.1 multi-channel audio track.

      Specified by:
        `setMonoSourceTrackIDs` in interface `SourceReferenceSegment`
      Parameters:
        `monoSourceTrackIDs` - Array of mono source track ids for this source reference.
      Throws:
        `IllegalArgumentException`

    - #### getMonoSourceTrackIDsSize

          @MediaPropertyCount(value="MonoSourceTrackIDs")
          public int getMonoSourceTrackIDsSize()
                                                                                        throws PropertyNotPresentException

      Description copied from interface: `SourceReferenceSegment`

      Returns the size of the mono source track ids array. For references from a multi-channel track to multiple mono tracks, the mono source track ids property specifies multiple mono tracks that are referenced. This is an optional property.

      Specified by:
        `getMonoSourceTrackIDsSize` in interface `SourceReferenceSegment`
      Returns:
        Size of the mono source track ids array.
      Throws:
        `PropertyNotPresentException` - The optional mono source track ids property is not present for this source reference.

    - #### clearMonoSourceTrackIDs

          @MediaPropertyClear(value="MonoSourceTrackIDs")
          public void clearMonoSourceTrackIDs()

    - #### getSourcePackageID

          @MediaProperty(uuid1=100729091,
                         uuid2=256,
                         uuid3=0,
                         uuid4={6,14,43,52,1,1,1,2},
                         definedName="SourcePackageID",
                         aliases={"SourceID","SourceMobID"},
                         typeName="PackageIDType",
                         optional=true,
                         uniqueIdentifier=false,
                         pid=4353,
                         symbol="SourcePackageID")
          public PackageID getSourcePackageID()
                                                                                                                                                                                                                                                                                                                                                                                                                                                     throws PropertyNotPresentException

      Description copied from interface: `SourceReferenceSegment`

      Returns the package id of the package that is the target of this reference. This is an optional property.

      If the source package id property is the zero package id, the package owning the source reference describes the original source. If this property is omitted, the reference is to another track within the same package.

      Specified by:
        `getSourcePackageID` in interface `SourceReferenceSegment`
      Returns:
        Source package id that is the target of this source reference.
      Throws:
        `PropertyNotPresentException` - The optional source package id property is not present in this source reference, implying that this is a reference to a track within the same package.
      See Also:
        `SourceReferenceValue.getSourcePackageID()`

    - #### setSourcePackageID

          @MediaPropertySetter(value="SourcePackageID")
          public void setSourcePackageID(PackageID sourcePackageID)

      Description copied from interface: `SourceReferenceSegment`

      Set the source package id of this source reference, which identifies the package that is the target of this reference.

      If the property has a value of the zero pcakage id, it means that the package owning this source reference describes the original source. Set this optional property to `null` to omit and indicate that this reference is to another track in the same package.

      For source clips, it is recommended that the `setSourceReference()` method is used to set the source package id property in preference to this method.

      Specified by:
        `setSourcePackageID` in interface `SourceReferenceSegment`
      Parameters:
        `sourcePackageID` - Source package id of this source reference.
      See Also:
        `SourceReferenceValue.setSourcePackageID(PackageID)`, `Forge.zeroPackageID()`, `SourceClip.setSourceReference(SourceReferenceValue)`

    - #### getSourceTrackID

          @MediaProperty(uuid1=100729091,
                         uuid2=512,
                         uuid3=0,
                         uuid4={6,14,43,52,1,1,1,2},
                         definedName="SourceTrackID",
                         aliases="SourceMobSlotID",
                         typeName="UInt32",
                         optional=false,
                         uniqueIdentifier=false,
                         pid=4354,
                         symbol="SourceTrackID")
          public int getSourceTrackID()

      Description copied from interface: `SourceReferenceSegment`

      Returns the track id of this source reference. If the source package id property is the the package package id, the source track id should be 0.

      Specified by:
        `getSourceTrackID` in interface `SourceReferenceSegment`
      Returns:
        Track id of this source reference.
      See Also:
        `SourceReferenceValue.getSourceTrackID()`, `TrackID`

    - #### setSourceTrackID

          @MediaPropertySetter(value="SourceTrackID")
          public void setSourceTrackID(int sourceTrackID)
                                                                            throws IllegalArgumentException

      Description copied from interface: `SourceReferenceSegment`

      Sets the track id of this source reference. If the source package id property is the the zero package id, the source track id should be 0.

      Specified by:
        `setSourceTrackID` in interface `SourceReferenceSegment`
      Parameters:
        `sourceTrackID` - Track id of this source reference.
      Throws:
        `IllegalArgumentException` - The given source track id is negative.
      See Also:
        `SourceReferenceValue.setSourceTrackID(int)`

    - #### initializeSourceTrackID

          public static final int initializeSourceTrackID()

    - #### clone

          public SourceReferenceSegment clone()

      Description copied from interface: `InterchangeObject`

      Create a cloned copy of this interchange object.

      Specified by:
        `clone` in interface `MediaEntity`
      Specified by:
        `clone` in interface `Component`
      Specified by:
        `clone` in interface `InterchangeObject`
      Specified by:
        `clone` in interface `Segment`
      Specified by:
        `clone` in interface `SourceReferenceSegment`
      Overrides:
        `clone` in class `SegmentImpl`
      Returns:
        Cloned copy of this interchange object.

    - #### getSourcePackageIDString

          public String getSourcePackageIDString()

    - #### setSourcePackageIDString

          public void setSourcePackageIDString(String sourcePackageID)

(c)2007-2016 Richard Cartwright, all rights reserved. Licensed under Apache 2 license and subject to the AMWA IPR policy.