Struct gluon_vm::api::OpaqueValue
[−]
[src]
pub struct OpaqueValue<T, V>(_, _) where T: Deref<Target=Thread>;
Type which represents an array in gluon
Type implementing both Pushable
and Getable
of values of V
.
The actual value, V
is not accessible directly but is only intended to be transferred between
two different threads.
Methods
impl<T, V> OpaqueValue<T, V> where T: Deref<Target=Thread>
[src]
Trait Implementations
impl<T, V> Debug for OpaqueValue<T, V> where T: Deref<Target=Thread>
[src]
impl<T, V> Clone for OpaqueValue<T, V> where T: Deref<Target=Thread> + Clone
[src]
fn clone(&self) -> Self
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl<T, V> VmType for OpaqueValue<T, V> where T: Deref<Target=Thread>,
V: VmType,
V::Type: Sized
[src]
V: VmType,
V::Type: Sized
type Type = V::Type
A version of Self
which implements Any
allowing a TypeId
to be retrieved
fn make_type(vm: &Thread) -> ArcType
Creates an gluon type which maps to Self
in rust
fn extra_args() -> VmIndex
How many extra arguments a function returning this type requires. Used for abstract types which when used in return position should act like they still need more arguments before they are called Read more
impl<'vm, T, V> Pushable<'vm> for OpaqueValue<T, V> where T: Deref<Target=Thread>,
V: VmType,
V::Type: Sized
[src]
V: VmType,
V::Type: Sized
fn push(self, thread: &'vm Thread, context: &mut Context) -> Result<()>
Pushes self
to stack
. If the call is successful a single element should have been added to the stack and Ok(())
should be returned. If the call is unsuccessful Status:Error
should be returned and the stack should be left intact Read more
impl<'vm, V> Getable<'vm> for OpaqueValue<&'vm Thread, V>
[src]
fn from_value(vm: &'vm Thread,
value: Variants)
-> Option<OpaqueValue<&'vm Thread, V>>
value: Variants)
-> Option<OpaqueValue<&'vm Thread, V>>
unsafe fn from_value_unsafe(vm: &'vm Thread, value: Variants) -> Option<Self>
unsafe version of from_value which allows references to the internal of GcPtr's to be extracted if value
is rooted Read more
impl<'vm, V> Getable<'vm> for OpaqueValue<RootedThread, V>
[src]
fn from_value(vm: &'vm Thread,
value: Variants)
-> Option<OpaqueValue<RootedThread, V>>
value: Variants)
-> Option<OpaqueValue<RootedThread, V>>
unsafe fn from_value_unsafe(vm: &'vm Thread, value: Variants) -> Option<Self>
unsafe version of from_value which allows references to the internal of GcPtr's to be extracted if value
is rooted Read more