pub fn generate_r6_r_wrapper(parsed_impl: &ParsedImpl) -> StringExpand description
Generates the complete R wrapper string for an R6-style class.
Produces an R6::R6Class(...) core definition followed by per-method
$set() blocks (see the module docs for the full $set-form shape, #369):
initializemethod (inline inpublic): calls the Rustnewconstructor, or accepts a pre-made.ptrwhen static methods returnSelf(factory pattern)- Public methods: one
ClassName$set("public", "name", function(...) {...})block per&self/&mut selfinstance method, each with its own roxygen - Private methods (inline in
private): methods marked with#[miniextendr(private)] - Active bindings: one
ClassName$set("active", "name", function(...) {...})block per getter/setter property (#[miniextendr(r6(prop = "..."))]) - Private
.ptrfield: holds theExternalPtrto the Rust struct - Finalizer (inline in
private): optional destructor called when the R6 object is garbage-collected - Deep clone (inline in
private): optional custom clone logic via#[miniextendr(r6(deep_clone))] - Static methods: emitted as
ClassName$method_name <- function(...)outside the class - Class options:
lock_objects,lock_class,cloneable,portable,inherit
Also generates roxygen2 documentation blocks for the class, its methods, and active bindings.