Sha256: ccf06403d01da5bf6464bf3e0f80241301e11c3732d8d01b84d50a209b3b713f

Contents?: true

Size: 258 Bytes

Versions: 6

Compression:

Stored size: 258 Bytes

Contents

$data ||= {}

class AdminsDAO
  include SmartIoC::Iocify

  bean :dao, instance: false

  inject :config

  class << self
    def insert(entity)
      config.app_name
      $data[entity.id] = entity
    end

    def get(id)
      $data[id]
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
smart_ioc-0.2.5 spec/smart_ioc/example/admins/repository/admins_dao.rb
smart_ioc-0.2.4 spec/smart_ioc/example/admins/repository/admins_dao.rb
smart_ioc-0.2.3 spec/smart_ioc/example/admins/repository/admins_dao.rb
smart_ioc-0.2.2 spec/smart_ioc/example/admins/repository/admins_dao.rb
smart_ioc-0.2.1 spec/smart_ioc/example/admins/repository/admins_dao.rb
smart_ioc-0.2.0 spec/smart_ioc/example/admins/repository/admins_dao.rb