Package com.wowza.wms.dvr
Class DvrManifestEntry
- Object
-
- com.wowza.wms.dvr.DvrManifestEntry
-
- Direct Known Subclasses:
DvrManifestChunkEntry
,DvrManifestCodecEntry
,DvrManifestOnMetadataEntry
,DvrManifestTimeMapEntry
public abstract class DvrManifestEntry extends Object
Abstract class representing entry in DVR manifest.
-
-
Field Summary
Fields Modifier and Type Field Description protected long
dvrStart
protected long
dvrStop
protected long
index
static String
MANIFESTFILE_KEY_ARTIFACT
static String
MANIFESTFILE_KEY_AUDIO_CODEC
static String
MANIFESTFILE_KEY_CHUNKINDEX
static String
MANIFESTFILE_KEY_DVRTIME
static String
MANIFESTFILE_KEY_ENCRYPTIONS
static String
MANIFESTFILE_KEY_INDEX
static String
MANIFESTFILE_KEY_METADATA
static String
MANIFESTFILE_KEY_NAME
static String
MANIFESTFILE_KEY_PACKETTIME
static String
MANIFESTFILE_KEY_SIZE
static String
MANIFESTFILE_KEY_START
static String
MANIFESTFILE_KEY_STOP
static String
MANIFESTFILE_KEY_TYPE
static String
MANIFESTFILE_KEY_UTCTIME
static String
MANIFESTFILE_KEY_VIDEO_CODEC
protected long
packetTime
protected static byte
SERIALIZE_CURRENT_VERSION
protected int
type
protected long
utcTime
-
Constructor Summary
Constructors Constructor Description DvrManifestEntry(int type, long index, long dvrStart, long dvrStop, long packetTime, long utcTime)
Constructor Valid types include:IVHost.CONTENTTYPE_AUDIO
,IVHost.CONTENTTYPE_VIDEO
,IVHost.CONTENTTYPE_DATA
,IDvrManifest.ON_METADATA_TYPE
,IDvrManifest.CODEC_TYPE
, orIDvrManifest.TIME_MAP_TYPE
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected String
encodeBytes(byte[] bytes)
Encode string of bytes as Base64.protected String
getCommonInitialTextRepString()
long
getDuration()
Get durationlong
getIndex()
Get manifest index.abstract String
getManifestRepresentation()
Get textual representation of record for textual manifest usage.long
getPacketStartTime()
Get chunk start timecode in packetTime units.long
getStartTimecode()
Get start timecode.long
getStopTimecode()
Get stop timecode.int
getType()
Get type of manifest record.long
getUtcStartTime()
Get chunk start timecode in UTC units.long
getUTCStartTime()
byte[]
serialize()
Serialize manifest record.abstract void
serialize(java.io.DataOutputStream out)
Serialize manifest record.
-
-
-
Field Detail
-
MANIFESTFILE_KEY_INDEX
public static final String MANIFESTFILE_KEY_INDEX
- See Also:
- Constant Field Values
-
MANIFESTFILE_KEY_TYPE
public static final String MANIFESTFILE_KEY_TYPE
- See Also:
- Constant Field Values
-
MANIFESTFILE_KEY_START
public static final String MANIFESTFILE_KEY_START
- See Also:
- Constant Field Values
-
MANIFESTFILE_KEY_STOP
public static final String MANIFESTFILE_KEY_STOP
- See Also:
- Constant Field Values
-
MANIFESTFILE_KEY_SIZE
public static final String MANIFESTFILE_KEY_SIZE
- See Also:
- Constant Field Values
-
MANIFESTFILE_KEY_ARTIFACT
public static final String MANIFESTFILE_KEY_ARTIFACT
- See Also:
- Constant Field Values
-
MANIFESTFILE_KEY_DVRTIME
public static final String MANIFESTFILE_KEY_DVRTIME
- See Also:
- Constant Field Values
-
MANIFESTFILE_KEY_CHUNKINDEX
public static final String MANIFESTFILE_KEY_CHUNKINDEX
- See Also:
- Constant Field Values
-
MANIFESTFILE_KEY_PACKETTIME
public static final String MANIFESTFILE_KEY_PACKETTIME
- See Also:
- Constant Field Values
-
MANIFESTFILE_KEY_UTCTIME
public static final String MANIFESTFILE_KEY_UTCTIME
- See Also:
- Constant Field Values
-
MANIFESTFILE_KEY_NAME
public static final String MANIFESTFILE_KEY_NAME
- See Also:
- Constant Field Values
-
MANIFESTFILE_KEY_AUDIO_CODEC
public static final String MANIFESTFILE_KEY_AUDIO_CODEC
- See Also:
- Constant Field Values
-
MANIFESTFILE_KEY_VIDEO_CODEC
public static final String MANIFESTFILE_KEY_VIDEO_CODEC
- See Also:
- Constant Field Values
-
MANIFESTFILE_KEY_ENCRYPTIONS
public static final String MANIFESTFILE_KEY_ENCRYPTIONS
- See Also:
- Constant Field Values
-
MANIFESTFILE_KEY_METADATA
public static final String MANIFESTFILE_KEY_METADATA
- See Also:
- Constant Field Values
-
SERIALIZE_CURRENT_VERSION
protected static final byte SERIALIZE_CURRENT_VERSION
- See Also:
- Constant Field Values
-
dvrStart
protected long dvrStart
-
dvrStop
protected long dvrStop
-
packetTime
protected long packetTime
-
utcTime
protected long utcTime
-
index
protected long index
-
type
protected int type
-
-
Constructor Detail
-
DvrManifestEntry
public DvrManifestEntry(int type, long index, long dvrStart, long dvrStop, long packetTime, long utcTime)
Constructor Valid types include:IVHost.CONTENTTYPE_AUDIO
,IVHost.CONTENTTYPE_VIDEO
,IVHost.CONTENTTYPE_DATA
,IDvrManifest.ON_METADATA_TYPE
,IDvrManifest.CODEC_TYPE
, orIDvrManifest.TIME_MAP_TYPE
- Parameters:
type
- typeindex
- manifest indexdvrStart
- start time (ms in DVR time scale)dvrStop
- stop time (ms in DVR time scale)packetTime
-utcTime
-
-
-
Method Detail
-
getStartTimecode
public long getStartTimecode()
Get start timecode. In milliseconds, DVR time base.- Returns:
- start time
-
getStopTimecode
public long getStopTimecode()
Get stop timecode. In milliseconds, DVR time base.- Returns:
- stop time
-
getPacketStartTime
public long getPacketStartTime()
Get chunk start timecode in packetTime units. In milliseconds.- Returns:
- packet start time
-
getUtcStartTime
public long getUtcStartTime()
Get chunk start timecode in UTC units. In milliseconds.- Returns:
- UTC start time
-
getDuration
public long getDuration()
Get duration- Returns:
- duration in ms
-
getType
public int getType()
Get type of manifest record. Valid types include:IVHost.CONTENTTYPE_AUDIO
,IVHost.CONTENTTYPE_VIDEO
,IVHost.CONTENTTYPE_DATA
,IDvrManifest.ON_METADATA_TYPE
,IDvrManifest.CODEC_TYPE
, orIDvrManifest.TIME_MAP_TYPE
- Returns:
- type
-
getIndex
public long getIndex()
Get manifest index.- Returns:
- index
-
getUTCStartTime
public long getUTCStartTime()
-
serialize
public abstract void serialize(java.io.DataOutputStream out)
Serialize manifest record.- Parameters:
out
- output stream
-
serialize
public byte[] serialize()
Serialize manifest record.- Returns:
- serialized data
-
getManifestRepresentation
public abstract String getManifestRepresentation()
Get textual representation of record for textual manifest usage.- Returns:
- textual representation of entry
-
getCommonInitialTextRepString
protected String getCommonInitialTextRepString()
-
encodeBytes
protected String encodeBytes(byte[] bytes)
Encode string of bytes as Base64. Provides check for null buffer or empty buffer.- Parameters:
bytes
- buffer to encode.- Returns:
- Base64 encoding or "".
-
-