mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer-rs.git
synced 2024-11-22 17:41:05 +00:00
Toc: implement Debug trait
This commit is contained in:
parent
f92f0a99e8
commit
84e4546f72
1 changed files with 26 additions and 0 deletions
|
@ -7,6 +7,7 @@
|
|||
// except according to those terms.
|
||||
|
||||
use std::ffi::CStr;
|
||||
use std::fmt;
|
||||
use std::mem;
|
||||
|
||||
use ffi;
|
||||
|
@ -99,6 +100,16 @@ impl ToOwned for TocRef {
|
|||
}
|
||||
}
|
||||
|
||||
impl fmt::Debug for TocRef {
|
||||
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
|
||||
f.debug_struct("Toc")
|
||||
.field("scope", &self.get_scope())
|
||||
.field("tags", &self.get_tags())
|
||||
.field("entries", &self.get_entries())
|
||||
.finish()
|
||||
}
|
||||
}
|
||||
|
||||
unsafe impl Sync for TocRef {}
|
||||
unsafe impl Send for TocRef {}
|
||||
|
||||
|
@ -237,6 +248,21 @@ impl ToOwned for TocEntryRef {
|
|||
}
|
||||
}
|
||||
|
||||
impl fmt::Debug for TocEntryRef {
|
||||
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
|
||||
f.debug_struct("TocEntry")
|
||||
.field("entry_type", &self.get_entry_type())
|
||||
.field("uid", &self.get_uid())
|
||||
.field("start_stop", &self.get_start_stop_times())
|
||||
.field("tags", &self.get_tags())
|
||||
.field("is_alternative", &self.is_alternative())
|
||||
.field("is_sequence", &self.is_sequence())
|
||||
.field("loop", &self.get_loop())
|
||||
.field("sub_entries", &self.get_sub_entries())
|
||||
.finish()
|
||||
}
|
||||
}
|
||||
|
||||
unsafe impl Sync for TocEntryRef {}
|
||||
unsafe impl Send for TocEntryRef {}
|
||||
|
||||
|
|
Loading…
Reference in a new issue