# Extension methods etc

**URL:** <https://www.ruby-forum.com/t/extension-methods-etc/129819>\
**Category:** IronRuby\
**Created:** [February 21, 2008, 7:51pm UTC](https://www.ruby-forum.com/t/extension-methods-etc/129819 "2008-02-21T19:51:40Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![xjivan](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/x/6f9a4e/32.png) [@xjivan](https://www.ruby-forum.com/u/xjivan)\
**Post date:** [February 21, 2008, 7:51pm UTC](https://www.ruby-forum.com/t/extension-methods-etc/129819/1 "2008-02-21T19:51:40Z")

</div>

Hi

As you’ve probably seen before I’d like to write a couple of articles  
that  
show how to use ironruby with a couple of .NET ORMS but in the process  
of  
writing those I get constantly tripped up.

When I have to pass a type parameter it looks like it loses some of it’s  
inheritance information at least that is the case with lightspeed. I can  
do  
without LightSpeed so atm this is no problem for me

When I want to use Linq 2 Sql I need to pass a type of block Func\<T,  
bool\>  
to the where expression db.categories.where {|c| puts c.name }  
But IronRuby doesn’t like it that much. So the question is how exactly  
do I  
use System::Enumberable.Where etc?

I haven’t gone further trying other ORM’s yet.

Thanks  
Ivan
