Search code examples
c#rubyobjectmoduleironruby

How to register a module to ruby?


How do I register a module to ruby with IronRuby and C#?


Solution

  • Do you mean using IronRuby from C# or C# from IronRuby?

    C# from IronRuby is easy(with some caveats)

    require 'C:/.../my_awesome_class.dll'
    MyAwesomeClass.do_something
    

    calling IronRuby from C# is more complicated, and you probably want to look at the docs for hosting ironruby.

    The IronRuby .Net docs are a good place to get started.