|
Media Authoring with Java API |
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Objecttv.amwa.maj.entity.InterchangeObject
tv.amwa.maj.entity.Component
tv.amwa.maj.entity.Segment
tv.amwa.maj.entity.Selector
@AAFClass(uuid1=218169601,
uuid2=257,
uuid3=3584,
uuid4={6,14,43,52,2,6,1,1},
definedName="Selector",
description="The Selector class provides the value of a single Segment while preserving references to unused alternatives.")
public class Selector
Implements a selected value of a single segment while preserving references to unused alternatives. A selector represents an editing decision, which is in contrast with an essence group that presents a group of alternative versions of the same essence that the application can choose from, based on the most appropriate or efficient essence format among the alternatives.
THE COMMENTS FOR THIS CLASS ARE INCOMPLETE.
| Nested Class Summary | |
|---|---|
static class |
Selector.AlternatesXMLHandler
|
static class |
Selector.SelectedXMLHandler
|
static class |
Selector.XMLHandler
|
| Nested classes/interfaces inherited from class tv.amwa.maj.entity.Segment |
|---|
Segment.SegmentXMLHandler |
| Nested classes/interfaces inherited from class tv.amwa.maj.entity.Component |
|---|
Component.ComponentAttributesXMLHandler, Component.ComponentUserCommentsXMLHandler, Component.ComponentXMLHandler, Component.KLVDataXMLHandler |
| Nested classes/interfaces inherited from class tv.amwa.maj.entity.InterchangeObject |
|---|
InterchangeObject.InterchangeObjectXMLHandler |
| Field Summary | |
|---|---|
static String |
SELECTOR_TAG
|
| Fields inherited from class tv.amwa.maj.entity.Component |
|---|
COMPONENT_ITEM |
| Constructor Summary | |
|---|---|
Selector(Segment selected)
Creates and initializes a new selector segment, which provides the value of a single segment while preserving references to unused alternatives. |
|
| Method Summary | |
|---|---|
void |
appendAlternateSegment(Segment segment)
Append the given segment to collection of alternative segments of this selector. |
void |
appendXMLChildren(Node parent)
Append child elements to the given parent node to serialize the value of an object to an XML fragment. |
Selector |
clone()
Creates a cloned copy of this entity. |
int |
countAlternateSegments()
Returns the number of segments in the collection of alternates of this selector. |
boolean |
equals(Object o)
Tests to see if the given object is equal to this interchange object. |
List<Segment> |
getAlternateSegments()
Returns a collection of all the segments of the collection of alternates of this selector. |
Segment |
getSelectedSegment()
Returns the selected segment of this selector. |
int |
hashCode()
Returns a hash code value for this interchange object. |
void |
removeAlternateSegment(Segment segment)
Removes the given segment from the collection of alternates for this selector. |
void |
setPropertiesFromInterface(Selector castFrom)
|
void |
setSelectedSegment(Segment selectedSegment)
Sets the selected segment of this selector. |
| Methods inherited from class tv.amwa.maj.entity.Segment |
|---|
segmentOffsetToTC, segmentTCToOffset, setPropertiesFromInterface |
| Methods inherited from class tv.amwa.maj.entity.Component |
|---|
appendAttribute, appendAttribute, appendComment, appendComment, appendKLVData, countAttributes, countComments, countKLVData, getAttributes, getComments, getDataDefinition, getKLVData, getLength, getLengthPresent, removeAttribute, removeComment, removeKLVData, setDataDefinition, setLength, setLengthPresent, setPropertiesFromInterface |
| Methods inherited from class tv.amwa.maj.entity.InterchangeObject |
|---|
castFromInterface, countProperties, createOptionalPropertyValue, disableGenerationTracking, enableGenerationTracking, getDefinition, getGeneration, getGenerationAUID, getProperties, getPropertyValue, isGenerationTracked, isPropertyPresent, omitOpionalProperty, registerImplementation, setPropertiesFromInterface, setPropertyValue, toString |
| Methods inherited from class java.lang.Object |
|---|
getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface tv.amwa.maj.iface.Segment |
|---|
segmentOffsetToTC, segmentTCToOffset |
| Methods inherited from interface tv.amwa.maj.iface.Component |
|---|
appendAttribute, appendAttribute, appendComment, appendComment, appendKLVData, countAttributes, countComments, countKLVData, getAttributes, getComments, getDataDefinition, getKLVData, getLength, removeAttribute, removeComment, removeKLVData, setDataDefinition, setLength |
| Methods inherited from interface tv.amwa.maj.iface.InterchangeObject |
|---|
countProperties, createOptionalPropertyValue, disableGenerationTracking, enableGenerationTracking, getDefinition, getGeneration, getGenerationAUID, getProperties, getPropertyValue, isGenerationTracked, isPropertyPresent, omitOpionalProperty, setPropertyValue |
| Methods inherited from interface tv.amwa.maj.entity.MAJCommon |
|---|
toString |
| Field Detail |
|---|
public static final String SELECTOR_TAG
| Constructor Detail |
|---|
public Selector(Segment selected)
throws NullPointerException,
BadLengthException
Creates and initializes a new selector segment, which provides the value of a
single segment while preserving references to unused alternatives.
This list of alternatives is initialized to an empty list. The length and kind of
data represented by this component is extracted from the given selected segment.
selected - Currently selected element.
NullPointerException - Selected element is null.
BadLengthException - The given selected segment has a negative length.| Method Detail |
|---|
public final void setPropertiesFromInterface(Selector castFrom)
InterchangeObject.setPropertiesFromInterface(tv.amwa.maj.iface.InterchangeObject)
@AAFProperty(uuid1=100729092,
uuid2=1544,
uuid3=0,
uuid4={6,14,43,52,1,1,1,2},
definedName="Alternates",
typeName="StrongReferenceVector of Segment",
optional=true,
uniqueIdentifier=false,
pid=3842)
public List<Segment> getAlternateSegments()
SelectorReturns a collection of all the segments of the collection of alternates of this selector. If the alternates property is omitted, this method returns an empty list.
getAlternateSegments in interface Selector
public void appendAlternateSegment(Segment segment)
throws NullPointerException,
BadLengthException,
InvalidDataDefinitionException
SelectorAppend the given segment to collection of alternative segments of this selector. This set represents unused segment alternatives. If currently omitted, the alternates optional property is made present by this method.
appendAlternateSegment in interface Selectorsegment - Segment to append to the collection of alternates of this
selector.
NullPointerException - The given alternate segment is null.
BadLengthException - The given segment does not have a length that matches the length
of this selector.
InvalidDataDefinitionException - The given segment does not have a data definition that
is compatible with the essence type of this selector.public int countAlternateSegments()
SelectorReturns the number of segments in the collection of alternates of this selector. If the alternates property is omitted, this method returns 0.
countAlternateSegments in interface Selector
public void removeAlternateSegment(Segment segment)
throws NullPointerException,
SegmentNotFoundException
SelectorRemoves the given segment from the collection of alternates for this selector.
removeAlternateSegment in interface Selectorsegment - Segment to remove from the collection of alternates of this selector.
NullPointerException - The given segment to remove from the list
of alternates is null.
SegmentNotFoundException - The given segment is not
contained in the list of alternates for this selector.
@AAFProperty(uuid1=100729092,
uuid2=521,
uuid3=0,
uuid4={6,14,43,52,1,1,1,2},
definedName="Selected",
typeName="StrongReference to Segment",
optional=false,
uniqueIdentifier=false,
pid=3841)
public Segment getSelectedSegment()
SelectorReturns the selected segment of this selector.
getSelectedSegment in interface Selector
public void setSelectedSegment(Segment selectedSegment)
throws NullPointerException,
BadLengthException,
InvalidDataDefinitionException
SelectorSets the selected segment of this selector. If the selected segment currently exists in the set of alternatives, the selected segment is removed from the set. The segment being replaced is appended to the set of alternatives.
setSelectedSegment in interface SelectorselectedSegment - Selected segment of this selector.
NullPointerException - The given selected segment is null.
BadLengthException - The given segment does not have a length that matches the
length of this selector.
InvalidDataDefinitionException - The given segment does not have a data definition that
is compatible with the essence type of this selector.public boolean equals(Object o)
MAJCommonTests to see if the given object is equal to this interchange object. To be equal, the given value must be not null, share the same interface to its value and each of the properties of the value must each be equal.
equals in interface MAJCommonequals in class Componento - Object to test for equality with.
Object.equals(Object)public int hashCode()
MAJCommonReturns a hash code value for this interchange object.
hashCode in interface MAJCommonhashCode in class ComponentObject.hashCode()public Selector clone()
MAJCommonCreates a cloned copy of this entity. The clone will be initialized to have the same value as this value but exists independently from then on. Changes to this value will not effect the clone and changes to the clone will not effect this. MAJ API clones are true deep clones with no shared references to areas of memory within the original.
This method does not throw a CloneNotSupportedException as all
entity values must implement the Cloneable interface. If a cloning
error does occur, a null value will be returned but this is very unlikely
to happen.
clone in interface MAJCommonclone in class SegmentObject.clone()public void appendXMLChildren(Node parent)
XMLSerializableAppend child elements to the given parent node to serialize the value of an object
to an XML fragment. Methods of the XMLBuilder class are provided to help with this
process.
appendXMLChildren in interface XMLSerializableappendXMLChildren in class Componentparent - XML parent element to append child nodes to.
|
Media Authoring with Java API |
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||