Sha256: f22de95413cee8e8d2a25281c0bce680cd3b480c1fc799024cca9791dc7e63ce

Contents?: true

Size: 829 Bytes

Versions: 28

Compression:

Stored size: 829 Bytes

Contents

class User < CouchRest::Model::Base
  # Set the default database to use
  use_database DB
  property :name, :accessible => true
  property :admin                     # this will be automatically protected
end

class SpecialUser < CouchRest::Model::Base
  # Set the default database to use
  use_database DB
  property :name                      # this will not be protected
  property :admin, :protected => true
end

# There are two modes of protection
#  1) Declare accessible poperties, assume all the rest are protected 
#    property :name, :accessible => true
#    property :admin                     # this will be automatically protected
#
#  2) Declare protected properties, assume all the rest are accessible
#    property :name                      # this will not be protected
#    property :admin, :protected => true

Version data entries

28 entries across 28 versions & 4 rubygems

Version Path
couchrest_model-2.2.0.beta2 spec/fixtures/models/user.rb
couchrest_model-2.2.0.beta1 spec/fixtures/models/user.rb
couchrest_model-2.1.0.rc1 spec/fixtures/models/user.rb
couchrest_model-2.1.0.beta2 spec/fixtures/models/user.rb
couchrest_model-2.1.0.beta1 spec/fixtures/models/user.rb
couchrest_model-2.0.4 spec/fixtures/models/user.rb
couchrest_model-2.0.3 spec/fixtures/models/user.rb
couchrest_model-2.0.1 spec/fixtures/models/user.rb
couchrest_model-2.0.0 spec/fixtures/models/user.rb
couchrest_model-2.0.0.beta2 spec/fixtures/models/user.rb
couchrest_model-2.0.0.beta spec/fixtures/models/user.rb
couchrest_model-1.2.0.beta spec/fixtures/models/user.rb
openlogic-couchrest_model-1.0.0 spec/fixtures/models/user.rb
couchrest_model-1.1.2 spec/fixtures/models/user.rb
couchrest_model-1.1.1 spec/fixtures/models/user.rb
couchrest_model-1.1.0 spec/fixtures/models/user.rb
couchrest_model-1.1.0.rc1 spec/fixtures/more/user.rb
couchrest_model-1.1.0.beta5 spec/fixtures/more/user.rb
couchrest_model-1.1.0.beta4 spec/fixtures/more/user.rb
couchrest_model-1.1.0.beta3 spec/fixtures/more/user.rb