Module: SmartAleck
- Includes:
- Optionally::Required
- Defined in:
- lib/smart_aleck.rb,
lib/smart_aleck/version.rb,
lib/smart_aleck/entry_creator.rb,
lib/smart_aleck/category_indexer.rb,
lib/smart_aleck/finding_viable_peers.rb
Defined Under Namespace
Classes: CategoryIndexer, EntryCreator, FindingViablePeers, NotConfigured
Constant Summary
collapse
- VERSION =
"0.1.0"
Class Method Summary
collapse
Class Method Details
.category_model ⇒ Object
16
17
18
|
# File 'lib/smart_aleck.rb', line 16
def self.category_model
@category_model
end
|
.clear_config! ⇒ Object
29
30
31
|
# File 'lib/smart_aleck.rb', line 29
def self.clear_config!
@entry_model = @category_model = nil
end
|
10
11
12
13
14
|
# File 'lib/smart_aleck.rb', line 10
def self.configure(options)
check_required_options(options, :category_model, :entry_model)
@category_model = options[:category_model]
@entry_model = options[:entry_model]
end
|
.entry_model ⇒ Object
20
21
22
|
# File 'lib/smart_aleck.rb', line 20
def self.entry_model
@entry_model
end
|
24
25
26
27
|
# File 'lib/smart_aleck.rb', line 24
def self.verify_configured
raise NotConfigured unless (category_model && entry_model)
true
end
|