[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Re: Performance hit of define_method

Jon Egil Strand

2/2/2007 9:31:00 AM

4 Answers

Chris Carter

2/2/2007 4:56:00 PM

0

On 2/2/07, Robert Dober <robert.dober@gmail.com> wrote:
> On 2/2/07, Jon Egil Strand <jes@luretanker.no> wrote:
> >
> >
> > <snip>
>
>
> If you are doing this for fun, learning research, than that's just great if
> you need this stuff (and even for fun, learning and research ;) you might
> want to have a look at Facet http://facets.rubyforge.or...
> especially OpenStruct and OpenObject.
>
> Thomas if you are reading this and you are not too busy, why is OpenStruct
> in Core and OpenObject in More? (is the former used much more often?) Just
> curious ;)
>
> Cheers
> Robert
>
>
>
>
> --
> We have not succeeded in answering all of our questions.
> In fact, in some ways, we are more confused than ever.
> But we feel we are confused on a higher level and about more important
> things.
> -Anonymous
>
>

Hi Robert,
It is because OpenStruct is in the ruby standard library, and the
facets OpenStruct is just a set of extensions to it. OpenObject is a
class made by Facets

--
Chris Carter
concentrationstudios.com
brynmawrcs.com

James Gray

2/2/2007 8:06:00 PM

0

On Feb 2, 2007, at 1:56 PM, Robert Dober wrote:

> On 2/2/07, Chris Carter <cdcarter@gmail.com> wrote:
>> It is because OpenStruct is in the ruby standard library,
>
>
> Can you believe that! One never stops learning !!!
> Sorry to correct you it is even in the Core.

I'm not sure if I understood you correctly Robert, but just to be
clear OpenStruct is not a part of Ruby's core. It is a Ruby standard
library. I'm talking about Ruby here, not Facets.

James Edward Gray II


James Gray

2/3/2007 7:02:00 PM

0

On Feb 3, 2007, at 2:34 AM, Robert Dober wrote:

> But I realize that I do not know how to distinguish between Core
> and STL.

If you can use it without a require, it's core Ruby. Array,
Enumerable, and Hash are examples.

If it comes with Ruby (no extra install), but you must require it to
use it, it's a standard library. OpenStruct, Logger, and WEBrick are
examples.

Hope that helps.

James Edward Gray II



dblack

2/3/2007 7:10:00 PM

0