Class: OsCtld::DB::Pools
Instance Attribute Summary
Attributes inherited from List
Instance Method Summary collapse
Methods inherited from List
#add, #contains?, #count, #each, #find, #get, instance, #remove, #sync
Instance Method Details
#get_or_default(name) ⇒ Object
13 14 15 16 17 18 19 20 21 22 |
# File 'lib/osctld/db/pools.rb', line 13 def get_or_default(name) sync do if name find(name) else objects.first end end end |