Re: [Rd] Discussion starter for package level Connection API

2006-10-09 Thread Jeffrey Horner
Here's a function to create new connections. It returns and SEXP that can be returned to R code, but before that, the user can set up all the function pointer members via passing in the address of an Rconnection. Here's how you'd call it: SEXP newcon; Rconnection conptr; newcon = R_NewConnecti

[Rd] Discussion starter for package level Connection API

2006-10-09 Thread Jeffrey Horner
Thought I'd try and start a discussion. Feel free to jump in. I guess R needs to strike the right balance between opening up the internals to package writers and not allowing them to do bad things. My first attempt at cracking this nut is to just memcpy() the Rconnection and not allow access to