Class: Throne::StringWithRevision

Inherits:
String
  • Object
show all
Defined in:
lib/throne/database.rb

Overview

Extended string, to store the couch revision

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(id, rev) ⇒ StringWithRevision

Returns a new instance of StringWithRevision.



123
124
125
126
# File 'lib/throne/database.rb', line 123

def initialize(id, rev)
  @revision = rev
  super(id)
end

Instance Attribute Details

#revisionObject (readonly)

Couch revision ID



121
122
123
# File 'lib/throne/database.rb', line 121

def revision
  @revision
end