pub struct RBackend { /* private fields */ }Expand description
Backend state for emitting R source code.
Implementations§
Source§impl RBackend
impl RBackend
Sourcepub fn take_output(&mut self) -> String
pub fn take_output(&mut self) -> String
Take the accumulated output, resetting the buffer.
Sourcepub fn register_vectorized(&mut self, name: &str, op: VectorizedOp)
pub fn register_vectorized(&mut self, name: &str, op: VectorizedOp)
Register a vectorized operation.
Sourcepub fn emit_function(&mut self, fun: &RFunction)
pub fn emit_function(&mut self, fun: &RFunction)
Emit an R function definition.
Sourcepub fn emit_expr(&mut self, expr: &RExpr) -> String
pub fn emit_expr(&mut self, expr: &RExpr) -> String
Emit an R expression to a string (may use output buffer for nested stmts).
Sourcepub fn emit_expr_pure(&self, expr: &RExpr) -> String
pub fn emit_expr_pure(&self, expr: &RExpr) -> String
Emit an R expression to a string (pure, no side-effects on buffer).
Sourcepub fn emit_vectorized(
&self,
op: &VectorizedOp,
vec_expr: &RExpr,
extra_args: &[RArg],
) -> String
pub fn emit_vectorized( &self, op: &VectorizedOp, vec_expr: &RExpr, extra_args: &[RArg], ) -> String
Emit a vectorized operation over a vector expression.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for RBackend
impl RefUnwindSafe for RBackend
impl Send for RBackend
impl Sync for RBackend
impl Unpin for RBackend
impl UnsafeUnpin for RBackend
impl UnwindSafe for RBackend
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