<postmodern>
has the coercion layer been split out of virtus yet?
<postmodern>
if not, im thinking of writing a really basic one
<postmodern>
this time using a from => to hash table of sorts
<postmodern>
where each from class, has a hash of to classes, and lambdas that handle the coercion
<postmodern>
this would allow for very configurable coercion rules
<postmodern>
maybe even use the === operator to match the object with the class
<postmodern>
that way you could even register regexps
<postmodern>
scratch the === idea, that is really only useful for Strings
<postmodern>
well i guess you could use === to define case/when like matchers
<postmodern>
rules[(1..100)][Float] = ...
<postmodern>
oh also forgot that procs respond to #===, handy :)
<postmodern>
also #[], which makes for some nice mixing of finite-domain hashes and full-domain lambdas
ShaneD has joined #rom-rb
breakingthings has quit [Ping timeout: 264 seconds]
skade has joined #rom-rb
<ShaneD>
I haven't checked in on this project yet. I was planning on doing a data mapper pattern presentation at my office for a dev lunch next week and wanted to know if any adapters for ROM are usable enough to test yet, even the memory adapter or mongo adapter?
<postmodern>
right you did split the coercion layer out into coercible
<postmodern>
ShaneD, i believe the postgres adapter supports some read queries
<postmodern>
ShaneD, of course there's always the memory adapter :)
<ShaneD>
That might work, I'll check it out. Tried it a few weeks ago and it didn't work. I was hoping to just do something really simple and show how easily you could change persistence strategies doing something like this.
breakingthings has joined #rom-rb
skade has quit [Quit: Computer has gone to sleep.]
breakingthings has quit [Ping timeout: 272 seconds]
<postmodern>
yeah solnic said they are working on a new SQL generator
ShaneD has quit [Ping timeout: 264 seconds]
skade has joined #rom-rb
breakingthings has joined #rom-rb
solnic has joined #rom-rb
lgierth has joined #rom-rb
mcls has joined #rom-rb
lgierth has quit [Quit: Ex-Chat]
skade has quit [Quit: Computer has gone to sleep.]
mcls has quit [Quit: Computer has gone to sleep.]
mcls has joined #rom-rb
cored has joined #rom-rb
postmodern has quit [Quit: Leaving]
skade has joined #rom-rb
mkristian has joined #rom-rb
mkristian has quit [Quit: bye]
skade has quit [Quit: Computer has gone to sleep.]
skade has joined #rom-rb
skade has quit [Quit: Computer has gone to sleep.]
skade has joined #rom-rb
skade has quit [Quit: Computer has gone to sleep.]
skade has joined #rom-rb
skade has quit [Read error: Connection reset by peer]