Module: Cockpit
- Defined in:
- lib/cockpit/core/settings.rb,
lib/cockpit/core/spec.rb,
lib/cockpit/core/scope.rb,
lib/cockpit/core/store.rb,
lib/cockpit/core/global.rb,
lib/cockpit/core/include.rb,
lib/cockpit/stores/mongo.rb,
lib/cockpit/stores/redis.rb,
lib/cockpit/stores/memory.rb,
lib/cockpit/core/definition.rb,
lib/cockpit/core/view_helper.rb,
lib/cockpit/stores/file_system.rb,
lib/cockpit/stores/active_record.rb
Overview
Defined Under Namespace
Modules: AR, ClassMethods, FileSystem, InstanceMethods, Memory, Mongo, Redis, ViewHelper
Classes: Scope, Settings, Store
Class Method Summary
collapse
Class Method Details
.included(base) ⇒ Object
3
4
5
6
|
# File 'lib/cockpit/core/include.rb', line 3
def self.included(base)
base.extend(ClassMethods)
base.send(:include, InstanceMethods)
end
|
.Settings(*args) ⇒ Object
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
# File 'lib/cockpit/core/global.rb', line 20
def self.Settings(*args)
case args.length
when 0
Cockpit::Settings.global
when 1
case args.first
when Hash
else
Cockpit::Settings[args.first]
end
when 2
Cockpit::Settings[args.first] = args.last
end
end
|