[Nitro] [ANN] Facets 1.8 (RC)

transfire at gmail.com transfire at gmail.com
Sun Jan 28 19:06:30 EST 2007



On Jan 28, 4:17 pm, "Michael Fellinger" <m.fellin... at gmail.com> wrote:
> On 1/28/07, George Moschovitis <george.moschovi... at gmail.com> wrote:
>
>
>
> > >   require 'facets/core/hash/insert'
>
> > >   klass.ann(:self).insert(:table, [])
> > >   klass.ann!(:self, :table) << info
>
> > ok, will try this...
>
> > > BTW. i'm thinking allowing the notation 'klass.ann(:self).table'. this
>
> > not necessatry from my point of view. I like klass.ann(:self, :table) very
> > much, it looks cleaner to mee too.http://pastie.caboo.se/36290
>
> that is how i implemented them... clean, simple, and really easy to use :)
> had to name them trait though, in order to not collide with facets

almost. annotations provides named key-value pairs. the intent is 
primarily to annotate methods not just an object. so:

  obj.ann name, key => value

so it's a little more complex than your traits implementation.

t.



More information about the Nitro-general mailing list