org.jaudiotagger.tag.mp4.field
Class Mp4DiscNoField
java.lang.Object
org.jaudiotagger.tag.mp4.Mp4TagField
org.jaudiotagger.tag.mp4.field.Mp4TagTextField
org.jaudiotagger.tag.mp4.field.Mp4TagTextNumberField
org.jaudiotagger.tag.mp4.field.Mp4DiscNoField
- All Implemented Interfaces:
- TagField, TagTextField
public class Mp4DiscNoField
- extends Mp4TagTextNumberField
Represents the Disc No field
Contains some reserved fields that we currently ignore
Reserved:2 bytes
Disc Number:2 bytes
Total no of Discs:2 bytes
Constructor Summary |
Mp4DiscNoField(int discNo)
Create new Disc No field with only discNo |
Mp4DiscNoField(int discNo,
int total)
Create new Disc No Field with Disc No and total number of discs |
Mp4DiscNoField(java.lang.String discValue)
Create new Disc Field parsing the String for the discno/total |
Mp4DiscNoField(java.lang.String id,
java.nio.ByteBuffer data)
|
Method Summary |
protected void |
build(java.nio.ByteBuffer data)
Processes the data and sets the position of the data buffer to just after the end of this fields data
ready for processing next field. |
java.lang.Short |
getDiscNo()
|
java.lang.Short |
getDiscTotal()
|
void |
setDiscNo(int discNo)
Set Disc No |
void |
setDiscTotal(int discTotal)
Set total number of discs |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
NONE_VALUE_INDEX
private static final int NONE_VALUE_INDEX
- See Also:
- Constant Field Values
DISC_NO_INDEX
private static final int DISC_NO_INDEX
- See Also:
- Constant Field Values
DISC_TOTAL_INDEX
private static final int DISC_TOTAL_INDEX
- See Also:
- Constant Field Values
Mp4DiscNoField
public Mp4DiscNoField(java.lang.String discValue)
throws FieldDataInvalidException
- Create new Disc Field parsing the String for the discno/total
- Parameters:
discValue
-
- Throws:
FieldDataInvalidException
Mp4DiscNoField
public Mp4DiscNoField(int discNo)
- Create new Disc No field with only discNo
- Parameters:
discNo
-
Mp4DiscNoField
public Mp4DiscNoField(int discNo,
int total)
- Create new Disc No Field with Disc No and total number of discs
- Parameters:
discNo
- total
-
Mp4DiscNoField
public Mp4DiscNoField(java.lang.String id,
java.nio.ByteBuffer data)
throws java.io.UnsupportedEncodingException
- Throws:
java.io.UnsupportedEncodingException
build
protected void build(java.nio.ByteBuffer data)
throws java.io.UnsupportedEncodingException
- Description copied from class:
Mp4TagField
- Processes the data and sets the position of the data buffer to just after the end of this fields data
ready for processing next field.
- Overrides:
build
in class Mp4TagTextNumberField
- Throws:
java.io.UnsupportedEncodingException
getDiscNo
public java.lang.Short getDiscNo()
- Returns:
setDiscNo
public void setDiscNo(int discNo)
- Set Disc No
- Parameters:
discNo
-
getDiscTotal
public java.lang.Short getDiscTotal()
- Returns:
setDiscTotal
public void setDiscTotal(int discTotal)
- Set total number of discs
- Parameters:
discTotal
-