class Foo include MongoMapper::Document plugin Joint attachment :image attachment :pdf end
By declaring these two attachments, you automagically get accessors for
Tempfile, etc) and the getter methods return a
GridIO type from the Ruby driver.
John even throws in some nifty proxy goodness:
doc.image.id doc.image.size doc.image.type doc.image.name