public final class ContentBranding extends MetadataContainer
Modifier and Type | Field and Description |
---|---|
static java.util.Set<java.lang.String> |
ALLOWED
Stores the allowed descriptor
keys.
|
static java.lang.String |
KEY_BANNER_IMAGE
Descriptor key representing the banner image.
|
static java.lang.String |
KEY_BANNER_TYPE
Descriptor key representing the banner image type.
Known/valid values are: 0: there is no image present 1: there is a BMP image 2: there is a JPEG image 3: there is a GIF image |
static java.lang.String |
KEY_BANNER_URL
Descriptor key representing the banner image URL.
|
static java.lang.String |
KEY_COPYRIGHT_URL
Descriptor key representing the copyright URL.
|
chunkLength, guid, position
Constructor and Description |
---|
ContentBranding()
Creates an instance.
|
ContentBranding(long pos,
java.math.BigInteger size)
Creates an instance.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getBannerImageURL()
Returns the banner image URL.
|
java.lang.String |
getCopyRightURL()
Returns the copyright URL.
|
long |
getCurrentAsfChunkSize()
This method calculates the total amount of bytes, the chunk would consume
in an ASF file.
|
byte[] |
getImageData()
Returns the binary image data.
|
long |
getImageType()
Returns the image type.
|
boolean |
isAddSupported(MetadataDescriptor descriptor)
Determines/checks if the given descriptor may be added to the container.
This implies a check for the capabilities of the container specified by its container type. |
void |
setBannerImageURL(java.lang.String imageURL)
This method sets the banner image URL, if
imageURL is not
blank. |
void |
setCopyRightURL(java.lang.String copyRight)
This method sets the copyright URL, if
copyRight is not
blank. |
void |
setImage(long imageType,
byte[] imageData) |
long |
writeInto(java.io.OutputStream out)
Writes the chunk into the specified output stream, as ASF stream chunk.
|
addDescriptor, assertDescriptor, assertDescriptor, containsDescriptor, getContainerType, getDescriptorCount, getDescriptors, getDescriptorsByName, getValueFor, hasDescriptor, isEmpty, prettyPrint, removeDescriptorsByName, setStringValue
getChunckEnd, getChunkEnd, getChunkLength, getGuid, getPosition, setPosition, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getGuid
public static final java.util.Set<java.lang.String> ALLOWED
public static final java.lang.String KEY_BANNER_IMAGE
public static final java.lang.String KEY_BANNER_TYPE
public static final java.lang.String KEY_BANNER_URL
public static final java.lang.String KEY_COPYRIGHT_URL
public ContentBranding()
public ContentBranding(long pos, java.math.BigInteger size)
pos
- Position of content description within file or streamsize
- Length of content description.public java.lang.String getBannerImageURL()
public java.lang.String getCopyRightURL()
public long getCurrentAsfChunkSize()
getCurrentAsfChunkSize
in interface WriteableChunk
getCurrentAsfChunkSize
in class MetadataContainer
public byte[] getImageData()
public long getImageType()
for known/valid values.
public boolean isAddSupported(MetadataDescriptor descriptor)
isAddSupported
in class MetadataContainer
descriptor
- the descriptor to test.true
if MetadataContainer.addDescriptor(MetadataDescriptor)
can be called with given descriptor.public void setBannerImageURL(java.lang.String imageURL)
imageURL
is not
blank.imageURL
- image URL to set.public void setCopyRightURL(java.lang.String copyRight)
copyRight
is not
blank.copyRight
- copyright URL to set.public void setImage(long imageType, byte[] imageData)
imageType
- imageData
- public long writeInto(java.io.OutputStream out) throws java.io.IOException
writeInto
in interface WriteableChunk
writeInto
in class MetadataContainer
out
- stream to write into.java.io.IOException
- on I/O errorsCopyright © 2005-2013 java.net. All Rights Reserved.