MP7Time Class Reference
This class represents an MPEG-7 time value. More...
#include <MP7Time.hpp>
Public Member Functions | |
MP7Time () | |
Default constructor. | |
bool | setTimePoint (uint value, uint ticksPerSecond=1) |
Set time point from a tick value. | |
bool | setTimePoint (const char *mp7Value) |
Set time point from the MPEG-7 representation. | |
bool | setTimePoint (const MP7Time &otherTime) |
Copy time point from other MP7Time value. | |
bool | moveTimePoint (int value, uint ticksPerSecond) |
Move time point by the given number of ticks. | |
bool | setDuration (uint value, uint ticks) |
Set duration from a tick value. | |
bool | setDuration (const char *mp7Value) |
Set duration from the MPEG-7 representation. | |
bool | setDuration (const MP7Time &duration) |
Set duration from another MP7Time instance. | |
bool | setDurationFromEnd (const MP7Time &end) |
Set the duration according to this object's time point and the given end time point. | |
bool | addDuration (const MP7Time &otherTime) |
Add the duration of otherTime . | |
const char * | timePointPretty (bool forceSubSec=false) const |
Pretty-print time point. | |
const char * | durationPretty () const |
Pretty-print duration. | |
MP7Time | endTimePoint () const |
Return end time point (time point + duration) of this interval. | |
const char * | endTimePointPretty (bool forceSubSec=false) const |
Pretty-print end time point (time point + duration). | |
const char * | toString () const |
Pretty-print time and duration. | |
const char * | timePointMP7 () const |
Return MPEG-7 representation of time point. | |
const char * | durationMP7 () const |
Return MPEG-7 representation of duration. | |
double | timeToSec () const |
Return time point in seconds. | |
int | timeToMSec () const |
Return time point in milliseconds. | |
int | durationToMSec () const |
Return duration in milliseconds. | |
double | durationToSec () const |
Return duration in seconds. | |
bool | timePointIsValid () const |
Return true if the time point is valid, i.e. | |
bool | durationIsNull () const |
Return true if the duration is 0. | |
int | compareTimePoint (const MP7Time &other) const |
Compare this time point to another one. | |
bool | contains (const MP7Time &time) const |
Return true if this interval contains the given time point or interval. |
Detailed Description
This class represents an MPEG-7 time value.It may denote a time point or a time interval. Note that this class may also represent media time.
- Author:
- Mario Taschwer
- Version:
- Id
- MP7Time.hpp,v 1.4 2005/01/14 12:01:19 mkropfbe Exp
Definition at line 57 of file MP7Time.hpp.
Constructor & Destructor Documentation
|
Default constructor. Initializes to time point 0 with duration 0. Definition at line 53 of file MP7Time.cpp.
|
Member Function Documentation
|
Add the duration of This function supports non-negative durations only. If one of the operands has a negative duration, an error status is returned.
References duration.
|
|
Compare this time point to another one. An invalid time point is considered to be earlier than any valid time point. Two invalid time points are considered to be equal. Note: The date part and time zone of the operands are currently ignored.
References tpoint. Referenced by contains(), and setDurationFromEnd().
|
|
Return MPEG-7 representation of duration. If the duration is an IncrDuration type, only the timeUnit will be returned.
|
|
Pretty-print duration.
Referenced by toString().
|
|
Return end time point (time point + duration) of this interval. Note: This method currently ignores the date and time-zone parts of an MP7Time instance. Definition at line 472 of file MP7Time.cpp. References tpoint. Referenced by contains(), and endTimePointPretty().
|
|
Pretty-print end time point (time point + duration). Note: This method currently ignores the date and time-zone parts of an MP7Time instance.
References endTimePoint(), and timePointPretty().
|
|
Move time point by the given number of ticks. If the resulting time point would be negative, this time point is reset to 0 and an error status is returned. The date part and time zone of this object are ignored.
|
|
Set duration from another MP7Time instance. The time point value remains unchanged.
References duration.
|
|
Set duration from the MPEG-7 representation.
References MP7TIME_TZ_LEN.
|
|
Set duration from a tick value.
|
|
Set the duration according to this object's time point and the given end time point. Note: This function currently ignores the date part and time zone of the operands.
References compareTimePoint(), duration, and tpoint.
|
|
Copy time point from other MP7Time value. The duration value is not modified.
References tpoint.
|
|
Set time point from the MPEG-7 representation.
References MP7TIME_DATE_LEN, and MP7TIME_TZ_LEN.
|
|
Set time point from a tick value.
|
|
Return it has been set before. Definition at line 724 of file MP7Time.cpp.
|
|
Return MPEG-7 representation of time point.
|
|
Pretty-print time point.
A fresh object returns
Referenced by endTimePointPretty(), and toString().
|
|
Return time point in milliseconds. The date and time zone parts of this instance are ignored. Definition at line 690 of file MP7Time.cpp.
|
|
Return time point in seconds. The date and time zone parts of this instance are ignored. Definition at line 680 of file MP7Time.cpp.
|
|
Pretty-print time and duration.
References durationPretty(), and timePointPretty().
|
The documentation for this class was generated from the following files: