pub enum AdapterPolicy {
Manual,
AutoObjectScalar(AutoObjectScalar),
Custom(&'static str),
Object {
kind: Option<&'static str>,
operation: ObjectOperation,
native: Option<&'static str>,
},
Create(&'static str),
}Variants§
Manual
Existing handwritten dispatch arm; used until it is migrated.
AutoObjectScalar(AutoObjectScalar)
Generated scalar call. Object arguments are explicitly guest handles.
Custom(&'static str)
Generated dispatch arm calls this named handwritten adapter.
Object
Generated call on one object of an optional kind (None: any object).
The native function is called through a shared helper per operation.
Fields
§
operation: ObjectOperationCreate(&'static str)
Generated constructor: the native (parent) -> object function plus the
kind the new object is registered under.
Trait Implementations§
Source§impl Clone for AdapterPolicy
impl Clone for AdapterPolicy
Source§fn clone(&self) -> AdapterPolicy
fn clone(&self) -> AdapterPolicy
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for AdapterPolicy
impl Debug for AdapterPolicy
Source§impl PartialEq for AdapterPolicy
impl PartialEq for AdapterPolicy
Source§fn eq(&self, other: &AdapterPolicy) -> bool
fn eq(&self, other: &AdapterPolicy) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Copy for AdapterPolicy
impl Eq for AdapterPolicy
impl StructuralPartialEq for AdapterPolicy
Auto Trait Implementations§
impl Freeze for AdapterPolicy
impl RefUnwindSafe for AdapterPolicy
impl Send for AdapterPolicy
impl Sync for AdapterPolicy
impl Unpin for AdapterPolicy
impl UnsafeUnpin for AdapterPolicy
impl UnwindSafe for AdapterPolicy
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more