This repository is private.
All pages are served over SSL and all pushing and pulling is done over SSH.
No one may fork, clone, or view it unless they are added as a member.
Every repository with this icon (
) is private.
Every repository with this icon (
This repository is public.
Anyone may fork, clone, or view it.
Every repository with this icon (
) is public.
Every repository with this icon (
Sam Pohlenz (author)
Sun Oct 04 21:32:52 -0700 2009
recliner /
| name | age | message | |
|---|---|---|---|
| |
.gitignore | ||
| |
LICENSE | ||
| |
README.md | ||
| |
Rakefile | ||
| |
VERSION | ||
| |
features/ | ||
| |
lib/ | ||
| |
play.rb | ||
| |
recliner.gemspec | ||
| |
spec/ | ||
| |
vendor/ |
README.md
Recliner
Recliner is a Ruby ORM for interfacing with CouchDB databases.
It is designed to be familiar to users of ActiveRecord and DataMapper, but diverges where necessary to fit with the CouchDB document/view paradigm.
Installation
Recliner is distributed as a gem. Install with:
gem install recliner
Sample Usage
require 'recliner'
Recliner::Document.use_database 'http://localhost:5984/my-database-location'
class Article < Recliner::Document
property :title, String, :default => 'Untitled'
property :body, String
property :published_at, Time, :protected => true
property :approved, Boolean, :default => false, :protected => true
timestamps!
validates_presence_of :title, :body
has :author, :class_name => 'User'
default_order :published_at
view :by_title, :order => :title
view :approved, :conditions => { :approved => true }
end








