|
Media Authoring with Java API |
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface TypeDefinitionExtendibleEnumeration
Specifies the definition of a property type that can have one of an extendible set of AUID values. Each value is an enumeration element with its own name. The elements are specified as an array of identifiers and an array of names, where a single element is defined by the identifier and name and the same index of the arrays.
The extendible enumeration factory and extendible enumeration item annotation have been provided with the MAJ API as a means to manage property values of the extendible enumeration type.
makeTypeDefinitionExtendibleEnumeration()
,
TypeCategory.ExtEnum
,
ExtendibleEnumerationWarehouse
,
ExtendibleEnumerationItem
Method Summary | |
---|---|
void |
appendElement(AUID value,
String name)
Appends the given element, a name and AUID pair, to this extendible enumeration type definition. |
int |
countElements()
Returns the number of enumeration elements of this extendible enumeration type definition. |
PropertyValue |
createValueFromName(String name)
Creates a property value defined by this extendible enumeration type definition using the given name. |
AUID |
getAUIDFromName(String elementName)
Returns the identifier of the enumeration element associated with the given name, as defined by this extendible enumeration type definition. |
AUID |
getAUIDValue(PropertyValue enumerationProperty)
Returns the AUID value associated with the given extendible enumeration property value according to this extendible enumeration type definition. |
String |
getElementName(int index)
Returns the name of the enumeration element at the given index in the list of elements of this extendible enumeration type definition. |
AUID |
getElementValue(int index)
Returns the AUID value for the enumeration element at the given index of in the list of elements of this extendible enumeration type definition. |
String |
getNameFromAUID(AUID elementValue)
Returns the name of the enumeration element associated with the given AUID value, as defined by this extendible enumeration type definition. |
String |
getNameFromValue(PropertyValue enumerationProperty)
Returns the name associated with the given property value, as defined by this extendible enumeration type definition. |
void |
setAUIDValue(PropertyValue enumerationProperty,
AUID value)
Sets the value of the given extendible enumeration property value to the given AUID that identifies an element of this extendible enumeration type definition. |
Methods inherited from interface tv.amwa.maj.iface.TypeDefinition |
---|
createValue, getTypeCategory |
Methods inherited from interface tv.amwa.maj.iface.MetaDefinition |
---|
getAUID, getDescription, getName, setDescription, setName |
Method Detail |
---|
PropertyValue createValueFromName(@AAFString String name) throws NullPointerException, InvalidParameterException
Creates a property value defined by this extendible enumeration type definition using the given name. The name is checked to see that it is in the list of names defining elements of this enumeration.
name
- Name to use to create a new extendible enumeration
property value.
NullPointerException
- The given name is null
.
InvalidParameterException
- The given name does not match an element
of this extendible enumeration type definition.setAUIDValue(PropertyValue, AUID)
@UInt32 int countElements()
Returns the number of enumeration elements of this extendible enumeration type definition.
AUID getElementValue(@UInt32 int index) throws IndexOutOfBoundsException
Returns the AUID value for the enumeration element at the given index of in the list of elements of this extendible enumeration type definition.
index
- Index of the required AUID value.
IndexOutOfBoundsException
- The given index is outside
the acceptable range for the list of elements of this extendible enumeration type
definition.@AAFString String getElementName(@UInt32 int index) throws IndexOutOfBoundsException
Returns the name of the enumeration element at the given index in the list of elements of this extendible enumeration type definition.
index
- Index of the required name.
IndexOutOfBoundsException
- The given index is outside
the acceptable range for this extendible enumeration type
definition.@AAFString String getNameFromValue(PropertyValue enumerationProperty) throws NullPointerException, IllegalPropertyValueException
Returns the name associated with the given property value, as defined by this extendible enumeration type definition.
enumerationProperty
- Property value to lookup the name of.
NullPointerException
- The given extendible enumeration property value is
null
.
IllegalPropertyValueException
- The given property value is not
defined by this extendible enumeration type definition.@AAFString String getNameFromAUID(AUID elementValue) throws NullPointerException, BadParameterException
Returns the name of the enumeration element associated with the given AUID value, as defined by this extendible enumeration type definition.
elementValue
- Value to use to lookup the element name.
NullPointerException
- The given identifier is null
.
BadParameterException
- The given value is not found
in the list of values of this extendible enumeration type
definition.getAUIDFromName(String)
AUID getAUIDFromName(@AAFString String elementName) throws NullPointerException, BadParameterException
Returns the identifier of the enumeration element associated with the given name, as defined by this extendible enumeration type definition.
elementName
- Name to use to lookup the element identifier.
NullPointerException
- The given element name is null
.
BadParameterException
- The given element name is not known
for in the list of values of this extendible enumeration type
definition.getNameFromAUID(AUID)
AUID getAUIDValue(PropertyValue enumerationProperty) throws NullPointerException, IllegalPropertyValueException
Returns the AUID value associated with the given extendible enumeration property value according to this extendible enumeration type definition.
enumerationProperty
- Extensible enumeration property value
to find the associated AUID value for.
NullPointerException
- The given extendible enumeration property value
is null
.
IllegalPropertyValueException
- The given property value is not
defined by this extendible enumeration type definition.getNameFromAUID(AUID)
,
getAUIDFromName(String)
void setAUIDValue(PropertyValue enumerationProperty, AUID value) throws NullPointerException, IllegalPropertyValueException, BadParameterException
Sets the value of the given extendible enumeration property value to the given AUID that identifies an element of this extendible enumeration type definition.
enumerationProperty
- Extensible enumeration property value
to change.value
- New value to set the given property value to.
NullPointerException
- One or both of the arguments is/are null
.
IllegalPropertyValueException
- The given property value is not
defined by this extendible enumeration type definition.
BadParameterException
- The given enumeration value identifier does not identifiy
an element of this extendible enumeration type.getNameFromAUID(AUID)
,
getAUIDFromName(String)
,
createValueFromName(String)
void appendElement(AUID value, @AAFString String name) throws NullPointerException, DuplicateException
Appends the given element, a name and AUID pair, to this extendible enumeration type definition.
value
- AUID for the new enumeration element to append.name
- Name for the new enumeration element to append.
NullPointerException
- One or both of the arguments is/are null
.
DuplicateException
- Appending the given enumeration element
would introduce a duplicate value and/or duplicate name.
|
Media Authoring with Java API |
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |