public class FrameBodyCTOC extends AbstractID3v2FrameBody implements ID3v2ChapterFrameBody, ID3v24FrameBody, ID3v23FrameBody
There may be more than one frame of this type in a tag but each must have an Element ID that is unique with respect to any other "CTOC" or "CHAP" frame in the tag.
Each "CTOC" frame represents one level or element of a table of contents by providing a list of Child Element IDs. These match the Element IDs of other "CHAP" and "CTOC" frames in the tag.
<ID3v2.3 or ID3v2.4 frame header, ID: "CTOC"> | (10 bytes) | |
Element ID | <text string> $00 | |
Flags | %000000ab | |
Entry count | $xx (8-bit unsigned int) | |
<Child Element ID list> | ||
<Optional embedded sub-frames> |
Flag a - Top-level bit
This is set to 1 to identify the top-level "CTOC" frame. This frame
is the root of the Table of Contents tree and is not a child of any
other "CTOC" frame. Only one "CTOC" frame in an ID3v2 tag can have
this bit set to 1. In all other "CTOC" frames this bit shall be set
to 0.
Flag b - Ordered bit
This should be set to 1 if the entries in the Child Element ID list
are ordered or set to 0 if they not are ordered. This provides a hint
as to whether the elements should be played as a continuous ordered
sequence or played individually.
The Entry count is the number of entries in the Child Element ID list that follows and must be greater than zero. Each entry in the list consists of:
Child Element ID | <text string> $00 |
If a parser does not recognise "CTOC" frames it can skip them using the size field in the frame header. When it does this it will skip any embedded sub-frames carried within the frame.
For more details, please refer to the ID3 Chapter Frame specifications:
TYPE_BODY
objectList
logger
Constructor and Description |
---|
FrameBodyCTOC()
Creates a new FrameBodyCTOC datatype.
|
FrameBodyCTOC(ByteBuffer byteBuffer,
int frameSize)
Creates a new FrameBodyCTOC datatype.
|
FrameBodyCTOC(FrameBodyCTOC body)
Creates a new FrameBodyCTOC datatype.
|
Modifier and Type | Method and Description |
---|---|
String |
getIdentifier()
The ID3v2 frame identifier
|
protected void |
setupObjectList()
TODO:proper mapping
|
createStructure, equals, getSize, read, setSize, setSize, write
getBriefDescription, getHeader, getLongDescription, getObject, getObjectValue, getTextEncoding, getUserFriendlyValue, isSubsetOf, iterator, setHeader, setObjectValue, setTextEncoding, toString
public FrameBodyCTOC()
public FrameBodyCTOC(FrameBodyCTOC body)
body
- public FrameBodyCTOC(ByteBuffer byteBuffer, int frameSize) throws InvalidTagException
byteBuffer
- frameSize
- InvalidTagException
- if unable to create framebody from bufferpublic String getIdentifier()
getIdentifier
in class AbstractID3v2FrameBody
protected void setupObjectList()
setupObjectList
in class AbstractTagFrameBody
Copyright © 2005–2020 jthink.net. All rights reserved.