[Mono-list] CSharpCodeProvider

Atsushi Eno atsushi at ximian.com
Mon Mar 13 05:55:42 EST 2006


Hi,

Aaron Oxford wrote:
> Perhaps the title of my post was misleading. I am not sure of the 
> details myself. Using Microsoft's gear under Windows, I can take a 
> string that contains a C# class and produce a class at runtime. I can go 
> straight from a string of code to an object that extends a base class in 
> my main project and then use it as if it were compiled with the main code.

That is what we (we, including you ;-) call CSharpCodeProvider I think
aka Microsoft.CSharp.CSharpCodeProvider. It is only about "managed code"
world Its feature at least at the point of .NET 1.x has long been
supported by Mono.

(Or your friend might have talked about MS Managed C++ which is not
part of Mono.)

> Are you saying that I could perhaps compile a .SO file and read it back 
> in as an assembly as a work-around for Mono/Linux? I'm going to 
> modularise the project to allow rewriting of platform/devenv dependent 
> parts such as sound and GUI so if there is a simple workaround that will 
> be more than sufficient.

No... for such need you can use DllImport to invoke functions from *.so:
http://www.mono-project.com/Interop_with_Native_Libraries

Atsushi Eno


More information about the Mono-list mailing list