I'd actually use the InMemoryAdapter as a basis to work from.  It just keeps 
everything in core ruby data structures, so it's easy to follow and swap out 
the code with your own implementation.

https://github.com/datamapper/dm-core/blob/master/lib/dm-core/adapters/in_memory_adapter.rb

To see examples of doing query build etc, look at others, yep :)


Il giorno 03/ago/2012, alle ore 22:32, Markus Schirp ha scritto:

> The best documentation are existing adapters.
> 
> An adapter that is easy to follow (IMHO) is the dm-mongo-adapter.
> 
> You can find it under https://github.com/solnic/dm-mongo-adapter.
> 
> The RDBMS adapters are a littlebit more complex to understand as they are 
> implemented on the abstract dm-do-adpater. But when you whant to start an 
> RDBMS adapter you should built it on top of dm-do-adpater.
> 
> Regards,
> 
> Markus
> 
> On 08/03/2012 02:11 PM, Greg wrote:
>> Hi all
>> 
>> I'm looking to create a new adapter for DataMapper. Is there a template
>> that I can use as a starting point, or a document that I can refer to
>> that explains the process?
>> 
>> Thanks
>> Greg
>> 
>> --
>> You received this message because you are subscribed to the Google
>> Groups "DataMapper" group.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msg/datamapper/-/0uQwrnm8URMJ.
>> To post to this group, send email to datamapper@googlegroups.com.
>> To unsubscribe from this group, send email to
>> datamapper+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/datamapper?hl=en.
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "DataMapper" group.
> To post to this group, send email to datamapper@googlegroups.com.
> To unsubscribe from this group, send email to 
> datamapper+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/datamapper?hl=en.
> 

-- 
You received this message because you are subscribed to the Google Groups 
"DataMapper" group.
To post to this group, send email to datamapper@googlegroups.com.
To unsubscribe from this group, send email to 
datamapper+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/datamapper?hl=en.

Reply via email to