Module: Access::Savable
Overview
Mixin for classes representing records Requires a method base (Savable creates an accessor to @base) and an #oid method.
Instance Attribute Summary collapse
-
#access ⇒ Object
The Access instance that manages this records base.
-
#base ⇒ Object
The “Base” instance that manages this record.
Instance Method Summary collapse
-
#delete ⇒ Object
delete this record from the database.
-
#save ⇒ Object
save changes to this record.
Instance Attribute Details
#access ⇒ Object
The Access instance that manages this records base
17 18 19 |
# File 'lib/access/savable.rb', line 17 def access @access end |
#base ⇒ Object
The “Base” instance that manages this record
20 21 22 |
# File 'lib/access/savable.rb', line 20 def base @base end |
Instance Method Details
#delete ⇒ Object
delete this record from the database
28 29 30 |
# File 'lib/access/savable.rb', line 28 def delete base.delete(oid()) end |
#save ⇒ Object
save changes to this record
23 24 25 |
# File 'lib/access/savable.rb', line 23 def save base.save(oid()) end |