Struct janus_plugin::session::SessionWrapper
[−]
[src]
pub struct SessionWrapper<T> {
pub handle: *mut PluginSession,
// some fields omitted
}A wrapper for a Janus session. Contains a pointer to the Janus PluginSession (which is used to identify this session in the Janus FFI) and any Rust state associated with the session.
Fields
handle: *mut PluginSession
Methods
impl<T> SessionWrapper<T>[src]
fn associate(
handle: *mut PluginSession,
state: T
) -> Result<Box<Arc<Self>>, NullHandleError>[src]
handle: *mut PluginSession,
state: T
) -> Result<Box<Arc<Self>>, NullHandleError>
Allocates a boxed, reference-counted state wrapper associated with a Janus PluginSession (whose plugin_handle will then point to the contents of the box).
fn from_ptr<'a>(
handle: *mut PluginSession
) -> Result<Arc<Self>, NullHandleError>[src]
handle: *mut PluginSession
) -> Result<Arc<Self>, NullHandleError>
Retrieves and clones the reference-counted state wrapper associated with a Janus PluginSession.
Trait Implementations
impl<T: Debug> Debug for SessionWrapper<T>[src]
impl<T> Deref for SessionWrapper<T>[src]
type Target = T
The resulting type after dereferencing.
fn deref(&self) -> &T[src]
Dereferences the value.