1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62
// This file was generated by gir (https://github.com/gtk-rs/gir)
// from gir-files (https://github.com/gtk-rs/gir-files)
// from gst-gir-files (https://gitlab.freedesktop.org/gstreamer/gir-files-rs.git)
// DO NOT EDIT
use crate::{ffi, ReportLevel};
use glib::translate::*;
glib::wrapper! {
#[derive(Debug, PartialEq, Eq, PartialOrd, Ord, Hash)]
pub struct Issue(Boxed<ffi::GstValidateIssue>);
match fn {
copy => |ptr| glib::gobject_ffi::g_boxed_copy(ffi::gst_validate_issue_get_type(), ptr as *mut _) as *mut ffi::GstValidateIssue,
free => |ptr| glib::gobject_ffi::g_boxed_free(ffi::gst_validate_issue_get_type(), ptr as *mut _),
type_ => || ffi::gst_validate_issue_get_type(),
}
}
impl Issue {
//#[doc(alias = "gst_validate_issue_new")]
//pub fn new(issue_id: /*Ignored*/IssueId, summary: &str, description: &str, default_level: ReportLevel) -> Issue {
// unsafe { TODO: call ffi:gst_validate_issue_new() }
//}
//#[doc(alias = "gst_validate_issue_new_full")]
//pub fn new_full(issue_id: /*Ignored*/IssueId, summary: &str, description: &str, default_level: ReportLevel, flags: IssueFlags) -> Issue {
// unsafe { TODO: call ffi:gst_validate_issue_new_full() }
//}
#[doc(alias = "gst_validate_issue_get_id")]
#[doc(alias = "get_id")]
pub fn id(&mut self) -> u32 {
unsafe { ffi::gst_validate_issue_get_id(self.to_glib_none_mut().0) }
}
/// Registers `self` in the issue type system
#[doc(alias = "gst_validate_issue_register")]
pub fn register(&mut self) {
unsafe {
ffi::gst_validate_issue_register(self.to_glib_none_mut().0);
}
}
#[doc(alias = "gst_validate_issue_set_default_level")]
pub fn set_default_level(&mut self, default_level: ReportLevel) {
unsafe {
ffi::gst_validate_issue_set_default_level(
self.to_glib_none_mut().0,
default_level.into_glib(),
);
}
}
//#[doc(alias = "gst_validate_issue_from_id")]
//pub fn from_id(issue_id: /*Ignored*/IssueId) -> Option<Issue> {
// unsafe { TODO: call ffi:gst_validate_issue_from_id() }
//}
}
unsafe impl Send for Issue {}
unsafe impl Sync for Issue {}