IcyHeaders
@UnstableApi
public final class IcyHeaders implements Metadata.Entry
ICY headers.
Summary
Constants |
|
|---|---|
static final String |
REQUEST_HEADER_ENABLE_METADATA_NAME = "Icy-MetaData" |
static final String |
Public fields |
|
|---|---|
final int |
Bitrate in bits per second ( |
final @Nullable String |
The genre ( |
final boolean |
Whether the radio station is listed ( |
final int |
The interval in bytes between metadata chunks ( |
final @Nullable String |
The stream name ( |
final @Nullable String |
The URL of the radio station ( |
Public constructors |
|---|
Public methods |
|
|---|---|
boolean |
|
int |
hashCode() |
static @Nullable IcyHeaders |
Parses |
void |
Updates the |
String |
toString() |
Inherited methods |
||||
|---|---|---|---|---|
|
Constants
REQUEST_HEADER_ENABLE_METADATA_NAME
public static final String REQUEST_HEADER_ENABLE_METADATA_NAME = "Icy-MetaData"
REQUEST_HEADER_ENABLE_METADATA_VALUE
public static final String REQUEST_HEADER_ENABLE_METADATA_VALUE = "1"
Public fields
bitrate
public final int bitrate
Bitrate in bits per second ((icy-br * 1000)), or NO_VALUE if the header was not present.
isPublic
public final boolean isPublic
Whether the radio station is listed (icy-pub), or false if the header was not present.
metadataInterval
public final int metadataInterval
The interval in bytes between metadata chunks (icy-metaint), or LENGTH_UNSET if the header was not present.
Public constructors
Public methods
parse
public static @Nullable IcyHeaders parse(Map<String, List<String>> responseHeaders)
Parses IcyHeaders from response headers.
| Returns | |
|---|---|
@Nullable IcyHeaders |
The parsed |
populateMediaMetadata
public void populateMediaMetadata(MediaMetadata.Builder builder)
Updates the MediaMetadata.Builder with the type-specific values stored in this
Entry.
| Parameters | |
|---|---|
MediaMetadata.Builder builder |
The builder to be updated. |