Enum querent_synapse::cross::CLRepr
source · pub enum CLRepr {
String(String, StringType),
Bool(bool),
Float(f64),
Int(i64),
Tuple(Vec<CLRepr>),
Array(Vec<CLRepr>),
Object(CLReprObject),
PythonRef(PythonRef),
Null,
}
Expand description
Cross language representation is abstraction to transfer values between JavaScript and Python across Rust. Converting between two different languages requires to use Context which is available on the call (one for python and one for js), which result as blocking.
Variants§
String(String, StringType)
Bool(bool)
Float(f64)
Int(i64)
Tuple(Vec<CLRepr>)
Array(Vec<CLRepr>)
Object(CLReprObject)
PythonRef(PythonRef)
Null
Implementations§
source§impl CLRepr
impl CLRepr
pub fn is_null(&self) -> bool
pub fn downcast_to_object(self) -> CLReprObject
pub fn kind(&self) -> CLReprKind
Trait Implementations§
Auto Trait Implementations§
impl Freeze for CLRepr
impl !RefUnwindSafe for CLRepr
impl Send for CLRepr
impl Sync for CLRepr
impl Unpin for CLRepr
impl UnwindSafe for CLRepr
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