Module: Interpret
- Defined in:
- lib/interpret.rb,
lib/interpret/engine.rb,
lib/interpret/logger.rb,
lib/interpret/version.rb,
app/models/interpret/ability.rb,
app/models/interpret/translation.rb,
app/helpers/interpret/interpret_helper.rb,
app/models/interpret/expiration_observer.rb,
app/controllers/interpret/translations_controller.rb
Defined Under Namespace
Modules: InterpretHelper
Classes: Ability, BaseController, Engine, ExpirationObserver, InterpretLogger, MissingTranslationsController, SearchController, ToolsController, Translation, TranslationsController
Constant Summary
collapse
- VERSION =
"1.1.2"
- @@parent_controller =
"application_controller"
- @@registered_envs =
[:production, :staging]
- @@soft =
true
- @@black_list =
[]
- @@current_user =
"current_user"
- @@ability =
"interpret/ability"
Class Method Summary
collapse
Class Method Details
.ability ⇒ Object
35
36
37
38
39
40
41
|
# File 'lib/interpret.rb', line 35
def self.ability
unless @@ability.is_a?(Class)
@@ability.classify.constantize
else
@@ability
end
end
|
23
24
25
|
# File 'lib/interpret.rb', line 23
def self.configure
yield self
end
|
.fixed_blacklist ⇒ Object
27
28
29
|
# File 'lib/interpret.rb', line 27
def self.fixed_blacklist
@@black_list.select{|x| !x.include?("*")}
end
|
.wild_blacklist ⇒ Object
31
32
33
|
# File 'lib/interpret.rb', line 31
def self.wild_blacklist
@@black_list.select{|x| x.include?("*")}.map{|x| x.gsub("*", "")}
end
|