garaio/xapian_db — Issue #26: object-conversion before running the blueprint definitions
Author: senny
Created: 2012-01-03 12:51:07+00:00
State: open

We are using the `Decorator-Pattern` to extract formatting functionality from the models. It should somehow be possible to run the blueprints against a different object than the ones returned from the database:

```ruby
XapianDb::DocumentBlueprint.setup :Person do |b|
b.conversion { |person| PersonDecorator.new(person) }
end
```

the snippet above would be sufficient for our needs but probably it would be better if there was a general way to index fields, which aren't directly defined on the model-class itself.