public abstract class AbstractFrameBodyTextInfo extends AbstractID3v2FrameBody
getFirstTextValue()
TYPE_BODY
objectList
logger
Modifier | Constructor and Description |
---|---|
protected |
AbstractFrameBodyTextInfo()
Creates a new FrameBodyTextInformation datatype.
|
protected |
AbstractFrameBodyTextInfo(AbstractFrameBodyTextInfo body)
Copy Constructor
|
protected |
AbstractFrameBodyTextInfo(ByteBuffer byteBuffer,
int frameSize)
Creates a new FrameBodyTextInformation data type from file.
|
protected |
AbstractFrameBodyTextInfo(byte textEncoding,
String text)
Creates a new FrameBodyTextInformation data type.
|
Modifier and Type | Method and Description |
---|---|
void |
addTextValue(String value)
Add additional value to value
|
String |
getFirstTextValue()
Get first value
|
int |
getNumberOfValues() |
String |
getText()
Retrieve the complete text String as it is held internally.
|
String |
getTextWithoutTrailingNulls()
Retrieve the complete text String but without any trailing nulls
If multiple values are held these will be returned, needless trailing nulls will not be returned
|
String |
getUserFriendlyValue() |
String |
getValueAtIndex(int index)
Get text value at index
When a multiple values are stored within a single text frame this method allows access to any of the
individual values.
|
List<String> |
getValues() |
void |
setText(String text)
Set the Full Text String.
|
protected void |
setupObjectList()
Setup the Object List.
|
void |
write(ByteArrayOutputStream tagBuffer)
Because Text frames have a text encoding we need to check the text
String does not contain characters that cannot be encoded in
current encoding before we write data.
|
createStructure, equals, getIdentifier, getSize, read, setSize, setSize
getBriefDescription, getHeader, getLongDescription, getObject, getObjectValue, getTextEncoding, isSubsetOf, iterator, setHeader, setObjectValue, setTextEncoding, toString
protected AbstractFrameBodyTextInfo()
protected AbstractFrameBodyTextInfo(AbstractFrameBodyTextInfo body)
body
- AbstractFrameBodyTextInformationprotected AbstractFrameBodyTextInfo(byte textEncoding, String text)
textEncoding
- Specifies what encoding should be used to write
text to file.text
- Specifies the text String.protected AbstractFrameBodyTextInfo(ByteBuffer byteBuffer, int frameSize) throws InvalidTagException
The super.super Constructor sets up the Object list for the frame.
byteBuffer
- frameSize
- InvalidTagException
- if unable to create framebody from bufferpublic void setText(String text)
If this String contains null terminator characters these are parsed as value separators, allowing you to hold multiple strings within one text frame. This functionality is only officially support in ID3v24.
text
- to setpublic String getUserFriendlyValue()
getUserFriendlyValue
in class AbstractTagFrameBody
public String getText()
public String getTextWithoutTrailingNulls()
public String getFirstTextValue()
public String getValueAtIndex(int index)
index
- public void addTextValue(String value)
value
- at indexpublic int getNumberOfValues()
public void write(ByteArrayOutputStream tagBuffer)
write
in class AbstractID3v2FrameBody
protected void setupObjectList()
setupObjectList
in class AbstractTagFrameBody
Copyright © 2005–2020 jthink.net. All rights reserved.