Trait glib::translate::FromGlibPtrFull [−][src]
pub trait FromGlibPtrFull<P: Ptr>: Sized { unsafe fn from_glib_full(ptr: P) -> Self; }
Expand description
Translate from a pointer type which is annotated with transfer full
.
This transfers the ownership of the value to the Rust side.
Because ownership can only be transferred if something is already referenced, this is unsuitable for floating references.
Safety
The implementation of this trait should not alter the reference count
or make copies of the underlying value.
Values obtained using this trait must be properly released on drop()
by the implementing type.
For more information, refer to module level documentation.
Required methods
unsafe fn from_glib_full(ptr: P) -> Self
unsafe fn from_glib_full(ptr: P) -> Self
Safety
See trait level notes on safety
Implementations on Foreign Types
Implementors
impl FromGlibPtrFull<*mut cairo_t> for Context
impl FromGlibPtrFull<*mut cairo_t> for Context
impl FromGlibPtrFull<*mut cairo_device_t> for Device
impl FromGlibPtrFull<*mut cairo_device_t> for Device
impl FromGlibPtrFull<*mut cairo_surface_t> for ImageSurface
impl FromGlibPtrFull<*mut cairo_surface_t> for ImageSurface
impl FromGlibPtrFull<*mut cairo_surface_t> for RecordingSurface
impl FromGlibPtrFull<*mut cairo_surface_t> for RecordingSurface
impl FromGlibPtrFull<*mut cairo_surface_t> for Surface
impl FromGlibPtrFull<*mut cairo_surface_t> for Surface
impl FromGlibPtrFull<*mut xcb_connection_t> for XCBConnection
impl FromGlibPtrFull<*mut xcb_connection_t> for XCBConnection
impl FromGlibPtrFull<*mut xcb_render_pictforminfo_t> for XCBRenderPictFormInfo
impl FromGlibPtrFull<*mut xcb_render_pictforminfo_t> for XCBRenderPictFormInfo
impl FromGlibPtrFull<*mut xcb_screen_t> for XCBScreen
impl FromGlibPtrFull<*mut xcb_screen_t> for XCBScreen
impl FromGlibPtrFull<*mut cairo_surface_t> for XCBSurface
impl FromGlibPtrFull<*mut cairo_surface_t> for XCBSurface
impl FromGlibPtrFull<*mut xcb_visualtype_t> for XCBVisualType
impl FromGlibPtrFull<*mut xcb_visualtype_t> for XCBVisualType
impl FromGlibPtrFull<*mut cairo_surface_t> for PdfSurface
impl FromGlibPtrFull<*mut cairo_surface_t> for PdfSurface
impl FromGlibPtrFull<*mut cairo_surface_t> for PsSurface
impl FromGlibPtrFull<*mut cairo_surface_t> for PsSurface
impl FromGlibPtrFull<*mut cairo_surface_t> for SvgSurface
impl FromGlibPtrFull<*mut cairo_surface_t> for SvgSurface
impl FromGlibPtrFull<*mut cairo_surface_t> for QuartzSurface
impl FromGlibPtrFull<*mut cairo_surface_t> for QuartzSurface
impl FromGlibPtrFull<*mut cairo_surface_t> for Win32Surface
impl FromGlibPtrFull<*mut cairo_surface_t> for Win32Surface